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

Connections doesn't always work with signal handlers for properties defined in _under_score_case

    XMLWordPrintable

    Details

    • Platform/s:
      All
    • Commits:
      2f4c131805f4009f42abe991e0f92f096bbc55fd (qt/qtdeclarative/5.14)

      Description

      Following signal handler works:

      property real __private_property
      on__Private_propertyChanged: console.log("__private_property", __private_property)
      

      But if I create such signal handler with Connections element in QML component where the property hasn't been defined within the same component

      Connections {
          target: item
          on__Private_propertyChanged: console.log("__private_property", __private_property)
      }
      

      the component loading fails in error

      Cannot assign to non-existent property "on__Private_propertyChanged"

      If both the property and Connections element have been defined within the same QML document there is no error. If property uses normal camelCase there is no error.

        Attachments

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

          Activity

            People

            Assignee:
            fabiankosmale Fabian Kosmale
            Reporter:
            jpetrell Joona Petrell
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:

                Gerrit Reviews

                There are no open Gerrit changes