Commit 7b46018
authored
[Android] Dispatch cancel event only when root view is enabled (#4123)
## Description
Currently, RootView on Android always dispatches `ACTION_CANCEL` before
starting to process the new event stream. When multiple root views are
rendered in the app, this will have a "waterfall" effect of each root
view dispatching its own `ACTION_CANCEL` on top of passing the one
received from the parent.
This PR addresses that by requiring the root view to be enabled to
dispatch the cancel event.
## Test plan
Checked the `Nested touchables` example1 parent 93e3a32 commit 7b46018
1 file changed
Lines changed: 1 addition & 1 deletion
File tree
- packages/react-native-gesture-handler/android/src/main/java/com/swmansion/gesturehandler/react
Lines changed: 1 addition & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
49 | 49 | | |
50 | 50 | | |
51 | 51 | | |
52 | | - | |
| 52 | + | |
53 | 53 | | |
54 | 54 | | |
55 | 55 | | |
| |||
0 commit comments