Re: Threading and NSApplicationMain()
Re: Threading and NSApplicationMain()
- Subject: Re: Threading and NSApplicationMain()
- From: Nick Zitzmann <email@hidden>
- Date: Tue, 12 Sep 2006 23:24:31 -0600
On Sep 12, 2006, at 10:51 PM, Rob Ross wrote:
I'm running a Java app, and using JNI calling a native method which
is trying to exercise methods in NSApplication or NSWorkspace, like
hideOtherApplications, which seem to do nothing when I call them.
Use NSApplicationLoad() if you're trying to use AppKit classes
without loading a main nib or invoking NSApplication's event loop.
Does anyone know if NSApplicationMain() starts the app in a new
thread, or in the same thread from which it is called?
NSApplicationMain() always launches in the same thread, which had
better be the main thread since a good deal of the AppKit is not
thread-safe.
Nick Zitzmann
<http://www.chronosnet.com/>
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden