Commit 704655ce authored by Don Gagne's avatar Don Gagne Committed by GitHub

Merge pull request #3745 from DonLakeFlyer/HelpFade

Remove fading help text
parents e35cf4c8 075175f2
...@@ -20,18 +20,14 @@ Item { ...@@ -20,18 +20,14 @@ Item {
state: "HelpShown" state: "HelpShown"
clip: true clip: true
property alias text: helpText.text
property alias source: icon.source property alias source: icon.source
property bool checked: false property bool checked: false
property bool logo: false property bool logo: false
property ExclusiveGroup exclusiveGroup: null property ExclusiveGroup exclusiveGroup: null
signal clicked()
readonly property real _topBottomMargins: ScreenTools.defaultFontPixelHeight / 2 readonly property real _topBottomMargins: ScreenTools.defaultFontPixelHeight / 2
property real _helpTextBottomMargin: 0 signal clicked()
property real _imageBottomMargin: 0
onExclusiveGroupChanged: { onExclusiveGroupChanged: {
if (exclusiveGroup) { if (exclusiveGroup) {
...@@ -41,43 +37,6 @@ Item { ...@@ -41,43 +37,6 @@ Item {
QGCPalette { id: qgcPal } QGCPalette { id: qgcPal }
states: [
State {
name: "HelpShown"
},
State {
name: "HelpHidden"
PropertyChanges { target: imageAnimation; running: true }
PropertyChanges { target: helpTextAnimation; running: true }
}
]
PropertyAnimation {
id: imageAnimation
target: _root
property: "_imageBottomMargin"
duration: 1000
easing.type: Easing.InOutQuad
to: _topBottomMargins
from: 0
}
PropertyAnimation {
id: helpTextAnimation
target: _root
property: "_helpTextBottomMargin"
duration: 1000
easing.type: Easing.InOutQuad
to: -helpText.height
from: 0
}
Timer {
interval: 10000
running: true
onTriggered: _root.state = "HelpHidden"
}
Rectangle { Rectangle {
anchors.fill: parent anchors.fill: parent
visible: logo visible: logo
...@@ -90,8 +49,8 @@ Item { ...@@ -90,8 +49,8 @@ Item {
anchors.right: parent.right anchors.right: parent.right
anchors.topMargin: _topBottomMargins anchors.topMargin: _topBottomMargins
anchors.top: parent.top anchors.top: parent.top
anchors.bottomMargin: _imageBottomMargin anchors.bottomMargin: _topBottomMargins
anchors.bottom: helpText.top anchors.bottom: parent.bottom
sourceSize.height: parent.height sourceSize.height: parent.height
fillMode: Image.PreserveAspectFit fillMode: Image.PreserveAspectFit
color: logo ? "white" : (checked ? qgcPal.buttonHighlight : qgcPal.buttonText) color: logo ? "white" : (checked ? qgcPal.buttonHighlight : qgcPal.buttonText)
...@@ -106,16 +65,6 @@ Item { ...@@ -106,16 +65,6 @@ Item {
visible: checked visible: checked
} }
QGCLabel {
id: helpText
anchors.left: parent.left
anchors.right: parent.right
anchors.bottomMargin: _helpTextBottomMargin
anchors.bottom: parent.bottom
horizontalAlignment: Text.AlignHCenter
color: logo ? "white" : qgcPal.buttonText
}
MouseArea { MouseArea {
anchors.fill: parent anchors.fill: parent
onClicked: { onClicked: {
......
...@@ -332,7 +332,6 @@ Rectangle { ...@@ -332,7 +332,6 @@ Rectangle {
exclusiveGroup: mainActionGroup exclusiveGroup: mainActionGroup
source: "/res/QGCLogoWhite" source: "/res/QGCLogoWhite"
logo: true logo: true
text: "Settings"
onClicked: toolBar.showPreferences() onClicked: toolBar.showPreferences()
} }
...@@ -343,7 +342,6 @@ Rectangle { ...@@ -343,7 +342,6 @@ Rectangle {
anchors.bottom: parent.bottom anchors.bottom: parent.bottom
exclusiveGroup: mainActionGroup exclusiveGroup: mainActionGroup
source: "/qmlimages/Gears.svg" source: "/qmlimages/Gears.svg"
text: "Setup"
onClicked: toolBar.showSetupView() onClicked: toolBar.showSetupView()
} }
...@@ -354,7 +352,6 @@ Rectangle { ...@@ -354,7 +352,6 @@ Rectangle {
anchors.bottom: parent.bottom anchors.bottom: parent.bottom
exclusiveGroup: mainActionGroup exclusiveGroup: mainActionGroup
source: "/qmlimages/Plan.svg" source: "/qmlimages/Plan.svg"
text: "Plan"
onClicked: toolBar.showPlanView() onClicked: toolBar.showPlanView()
} }
...@@ -365,7 +362,6 @@ Rectangle { ...@@ -365,7 +362,6 @@ Rectangle {
anchors.bottom: parent.bottom anchors.bottom: parent.bottom
exclusiveGroup: mainActionGroup exclusiveGroup: mainActionGroup
source: "/qmlimages/PaperPlane.svg" source: "/qmlimages/PaperPlane.svg"
text: "Fly"
onClicked: toolBar.showFlyView() onClicked: toolBar.showFlyView()
} }
} }
......
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