PeterStaev / nativescript-image-swipe

A NativeScript widget to easily :point_up_2: and :mag: through a list of images
Apache License 2.0
35 stars 21 forks source link

Zoom doesn't work inside of ScrollView on Android #9

Open buuhuu opened 7 years ago

buuhuu commented 7 years ago

I put the ImageSwipe as view (beside others) in a ScrollView (vertical). Zooming doesn't work in that case on android devices.

According to some research this is hard to achieve as the ScrollView#dispatchTouchEvent() would be required to invoke the custom GestureDetector.

buuhuu commented 7 years ago

Seems to be related to some particular devices only. Doesn't work on HTC One M8 (Android 7) but it does work (kind of) on Samsung Galaxy S5 (Android 6)

buuhuu commented 7 years ago

I worked around that by implementing my own OnTouchListener dispatching touch events to the currently visible image view. Its more like a hack but it works for now.

shahramrz commented 4 years ago

I have the same problem, would you please let me know how you solve this problem? any sample code or how to implement OnTouchListener thanks