prevent accidental side menu popup

master
esterTion 2020-11-02 00:22:29 +08:00
parent 049407e1b5
commit 1af0d2ecf4
3 changed files with 5 additions and 2 deletions

View File

@ -353,7 +353,7 @@
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
CODE_SIGN_IDENTITY = "Apple Development"; CODE_SIGN_IDENTITY = "Apple Development";
CODE_SIGN_STYLE = Automatic; CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 10; CURRENT_PROJECT_VERSION = 11;
DEVELOPMENT_TEAM = K9CP5766XY; DEVELOPMENT_TEAM = K9CP5766XY;
INFOPLIST_FILE = "Brokenithm-iOS/Info.plist"; INFOPLIST_FILE = "Brokenithm-iOS/Info.plist";
IPHONEOS_DEPLOYMENT_TARGET = 8.0; IPHONEOS_DEPLOYMENT_TARGET = 8.0;
@ -377,7 +377,7 @@
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
CODE_SIGN_IDENTITY = "Apple Development"; CODE_SIGN_IDENTITY = "Apple Development";
CODE_SIGN_STYLE = Automatic; CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 10; CURRENT_PROJECT_VERSION = 11;
DEVELOPMENT_TEAM = K9CP5766XY; DEVELOPMENT_TEAM = K9CP5766XY;
INFOPLIST_FILE = "Brokenithm-iOS/Info.plist"; INFOPLIST_FILE = "Brokenithm-iOS/Info.plist";
IPHONEOS_DEPLOYMENT_TARGET = 8.0; IPHONEOS_DEPLOYMENT_TARGET = 8.0;

View File

@ -33,6 +33,7 @@
BOOL invertAir; BOOL invertAir;
NSNumber *menuHoldDuration; NSNumber *menuHoldDuration;
UILongPressGestureRecognizer *openCloseHold; UILongPressGestureRecognizer *openCloseHold;
int touchCount;
} }
@property UIView *airIOView; @property UIView *airIOView;
@property UIView *sliderIOView; @property UIView *sliderIOView;

View File

@ -247,6 +247,7 @@
} }
-(void)openOrCloseFunc { -(void)openOrCloseFunc {
if (self->touchCount > 1) return;
if (funcViewOn) { if (funcViewOn) {
[self closeFunc]; [self closeFunc];
} else { } else {
@ -296,6 +297,7 @@
[server BroadcastData:io]; [server BroadcastData:io];
} }
-(void)updateTouches:(UIEvent *)event { -(void)updateTouches:(UIEvent *)event {
self->touchCount = event.allTouches.count;
if (openCloseEventOnce) { if (openCloseEventOnce) {
if (event.allTouches.count == 1 && [event.allTouches anyObject].phase == UITouchPhaseEnded) { if (event.allTouches.count == 1 && [event.allTouches anyObject].phase == UITouchPhaseEnded) {
openCloseEventOnce = NO; openCloseEventOnce = NO;