qml: wallet loading indicator as modal dialog, unclosable
This commit is contained in:
@@ -171,30 +171,6 @@ ApplicationWindow
|
||||
}
|
||||
}
|
||||
|
||||
Pane {
|
||||
id: walletLoadingPane
|
||||
parent: Overlay.overlay
|
||||
anchors.fill: parent
|
||||
background: Rectangle { color: Material.dialogColor }
|
||||
visible: Daemon.loading
|
||||
|
||||
ColumnLayout {
|
||||
anchors.centerIn: parent
|
||||
spacing: 2 * constants.paddingXLarge
|
||||
|
||||
Label {
|
||||
Layout.alignment: Qt.AlignHCenter
|
||||
text: qsTr('Opening wallet...')
|
||||
font.pixelSize: constants.fontSizeXXLarge
|
||||
}
|
||||
|
||||
BusyIndicator {
|
||||
Layout.alignment: Qt.AlignHCenter
|
||||
running: Daemon.loading
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Timer {
|
||||
id: coverTimer
|
||||
interval: 10
|
||||
@@ -283,6 +259,14 @@ ApplicationWindow
|
||||
}
|
||||
}
|
||||
|
||||
property alias loadingWalletDialog: _loadingWalletDialog
|
||||
Component {
|
||||
id: _loadingWalletDialog
|
||||
LoadingWalletDialog {
|
||||
onClosed: destroy()
|
||||
}
|
||||
}
|
||||
|
||||
property alias channelOpenProgressDialog: _channelOpenProgressDialog
|
||||
ChannelOpenProgressDialog {
|
||||
id: _channelOpenProgressDialog
|
||||
@@ -409,6 +393,13 @@ ApplicationWindow
|
||||
function onAuthRequired(method) {
|
||||
handleAuthRequired(Daemon, method)
|
||||
}
|
||||
function onLoadingChanged() {
|
||||
if (!Daemon.loading)
|
||||
return
|
||||
console.log('wallet loading')
|
||||
var dialog = loadingWalletDialog.createObject(app, { allowClose: false } )
|
||||
dialog.open()
|
||||
}
|
||||
}
|
||||
|
||||
Connections {
|
||||
|
||||
Reference in New Issue
Block a user