touch-packages team mailing list archive
-
touch-packages team
-
Mailing list archive
-
Message #66765
[Bug 1436767] Re: No error output if item is used for the Page assignment
yes, I currently get it working by defining it like:
ExternalPage.qml
Page {
Label {
anchors.centerIn: parent
text: i18n.tr("This is the external page")
}
}
If it is defined to be like:
ExternalPage.qml
import QtQuick 2.0
import Ubuntu.Components 1.1
Item {
anchors.fill: parent
Label {
anchors.centerIn: parent
text: i18n.tr("This is page xxx one")
}
}
It does not work. The intention for the bug is to have some warnings
when non-page is assigned during the running. Otherwise, a developer
does not know what is happening or what could be wrong when an "Item" is
assigned to a page.
Best regards,
XiaoGuo
--
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to ubuntu-ui-toolkit in
Ubuntu.
https://bugs.launchpad.net/bugs/1436767
Title:
No error output if item is used for the Page assignment
Status in ubuntu-ui-toolkit package in Ubuntu:
Opinion
Bug description:
I have a sample QML application at:
https://gitcafe.com/ubuntu/TabApp2.git
You may use the command:
git clone https://gitcafe.com/ubuntu/TabApp2.git
to get the code.
In the ExternalPage.qml,
import QtQuick 2.0
import Ubuntu.Components 1.1
Item {
anchors.fill: parent
Label {
anchors.centerIn: parent
text: i18n.tr("This is page xxx one")
}
}
I defined it as an "Item". However, when I assign it in the following
way:
Tab {
id: externalTab
title: i18n.tr("External")
page: Loader {
id: loader
anchors.fill: parent
source: (tabs.selectedTab === externalTab) ? Qt.resolvedUrl("ExternalPage.qml") : ""
onLoaded: {
console.log( loader.source + " is loaded")
}
}
}
it does not output any error messages, making it hard to use if a
developer does not know how to define it.
Best regards,
XiaoGuo
To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/ubuntu-ui-toolkit/+bug/1436767/+subscriptions
References