I have an ASObjC application with a custom view class. So there are two scripts: the app delegate and the custom view class. When the app starts the following actions are invoked in the following order:
If there is a problem with the files needed for the app, I could determine that in the initWithFrame action and abort the launch, but the first action that responds to a quit command is the applicationWillFinishLaunching action. Hence, I end up building the whole UI and then quitting. I can loop around the contents of the first three actions, but that seems silly. Obviously, there is a another way.
What I mean is that the only handler in which the old-fashioned AppleScript quit works is applicationWillFinishLaunching_. Whereas, in previous efforts,
current application’s terminate_(current application)
or current application’s terminate_(me)
or current application’s applicationShouldTerminate_(current application)
or current application’s applicationShouldTerminate_(me)
does nothing ” not even generate an error ” no matter which handler I put it in.
Incidentally, it is really cool of you to provide all this help to fools like me. Thanks.