lcl: TImage: check Picture.Graphic existence before setting it Transparency

git-svn-id: trunk@16389 -
This commit is contained in:
paul 2008-09-03 13:46:55 +00:00
parent 87854c957c
commit 67ef0cd399

View File

@ -123,7 +123,7 @@ procedure TCustomImage.SetTransparent(Value : Boolean);
begin
if FTransparent=Value then exit;
FTransparent := Value;
if (FPicture.Graphic.Transparent <> FTransparent)
if (FPicture.Graphic <> nil) and (FPicture.Graphic.Transparent <> FTransparent)
then FPicture.Graphic.Transparent := FTransparent
else PictureChanged(Self);
end;