I am trying to create an application that will receive multimedia files from the Mail application using Long Press> Open in "My app"
I'm having trouble linking the file types I want with my application. I use Unified Type Identifier Identifier
This is what my info.plist looks like:
<key>CFBundleDocumentTypes</key> <array> <dict> <key>CFBundleTypeExtensions</key> <array> <string>mp3</string> </array> <key>CFBundleTypeName</key> <string>MP3 Audio</string> <key>CFBundleTypeRole</key> <string>Viewer</string> <key>LSHandlerRank</key> <string>Alternate</string> <key>LSItemContentTypes</key> <array> <string>public.mp3</string> </array> <key>LSTypeIsPackage</key> <false/> </dict> <dict> <key>CFBundleTypeExtensions</key> <array> <string>avi</string> </array> <key>CFBundleTypeName</key> <string>AVI movie</string> <key>LSHandlerRank</key> <string>Alternate</string> <key>CFBundleTypeRole</key> <string>Viewer</string> <key>LSItemContentTypes</key> <array> <string>public.avi</string> <string>video/x-msvideo</string> </array> <key>LSTypeIsPackage</key> <false/> </dict> <dict> <key>CFBundleTypeExtensions</key> <array> <string>3gp</string> </array> <key>CFBundleTypeName</key> <string>3GPP movie</string> <key>LSHandlerRank</key> <string>Alternate</string> <key>CFBundleTypeRole</key> <string>Viewer</string> <key>LSItemContentTypes</key> <array> <string>public.3gpp</string> <string>application/octet-stream</string> </array> <key>LSTypeIsPackage</key> <false/> </dict> <dict> <key>CFBundleTypeExtensions</key> <array> <string>mpg4</string> <string>mp4</string> <string>m4v</string> </array> <key>CFBundleTypeName</key> <string>MPEG-4 content</string> <key>LSHandlerRank</key> <string>Alternate</string> <key>CFBundleTypeRole</key> <string>Viewer</string> <key>LSItemContentTypes</key> <array> <string>public.mpeg-4</string> <string>video/mp4</string> <string>video/mp4v</string> </array> <key>LSTypeIsPackage</key> <false/> </dict> <dict> <key>CFBundleTypeExtensions</key> <array> <string>mov</string> </array> <key>CFBundleTypeName</key> <string>QuickTime movie</string> <key>LSHandlerRank</key> <string>Alternate</string> <key>CFBundleTypeRole</key> <string>Viewer</string> <key>LSItemContentTypes</key> <array> <string>com.apple.quicktime-movie</string> <string>video/quicktime</string> </array> <key>LSTypeIsPackage</key> <false/> </dict> </array>
Of these, only Mp3 and AVI show the Open In "My app" option. I just get the option "Save Video", which adds the video to the camera roll. What am I doing wrong?
The formats I want to link are: AVI, 3GP, MP4, M4V, MOV.
I also tried this. It works for MP3, WAV, AVI, FLV, but still not suitable for 3GP, MP4, MOV, M4V
<key>CFBundleDocumentTypes</key> <array> <dict> <key>CFBundleTypeName</key> <string>Audio</string> <key>CFBundleTypeRole</key> <string>Editor</string> <key>LSItemContentTypes</key> <array> <string>public.audio</string> </array> </dict> <dict> <key>CFBundleTypeName</key> <string>Video</string> <key>CFBundleTypeRole</key> <string>Editor</string> <key>LSItemContentTypes</key> <array> <string>public.movie</string> </array> </dict> </array>
source share