Looks like building with the new SDK adds an automatic ‘Open' menu item to Mac Catalyst, and it doesn't look like there’s a public API menu identifier to remove it 😑
Hopper time.
Looks like building with the new SDK adds an automatic ‘Open' menu item to Mac Catalyst, and it doesn't look like there’s a public API menu identifier to remove it 😑
Hopper time.
And the solution is:
builder.remove(menu: UIMenu.Identifier("com.apple.menu.open"))
Come on, folks. Export your symbols.
@stroughtonsmith Another solution (other than removing it via the UIKit code you suggested) is to embrace it by implementing `@IBAction func open(_ sender: AnyObject?)` on your AppDelegate.
I submitted a handful of feedbacks including FB14662087 on this one but they didn't get anywhere.
@cocoawithlove Hi, Matt. Your approach works fine for my Catalyst app on Mac. On iPad, though, it crashes the app with a "duplicate command” error:
"Menu has duplicates --
<_UIImmutableKeyCommand: 0x10496e940> -> Title: Open... Action: open: Input: o + (UIKeyModifierCommand)
<UIKeyCommand: 0x10496fd40> -> Title: Open... Action: open: Input: o + (UIKeyModifierCommand)”
I presume my open: implementation adds the 2nd UIKeyCommand. I can't find a way to remove or override the 1st, though.