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

Invalid updates of contentY of Flickable on touch screen

    XMLWordPrintable

    Details

    • Platform/s:
      Windows
    • Commits:
      d08038ba70 (qt/qtdeclarative/dev) d08038ba70 (qt/tqtc-qtdeclarative/dev) ee68d19b1d (qt/qtdeclarative/6.3) ee68d19b1d (qt/tqtc-qtdeclarative/6.3) cf39c6e28d (qt/qtdeclarative/6.2) cf39c6e28d (qt/tqtc-qtdeclarative/6.2) cf39c6e28d (qt/qtdeclarative/6.2.4)

      Description

      Flickable has a problem with updating of contentY while moving (no flicking) on touch screen with touch (mouse is OK). The problem is on Windows, I tested it with Qt 6.2.1 for Android and there it works fine. This must be a regression, because on Windows with Qt 5.15.0 the problem does not occur either.

       

      I have attached a sample application showing the problem (test22.zip):

       

      import QtQuick 2.15
      import QtQuick.Controls 2.15
      
      ApplicationWindow {
          width: 640
          height: 480
          visible: true
          title: qsTr("Scroll")
      
          Flickable {
              anchors.fill: parent
              contentWidth: width
              contentHeight: contentRect.height
              onContentYChanged: {
                  console.debug("contentY", contentY)
              }
      
              Rectangle {
                  id: contentRect
      
                  width: parent.width
                  height: 1000
                  color: "grey"
                  gradient: Gradient {
                      GradientStop { position: 0.0; color: "lightsteelblue" }
                      GradientStop { position: 1.0; color: "blue" }
                  }
              }
          }
      }
      
      

      To reproduce the problem you have to touch the flickable somewhere in the middle and slowly move your finger towards the top of the window. You may then notice strange content jumping instead of moving smoothly. Some of the contentY values appear to be totally incorrect.

       

      Below are the logs from the application:

      1. For Qt 6.2.1 (incorrect - for moving from bottom to top there should not be any negative values):
        qml: contentY 0.5
        qml: contentY 1.5
        qml: contentY 2
        qml: contentY 2.5
        qml: contentY 3
        qml: contentY 4
        qml: contentY -105.5
        qml: contentY 6
        qml: contentY -103.5
        qml: contentY 8
        qml: contentY -102
        qml: contentY -101
        qml: contentY -100.5
        qml: contentY 11.5
        qml: contentY -97.5
        qml: contentY -95.5
        qml: contentY -94.5
        qml: contentY -92.5
        qml: contentY -91.5
        qml: contentY 20.5
        qml: contentY -88.5
        qml: contentY -87.5
        qml: contentY -87
        qml: contentY -85.5
        qml: contentY -85
        qml: contentY -83.5
        qml: contentY -82.5
        qml: contentY -81
        qml: contentY -80.5
        qml: contentY -79
        qml: contentY -78
        qml: contentY -77
        qml: contentY -76
        qml: contentY 35
        qml: contentY -75
        qml: contentY 36
        qml: contentY 36.5
        qml: contentY -73.5
        
      1. For Qt 5.15.0 (correct):
        qml: contentY 2.5
        qml: contentY 4
        qml: contentY 5
        qml: contentY 6.5
        qml: contentY 7
        qml: contentY 8
        qml: contentY 9
        qml: contentY 10
        qml: contentY 11.5
        qml: contentY 12.5
        qml: contentY 13
        qml: contentY 14
        qml: contentY 15
        qml: contentY 16
        qml: contentY 17
        qml: contentY 17.5
        qml: contentY 19
        qml: contentY 20
        qml: contentY 20.5
        qml: contentY 21
        qml: contentY 22.5
        qml: contentY 24
        qml: contentY 25.5
        qml: contentY 27.5
        qml: contentY 28
        qml: contentY 29.5
        qml: contentY 31
        qml: contentY 32
        qml: contentY 33.5
        qml: contentY 35.5
        qml: contentY 36.5
        qml: contentY 38
        qml: contentY 39
        qml: contentY 39.5
        qml: contentY 40.5
        qml: contentY 41.5
        qml: contentY 42.5
        qml: contentY 45
        qml: contentY 47
        qml: contentY 49
        qml: contentY 49.5
        qml: contentY 52
        qml: contentY 53.5
        qml: contentY 54.5
        qml: contentY 55
        qml: contentY 56.5
        qml: contentY 58
        qml: contentY 59
        qml: contentY 59.5
        qml: contentY 60.5
        qml: contentY 61
        qml: contentY 62
        qml: contentY 62.5
        qml: contentY 63
        qml: contentY 64
        qml: contentY 64.5
        qml: contentY 64
        

       

        Attachments

          Issue Links

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

            Activity

              People

              Assignee:
              hurlevent Oliver Eftevaag
              Reporter:
              permotion88 Karol Polak
              Votes:
              1 Vote for this issue
              Watchers:
              4 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:

                  Gerrit Reviews

                  There are no open Gerrit changes