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

MouseArea grab is sticky with a nested Flickable and drag.filterChildren: true

    XMLWordPrintable

Details

    • e05fbf5c8bf636db5c500c3371d673de17de8c33

    Description

      A recent change introduced the `overThreshold` flag to MouseArea implementation. It is not always reset to false when the gesture is complete.

      For example, flick this up to the end, then try to drag it back down. The MouseArea will steal the drag.

      import QtQuick 2.5
      
      Rectangle {
          width: 240
          height: 320
      
          MouseArea {
              objectName: "mouseArea"
              anchors.fill: parent
      
              drag.target: moveable
              drag.filterChildren: true
      
              Rectangle {
                  id: moveable
                  objectName: "moveable"
                  color: "red"
                  x: 50
                  y: 80
                  width: 200
                  height: 200
              }
      
              Flickable {
                  objectName: "flickable"
                  anchors.fill: parent
                  contentHeight: 500
      
                  Rectangle {
                      x: 100
                      y: 50
                      width: 50
                      height: 400
                      color: "yellow"
                  }
              }
          }
      }
      

      Attachments

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

        Activity

          People

            martinj Martin Jones
            martinj Martin Jones
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes