Commit 207e4885 authored by Yasen's avatar Yasen

Custom Main Toolbar drawer visual improvements

Drawer now affected by theme, consistent with the rest of the active elements.

TODO: Add hover for desktop
parent abab5199
...@@ -22,7 +22,8 @@ Button { ...@@ -22,7 +22,8 @@ Button {
background: Rectangle { background: Rectangle {
anchors.fill: parent anchors.fill: parent
color: mouseArea.pressed ? qgcPal.buttonHighlight : Qt.rgba(0,0,0,0) color: qgcPal.buttonHighlight
visible: (mouseArea.pressed || button.checked)
} }
contentItem: Row { contentItem: Row {
...@@ -40,7 +41,7 @@ Button { ...@@ -40,7 +41,7 @@ Button {
width: height width: height
sourceSize.height: parent.height sourceSize.height: parent.height
fillMode: Image.PreserveAspectFit fillMode: Image.PreserveAspectFit
color: (mouseArea.pressed || button.checked) ? qgcPal.primaryButton : qgcPal.buttonText color: qgcPal.buttonText
source: button.icon.source source: button.icon.source
anchors.verticalCenter: parent.verticalCenter anchors.verticalCenter: parent.verticalCenter
} }
...@@ -48,7 +49,7 @@ Button { ...@@ -48,7 +49,7 @@ Button {
id: _label id: _label
visible: text !== "" visible: text !== ""
text: button.text text: button.text
color: (mouseArea.pressed || button.checked) ? qgcPal.primaryButton : qgcPal.buttonText color: qgcPal.buttonText
anchors.verticalCenter: parent.verticalCenter anchors.verticalCenter: parent.verticalCenter
} }
} }
......
...@@ -169,10 +169,10 @@ Item { ...@@ -169,10 +169,10 @@ Item {
} }
ColumnLayout { ColumnLayout {
id: buttons id: buttons
spacing: 0
anchors.top: parent.top anchors.top: parent.top
anchors.left: parent.left anchors.left: parent.left
anchors.right: parent.right anchors.right: parent.right
spacing: ScreenTools.defaultFontPixelHeight * 0.125
Rectangle { Rectangle {
Layout.alignment: Qt.AlignVCenter Layout.alignment: Qt.AlignVCenter
width: parent.width width: parent.width
...@@ -181,6 +181,7 @@ Item { ...@@ -181,6 +181,7 @@ Item {
} }
CustomToolBarButton { CustomToolBarButton {
id: flyButton id: flyButton
spacing: 1
text: qsTr("Fly") text: qsTr("Fly")
icon.source: "/qmlimages/PaperPlane.svg" icon.source: "/qmlimages/PaperPlane.svg"
Layout.fillWidth: true Layout.fillWidth: true
...@@ -254,10 +255,9 @@ Item { ...@@ -254,10 +255,9 @@ Item {
ColumnLayout { ColumnLayout {
id: lowerButtons id: lowerButtons
anchors.bottom: parent.bottom anchors.bottom: parent.bottom
anchors.bottomMargin: ScreenTools.defaultFontPixelHeight * 0.125
anchors.left: parent.left anchors.left: parent.left
anchors.right: parent.right anchors.right: parent.right
spacing: ScreenTools.defaultFontPixelHeight * 0.125 spacing: 0
Rectangle { Rectangle {
Layout.alignment: Qt.AlignVCenter Layout.alignment: Qt.AlignVCenter
width: parent.width width: parent.width
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment