Revert "fix(RightTabView): revert to using a StackLayout instead of a Loader"
This reverts commit b58612f070
.
This commit is contained in:
parent
0fbb2ebcb5
commit
a6abdbeeef
|
@ -30,7 +30,8 @@ RightTabBaseView {
|
||||||
function resetView() {
|
function resetView() {
|
||||||
stack.currentIndex = 0
|
stack.currentIndex = 0
|
||||||
root.currentTabIndex = 0
|
root.currentTabIndex = 0
|
||||||
historyView.resetView()
|
if (walletTabBar.currentIndex === 2)
|
||||||
|
mainViewLoader.item.resetView()
|
||||||
}
|
}
|
||||||
|
|
||||||
function resetStack() {
|
function resetStack() {
|
||||||
|
@ -119,12 +120,21 @@ RightTabBaseView {
|
||||||
highlighted: checked
|
highlighted: checked
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
StackLayout {
|
Loader {
|
||||||
id: mainViewLoader
|
id: mainViewLoader
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.fillHeight: true
|
Layout.fillHeight: true
|
||||||
currentIndex: walletTabBar.currentIndex
|
sourceComponent: {
|
||||||
|
switch (walletTabBar.currentIndex) {
|
||||||
|
case 0: return assetsView
|
||||||
|
case 1: return collectiblesView
|
||||||
|
case 2: return historyView
|
||||||
|
}
|
||||||
|
}
|
||||||
|
active: visible
|
||||||
|
|
||||||
|
Component {
|
||||||
|
id: assetsView
|
||||||
AssetsView {
|
AssetsView {
|
||||||
areAssetsLoading: RootStore.overview.balanceLoading
|
areAssetsLoading: RootStore.overview.balanceLoading
|
||||||
assets: RootStore.walletAssetsStore.groupedAccountAssetsModel
|
assets: RootStore.walletAssetsStore.groupedAccountAssetsModel
|
||||||
|
@ -152,7 +162,9 @@ RightTabBaseView {
|
||||||
onManageTokensRequested: Global.changeAppSectionBySectionType(Constants.appSection.profile, Constants.settingsSubsection.wallet,
|
onManageTokensRequested: Global.changeAppSectionBySectionType(Constants.appSection.profile, Constants.settingsSubsection.wallet,
|
||||||
Constants.walletSettingsSubsection.manageAssets)
|
Constants.walletSettingsSubsection.manageAssets)
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
Component {
|
||||||
|
id: collectiblesView
|
||||||
CollectiblesView {
|
CollectiblesView {
|
||||||
collectiblesModel: RootStore.collectiblesStore.allCollectiblesModel
|
collectiblesModel: RootStore.collectiblesStore.allCollectiblesModel
|
||||||
networkFilters: RootStore.networkFilters
|
networkFilters: RootStore.networkFilters
|
||||||
|
@ -176,7 +188,9 @@ RightTabBaseView {
|
||||||
onManageTokensRequested: Global.changeAppSectionBySectionType(Constants.appSection.profile, Constants.settingsSubsection.wallet,
|
onManageTokensRequested: Global.changeAppSectionBySectionType(Constants.appSection.profile, Constants.settingsSubsection.wallet,
|
||||||
Constants.walletSettingsSubsection.manageCollectibles)
|
Constants.walletSettingsSubsection.manageCollectibles)
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
Component {
|
||||||
|
id: historyView
|
||||||
HistoryView {
|
HistoryView {
|
||||||
id: historyView
|
id: historyView
|
||||||
overview: RootStore.overview
|
overview: RootStore.overview
|
||||||
|
@ -191,6 +205,7 @@ RightTabBaseView {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
CollectibleDetailView {
|
CollectibleDetailView {
|
||||||
collectible: RootStore.collectiblesStore.detailedCollectible
|
collectible: RootStore.collectiblesStore.detailedCollectible
|
||||||
isCollectibleLoading: RootStore.collectiblesStore.isDetailedCollectibleLoading
|
isCollectibleLoading: RootStore.collectiblesStore.isDetailedCollectibleLoading
|
||||||
|
|
|
@ -40,10 +40,8 @@ ColumnLayout {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
onVisibleChanged: {
|
Component.onCompleted: {
|
||||||
if (!visible)
|
filterPanelLoader.active = true
|
||||||
return
|
|
||||||
|
|
||||||
if (RootStore.transactionActivityStatus.isFilterDirty) {
|
if (RootStore.transactionActivityStatus.isFilterDirty) {
|
||||||
WalletStores.RootStore.currentActivityFiltersStore.applyAllFilters()
|
WalletStores.RootStore.currentActivityFiltersStore.applyAllFilters()
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue