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

Application clickthrough with trackpad tap sends mousedown but no mouseup

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • P1: Critical
    • 5.15.11, 6.4
    • 5.12.4, 5.13.0
    • WebEngine
    • None
    • macOS

    Description

      To reproduce, open a page with the simplebrowser example application, then open developer tools and run in the console:

      document.addEventListener("mousedown", function(event) { console.log(event); }, true)
      document.addEventListener("mouseup", function(event) { console.log(event); }, true)

      Then, try to test application click-through. With the developer tools window focused, use the trackpad to make a 'tap' click on the web page in the other window. (Note that you may need to enable 'Tap to Click' in the macOS Trackpad preferences page if you haven't done so.)

      You should see a mousedown event emitted in the developer console, but no accompanying mouseup.

      This can confuse some web applications; e.g. the mousedown might be interpreted as the start of a drag event, and since no mouseup event was observed the behavior the web application will erroneously believe the user is attempting to perform a mouse drag.

      At the Qt level, if I install an event filter on qApp that just logs Qt mouse events, for normal clicks I see a pair of MousePress / MouseRelease events; for some reason, on the click-through trackpad tap I see a pair of MousePress events but just one single MouseRelease event. I suspect this missing MouseRelease event is the source of the issue.

      Attachments

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

        Activity

          People

            mibrunin Michael Bruning
            kevinushey Kevin Ushey
            Votes:
            2 Vote for this issue
            Watchers:
            6 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes