On Thu, 06 Oct 2005 11:19:22 +0000, Richard wrote: > On 2005-10-06 10:11:53 +0000 Chris Vetter <[EMAIL PROTECTED]> wrote: > > I actually played around with NSWorkspaceWillPowerOffNotification last > > night by posting this notification in one application, explicitly > > listening for it in another and a third without a listener. > > Neither of the three applications got a -applicationShouldTerminate: > The -applicationShouldTerminate: message is supposed to be sent to the > application's delegate by the -terminate method. > My reading of it is that it's your responsibility as a developer to have > your code listen for the notification and call [NSApp -terminate] when > you receive it. I don't think the gui/AppKit does that for you.
Yes, GNUstep's AppKit doesn't and I don't think it should. However, think about a workspace / desktop application, like GWorkspace or OpenSpace. They usually offer something like "Log out" -- sending a "power off" note would be the only *clean* way of letting other applications know that the user is about to log out (ie. terminate the workspace, which would normally result in 'killing' everything else unless you still would have to 'shut down' the window manager) Or, again, use -launchedApplications, then iterate through the array and try sending a termination. > Did you try this on MacOS-X? It would be interesting to know how it > actually behaves. No, GNUstep on FreeBSD (as usual ;-) -- Chris -- 5 GB Mailbox, 50 FreeSMS http://www.gmx.net/de/go/promail +++ GMX - die erste Adresse für Mail, Message, More +++ _______________________________________________ Discuss-gnustep mailing list [email protected] http://lists.gnu.org/mailman/listinfo/discuss-gnustep
