Commit 02dabe3c authored by Harald Sitter's avatar Harald Sitter 🏳️‍🌈
Browse files

dont fill the entire page with busy indication

it looks silly to have a huge indicator.

instead use a wrapper item and center the indicator inside
parent 3fd6518c
...@@ -25,32 +25,35 @@ QQC2.StackView { ...@@ -25,32 +25,35 @@ QQC2.StackView {
// it into the stack once they are done with their thing. // it into the stack once they are done with their thing.
property var pendingStack: [] property var pendingStack: []
initialItem: QQC2.BusyIndicator { initialItem: Item {
running: !sambaPlugin.ready || !groupManager.ready QQC2.BusyIndicator {
anchors.centerIn: parent
onRunningChanged: { running: !sambaPlugin.ready || !groupManager.ready
if (running) {
return onRunningChanged: {
} if (running) {
return
}
pendingStack.push("ACLPage.qml") pendingStack.push("ACLPage.qml")
if (!sambaPlugin.userManager.currentUser().inSamba) { if (!sambaPlugin.userManager.currentUser().inSamba) {
pendingStack.push("UserPage.qml") pendingStack.push("UserPage.qml")
} }
if (!groupManager.member) { if (!groupManager.member) {
pendingStack.push("GroupPage.qml") pendingStack.push("GroupPage.qml")
} }
if (!sambaPlugin.isSambaInstalled()) { if (!sambaPlugin.isSambaInstalled()) {
// NB: the plugin may be built without installer support! // NB: the plugin may be built without installer support!
if (Samba.Installer === undefined) { if (Samba.Installer === undefined) {
pendingStack.push("MissingSambaPage.qml") pendingStack.push("MissingSambaPage.qml")
} else { } else {
pendingStack.push("InstallPage.qml") pendingStack.push("InstallPage.qml")
}
} }
}
stack.clear() stack.clear()
stack.push(pendingStack.pop()) stack.push(pendingStack.pop())
}
} }
} }
} }
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment