I have developed a daemon that have an Objective-C class "ApplicationWatcher" which checks the foreground applications with NSWorkspace.

In my main I create the ApplicationWatcher, and the class starts an NSTimer. This is probably a stupid question, but I want the daemon to continue running, but at the end of main the daemon quit, even if I have an NSTimer running.
So what should I do in main to have the daemon running?

In an ordinary Cocoa application the main contains "return NSApplicationMain(argc, (const char **) argv);", but as this is a daemon I can't call this.

Ivan
_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

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:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to [EMAIL PROTECTED]

Reply via email to