mirror of
https://github.com/gnustep/libs-gui.git
synced 2025-05-30 19:20:37 +00:00
* Source/NSImage.m (-bestRepresentationForDevice:): Fix last
change for the case where there are no representations for the image. git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@34168 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
5cc268b1b4
commit
c387e7ad6e
2 changed files with 15 additions and 1 deletions
|
@ -1502,7 +1502,16 @@ static NSSize GSResolutionOfImageRep(NSImageRep *rep)
|
|||
}
|
||||
}
|
||||
}
|
||||
return [reps objectAtIndex: 0];
|
||||
|
||||
|
||||
if ([reps count] > 0)
|
||||
{
|
||||
return [reps objectAtIndex: 0];
|
||||
}
|
||||
else
|
||||
{
|
||||
return nil;
|
||||
}
|
||||
}
|
||||
|
||||
- (NSImageRep *) bestRepresentationForRect: (NSRect)rect
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue