Apple Events and Modal Sessions
Apple Events and Modal Sessions
- Subject: Apple Events and Modal Sessions
- From: Seth Willits <email@hidden>
- Date: Wed, 28 Jan 2009 21:50:39 -0800
I'm fiddling with a URL handler in my app and I noticed that if a
modal session was running, the handler - registered with my NSApp's
delegate - was not being called, even after the dialog closed. I
looked around the docs for a bit to find a reason/workaround and
discovered by chance that if I simply made the window's controller
object the AE handler, then it worked; when the dialog is open, the
handler is called. If the AE handler is NSApp's delegate, it doesn't.
I can't figure out *why* this happening though. All I do is call
[NSApp runModalForWindow:window], so it's not as if the controller
object is the delegate of the modal session and thus somehow something
behind the scenes lets AEs fire. The controller isn't even the
delegate of the window.
Does anyone know what's really going on here? Should AppleEvents
always be firing during a modal session?
--
Seth Willits
_______________________________________________
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