Re: how to terminate the application?
Re: how to terminate the application?
- Subject: Re: how to terminate the application?
- From: "stephen joseph butler" <email@hidden>
- Date: Sat, 10 Feb 2007 06:22:18 -0600
2007/2/10, Silicon <email@hidden>:
In my controller, I treat the File's owner as an outlet of my
controller, which named theApp.
I draw a connection from my controller's theApp outlet to the file's
owner;
Then if the user clicks a button, I send the message to [theApp
terminate], however it doesnt work-the application is still running.
What's wrong? Can someone tell me how should I accomplish this task?
This is all unnecessary because AppKit provides a global variable called NSApp.
Also, it's "terminate:", not "terminate". Call [NSApp terminate:nil]
from anywhere inside your main thread.
_______________________________________________
Cocoa-dev mailing list (email@hidden)
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