I am trying to implement the registering process that allows my iOS app to show up in the "Open in" list of other applications (as described in Apple's Document Interaction Programming Topics). I want my app to be able to handle audio from any app that will provide a standard audio file format (MP3, AIFF, WAV, etc.).
As I understand it, all I should need to do is add the CFBundleDocumentTypes
key, with relevant subdata, to my app's Info.plist. This is what I put in (via Xcode 4's Document Types editor):
<key>CFBundleDocumentTypes</key>
<array>
<dict>
<key>CFBundleTypeIconFiles</key>
<array>
<string>scrubbulator-icon</string>
</array>
<key>CFBundleTypeName</key>
<string>Audio</string>
<key>LSHandlerRank</key>
<string>Alternative</string>
<key>LSItemContentTypes</key>
<array>
<string>public.mp3</string>
</array>
</dict>
</array>
The addition of this code is not displaying my app in apps' "Open in" menu (I am testing on an iPhone, using an MP3 in Dropbox as the file source. The apps AudioMemos and Evernote are both displayed for an MP3 file in Dropbox, so I know the format is supported). Is there something obvious I'm doing wrong, or is there something else I need to implement?
(Note: I have not set up a UTExportedTypeDeclarations
item in my Info.plist, as I understand these to be necessary only for custom UTIs. As I'm using System UTIs I believe it shouldn't be necessary, but please correct me if I am wrong.)
EDIT
I've added the following Exported Type UTI, with no success:
<key>UTExportedTypeDeclarations</key>
<array>
<dict>
<key>UTTypeConformsTo</key>
<array>
<string>kUTTypeMP3</string>
</array>
<key>UTTypeDescription</key>
<string>Audio file</string>
<key>UTTypeIdentifier</key>
<string>kUTTypeMP3</string>
<key>UTTypeTagSpecification</key>
<dict>
<key>public.filename-extension</key>
<array>
<string>mp3</string>
</array>
</dict>
</dict>
</array>
You should use
Alternate
instead ofAlternative
For all standard file format: