Changeset 19995
- Timestamp:
- 04/22/07 16:07:57 (2 years ago)
- Files:
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
juggler/trunk/modules/vrjuggler/data/bundle/vrjuggler.plist
r19884 r19995 5 5 <key>VRJConfigHandling</key> 6 6 <false/> 7 <key>VRJControllerClass</key> 8 <string>VrjMainController</string> 7 9 </dict> 8 10 </plist> juggler/trunk/modules/vrjuggler/vrj/Kernel/CocoaWrapper.mm
r19992 r19995 29 29 #include <assert.h> 30 30 #include <boost/bind.hpp> 31 #include <objc/objc-runtime.h> 31 32 32 33 #import <Foundation/NSValue.h> … … 428 429 // application:openFile: and application:openFiles: messages. 429 430 BOOL load_cfg_files = YES; 431 NSString* ctrl_class_name = @"VrjMainController"; 430 432 431 433 if ( vrj_dict ) … … 437 439 load_cfg_files = [cfg_handling boolValue]; 438 440 } 439 } 440 441 VrjMainController* main_controller = 442 [[[VrjMainController alloc] init] autorelease]; 441 442 NSString* name = [vrj_dict objectForKey:@"VRJControllerClass"]; 443 444 if ( nil != name ) 445 { 446 ctrl_class_name = name; 447 } 448 } 449 450 id controller_class = objc_getClass([ctrl_class_name UTF8String]); 451 452 if ( nil == controller_class ) 453 { 454 NSLog(@"WARNING: Could not find declaration of %@!\n", ctrl_class_name); 455 NSLog(@" Falling back on VrjMainController\n"); 456 controller_class = [VrjMainController class]; 457 } 458 459 id main_controller = [[[controller_class alloc] init] autorelease]; 443 460 [main_controller setLoadConfigs:load_cfg_files]; 444 461
