software-mansion / react-native-gesture-handler

Declarative API exposing platform native touch and gesture system to React Native.
https://docs.swmansion.com/react-native-gesture-handler/
MIT License
5.85k stars 954 forks source link

Differences in onStart Callback with activateAfterLongPress Property for Pan Gesture between iOS and Android #2620

Closed huuthinh95 closed 4 months ago

huuthinh95 commented 7 months ago

Description

When using the Pan gesture and adding the properties activateAfterLongPress, the callback onStart behaves differently on two platforms, iOS and Android (iOS is called twice, while Android is called once). I believe there is a problem on iOS because onStart should only be called once, just like on Android.

Steps to reproduce

  1. Open link Snack
  2. Long-press the view for 500ms and then perform the Pan gesture.
  3. Check log

Snack or a link to a repository

https://snack.expo.dev/@huuthinhbk123/pangesture

Gesture Handler version

2.13.1

React Native version

0.72.3

Platforms

Android, iOS

JavaScript runtime

None

Workflow

None

Architecture

None

Build type

None

Device

None

Device model

No response

Acknowledgements

Yes

codegabk commented 2 weeks ago

Which version of gesture handler can i use to get this fix ? The issue doesn't seem to be fixed on 2.15.0 or current latest 2.16.0