qml: qualify all signal handler parameters
This commit is contained in:
@@ -310,7 +310,7 @@ Pane {
|
|||||||
address: root.address
|
address: root.address
|
||||||
onFrozenChanged: addressDetailsChanged()
|
onFrozenChanged: addressDetailsChanged()
|
||||||
onLabelChanged: addressDetailsChanged()
|
onLabelChanged: addressDetailsChanged()
|
||||||
onAuthRequired: {
|
onAuthRequired: (method, authMessage) => {
|
||||||
app.handleAuthRequired(addressdetails, method, authMessage)
|
app.handleAuthRequired(addressdetails, method, authMessage)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -202,7 +202,7 @@ ElDialog {
|
|||||||
wallet: Daemon.currentWallet
|
wallet: Daemon.currentWallet
|
||||||
channelid: dialog.channelid
|
channelid: dialog.channelid
|
||||||
|
|
||||||
onAuthRequired: {
|
onAuthRequired: (method, authMessage) => {
|
||||||
app.handleAuthRequired(channeldetails, method, authMessage)
|
app.handleAuthRequired(channeldetails, method, authMessage)
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -228,7 +228,7 @@ ElDialog {
|
|||||||
dialog.close()
|
dialog.close()
|
||||||
}
|
}
|
||||||
|
|
||||||
onChannelCloseFailed: {
|
onChannelCloseFailed: (message) => {
|
||||||
errorText.text = message
|
errorText.text = message
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -212,16 +212,19 @@ ElDialog {
|
|||||||
ChannelOpener {
|
ChannelOpener {
|
||||||
id: channelopener
|
id: channelopener
|
||||||
wallet: Daemon.currentWallet
|
wallet: Daemon.currentWallet
|
||||||
onAuthRequired: {
|
onAuthRequired: (method, authMessage) => {
|
||||||
app.handleAuthRequired(channelopener, method, authMessage)
|
app.handleAuthRequired(channelopener, method, authMessage)
|
||||||
}
|
}
|
||||||
onValidationError: {
|
onValidationError: (code, message) => {
|
||||||
if (code == 'invalid_nodeid') {
|
if (code == 'invalid_nodeid') {
|
||||||
var dialog = app.messageDialog.createObject(app, { title: qsTr('Error'), 'text': message })
|
var dialog = app.messageDialog.createObject(app, {
|
||||||
|
title: qsTr('Error'),
|
||||||
|
text: message
|
||||||
|
})
|
||||||
dialog.open()
|
dialog.open()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
onConflictingBackup: {
|
onConflictingBackup: (message) => {
|
||||||
var dialog = app.messageDialog.createObject(app, { 'text': message, 'yesno': true })
|
var dialog = app.messageDialog.createObject(app, { 'text': message, 'yesno': true })
|
||||||
dialog.open()
|
dialog.open()
|
||||||
dialog.accepted.connect(function() {
|
dialog.accepted.connect(function() {
|
||||||
@@ -237,17 +240,17 @@ ElDialog {
|
|||||||
})
|
})
|
||||||
dialog.open()
|
dialog.open()
|
||||||
}
|
}
|
||||||
onChannelOpening: {
|
onChannelOpening: (peer) => {
|
||||||
console.log('Channel is opening')
|
console.log('Channel is opening')
|
||||||
app.channelOpenProgressDialog.reset()
|
app.channelOpenProgressDialog.reset()
|
||||||
app.channelOpenProgressDialog.peer = peer
|
app.channelOpenProgressDialog.peer = peer
|
||||||
app.channelOpenProgressDialog.open()
|
app.channelOpenProgressDialog.open()
|
||||||
}
|
}
|
||||||
onChannelOpenError: {
|
onChannelOpenError: (message) => {
|
||||||
app.channelOpenProgressDialog.state = 'failed'
|
app.channelOpenProgressDialog.state = 'failed'
|
||||||
app.channelOpenProgressDialog.error = message
|
app.channelOpenProgressDialog.error = message
|
||||||
}
|
}
|
||||||
onChannelOpenSuccess: {
|
onChannelOpenSuccess: (cid, has_onchain_backup, min_depth, tx_complete) => {
|
||||||
var message = qsTr('Channel established.') + ' '
|
var message = qsTr('Channel established.') + ' '
|
||||||
+ qsTr('This channel will be usable after %1 confirmations').arg(min_depth)
|
+ qsTr('This channel will be usable after %1 confirmations').arg(min_depth)
|
||||||
if (!tx_complete) {
|
if (!tx_complete) {
|
||||||
|
|||||||
@@ -399,7 +399,7 @@ Pane {
|
|||||||
id: txdetails
|
id: txdetails
|
||||||
wallet: Daemon.currentWallet
|
wallet: Daemon.currentWallet
|
||||||
onLabelChanged: root.detailsChanged()
|
onLabelChanged: root.detailsChanged()
|
||||||
onConfirmRemoveLocalTx: {
|
onConfirmRemoveLocalTx: (message) => {
|
||||||
var dialog = app.messageDialog.createObject(app, { text: message, yesno: true })
|
var dialog = app.messageDialog.createObject(app, { text: message, yesno: true })
|
||||||
dialog.accepted.connect(function() {
|
dialog.accepted.connect(function() {
|
||||||
txdetails.removeLocalTx(true)
|
txdetails.removeLocalTx(true)
|
||||||
|
|||||||
@@ -264,16 +264,20 @@ Item {
|
|||||||
InvoiceParser {
|
InvoiceParser {
|
||||||
id: invoiceParser
|
id: invoiceParser
|
||||||
wallet: Daemon.currentWallet
|
wallet: Daemon.currentWallet
|
||||||
onValidationError: {
|
onValidationError: (code, message) => {
|
||||||
var dialog = app.messageDialog.createObject(app, { text: message })
|
var dialog = app.messageDialog.createObject(app, {
|
||||||
|
text: message
|
||||||
|
})
|
||||||
dialog.closed.connect(function() {
|
dialog.closed.connect(function() {
|
||||||
restartSendDialog()
|
restartSendDialog()
|
||||||
})
|
})
|
||||||
dialog.open()
|
dialog.open()
|
||||||
}
|
}
|
||||||
onValidationWarning: {
|
onValidationWarning: (code, message) => {
|
||||||
if (code == 'no_channels') {
|
if (code == 'no_channels') {
|
||||||
var dialog = app.messageDialog.createObject(app, { text: message })
|
var dialog = app.messageDialog.createObject(app, {
|
||||||
|
text: message
|
||||||
|
})
|
||||||
dialog.closed.connect(function() {
|
dialog.closed.connect(function() {
|
||||||
restartSendDialog()
|
restartSendDialog()
|
||||||
})
|
})
|
||||||
@@ -284,18 +288,28 @@ Item {
|
|||||||
}
|
}
|
||||||
onValidationSuccess: {
|
onValidationSuccess: {
|
||||||
closeSendDialog()
|
closeSendDialog()
|
||||||
var dialog = invoiceDialog.createObject(app, { invoice: invoiceParser, payImmediately: invoiceParser.isLnurlPay })
|
var dialog = invoiceDialog.createObject(app, {
|
||||||
|
invoice: invoiceParser,
|
||||||
|
payImmediately: invoiceParser.isLnurlPay
|
||||||
|
})
|
||||||
dialog.open()
|
dialog.open()
|
||||||
}
|
}
|
||||||
onInvoiceCreateError: console.log(code + ' ' + message)
|
onInvoiceCreateError: (code, message) => {
|
||||||
|
console.log(code + ' ' + message)
|
||||||
|
}
|
||||||
|
|
||||||
onLnurlRetrieved: {
|
onLnurlRetrieved: {
|
||||||
closeSendDialog()
|
closeSendDialog()
|
||||||
var dialog = lnurlPayDialog.createObject(app, { invoiceParser: invoiceParser })
|
var dialog = lnurlPayDialog.createObject(app, {
|
||||||
|
invoiceParser: invoiceParser
|
||||||
|
})
|
||||||
dialog.open()
|
dialog.open()
|
||||||
}
|
}
|
||||||
onLnurlError: {
|
onLnurlError: (code, message) => {
|
||||||
var dialog = app.messageDialog.createObject(app, { title: qsTr('Error'), text: message })
|
var dialog = app.messageDialog.createObject(app, {
|
||||||
|
title: qsTr('Error'),
|
||||||
|
text: message }
|
||||||
|
)
|
||||||
dialog.open()
|
dialog.open()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -477,7 +491,7 @@ Item {
|
|||||||
finalizer: TxFinalizer {
|
finalizer: TxFinalizer {
|
||||||
wallet: Daemon.currentWallet
|
wallet: Daemon.currentWallet
|
||||||
canRbf: true
|
canRbf: true
|
||||||
onFinished: {
|
onFinished: (signed, saved, complete) => {
|
||||||
if (!complete) {
|
if (!complete) {
|
||||||
var msg
|
var msg
|
||||||
if (wallet.isWatchOnly) {
|
if (wallet.isWatchOnly) {
|
||||||
|
|||||||
@@ -405,11 +405,14 @@ ApplicationWindow
|
|||||||
swaphelper: SwapHelper {
|
swaphelper: SwapHelper {
|
||||||
id: _swaphelper
|
id: _swaphelper
|
||||||
wallet: Daemon.currentWallet
|
wallet: Daemon.currentWallet
|
||||||
onAuthRequired: {
|
onAuthRequired: (method, authMessage) => {
|
||||||
app.handleAuthRequired(_swaphelper, method, authMessage)
|
app.handleAuthRequired(_swaphelper, method, authMessage)
|
||||||
}
|
}
|
||||||
onError: {
|
onError: (message) => {
|
||||||
var dialog = app.messageDialog.createObject(app, { title: qsTr('Error'), text: message })
|
var dialog = app.messageDialog.createObject(app, {
|
||||||
|
title: qsTr('Error'),
|
||||||
|
text: message
|
||||||
|
})
|
||||||
dialog.open()
|
dialog.open()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user