Thanks, Riccardo and Fred.
I will take a look asap. Currently, I have different issues with the SVN
trunk from Saturday eve. I'll come back with that in a different thread,
though.

Andreas

Am 25.08.2011 17:22, schrieb Riccardo Mottola:
> Hi,
> 
>> Unfortunately, image is never nil. If no thumbnail file exists, an
>> NSImage object is returned which contains no representations (check
>> class NSBitmapImageRep, +imageRepsWithData:). Hence, no image is
>> displayed, not even the one for unknown file types.
>>
> Perhaps this has to do with multiple representations: imageRepWithData
> returns NIL imageRepsWithData returns an empty array.
> 
> initWithContentsOfFile says though:
> 
> (from Cocoa Docs)
> 
> Return Value
> 
> An initialized NSImage instance, or nil if the method cannot create an
> image representation from the contents of the specified file.
> 
> I think the culprit is _loadFromFile: it checks that the array is not
> nil, instead it should check that the array is not empty.
> 
> I patched that, I dont't seem to have caused havoc elsewhere, please try
> if it solves your problem.
> 
> Riccardo
> 
> _______________________________________________
> Discuss-gnustep mailing list
> [email protected]
> https://lists.gnu.org/mailman/listinfo/discuss-gnustep


Attachment: signature.asc
Description: OpenPGP digital signature

_______________________________________________
Discuss-gnustep mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/discuss-gnustep

Reply via email to