equal
deleted
inserted
replaced
26 switch (theButton.tag) { |
26 switch (theButton.tag) { |
27 case 0: |
27 case 0: |
28 [[self parentViewController] dismissModalViewControllerAnimated:YES]; |
28 [[self parentViewController] dismissModalViewControllerAnimated:YES]; |
29 break; |
29 break; |
30 case 1: |
30 case 1: |
31 [self performSelector:@selector(startGame) |
31 theButton.enabled = NO; |
32 withObject:nil |
32 [self performSelector:@selector(startGame:) |
|
33 withObject:theButton |
33 afterDelay:0.25]; |
34 afterDelay:0.25]; |
34 break; |
35 break; |
35 default: |
36 default: |
36 break; |
37 break; |
37 } |
38 } |
66 // this message is compulsory otherwise the table won't be loaded at all |
67 // this message is compulsory otherwise the table won't be loaded at all |
67 [activeController viewWillAppear:NO]; |
68 [activeController viewWillAppear:NO]; |
68 [self.view addSubview:activeController.view]; |
69 [self.view addSubview:activeController.view]; |
69 } |
70 } |
70 |
71 |
71 -(void) startGame { |
72 -(void) startGame:(UIButton *)button { |
|
73 button.enabled = YES; |
|
74 |
72 // don't start playing if the preview is in progress |
75 // don't start playing if the preview is in progress |
73 if ([mapConfigViewController busy]) { |
76 if ([mapConfigViewController busy]) { |
74 UIAlertView *alert = [[UIAlertView alloc] initWithTitle:NSLocalizedString(@"Wait for the Preview",@"") |
77 UIAlertView *alert = [[UIAlertView alloc] initWithTitle:NSLocalizedString(@"Wait for the Preview",@"") |
75 message:NSLocalizedString(@"Before playing the preview needs to be generated",@"") |
78 message:NSLocalizedString(@"Before playing the preview needs to be generated",@"") |
76 delegate:nil |
79 delegate:nil |