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

Pinch gesture triggers CTRL key event

    XMLWordPrintable

Details

    • Windows

    Description

      The two-finger pinch (&zoom) gesture triggers the Key_Control event on Windows trackpads.

      Example:

      import QtQuick
      import QtQuick.Controls.Material
      import QtQuick.Layouts
      
      ApplicationWindow {
          id: window
          width: 640
          height: 480
          visible: true
          title: qsTr("Test")
      
          Page {
              id: page
              anchors.fill: parent
              focus: true
      
              MouseArea {
                  onClicked: page.forceActiveFocus()
              }
      
              Keys.onPressed: function(event) {
                  console.log("Key pressed: " + event.key);
      
      
                  if (event.key === Qt.Key_Control) {
                      console.log("CTRL pressed!");
                  }
              }
          }
      
      }
      

      Attachments

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

        Activity

          People

            benjamin.hadra Benjamin Hadra
            Harald Meyer Harald Meyer
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes