summaryrefslogtreecommitdiffstats
path: root/app/cluster-gauges.qml
diff options
context:
space:
mode:
authorScott Murray <scott.murray@konsulko.com>2018-12-17 22:57:51 -0800
committerScott Murray <scott.murray@konsulko.com>2018-12-17 23:03:07 -0800
commit6ec520cca1ae419f02d99c2195626ac89c0d0b6d (patch)
tree2255c690ced127e2f55a62d71458969edd477040 /app/cluster-gauges.qml
parent98a10ae29d925dbba6b9cb767ce9db00591ade41 (diff)
Add status icons provided by AGL graphics design team, and tweak the animation behavior to simulate power on at the start of the cycle by blinking them. Additionally, the speed has been switched to MPH, and the turn signal animation has been udpated to simulate passing as opposed to a turn at the start of the cycle. Change-Id: If5e3b9d2138d1129a7478bea1f4f2cb6b05f1499 Signed-off-by: Scott Murray <scott.murray@konsulko.com>
Diffstat (limited to 'app/cluster-gauges.qml')
-rw-r--r--app/cluster-gauges.qml104
1 files changed, 98 insertions, 6 deletions
diff --git a/app/cluster-gauges.qml b/app/cluster-gauges.qml
index 013a0c1..a48d71c 100644
--- a/app/cluster-gauges.qml
+++ b/app/cluster-gauges.qml
@@ -81,7 +81,7 @@ ApplicationWindow {
id: statusFrame
x: (parent.width - width) / 2
y: 80
- width: 960
+ width: 1152
height: 96
radius: height / 5
@@ -92,13 +92,13 @@ ApplicationWindow {
Row {
width: parent.width
height: parent.height * 0.75
- spacing: (parent.width - (10 * parent.height * 0.75)) / 11
+ spacing: (parent.width - (12 * parent.height * 0.75)) / 13
anchors.fill: parent
anchors.topMargin: (parent.height - height) /2
anchors.bottomMargin: (parent.height - height) /2
- anchors.leftMargin: (parent.width - (10 * parent.height * 0.75)) / 11
- anchors.rightMargin: (parent.width - (10 * parent.height * 0.75)) / 11
+ anchors.leftMargin: (parent.width - (12 * parent.height * 0.75)) / 13
+ anchors.rightMargin: (parent.width - (12 * parent.height * 0.75)) / 13
Rectangle {
width: height
@@ -129,6 +129,34 @@ ApplicationWindow {
color: "black"
border.width: 2
border.color: "grey"
+
+ Image {
+ source: valueSource.startUp ? './images/AGL_Icons_Engine_yellow.svg' : './images/AGL_Icons_Engine.svg'
+ anchors.verticalCenter: parent.verticalCenter
+ anchors.horizontalCenter: parent.horizontalCenter
+ width: height
+ height: parent.height * 0.75
+ fillMode: Image.PreserveAspectFit
+ }
+ }
+
+ Rectangle {
+ width: height
+ height: parent.height
+ radius: height / 5
+
+ color: "black"
+ border.width: 2
+ border.color: "grey"
+
+ Image {
+ source: valueSource.startUp ? './images/AGL_Icons_Oil_red.svg' : './images/AGL_Icons_Oil.svg'
+ anchors.verticalCenter: parent.verticalCenter
+ anchors.horizontalCenter: parent.horizontalCenter
+ width: height
+ height: parent.height * 0.75
+ fillMode: Image.PreserveAspectFit
+ }
}
Rectangle {
@@ -139,6 +167,15 @@ ApplicationWindow {
color: "black"
border.width: 2
border.color: "grey"
+
+ Image {
+ source: valueSource.startUp ? './images/AGL_Icons_ABS_red.svg' : './images/AGL_Icons_ABS.svg'
+ anchors.verticalCenter: parent.verticalCenter
+ anchors.horizontalCenter: parent.horizontalCenter
+ width: height
+ height: parent.height * 0.75
+ fillMode: Image.PreserveAspectFit
+ }
}
Rectangle {
@@ -149,6 +186,15 @@ ApplicationWindow {
color: "black"
border.width: 2
border.color: "grey"
+
+ Image {
+ source: valueSource.startUp ? './images/AGL_Icons_Battery_red.svg' : './images/AGL_Icons_Battery.svg'
+ anchors.verticalCenter: parent.verticalCenter
+ anchors.horizontalCenter: parent.horizontalCenter
+ width: height
+ height: parent.height * 0.75
+ fillMode: Image.PreserveAspectFit
+ }
}
Rectangle {
@@ -202,6 +248,34 @@ ApplicationWindow {
color: "black"
border.width: 2
border.color: "grey"
+
+ Image {
+ source: valueSource.startUp ? './images/AGL_Icons_Seatbelt_red.svg' : './images/AGL_Icons_Seatbelt.svg'
+ anchors.verticalCenter: parent.verticalCenter
+ anchors.horizontalCenter: parent.horizontalCenter
+ width: height
+ height: parent.height * 0.75
+ fillMode: Image.PreserveAspectFit
+ }
+ }
+
+ Rectangle {
+ width: height
+ height: parent.height
+ radius: height / 5
+
+ color: "black"
+ border.width: 2
+ border.color: "grey"
+
+ Image {
+ source: valueSource.startUp ? './images/AGL_Icons_OpenDoor_red.svg' : './images/AGL_Icons_OpenDoor.svg'
+ anchors.verticalCenter: parent.verticalCenter
+ anchors.horizontalCenter: parent.horizontalCenter
+ width: height
+ height: parent.height * 0.75
+ fillMode: Image.PreserveAspectFit
+ }
}
Rectangle {
@@ -212,6 +286,15 @@ ApplicationWindow {
color: "black"
border.width: 2
border.color: "grey"
+
+ Image {
+ source: valueSource.startUp ? './images/AGL_Icons_Lights_red.svg' : './images/AGL_Icons_Lights.svg'
+ anchors.verticalCenter: parent.verticalCenter
+ anchors.horizontalCenter: parent.horizontalCenter
+ width: height
+ height: parent.height * 0.75
+ fillMode: Image.PreserveAspectFit
+ }
}
Rectangle {
@@ -222,6 +305,15 @@ ApplicationWindow {
color: "black"
border.width: 2
border.color: "grey"
+
+ Image {
+ source: valueSource.startUp ? './images/AGL_Icons_ParkingBrake_red.svg' : './images/AGL_Icons_ParkingBrake.svg'
+ anchors.verticalCenter: parent.verticalCenter
+ anchors.horizontalCenter: parent.horizontalCenter
+ width: height
+ height: parent.height * 0.75
+ fillMode: Image.PreserveAspectFit
+ }
}
Rectangle {
@@ -260,8 +352,8 @@ ApplicationWindow {
width: parent.width * 0.9
height: width
- maximumValue: 220
- value: valueSource.kph
+ maximumValue: valueSource.mphDisplay ? 140 : 220
+ value: valueSource.kph * valueSource.speedScaling
style: DashboardGaugeStyle {}
}