Prevent iCloud window from opening on OSX 10.8 app launch
I have written an OSX app that uses iCloud document storage. Whenever I open it in Mountain Lion (not on Lion), an iCloud window opens that looks like the following:
Is there a way to prevent this from happening on launch?
applicationShouldOpenUntitledFile: is not getting called (yes, I’m sure I’m listening in my delegate.
2) If I force quit the app, the next time it opens, I don’t get the dialog. But, if I go through the normal Quit process, it does appear.
Update 2 (also added as an answer, to help people that may stumble across this question in the future):
applicationShouldOpenUntitledFile: from the duplicate question was not working. After lots of experimentation, I figured out that if I remove the
NSDocumentClass key and value from my Info.plist in the
CFBundleDocumentTypes array, the window is no longer opened. I’ve added that answer to the duplicate question as well.
- How to identify/mark OS X app instance
- Count colors in image: `NSCountedSet` and `colorAtX` are very slow
- Using frameworks in a command line tool
- Core Data: NSCocoaErrorDomain=134040 Only Occurs On Real Phone, Not Simulator
- NSString to NSArray
- An id conforming to the protocol vs Qualify an id with a protocol
Solutions Collect From Internet About “Prevent iCloud window from opening on OSX 10.8 app launch”
applicationShouldOpenUntitledFile: from iCloud enabled – Stop the open file displaying on application launch? was not working. After lots of experimentation, I figured out that if I remove the
NSDocumentClass key and value from my
Info.plist in the
CFBundleDocumentTypes array, the window is no longer opened.
- Disable Xcode 8 code completion for image name
- Make UITableView scrollable by index
- Best way to switch View Controller in iOS
- Xcode – Debugging a unit test target
- What is difference between “?” and “!” in Swift?
- Printing NSManagedObject subclassed Core Data object to console returns empty line in Swift
- how to simplify and make it better using enum, swift learning, enum
- How to convert UIColor to HEX and display in NSLog
- Best practices for overriding isEqual: and hash
- Xcode 4.5.1 get stuck when archiving
- Objective C Adding a Contact to a specific Group in the iPhone
- In Xcode Interface Builder – why are the options in the Editor—>Arrange menu (containing Send to Front, Send to Back) often disabled?
- How to add buttons when NSVisualEffectView is used
- Keyboard loses hiding ability “if I use a UIAlertView”
- Memory leak in NSString stringWithUTF8String