Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-30596 bi-directional or multi-sync variation of Binding
  3. QTBUG-132541

Establish late-bound mode for Binding using property declarations

    XMLWordPrintable

Details

    • 0aa37f979 (dev)

    Description

      The same way Connections has a late-bound mode using function declarations of a specific form, Binding should have a late-bound mode using property declarations of a specific form. Instead of the current:

      Binding {
          foo.bar: some + expression
      }
      

      You'd write:

      Binding {
          target: foo
          property int bar: some + expression
      }
      

      If the "property" property is not given, Binding would then automatically synchronize any declared properties with equivalent properties of the target.

      An interesting question is how to handle the type here. Does the declaration only match if the type is the same or do we allow coercions? Connections does coerce signal arguments. So that would be an argument for allowing coercion here, too.

      Attachments

        For Gerrit Dashboard: QTBUG-132541
        # Subject Branch Project Status CR V

        Activity

          People

            qtqmlteam Qt Qml Team User
            ulherman Ulf Hermann
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

            Dates

              Created:
              Updated:

              Gerrit Reviews

                There are 2 open Gerrit changes