Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Fixed issue of touchable board while displaying pause modal

  • Loading branch information...
commit 9652417dc306c45106d75660903d92db7e7c068f 1 parent 10d049b
@mwcbrent mwcbrent authored
View
5 concentration/ConcentrationViewController.m
@@ -142,7 +142,8 @@ - (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interface
}
- (void) touchesBegan:(NSSet *)touches withEvent:(UIEvent *)event {
- [self.board touchesBegan:touches withEvent:event];
+ if(self.board.enabled)
+ [self.board touchesBegan:touches withEvent:event];
}
#pragma mark - Game Events
@@ -164,12 +165,14 @@ - (void)showHelpOverlay
{
[self.view addSubview:self.helpOverlay.view];
[[NSNotificationCenter defaultCenter] postNotificationName:@"pauseTime" object:nil];
+ self.board.enabled = NO;
}
- (void)hideHelpOverlay
{
[self.helpOverlay.view removeFromSuperview];
[[NSNotificationCenter defaultCenter] postNotificationName:@"resumeTime" object:nil];
+ self.board.enabled = YES;
}
- (void)gameStart
View
1  concentration/ScoreBoard.h
@@ -17,7 +17,6 @@
@property (nonatomic, retain) UIButton *restartButton;
@property (nonatomic, retain) UIButton *helpButton;
@property (nonatomic, assign) NSDate *levelStartTime;
-@property (nonatomic, retain) NSDate *pauseStartTime;
@property (nonatomic, retain) NSTimer *clock;
@end
Please sign in to comment.
Something went wrong with that request. Please try again.