Source/iPhoneAppDelegate.m
changeset 13 db7bb080c3d5
parent 8 45c82a071aca
child 16 28392c9a969f
     1.1 --- a/Source/iPhoneAppDelegate.m	Wed May 28 12:47:10 2008 -0700
     1.2 +++ b/Source/iPhoneAppDelegate.m	Tue Jul 08 13:12:01 2008 -0700
     1.3 @@ -13,6 +13,19 @@
     1.4  #import "GGBUtils.h"
     1.5  
     1.6  
     1.7 +// Temporary HACK to fix logging problem in beta 6 iPhone OS
     1.8 +extern void _NSSetLogCStringFunction(void (*)(const char *string, unsigned length, BOOL withSyslogBanner));
     1.9 +static void PrintNSLogMessage(const char *string, unsigned length, BOOL withSyslogBanner)
    1.10 +{
    1.11 +	puts(string);
    1.12 +}
    1.13 +static void HackNSLog(void) __attribute__((constructor));
    1.14 +static void HackNSLog(void)
    1.15 +{
    1.16 +	_NSSetLogCStringFunction(PrintNSLogMessage);
    1.17 +}
    1.18 +
    1.19 +
    1.20  @implementation GGB_iPhoneAppDelegate
    1.21  
    1.22  
    1.23 @@ -23,9 +36,6 @@
    1.24  
    1.25  - (void)applicationDidFinishLaunching:(UIApplication *)application 
    1.26  {	
    1.27 -    for( NSString *family in [UIFont familyNames] )
    1.28 -        NSLog(@"%@: (%@)", family, [[UIFont fontNamesForFamilyName: family] componentsJoinedByString: @", "]);
    1.29 -        
    1.30      // Create window
    1.31      self.window = [[[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]] autorelease];
    1.32      _window.layer.backgroundColor = GetCGPatternNamed(@"Background.png");
    1.33 @@ -48,7 +58,7 @@
    1.34      [_window addSubview: _headline];
    1.35      
    1.36      // Start game:
    1.37 -    [self startGameNamed: @"KlondikeGame"];
    1.38 +    [self startGameNamed: @"CheckersGame"];
    1.39      
    1.40      // Show window
    1.41      [_window makeKeyAndVisible];