NSSavePanel problem with sandboxing
NSSavePanel problem with sandboxing
- Subject: NSSavePanel problem with sandboxing
- From: Graham Cox <email@hidden>
- Date: Thu, 05 Sep 2013 20:27:13 +0200
I'm using NSSavePanel in a sandboxed app. The panel includes a custom accessory view, which works fine.
I run the panel using -[NSSavePanel beginSheetModalForWindow:completionHandler:];
In the completion handler, I call [savePanel makeFirstResponder:savePanel] so that any text fields left in a 'pending' state commit their contents to update the stuff they set via action methods. This is the usual way I commit unsaved fields in any dialog or sheet, and that's always worked.
This also works, except on 10.7 (10.6 and 10.8 seem OK). On 10.7, I get an exception: -[NSRemoteSavePanel makeFirstResponder:]: unrecognized selector sent to instance. The documentation for sandboxing suggests that this is likely to be the case, though I've read somewhere that the full NSPanel methods are available at some well-defined times (I can't however find the documentation that mentions that, and whether the completion handler is one of the sanctioned times).
What can I do here to workaround this?
--Graham
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden