xamarin / Xamarin.Forms

Xamarin.Forms is no longer supported. Migrate your apps to .NET MAUI.
https://aka.ms/xamarin-upgrade
Other
5.62k stars 1.87k forks source link

[Bug] Tap event not firing inside scrollview #6257

Open SFSteve opened 5 years ago

SFSteve commented 5 years ago

Description

When compiling the android project using 9.0, any items inside a scrollview will no longer fire the click event immediately when the scrollview moves

Steps to Reproduce

  1. Create a xaml view that contains a scrollview with a clickable element
  2. Swipe the view to trigger a scroll and tap the element

Expected Behavior

The click event fires immediately on tapping the element

Actual Behavior

The element must be tapped twice, or the user must wait upwards of 2-3 seconds after scrolling then tap before the event will fire

Basic Information

Works as expected with 8.1 and below. Tested using buttons, labels, stacklayouts and frames, with click event listeners in the code behind and commands in the viewmodel. Consistently recreated in every scenario. The scroll gesture must be a flick/swipe i.e. so the scroll continues after the user stops touching the screen, seems to work as expected with a slow controlled scroll. Created a separate test android project using 9.0 that did not use Forms and the tap event worked as expected.

Screenshots

Reproduction Link

https://github.com/stephenclarkstorefeeder/XamarinFormsClickOnScrollIssue

kingces95 commented 5 years ago

8F109F99-9DAB-423D-941A-F533E9643039 Yep. Sometimes on master 9.0 I gotta click twice.