Hi Bryan,
i work with CW 8.3 to, but it works fine (most of the time).
Is it a Mach-0 Target, do you use Carbon-Events?
Gruß Chris
> I have a PP project that is working fine under Panther, but under Tiger
> it is not receiving the quit AppleEvent when the application is shut
[quoted text clipped - 7 lines]
>
> Bryan
Bryan Christianson - 28 Jun 2005 08:38 GMT
> Hi Bryan,
>
[quoted text clipped - 14 lines]
> >
> > Bryan
It is a Mach-0 target using WNE. I just did a test and found I can write
an AppleScript to Quit the application OK. It just doesnt get the
AppleEvent that should be generated by the Quit menu item.
James W. Walker - 28 Jun 2005 17:10 GMT
> It is a Mach-0 target using WNE. I just did a test and found I can write
> an AppleScript to Quit the application OK. It just doesnt get the
> AppleEvent that should be generated by the Quit menu item.
Is it possible that you are getting the kHICommandQuit Carbon Event?
(Just because you're using WNE doesn't mean that you don't have any
Carbon Event handlers.)
Bryan Christianson - 28 Jun 2005 22:59 GMT
> > It is a Mach-0 target using WNE. I just did a test and found I can write
> > an AppleScript to Quit the application OK. It just doesnt get the
[quoted text clipped - 3 lines]
> (Just because you're using WNE doesn't mean that you don't have any
> Carbon Event handlers.)
I dont think thats the case unless a default handler is being inserted
somehow. As I said, if I send a 'quit' from AppleScript and as I have
just found, use the Quit selection from the Dock popup menu, then the
apple event is sent and handled correctly.

Signature
Bryan
> I have a PP project that is working fine under Panther, but under Tiger
> it is not receiving the quit AppleEvent when the application is shut
[quoted text clipped - 7 lines]
>
> Bryan
Problem solved - thanks for the pointers guys.
I setup a Carbon event handler (although this a WNE application) and it
seems to do the trick
static OSStatus quit_handler(EventHandlerCallRef inHandlerCallRef,
EventRef inEvent, void *inUserData) {
CAppearanceApp *app = (CAppearanceApp *)inUserData;
app->DoQuit();
return(0);
}
voidCAppearanceApp::SetupQuitHandler(void) {
EventHandlerUPP handler;
EventTypeSpec eventList = { kEventClassApplication,
kEventAppQuit };
handler = NewEventHandlerUPP(quit_handler);
InstallEventHandler(
::GetApplicationEventTarget(), handler, 1, &eventList, this,
NULL);
}
James W. Walker - 29 Jun 2005 05:49 GMT
> Problem solved - thanks for the pointers guys.
For the record, what exactly was the circumstance in which you did not
get the quit AppleEvent? In one message you said "shut down", leading
me to think you were talking about the computer shutting down, and in
another message you mentioned the Quit menu item.
Bryan Christianson - 29 Jun 2005 12:39 GMT
> > Problem solved - thanks for the pointers guys.
>
> For the record, what exactly was the circumstance in which you did not
> get the quit AppleEvent? In one message you said "shut down", leading
> me to think you were talking about the computer shutting down, and in
> another message you mentioned the Quit menu item.
Oh - sorry about the ambiguity. The problem was occurring when selecting
the Quit menu item from the application menu.