|
@@ -23,6 +23,7 @@
|
|
|
@property(nonatomic, strong)NoNetView *noNetView;
|
|
|
@property(nonatomic, strong)ZKClipboardView *clipboardView;
|
|
|
@property(nonatomic, strong)ZKFaceVerifyMsgView *verifyMsgView;
|
|
|
+@property(nonatomic, strong)UIPanGestureRecognizer *recognizer;
|
|
|
|
|
|
@end
|
|
|
|
|
@@ -150,6 +151,7 @@ NSString *const new_AesKey_3 = @"mGlAgnIBB8bx2nch";
|
|
|
self.progressView.alpha = 1.0f;
|
|
|
[self.progressView setProgress:newprogress animated:YES];
|
|
|
if (newprogress >= 1.0f) {
|
|
|
+ self.recognizer.enabled = YES;
|
|
|
[UIView animateWithDuration:0.3f
|
|
|
delay:0.3f
|
|
|
options:UIViewAnimationOptionCurveEaseOut
|
|
@@ -226,12 +228,10 @@ NSString *const new_AesKey_3 = @"mGlAgnIBB8bx2nch";
|
|
|
} else if (recoginzer.state==UIGestureRecognizerStateEnded||(recoginzer.state==UIGestureRecognizerStatePossible)){
|
|
|
if (touchPoint.x - startTouch.x > width*0.125) {
|
|
|
[UIView animateWithDuration:0.3 animations:^{
|
|
|
- [self moveViewWithX:width];
|
|
|
-// [self.webView goBack];
|
|
|
-
|
|
|
- NSString *jsName = @"window.history.back()";
|
|
|
- [self executeCallJS:jsName];
|
|
|
-
|
|
|
+ if (recoginzer.state==UIGestureRecognizerStateEnded) {
|
|
|
+ [self moveViewWithX:width];
|
|
|
+ [self.webView goBack];
|
|
|
+ }
|
|
|
} completion:^(BOOL finished) {
|
|
|
_isMoving = NO;
|
|
|
[self moveViewWithX:0];
|
|
@@ -445,9 +445,9 @@ NSString *const new_AesKey_3 = @"mGlAgnIBB8bx2nch";
|
|
|
[[AFNetworkReachabilityManager sharedManager] startMonitoring];
|
|
|
[self initNotification];
|
|
|
|
|
|
- UIPanGestureRecognizer *recognizer = [[UIPanGestureRecognizer alloc]initWithTarget:self action:@selector(paningGestureReceive:)];
|
|
|
- [recognizer delaysTouchesBegan];
|
|
|
- [self.view addGestureRecognizer:recognizer];
|
|
|
+ self.recognizer = [[UIPanGestureRecognizer alloc]initWithTarget:self action:@selector(paningGestureReceive:)];
|
|
|
+ [self.recognizer delaysTouchesBegan];
|
|
|
+ [self.view addGestureRecognizer:self.recognizer];
|
|
|
|
|
|
//监听底部栏
|
|
|
[NSTimer scheduledTimerWithTimeInterval:3 target:self selector:@selector(bottomThreeListening) userInfo:nil repeats:YES];
|
|
@@ -487,7 +487,7 @@ NSString *const new_AesKey_3 = @"mGlAgnIBB8bx2nch";
|
|
|
|
|
|
// 页面开始加载时调用
|
|
|
- (void)webView:(WKWebView *)webView didStartProvisionalNavigation:(WKNavigation *)navigation{
|
|
|
-
|
|
|
+ self.recognizer.enabled = NO;
|
|
|
}
|
|
|
// 当内容开始返回时调用
|
|
|
- (void)webView:(WKWebView *)webView didCommitNavigation:(WKNavigation *)navigation{
|
|
@@ -495,6 +495,7 @@ NSString *const new_AesKey_3 = @"mGlAgnIBB8bx2nch";
|
|
|
|
|
|
// 页面加载失败时调用
|
|
|
- (void)webView:(WKWebView *)webView didFailProvisionalNavigation:(WKNavigation *)navigation withError:(nonnull NSError *)error{
|
|
|
+ self.recognizer.enabled = YES;
|
|
|
[[GlobalData shareInstance] addOnePlistData:@{
|
|
|
@"detail":[[self stringByEvaluatingJavaScriptFromString:@"document.location.href"] stringByAppendingString:[NSString stringWithFormat:@"\n%@",[error description]]],
|
|
|
@"reqTime":[NSNumber numberWithInt:0],
|