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

For MultiPointTouchArea with a child PinchArea multiple pressed signals for multiple touch points on mouse press

    XMLWordPrintable

    Details

    • Commits:
      9b64eee22d (qt/qtdeclarative/dev) 9b64eee22d (qt/tqtc-qtdeclarative/dev) 16dd2c71b8 (qt/qtdeclarative/6.3) 16dd2c71b8 (qt/tqtc-qtdeclarative/6.3) 0121c6737c (qt/tqtc-qtdeclarative/5.15) 16dd2c71b8 (qt/tqtc-qtdeclarative/6.3.1)

      Description

      According to docs: "If mouseEnabled is true (the default) and the left mouse button is pressed while the mouse is over the touch area, the current mouse position will be one of these touch points." (https://doc.qt.io/qt-5/qml-qtquick-multipointtoucharea.html#touchPoints-prop)

      In Qt 5.12.7 this works unless MultiPointTouchArea is filled by a PinchArea. In the attached test application (where a PinchArea is involved) on the first click both of the 2 user defined touch points seem to correspond to the mouse position. On the following clicks there are again multiple pressed signals but the touch points change. There are also missing releases. The same issue can be reproduced with Qt 5.14.1 too. In Qt 5.12.6 this issue can't be reproduced at all.

      Output in 5.12.6 for two consecutive mouse clicks:
      qml: onPressed called Mon Apr 20 15:00:36 2020 GMT+0300
      qml: point1 (onPressed) pressed=true
      qml: onReleased called Mon Apr 20 15:00:36 2020 GMT+0300
      qml: point1 (onReleased) pressed=false
      qml: onPressed called Mon Apr 20 15:00:38 2020 GMT+0300
      qml: point1 (onPressed) pressed=true
      qml: onReleased called Mon Apr 20 15:00:38 2020 GMT+0300
      qml: point1 (onReleased) pressed=false

      Output in 5.12.7 for two consecutive mouse clicks:
      qml: onPressed called Mon Apr 20 15:01:07 2020 GMT+0300
      qml: point1 (onPressed) pressed=true
      qml: onPressed called Mon Apr 20 15:01:07 2020 GMT+0300
      qml: point2 (onPressed) pressed=true
      qml: onReleased called Mon Apr 20 15:01:07 2020 GMT+0300
      qml: point2 (onReleased) pressed=false
      qml: onPressed called Mon Apr 20 15:01:12 2020 GMT+0300
      qml: point2 (onPressed) pressed=true
      qml: onPressed called Mon Apr 20 15:01:12 2020 GMT+0300
      qml: (onPressed) pressed=true
      qml: onReleased called Mon Apr 20 15:01:13 2020 GMT+0300
      qml: (onReleased) pressed=false

      NOTE: the user defined touch points have object names set and logged. However in the log above it can be seen that one of the touch points doesn't have an object name (last 3 rows).

      Steps to reproduce the issue:

      1. Build and run the attached example, use Qt 5.12.7 or newer
      2. Click anywhere on the test app window

        Attachments

          Issue Links

          For Gerrit Dashboard: QTBUG-83662
          # Subject Branch Project Status CR V

            Activity

              People

              Assignee:
              srutledg Shawn Rutledge
              Reporter:
              miikapernu Miika Pernu
              Votes:
              1 Vote for this issue
              Watchers:
              3 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:

                  Gerrit Reviews

                  There are no open Gerrit changes