Small window: close main pane when recycling page

This commit is contained in:
miruka 2020-09-03 11:06:45 -04:00
parent f5c6a2627b
commit 462d3972ff

View File

@ -59,16 +59,20 @@ HLoader {
return true
}
function closeMainPane() {
if (mainPane.collapse) mainPane.close()
}
function takeFocus() {
pageLoader.item.forceActiveFocus()
if (mainPane.collapse) mainPane.close()
closeMainPane()
}
clip: appearAnimation.running
onLoaded: { takeFocus(); appearAnimation.restart() }
onRecycled: appearAnimation.restart()
onRecycled: { closeMainPane(); appearAnimation.restart() }
Component.onCompleted: {
if (! py.startupAnyAccountsSaved) {