Last active
December 15, 2015 07:59
-
-
Save sdabet/5227318 to your computer and use it in GitHub Desktop.
Override registerWithTouchDispatcher to disable touch swallowing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-(id) init { | |
if(self = [super init]) { | |
self.touchEnabled = YES; | |
} | |
return self; | |
} | |
/* Need to override because we don't want to swallow touches */ | |
-(void) registerWithTouchDispatcher { | |
[[[CCDirector sharedDirector] touchDispatcher] addTargetedDelegate:self priority:0 swallowsTouches:NO]; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment