4

I updated to iOS 13 and now my app won't show up in the new "Open In..."-dialogs anymore. I previously did the following to get my app to show up there, if the opened file was a .plist file:

  1. I edited the Info.plist like in the screenshot below.
  2. In the AppDelegate I use
func application(_ app: UIApplication, open url: URL, options: [UIApplication.OpenURLOptionsKey : Any] = [:]) -> Bool {}

to handle the given file.

Any ideas what could've changed or what I might have accidentally changed so that it isn't working anymore? As far as I know I followed the steps provided by Apple correctly.

Edit: Could it be that they changed something so that I have to do something different, because .plist is maybe a known filetype and not a custom one?

Edit 2: I discovered that it works if I change "plist" to something else. I tried replacing it with "test" and send a file called "abc.test" to my phone and it showed my app to open it.

Edit 3: In XML it looks like this:

<key>CFBundleDocumentTypes</key>
    <array>
        <dict>
            <key>CFBundleTypeIconFiles</key>
            <array/>
            <key>CFBundleTypeName</key>
            <string>Plist File</string>
            <key>CFBundleTypeRole</key>
            <string>Editor</string>
            <key>LSHandlerRank</key>
            <string>Owner</string>
            <key>LSItemContentTypes</key>
            <array>
                <string>rtm.plist</string>
            </array>
        </dict>
    </array>

<key>UTExportedTypeDeclarations</key>
    <array>
        <dict>
            <key>UTTypeConformsTo</key>
            <array>
                <string>public.data</string>
            </array>
            <key>UTTypeDescription</key>
            <string>Plist File</string>
            <key>UTTypeIconFiles</key>
            <array/>
            <key>UTTypeIdentifier</key>
            <string>rtm.plist</string>
            <key>UTTypeTagSpecification</key>
            <dict>
                <key>public.filename-extension</key>
                <array>
                    <string>plist</string>
                </array>
            </dict>
        </dict>
    </array>

Edit 4: If I just put "public.data" as the document type my app gets shown and my code works. But I only want it to be shown for plist-files.

Edit 5: I removed all Document Types and UTIs and just added "public.plist" as a Document Type and now it works. Seems that you can't use own UTIs with common file types anymore.

enter image description here

LarsGvB
  • 267
  • 3
  • 11
  • Unless you've completely opted out of using scenes (which you should not do), you should implement the corresponding UISceneDelegate method. – rmaddy Oct 08 '19 at 20:46
  • @rmaddy Shouldn't my app still be shown without that, but the calls run into nowhere? – LarsGvB Oct 08 '19 at 20:51

1 Answers1

3

Ran into the same issue.

In my case the fix was --> change public.item to public.data.

And my app magically reappeared in the open-in menu.

vomi
  • 993
  • 8
  • 18
  • I already had it set to „public.data“. See my last edit on how i fixed it for me. – LarsGvB Oct 11 '19 at 13:59
  • 1
    I know, but my problem was just slightly different, because I was using public.item which is supposedly covering public.data. Your answer helped me very much figuring this issue. Thanks. – vomi Oct 12 '19 at 08:46