aboutsummaryrefslogtreecommitdiff
path: root/components/StandardButton.qml
diff options
context:
space:
mode:
authorxiphon <xiphon@protonmail.com>2020-04-04 13:22:25 +0000
committerxiphon <xiphon@protonmail.com>2020-04-06 16:59:33 +0000
commit6ed7fcec67109602a6b1dbe390b4274b9467931e (patch)
tree4d983c69547036bc1c883d525ceb5d8e0425e3b7 /components/StandardButton.qml
parentdf54439972b885476ccc13b468b17508493521c7 (diff)
downloadmonzero-gui-6ed7fcec67109602a6b1dbe390b4274b9467931e.tar.gz
monzero-gui-6ed7fcec67109602a6b1dbe390b4274b9467931e.tar.xz
monzero-gui-6ed7fcec67109602a6b1dbe390b4274b9467931e.zip
UpdateDialog: implement update download functionality
Diffstat (limited to 'components/StandardButton.qml')
-rw-r--r--components/StandardButton.qml16
1 files changed, 13 insertions, 3 deletions
diff --git a/components/StandardButton.qml b/components/StandardButton.qml
index 77cd2dad..5b4e2279 100644
--- a/components/StandardButton.qml
+++ b/components/StandardButton.qml
@@ -33,11 +33,17 @@ import "../components" as MoneroComponents
Item {
id: button
+ property bool primary: true
property string rightIcon: ""
property string rightIconInactive: ""
- property string textColor: button.enabled? MoneroComponents.Style.buttonTextColor: MoneroComponents.Style.buttonTextColorDisabled
+ property color textColor: !button.enabled
+ ? MoneroComponents.Style.buttonTextColorDisabled
+ : primary
+ ? MoneroComponents.Style.buttonTextColor
+ : MoneroComponents.Style.buttonSecondaryTextColor;
property bool small: false
property alias text: label.text
+ property alias fontBold: label.font.bold
property int fontSize: {
if(small) return 14;
else return 16;
@@ -70,7 +76,9 @@ Item {
when: buttonArea.containsMouse || button.focus
PropertyChanges {
target: buttonRect
- color: MoneroComponents.Style.buttonBackgroundColorHover
+ color: primary
+ ? MoneroComponents.Style.buttonBackgroundColorHover
+ : MoneroComponents.Style.buttonSecondaryBackgroundColorHover
}
},
State {
@@ -78,7 +86,9 @@ Item {
when: button.enabled
PropertyChanges {
target: buttonRect
- color: MoneroComponents.Style.buttonBackgroundColor
+ color: primary
+ ? MoneroComponents.Style.buttonBackgroundColor
+ : MoneroComponents.Style.buttonSecondaryBackgroundColor
}
},
State {