|
|
@ -157,12 +157,6 @@ Pane { |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
property var channelOpenProgressDialogInstance |
|
|
|
Component { |
|
|
|
id: channelOpenProgressDialog |
|
|
|
ChannelOpenProgressDialog { } |
|
|
|
} |
|
|
|
|
|
|
|
ChannelOpener { |
|
|
|
id: channelopener |
|
|
|
wallet: Daemon.currentWallet |
|
|
@ -190,21 +184,22 @@ Pane { |
|
|
|
} |
|
|
|
onChannelOpening: { |
|
|
|
console.log('Channel is opening') |
|
|
|
channelOpenProgressDialogInstance = channelOpenProgressDialog.createObject(app, {peer: peer}) |
|
|
|
channelOpenProgressDialogInstance.open() |
|
|
|
app.channelOpenProgressDialog.reset() |
|
|
|
app.channelOpenProgressDialog.peer = peer |
|
|
|
app.channelOpenProgressDialog.open() |
|
|
|
} |
|
|
|
onChannelOpenError: { |
|
|
|
channelOpenProgressDialogInstance.state = 'failed' |
|
|
|
channelOpenProgressDialogInstance.error = message |
|
|
|
app.channelOpenProgressDialog.state = 'failed' |
|
|
|
app.channelOpenProgressDialog.error = message |
|
|
|
} |
|
|
|
onChannelOpenSuccess: { |
|
|
|
var message = 'success!' |
|
|
|
if (!has_backup) |
|
|
|
message = message + ' (but no backup. TODO: show QR)' |
|
|
|
channelOpenProgressDialogInstance.state = 'success' |
|
|
|
channelOpenProgressDialogInstance.error = message |
|
|
|
app.channelOpenProgressDialog.state = 'success' |
|
|
|
app.channelOpenProgressDialog.error = message |
|
|
|
channelopener.wallet.channelModel.new_channel(cid) |
|
|
|
// app.stack.pop() |
|
|
|
app.stack.pop() |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|