xamarin/Xamarin.Forms
[Bug, Android, UWP] Image NumberOfTapsRequired fails on Android when greater than 2
オープン
#6,976 opened on 2019/07/25
a/gestures 🖖e/3 :clock3:help wantedp/Androidp/UWPt/bug :bug:up-for-grabs
Repository metrics
- Stars
- (5,644 個のスター)
- PR merge metrics
- (30d に merged PR はありません)
説明
Description
When adding Image.GestureRecognizers XAML as per the documentation, it will only work when the NumberOfTapsRequired property is set to 1 or 2.
Steps to Reproduce
- Create a basic Xamarin Forms Project and in MainPage.xaml, add the following
<Image Source="https://upload.wikimedia.org/wikipedia/commons/thumb/f/f2/Xamarin-logo.svg/1280px-Xamarin-logo.svg.png" VerticalOptions="Center" HeightRequest="64"> <Image.GestureRecognizers> <TapGestureRecognizer Tapped="OnTapGestureRecognizerTapped" NumberOfTapsRequired="3" /> </Image.GestureRecognizers> </Image> - Add the following code in MainPage.xaml.cs:
void OnTapGestureRecognizerTapped(object sender, EventArgs args) { DisplayAlert("Hello", "Hello World!", "OK"); } - Run Android Project and attempt to tap the app multiple times.
Expected Behavior
The alert is displayed after three taps (this works as expected in iOS)
Actual Behavior
No alert is displayed, even after numerous taps.
Basic Information
- Version with issue: 4.1.0.555618
- Last known good version: Unknown
- IDE: Visual Studio for Mac 8.2 Enterprise
- Platform Target Frameworks:
- iOS: 21.14.0.110
- Android: 9.4.0.51
- Nuget Packages: None
- Affected Devices: All Android