Closed Glazzes closed 2 months ago
I'd like to add something to this issue after some testing from my part, scaling the item affects the values reported as already mentioned however modifying width and height properties reports correct values.
I'd like to add something to this issue after some testing from my part, scaling the item affects the values reported as already mentioned however modifying width and height properties reports correct values.
Hey, thanks for your report. I've pushed the code that should fix the issue.
@coado Thank you for your work, I wonder, was this an Android only issue? As I mentioned I don't have an iPhone.
@coado Thank you for your work, I wonder, was this an Android only issue? As I mentioned I don't have an iPhone.
Yes, that was something specific to android implementation. The iOS handles that out of the box.
Description
Hi there and thank you all for your open source efforts, I'm currently creating a zoomable image component and in order to achieve this behavior I need the absolute position (absoluteX and absoluteY values) of both fingers on the screen, however I'm getting the following issues.
onTouchesDown
andonTouchesMove
for both pointers are all correct.if the element to pinch is scaled, the values reported by
onTouchesDown
andonTouchesMove
are all incorrect, for some reason one of the pointers is able to report the correct value for the x axis.Some other things to note about this problem, if both fingers are moved in the same horizontal direction both pointers will report valid values on the x axis.
If you keep one finger stand still at the screen and start moving the other, you will be able to see the values reported for the stand still finger will start to increase.
I can not tell whether this problem happens on iOS as I don't own an Apple device.
Steps to reproduce
onUpdate
callbackonUpdate
callbackSnack or a link to a repository
https://snack.expo.dev/@glazzes/d545df
Gesture Handler version
2.16.1
React Native version
0.74.1
Platforms
Android
JavaScript runtime
Hermes
Workflow
Expo managed workflow
Architecture
Paper (Old Architecture)
Build type
Debug mode
Device
Real device
Device model
Alcatel 5044R (Android 7)
Acknowledgements
Yes