Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-138619

TapHandler in Popup doesn't work if ListView has an Image that doesn't load

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: P2: Important P2: Important
    • None
    • 6.8.3
    • Quick: Controls 2
    • None

      This is sort of an obscure combination, however it seems to be a bug.

      When using a Popup that has a TapHandler that is parented to the contentItem, and the content is a ListView where the delegates have an Image - if any of the images fail to load, then the TapHandler on the Popup will not get the tap event. If the images all load, then the TapHandler works.

      In my debugging of the issue, I could find that it has something to do with the ListView taking an exclusive grab of the event, i.e. event->exclusiveGrabber() returns the ListView.

      I have attached an example demonstrating the issue. Clicking on the popup should dismiss it, and print to the console that the TapHandler on the popup was clicked. In the default cause, this won't happen.
      Either comment out the first item in the model, or, uncomment the TapHandler inside the ListView, and now the TapHandler on the popup will work when clicked.

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

            qt.team.quick.subscriptions Qt Quick and Widgets Team
            moustacha Sam Shaw
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:

                There are no open Gerrit changes