Bug 36703 - TapGestureRecognizer inside initially disable Image will never fire Tapped event
Summary: TapGestureRecognizer inside initially disable Image will never fire Tapped event
Status: RESOLVED FIXED
Alias: None
Product: Forms
Classification: Xamarin
Component: Android (show other bugs)
Version: 2.0.0
Hardware: PC Mac OS
: --- normal
Target Milestone: ---
Assignee: E.Z. Hart [MSFT]
URL:
: 59157 (view as bug list)
Depends on:
Blocks:
 
Reported: 2015-12-08 07:58 UTC by Kent
Modified: 2017-08-31 19:27 UTC (History)
8 users (show)

Tags: ac
Is this bug a regression?: ---
Last known good build:


Attachments
Repro (200.52 KB, application/zip)
2015-12-08 07:58 UTC, Kent
Details


Notice (2018-05-24): bugzilla.xamarin.com is now in read-only mode.

Please join us on Visual Studio Developer Community and in the Xamarin and Mono organizations on GitHub to continue tracking issues. Bugzilla will remain available for reference in read-only mode. We will continue to work on open Bugzilla bugs, copy them to the new locations as needed for follow-up, and add the new items under Related Links.

Our sincere thanks to everyone who has contributed on this bug tracker over the years. Thanks also for your understanding as we make these adjustments and improvements for the future.


Please create a new report on Developer Community or GitHub with your current version information, steps to reproduce, and relevant error messages or log files if you are hitting an issue that looks similar to this resolved bug and you do not yet see a matching new report.

Related Links:
Status:
RESOLVED FIXED

Description Kent 2015-12-08 07:58:42 UTC
Created attachment 14177 [details]
Repro

When a TapGestureRecognizer is contained within an Image like this:

<Image IsEnabled="False">
    <Button.GestureRecognizers>
        <TapGestureRecognizer/>
    </Button.GestureRecognizers>
</Image>

It will never raise its Tapped event on Android. That's true even if the Image is enabled after the fact.

If the Image is not disabled to begin with, the gesture works fine.

The attached repro demonstrates this. Open the solution and run it under Android. Tapping the image will never display a message.

Run the same code on iOS and it works. Alternatively, change the Image so it is initially enabled and it will also work.
Comment 2 stephen.machwirth 2016-11-15 11:51:45 UTC
Having the same issue.
Comment 3 E.Z. Hart [MSFT] 2017-06-05 21:50:40 UTC
PR: https://github.com/xamarin/Xamarin.Forms/pull/968
Comment 4 Jimmy [MSFT] 2017-08-17 15:32:00 UTC
This should be fixed in 2.4.0-pre1. Thanks!
Comment 5 Jimmy [MSFT] 2017-08-31 19:27:19 UTC
*** Bug 59157 has been marked as a duplicate of this bug. ***