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

Properties not spliced correctly in QML JavaScript

XMLWordPrintable

      class A : public QObject {
          Q_PROPERTY(int foo ...);
      };
      
      class B : public QObject {
          Q_INVOKABLE void foo();
      };
      

      From JavaScript in QML, reading the property "foo" on an instance of type B will return the foo Q_PROPERTY instead of the foo Q_INVOKABLE. That is, properties incorrectly always take precedence over methods.

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

            aakenned Aaron Kennedy
            aakenned Aaron Kennedy
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:

                There are no open Gerrit changes