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

The activeFocusChanged signal not emitted when QML Viewer window itself has no focus.

    XMLWordPrintable

Details

    Description

      The test code listed as below.

      import QtQuick 1.1
      
      Rectangle {
          width: 120
          height: 120
          color: activeFocus ? "blue" : "red"
          Text {
              anchors.centerIn: parent
              text: "Text"
          }
          MouseArea {
              anchors.fill: parent
              onClicked: {
                  parent.forceActiveFocus()
              }
          }
      }
      

      Run qmlviewer with the above test code. Try to select other window to reproduce this case.

      This case cannot be reproduced using Qt Quick 2.0 environment.

      Attachments

        1. activetest.zip
          0.9 kB
          Leonard Lee
        2. main.zip
          0.8 kB
          Sebastian Paluch
        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            Unassigned Unassigned
            leonlee Leonard Lee
            Votes:
            1 Vote for this issue
            Watchers:
            6 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes