[PlasmaComponents/TabGroup] Fix check if item inherits from Page
TabGroup had a feature where if the item inserted in the stack was a PlasmaComponents.Page it would update a property. The check that this property exists was previously bogus leading to errors if TabGroup was used with non-Page items that happened to have the same property, such as Loader
This commit is contained in:
parent
e03b9bf081
commit
1a1e32bff3
@ -127,7 +127,7 @@ FocusScope {
|
||||
function incomingDone() {
|
||||
state = ""
|
||||
if (priv.incomingPage) {
|
||||
if (priv.incomingPage.status != undefined) {
|
||||
if (priv.incomingPage instanceof PlasmaComponents.Page) {
|
||||
priv.incomingPage.status = PlasmaComponents.PageStatus.Active
|
||||
}
|
||||
priv.incomingPage = null
|
||||
@ -136,7 +136,7 @@ FocusScope {
|
||||
|
||||
function outgoingDone() {
|
||||
if (priv.outgoingPage) {
|
||||
if (priv.outgoingPage.status != undefined) {
|
||||
if (priv.outgoingPage instanceof PlasmaComponents.Page) {
|
||||
priv.outgoingPage.status = PlasmaComponents.PageStatus.Active
|
||||
}
|
||||
priv.outgoingPage.visible = false
|
||||
@ -251,7 +251,7 @@ FocusScope {
|
||||
currentTabContainer.visible = true
|
||||
incomingPage = currentTabContainer.children[0]
|
||||
incomingPage.visible = true
|
||||
if (incomingPage.status != undefined) {
|
||||
if (incomingPage instanceof PlasmaComponents.Page) {
|
||||
incomingPage.status = PlasmaComponents.PageStatus.Activating
|
||||
}
|
||||
if (currentIndex < newCurrentIndex) {
|
||||
|
Loading…
Reference in New Issue
Block a user