aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorluigi1111 <luigi1111w@gmail.com>2018-11-09 13:24:36 -0600
committerluigi1111 <luigi1111w@gmail.com>2018-11-09 13:24:36 -0600
commit270a6379249a149c89ad54d0b232a106bbf61d8e (patch)
tree216d3a13a1c5ff1461377435b031126b16686734
parent71603973c882faedb971324baed36e03af50e8ce (diff)
parent42a9e2fe35e1b22d3597df1281dfeeb130fe18fa (diff)
downloadmonzero-gui-270a6379249a149c89ad54d0b232a106bbf61d8e.tar.gz
monzero-gui-270a6379249a149c89ad54d0b232a106bbf61d8e.tar.xz
monzero-gui-270a6379249a149c89ad54d0b232a106bbf61d8e.zip
Merge pull request #1728
808ecf5 settings-node: implement correct 'Start/Stop daemon' button logic (xiphon) 42a9e2f settings-node: change element id 'btnStopNode' to 'btnStartStopNode' (xiphon)
-rw-r--r--pages/settings/SettingsNode.qml16
1 files changed, 10 insertions, 6 deletions
diff --git a/pages/settings/SettingsNode.qml b/pages/settings/SettingsNode.qml
index 0e9bccfb..b690c70e 100644
--- a/pages/settings/SettingsNode.qml
+++ b/pages/settings/SettingsNode.qml
@@ -382,28 +382,32 @@ Rectangle{
Layout.preferredWidth: parent.width
Rectangle {
- id: rectStopNode
- color: MoneroComponents.Style.buttonBackgroundColorDisabled
- width: btnStopNode.width + 40
+ id: rectStartStopNode
+ color: MoneroComponents.Style.buttonBackgroundColor
+ width: btnStartStopNode.width + 40
height: 24
radius: 2
Text {
- id: btnStopNode
+ id: btnStartStopNode
anchors.verticalCenter: parent.verticalCenter
anchors.horizontalCenter: parent.horizontalCenter
color: MoneroComponents.Style.defaultFontColor
font.family: MoneroComponents.Style.fontRegular.name
font.pixelSize: 14 * scaleRatio
font.bold: true
- text: qsTr("Stop local node") + translationManager.emptyString
+ text: (appWindow.daemonRunning ? qsTr("Stop local node") : qsTr("Start daemon")) + translationManager.emptyString
}
MouseArea {
cursorShape: Qt.PointingHandCursor
anchors.fill: parent
onClicked: {
- appWindow.stopDaemon();
+ if (appWindow.daemonRunning) {
+ appWindow.stopDaemon();
+ } else {
+ appWindow.startDaemon(persistentSettings.daemonFlags);
+ }
}
}
}