Public bug reported:

If using APL and setting the primaryPageSource:
Qt.resolvedUrl("MyPage.qml) the APL is so slow to load that the
primaryPage value doesnt exist until way after the component.oncompleted
signal is emitted.

I came across this issue when using the contenthub. if i select a file
in Telegram for example and my app recieves the transfer it tries to add
a page to the APL: addPageToCurrentColumn(pageLayout.primaryPage,
Qt.resolvedUrl("MyPage2.qml"))

Error:

qml: No SourcePage specified. Page will not be added.


Note: setting primaryPage: MyPage{} works without issue and resolves. 

Example:

import QtQuick 2.4
import Ubuntu.Components 1.3


MainView {
    objectName: "mainView"
    applicationName: "aplTest.Testers"

    width: units.gu(100)
    height: units.gu(100)

    AdaptivePageLayout {
        id: apl
        anchors.fill: parent
        primaryPageSource: Qt.resolvedUrl("UI_FileOne.qml") //<-- qml: No 
sourcePage specified. Page will not be added.
        //primaryPage: UI_FileOne{} //<-- This works

        layouts: [
            PageColumnsLayout {
                when: true;
                // Just a single column layout
                PageColumn {
                    fillWidth: true
                }

            }
        ]

        Component.onCompleted: {

            apl.addPageToCurrentColumn(apl.primaryPage,
Qt.resolvedUrl("UI_FileTwo.qml"));

        }
    }//AdaptivePageLayout

}//Mainview

** Affects: ubuntu-ui-toolkit (Ubuntu)
     Importance: Undecided
         Status: New

-- 
You received this bug notification because you are a member of Ubuntu
SDK bug tracking, which is subscribed to ubuntu-ui-toolkit in Ubuntu.
https://bugs.launchpad.net/bugs/1598491

Title:
  AdaptivePageLayout primaryPageSource: is slow to load

Status in ubuntu-ui-toolkit package in Ubuntu:
  New

Bug description:
  If using APL and setting the primaryPageSource:
  Qt.resolvedUrl("MyPage.qml) the APL is so slow to load that the
  primaryPage value doesnt exist until way after the
  component.oncompleted signal is emitted.

  I came across this issue when using the contenthub. if i select a file
  in Telegram for example and my app recieves the transfer it tries to
  add a page to the APL: addPageToCurrentColumn(pageLayout.primaryPage,
  Qt.resolvedUrl("MyPage2.qml"))

  Error:

  qml: No SourcePage specified. Page will not be added.

  
  Note: setting primaryPage: MyPage{} works without issue and resolves. 

  Example:

  import QtQuick 2.4
  import Ubuntu.Components 1.3

  
  MainView {
      objectName: "mainView"
      applicationName: "aplTest.Testers"

      width: units.gu(100)
      height: units.gu(100)

      AdaptivePageLayout {
          id: apl
          anchors.fill: parent
          primaryPageSource: Qt.resolvedUrl("UI_FileOne.qml") //<-- qml: No 
sourcePage specified. Page will not be added.
          //primaryPage: UI_FileOne{} //<-- This works

          layouts: [
              PageColumnsLayout {
                  when: true;
                  // Just a single column layout
                  PageColumn {
                      fillWidth: true
                  }

              }
          ]

          Component.onCompleted: {

              apl.addPageToCurrentColumn(apl.primaryPage,
  Qt.resolvedUrl("UI_FileTwo.qml"));

          }
      }//AdaptivePageLayout

  }//Mainview

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/ubuntu-ui-toolkit/+bug/1598491/+subscriptions

-- 
Mailing list: https://launchpad.net/~ubuntu-sdk-bugs
Post to     : ubuntu-sdk-bugs@lists.launchpad.net
Unsubscribe : https://launchpad.net/~ubuntu-sdk-bugs
More help   : https://help.launchpad.net/ListHelp

Reply via email to