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

Allow multiple targets in Connections

    XMLWordPrintable

Details

    • All

    Description

      Similar to the concept Generalized group properties in Binding since Qt 6.3, I believe it would be helpful to provide the same feature to the Connections component.

      I used to write foobarSignal.connect() rather than using a Connections component, because I think there is too much overhead to create extra Connections object just to handle one single signal of another object.

      With generalized group properties, we could handle multiple signals from different (even dynamic) objects in a single Connections:

      Window {
          id: window
      
          Loader {
              id: loader
              sourceComponent: Button {}
          }
      
          Connections {
              ignoreUnknownSignals: true
      
              window.onClosing: ...
              loader.item.onClicked: ...
          }
      }
      

      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
            gpbeta Joshua GPBeta
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:

              Gerrit Reviews

                There are no open Gerrit changes