Changeset 20722
- Timestamp:
- 08/14/07 08:49:23 (1 year ago)
- Files:
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
juggler/trunk/modules/vrjuggler/doc/programmer.guide/programmer.guide.xml
r20713 r20722 11427 11427 } 11428 11428 11429 -(void) applicationDidFinishLaunching:(NSNotification*) aNotification 11430 { 11431 // We're ready to allow windows to open! 11432 NSConditionLock* lock = gadget::InputAreaCocoa::getWindowLock(); 11433 [lock unlock]; 11434 } 11435 11429 11436 -(BOOL) application:(NSApplication*) theApplication 11430 11437 openFile:(NSString*) file … … 11536 11543 it down when the time is right. Because of that, we want the 11537 11544 kernel to control the termination process.</para> 11545 </section> 11546 11547 <section> 11548 <title><methodname>-applicationDidFinishLaunching:</methodname></title> 11549 11550 <para>When the application finishes launching, NSApplication 11551 sends this message to its delegate. In the case of VR Juggler, 11552 this is when we know that it is safe to allow threads for 11553 Gadgeteer input windows and VR Juggler graphics pipes to open 11554 windows. Until now, any such threads have been blocking on the 11555 global window lock, acquired when 11556 <classname>vrj::CocoaWrapper</classname> was instantiated. When 11557 the delegate receives this message, it is time to release that 11558 lock. Other operations can be performed in this method 11559 implementation, but this step is absolutely critical.</para> 11538 11560 </section> 11539 11561 … … 11659 11681 creating the <classname>NSApplication</classname> singleton object 11660 11682 by sending the <classname>NSApplication</classname> class the 11661 <methodname>+sharedApplication</methodname> message.</para> 11683 <methodname>+sharedApplication</methodname> message. The global 11684 lock must be released once we know that the application has 11685 finished launching. If a delegate is used with the 11686 <classname>NSApplication</classname> singleton, the lock should be 11687 released when the delegate receives the 11688 <methodname>-applicationDidFinishLaunching:</methodname> 11689 message.</para> 11662 11690 11663 11691 <para>Beyond that, the programmer is free to do as s/he wishes in
