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

MouseHandler does not emit clicked or doubleClicked events

    XMLWordPrintable

Details

    • Windows

    Description

      Example:

      import QtQuick.Scene3D 2.12
      import Qt3D.Core 2.12
      import Qt3D.Input 2.12
      import Qt3D.Render 2.12
      import Qt3D.Extras 2.12
      import QtQuick.Window 2.12 as QQW
      import QtQuick 2.12 as QQ2
      
      QQW.Window {
          visible: true
          width: 640
          height: 480
      
          Scene3D {
              anchors.fill: parent
              aspects: ["input", "render"]
      
              Entity {
                  components: [
                      RenderSettings {
                          activeFrameGraph: ForwardRenderer {
                              camera: Camera {}
                          }
                      },
                      InputSettings {}
                  ]
      
                  Entity {
                      components: [
                          MouseHandler {
                              sourceDevice: MouseDevice {}
                              onClicked: console.log("clicked")
                              onDoubleClicked: console.log("doubleClicked")
                          }
                      ]
                  }
              }
          }
      }
      

      Might be related to QTBUG-54067.

      Attachments

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

        Activity

          People

            mkrus Mike Krus
            jirauser43583 user-49824 (Inactive)
            Votes:
            2 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes