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

Loader with sourceComponent results in double calls to onLoaded

    XMLWordPrintable

Details

    • 82ff3f484c7ec49e60b7fddf23794937974a6768, 80f74d3801ddece4d34b4a663bf1bdc23ecc4a67

    Description

      Run the code below. Note that "onLoaded called. status = 1" is printed twice (i.e. one time too many).

      import QtQuick 1.0
      
      Item {
          width: 640
          height: 480
      
          Loader {
              sourceComponent: redRectComponent
              onLoaded: print("onLoaded called. status = " + status)
          }
      
          Component {
              id: redRectComponent
              Rectangle {
                  width: 100
                  height: 100
                  color: "red"
              }
          }
      }
      

      Attachments

        Issue Links

          Activity

            People

              bealam Bea Lam (closed Nokia identity) (Inactive)
              mathiasm Mathias Malmqvist
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: