问题
Xcode 7 has warnings for my launch image set. It reads:
The launch image set "LaunchImage" references a file "Default@2x.PNG", but that file does not have a valid extension.
I tried removing the image and put it back again with no luck. What is it warning about and how can I fix it?
回答1:
Try changing Default@2x.png
instead of Default@2x.PNG
.
回答2:
In Xcode 7 if you apply an extension that is uppercase like .PNG
or .JPG
, you will get a warning related to 'invalid extension'.
This problem is .PNG
, turning it to lowercase can fix this warning on image files like .jpg and .png.
Hope that helps!
回答3:
If you have the file Image.PNG
, convert it into Image.png
, and if you have the file extension Image.JPG
, convert it into Image.jpg
.
Make sure your images have extension with lowercase letters, not capital letters. Hope this will help!
回答4:
Can't comment, yet found this helpful:
After renaming the image's extension name to lowercase the warning goes away
(as explained in the accepted answer: .PNG
->
.png
)
If the warning doesn't go away, clean the project by going to
Product
->
Clean
(or just: Shift + CMD + K)
来源:https://stackoverflow.com/questions/32632577/xcode-7-warning-the-launch-image-does-not-have-a-valid-extension