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

QQmlConnections::enabled is not FINAL

    XMLWordPrintable

Details

    • Bug
    • Resolution: Invalid
    • P2: Important
    • 6.6
    • 6.4.1
    • QML: Compiler

    Description

      Nitpick:

          Item {
              id: item
              property Connections foo: Connections {
                  id: con
                  enabled: false
              }
          }
      
          Component.onCompleted: {
              con.enabled = false
              item.foo.enabled = true
          }
      

      compiles with

      Warning: main.qml:20:14: Could not compile binding for onCompleted: Member enabled of bool of bool can be shadowed [compiler]
              item.foo.enabled = true
                   ^^^
      

      .

      If you use an id for the connection itself, there's no warning.

      Attachments

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

        Activity

          People

            qtqmlteam Qt Qml Team User
            cajus Cajus Pollmeier
            Votes:
            1 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes