1
mirror of https://github.com/monero-project/monero-gui synced 2025-01-02 21:26:24 +01:00

Merge pull request #851

86e9f38 Only prompt for daemon auto start when daemon address is local (Jaquee)
This commit is contained in:
Riccardo Spagni 2017-09-04 17:17:52 +02:00
commit 56868c06b5
No known key found for this signature in database
GPG Key ID: 55432DF31CCD4FCD
2 changed files with 11 additions and 11 deletions

View File

@ -302,7 +302,7 @@ ApplicationWindow {
middlePanel.transferView.updatePriorityDropdown();
// If wallet isnt connected and no daemon is running - Ask
if(!walletInitialized && status === Wallet.ConnectionStatus_Disconnected && !daemonManager.running(persistentSettings.testnet)){
if(isDaemonLocal() && !walletInitialized && status === Wallet.ConnectionStatus_Disconnected && !daemonManager.running(persistentSettings.testnet)){
daemonManagerDialog.open();
}
// initialize transaction history once wallet is initialized first time;
@ -1376,4 +1376,14 @@ ApplicationWindow {
onTriggered: checkUpdates()
}
function isDaemonLocal() {
var daemonAddress = appWindow.persistentSettings.daemon_address
if (daemonAddress === "")
return false
var daemonHost = daemonAddress.split(":")[0]
if (daemonHost === "127.0.0.1" || daemonHost === "localhost")
return true
return false
}
}

View File

@ -37,16 +37,6 @@ Rectangle {
color: "#F0EEEE"
property var currentHashRate: 0
function isDaemonLocal() {
var daemonAddress = appWindow.persistentSettings.daemon_address
if (daemonAddress === "")
return false
var daemonHost = daemonAddress.split(":")[0]
if (daemonHost === "127.0.0.1" || daemonHost === "localhost")
return true
return false
}
/* main layout */
ColumnLayout {
id: mainLayout