diff --git a/packages/edit-post/src/editor.native.js b/packages/edit-post/src/editor.native.js index d600a8ea8dec55..6638c3bd05e0eb 100644 --- a/packages/edit-post/src/editor.native.js +++ b/packages/edit-post/src/editor.native.js @@ -4,6 +4,7 @@ import memize from 'memize'; import { map, without } from 'lodash'; import { I18nManager } from 'react-native'; +import { GestureHandlerRootView } from 'react-native-gesture-handler'; /** * WordPress dependencies @@ -174,17 +175,19 @@ class Editor extends Component { }; return ( - - - - - + + + + + + + ); } } diff --git a/packages/react-native-bridge/android/react-native-bridge/build.gradle b/packages/react-native-bridge/android/react-native-bridge/build.gradle index cbcba3f7fec13b..b3bbd7116e5c07 100644 --- a/packages/react-native-bridge/android/react-native-bridge/build.gradle +++ b/packages/react-native-bridge/android/react-native-bridge/build.gradle @@ -85,7 +85,8 @@ dependencies { implementation "org.wordpress-mobile:react-native-clipboard:${extractPackageVersion(packageJson, '@react-native-clipboard/clipboard', 'dependencies')}" implementation "org.wordpress-mobile:react-native-fast-image:${extractPackageVersion(packageJson, 'react-native-fast-image', 'dependencies')}" - implementation("com.github.wordpress-mobile:react-native-gesture-handler:${extractPackageVersion(packageJson, 'react-native-gesture-handler', 'dependencies')}", { + // implementation("com.github.wordpress-mobile:react-native-gesture-handler:${extractPackageVersion(packageJson, 'react-native-gesture-handler', 'dependencies')}", { + implementation("com.github.wordpress-mobile:react-native-gesture-handler:wp-fork-2.5.0-SNAPSHOT", { // Remove Reanimated transitive dependency as it's already defined here exclude group: 'com.github.wordpress-mobile', module: 'react-native-reanimated' }) diff --git a/packages/react-native-bridge/android/react-native-bridge/src/main/java/org/wordpress/mobile/WPAndroidGlue/WPAndroidGlueCode.java b/packages/react-native-bridge/android/react-native-bridge/src/main/java/org/wordpress/mobile/WPAndroidGlue/WPAndroidGlueCode.java index 74236bb49bcd8c..bd3111e846325a 100644 --- a/packages/react-native-bridge/android/react-native-bridge/src/main/java/org/wordpress/mobile/WPAndroidGlue/WPAndroidGlueCode.java +++ b/packages/react-native-bridge/android/react-native-bridge/src/main/java/org/wordpress/mobile/WPAndroidGlue/WPAndroidGlueCode.java @@ -45,7 +45,6 @@ import com.reactnativecommunity.slider.ReactSliderPackage; import org.linusu.RNGetRandomValuesPackage; import com.reactnativecommunity.webview.RNCWebViewPackage; -import com.swmansion.gesturehandler.react.RNGestureHandlerEnabledRootView; import com.swmansion.gesturehandler.RNGestureHandlerPackage; import com.swmansion.reanimated.ReanimatedJSIModulePackage; import com.swmansion.reanimated.ReanimatedPackage; @@ -615,7 +614,7 @@ public void onCreateView(Context initContext, mIsDarkMode = gutenbergProps.isDarkMode(); mExceptionLogger = exceptionLogger; mBreadcrumbLogger = breadcrumbLogger; - mReactRootView = new RNGestureHandlerEnabledRootView(new MutableContextWrapper(initContext)); + mReactRootView = new ReactRootView(new MutableContextWrapper(initContext)); mReactRootView.setBackgroundColor(colorBackground); ReactInstanceManagerBuilder builder = diff --git a/packages/react-native-editor/android/app/build.gradle b/packages/react-native-editor/android/app/build.gradle index 1147ac2eac2546..fcc2d990102a38 100644 --- a/packages/react-native-editor/android/app/build.gradle +++ b/packages/react-native-editor/android/app/build.gradle @@ -264,7 +264,8 @@ dependencies { implementation "org.wordpress-mobile:react-native-clipboard:${extractPackageVersion(packageJson, '@react-native-clipboard/clipboard', 'dependencies')}" implementation "org.wordpress-mobile:react-native-fast-image:${extractPackageVersion(packageJson, 'react-native-fast-image', 'dependencies')}" - implementation("com.github.wordpress-mobile:react-native-gesture-handler:${extractPackageVersion(packageJson, 'react-native-gesture-handler', 'dependencies')}", { + // implementation("com.github.wordpress-mobile:react-native-gesture-handler:${extractPackageVersion(packageJson, 'react-native-gesture-handler', 'dependencies')}", { + implementation("com.github.wordpress-mobile:react-native-gesture-handler:wp-fork-2.5.0-SNAPSHOT", { // Remove Reanimated transitive dependency as it's already defined here exclude group: 'com.github.wordpress-mobile', module: 'react-native-reanimated' }) diff --git a/packages/react-native-editor/android/app/src/main/java/com/gutenberg/MainActivity.java b/packages/react-native-editor/android/app/src/main/java/com/gutenberg/MainActivity.java index 447f2d35ee4ded..ae81e808011eaf 100644 --- a/packages/react-native-editor/android/app/src/main/java/com/gutenberg/MainActivity.java +++ b/packages/react-native-editor/android/app/src/main/java/com/gutenberg/MainActivity.java @@ -6,8 +6,6 @@ import com.facebook.react.ReactActivity; import com.facebook.react.ReactActivityDelegate; -import com.facebook.react.ReactRootView; -import com.swmansion.gesturehandler.react.RNGestureHandlerEnabledRootView; import org.wordpress.mobile.WPAndroidGlue.GutenbergProps; @@ -27,11 +25,6 @@ protected String getMainComponentName() { @Override protected ReactActivityDelegate createReactActivityDelegate() { return new ReactActivityDelegate(this, getMainComponentName()) { - @Override - protected ReactRootView createRootView() { - return new RNGestureHandlerEnabledRootView(MainActivity.this); - } - @Nullable @Override protected Bundle getLaunchOptions() {