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

QQmlComponent is unusable after initial property errors

XMLWordPrintable

    • 79f9e22ef7 (qt/qtdeclarative/dev) 79f9e22ef7 (qt/tqtc-qtdeclarative/dev)

      If invalid properties are passed to QQmlComponent::createWithInitialProperties or QQmlComponent::setInitialProperties, QQmlComponent goes into the error state and is impossible to use again. See the attached testcase.

      Those properties are set for a single instance, so I wouldn't expect them to break the component.

      A workaround is to reach into QQmlComponentPrivate and clear the errors after that happens:

      QQmlComponentPrivate::get(component)->state.errors.clear();
      

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

            agolubev Andrei Golubev
            special John Brooks
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved:

                There are no open Gerrit changes