cartool
cartool copied to clipboard
AppIcon doesn't work
This tool can't extract AppIcon.
Instead of:
for (NSNumber *scaleFactor in @[@1, @2, @3])
{
CUINamedImage *image = [catalog imageWithName:key scaleFactor:scaleFactor.doubleValue];
if (image && image.scale == scaleFactor.floatValue) [images addObject:image];
}
I tried simply:
[images addObjectsFromArray:[catalog imagesWithName:key]];
In my one test, this added 23 images to the array, which are of type CUINamedMultisizeImageSet.h , which doesn't respond to -size, and therefore crashes on CGSizeEqualToSize(image.size, CGSizeZero). Looks like this type is new in iOS 11 (it's not present in the iOS 10 runtime headers).
So if we want to make this work we'll have to add support for this type.