Merge pull request #1286

cd4418d Receive: make tracking optional
a9331a7 Set daemon address to WalletManager (requires #3576)
This commit is contained in:
luigi1111 2018-04-24 21:40:46 -05:00
commit 1956f5896d
No known key found for this signature in database
GPG key ID: F4ACA0183641E010
2 changed files with 12 additions and 2 deletions

View file

@ -420,7 +420,9 @@ ApplicationWindow {
function connectRemoteNode() { function connectRemoteNode() {
console.log("connecting remote node"); console.log("connecting remote node");
persistentSettings.useRemoteNode = true; persistentSettings.useRemoteNode = true;
currentWallet.initAsync(persistentSettings.remoteNodeAddress); currentDaemonAddress = persistentSettings.remoteNodeAddress;
currentWallet.initAsync(currentDaemonAddress);
walletManager.setDaemonAddress(currentDaemonAddress);
remoteNodeConnected = true; remoteNodeConnected = true;
} }
@ -429,6 +431,7 @@ ApplicationWindow {
persistentSettings.useRemoteNode = false; persistentSettings.useRemoteNode = false;
currentDaemonAddress = localDaemonAddress currentDaemonAddress = localDaemonAddress
currentWallet.initAsync(currentDaemonAddress); currentWallet.initAsync(currentDaemonAddress);
walletManager.setDaemonAddress(currentDaemonAddress);
remoteNodeConnected = false; remoteNodeConnected = false;
} }

View file

@ -72,7 +72,7 @@ Rectangle {
} }
function update() { function update() {
if (!appWindow.currentWallet) { if (!appWindow.currentWallet || !trackingEnabled.checked) {
setTrackingLineText("-") setTrackingLineText("-")
return return
} }
@ -325,6 +325,11 @@ Rectangle {
} }
} }
CheckBox {
id: trackingEnabled
text: qsTr("Enable") + translationManager.emptyString
}
TextEdit { TextEdit {
id: trackingLine id: trackingLine
readOnly: true readOnly: true
@ -407,6 +412,8 @@ Rectangle {
update() update()
timer.running = true timer.running = true
trackingEnabled.checked = false
} }
function onPageClosed() { function onPageClosed() {