finetuning of the inactive states

contributes to: issue CURA-184
This commit is contained in:
Tamara Hogenhout 2015-09-22 15:37:46 +02:00
parent e1c113a81a
commit 781ab5fdca
2 changed files with 8 additions and 5 deletions

View file

@ -194,10 +194,13 @@ Rectangle {
style: ButtonStyle { style: ButtonStyle {
background: Rectangle { background: Rectangle {
opacity: control.enabled ? 1.0 : 0.5 //opacity: control.enabled ? 1.0 : 0.5
//Behavior on opacity { NumberAnimation { duration: 50; } } //Behavior on opacity { NumberAnimation { duration: 50; } }
color: { color: {
if(control.enabled && control.hovered) { if(!control.enabled){
return UM.Theme.colors.button;
}
else if(control.enabled && control.hovered) {
return UM.Theme.colors.load_save_button_hover return UM.Theme.colors.load_save_button_hover
} else { } else {
return UM.Theme.colors.load_save_button return UM.Theme.colors.load_save_button
@ -221,7 +224,7 @@ Rectangle {
} }
Label { Label {
id: actualLabel id: actualLabel
opacity: control.enabled ? 1.0 : 0.5 opacity: control.enabled ? 1.0 : 0.4
//Behavior on opacity { NumberAnimation { duration: 50; } } //Behavior on opacity { NumberAnimation { duration: 50; } }
anchors.centerIn: parent anchors.centerIn: parent
color: UM.Theme.colors.load_save_button_text color: UM.Theme.colors.load_save_button_text

View file

@ -156,7 +156,7 @@ QtObject {
Label { Label {
id: tool_button_arrow id: tool_button_arrow
opacity: !control.enabled ? 0.6 : 1.0 opacity: !control.enabled ? 0.4 : 1.0
anchors.right: parent.right; anchors.right: parent.right;
anchors.rightMargin: (UM.Theme.sizes.button.width - UM.Theme.sizes.button_icon.width - tool_button_arrow.width) / 2 anchors.rightMargin: (UM.Theme.sizes.button.width - UM.Theme.sizes.button_icon.width - tool_button_arrow.width) / 2
anchors.verticalCenter: parent.verticalCenter; anchors.verticalCenter: parent.verticalCenter;
@ -171,7 +171,7 @@ QtObject {
label: Item { label: Item {
Image { Image {
anchors.centerIn: parent; anchors.centerIn: parent;
opacity: !control.enabled ? 0.6 : 1.0 opacity: !control.enabled ? 0.4 : 1.0
source: control.iconSource; source: control.iconSource;
width: UM.Theme.sizes.button_icon.width; width: UM.Theme.sizes.button_icon.width;
height: UM.Theme.sizes.button_icon.height; height: UM.Theme.sizes.button_icon.height;