mirror of
https://github.com/gnustep/libs-gui.git
synced 2025-04-26 04:41:10 +00:00
Minor fix to get dnd working with cached bitmaps again.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@5348 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
652cb43876
commit
57d09a0d22
1 changed files with 6 additions and 1 deletions
|
@ -849,6 +849,7 @@ static Class cacheClass = 0;
|
||||||
/*
|
/*
|
||||||
* What's the best representation? FIXME
|
* What's the best representation? FIXME
|
||||||
* At the moment we take the last bitmap we find.
|
* At the moment we take the last bitmap we find.
|
||||||
|
* If we can't find a bitmap, we take whatever we can!
|
||||||
*/
|
*/
|
||||||
[_reps getObjects: reps];
|
[_reps getObjects: reps];
|
||||||
for (i = 0; i < count; i++)
|
for (i = 0; i < count; i++)
|
||||||
|
@ -859,6 +860,10 @@ static Class cacheClass = 0;
|
||||||
{
|
{
|
||||||
rep = repd->rep;
|
rep = repd->rep;
|
||||||
}
|
}
|
||||||
|
else if (rep == nil)
|
||||||
|
{
|
||||||
|
rep = repd->rep;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return rep;
|
return rep;
|
||||||
|
@ -867,7 +872,7 @@ static Class cacheClass = 0;
|
||||||
- (NSImageRep*) cacheForRep: (NSImageRep*)rep
|
- (NSImageRep*) cacheForRep: (NSImageRep*)rep
|
||||||
onDevice: (NSDictionary*)deviceDescription
|
onDevice: (NSDictionary*)deviceDescription
|
||||||
{
|
{
|
||||||
if (NSImageDoesCaching == YES)
|
if (NSImageDoesCaching == YES && [rep isKindOfClass: cacheClass] == NO)
|
||||||
{
|
{
|
||||||
NSImageRep *cacheRep = nil;
|
NSImageRep *cacheRep = nil;
|
||||||
unsigned count = [_reps count];
|
unsigned count = [_reps count];
|
||||||
|
|
Loading…
Reference in a new issue