Selaa lähdekoodia

fix(WKWebview): Update webview property when allowsBackForwardNavigationGestures prop changes (#173)

Chet Corcos 5 vuotta sitten
vanhempi
commit
4bc1dc20fd
1 muutettua tiedostoa jossa 7 lisäystä ja 0 poistoa
  1. 7
    0
      ios/RNCWKWebView.m

+ 7
- 0
ios/RNCWKWebView.m Näytä tiedosto

@@ -125,6 +125,13 @@ static NSString *const MessageHanderName = @"ReactNative";
125 125
   }
126 126
 }
127 127
 
128
+// Update webview property when the component prop changes.
129
+- (void)setAllowsBackForwardNavigationGestures:(BOOL)allowsBackForwardNavigationGestures {
130
+  _allowsBackForwardNavigationGestures = allowsBackForwardNavigationGestures;
131
+  _webView.allowsBackForwardNavigationGestures = _allowsBackForwardNavigationGestures;
132
+}
133
+
134
+
128 135
 - (void)removeFromSuperview
129 136
 {
130 137
     if (_webView) {