我希望我的应用在图像的“打开方式”选项中。
我在我的 Info.plist 中使用了这段代码
<key>CFBundleDocumentTypes</key>
<array>
<dict>
<key>CFBundleTypeName</key>
<string>Image</string>
<key>LSHandlerRank</key>
<string>Alternate</string>
<key>LSItemContentTypes</key>
<array>
<string>public.image</string>
</array>
</dict>
<dict>
<key>CFBundleTypeName</key>
<string>PNG image</string>
<key>LSHandlerRank</key>
<string>Alternate</string>
<key>LSItemContentTypes</key>
<array>
<string>public.png</string>
</array>
</dict>
<dict>
<key>CFBundleTypeName</key>
<string>JPEG image</string>
<key>LSHandlerRank</key>
<string>Alternate</string>
<key>LSItemContentTypes</key>
<array>
<string>public.jpeg</string>
</array>
</dict>
</array>
在应用程序“收件箱”中,在共享图像时,我可以看到我的应用程序“Quotle”:
但是在 Apple 的应用程序“照片”中,我没有看到我的应用程序:
如何才能在“照片”应用程序的共享菜单中看到我的应用程序?
最佳答案
为了在照片的共享列表中显示您的应用程序,您需要将共享扩展的新目标添加到您的项目中,请引用 document有关如何添加共享扩展的更多信息。
关于ios - 我的 iOS 应用程序不处理所有应用程序中的图像文件类型,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/34874306/