Add sample qml application
[staging/HomeScreen.git] / sample-qml / apps / HVAC_org / HVAC.qml
1 /* Copyright (C) 2015, Jaguar Land Rover. All Rights Reserved.
2  *
3  * This Source Code Form is subject to the terms of the Mozilla Public
4  * License, v. 2.0. If a copy of the MPL was not distributed with this
5  * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
6
7 import QtQuick 2.0
8 import system 1.0
9 import utils 1.0
10 import "models"
11
12 App {
13     appId: "hvac"
14
15     HazardButton {
16         id: hazardButton
17         y: 100
18         anchors.horizontalCenter: parent.horizontalCenter
19     }
20
21     TempSlider {
22         id: lTempSlider
23         x: 30
24         anchors.top: hazardButton.bottom
25         anchors.topMargin: 115
26         side: "left"
27     }
28
29     Row {
30         anchors.horizontalCenter: parent.horizontalCenter
31         anchors.top: hazardButton.bottom
32         anchors.topMargin: 90
33         spacing: 200
34
35         MiddleColumn { side: "left" }
36         MiddleColumn { side: "right" }
37     }
38
39     TempSlider {
40         id: rTempSlider
41         anchors.top: hazardButton.bottom
42         anchors.topMargin: 115
43         anchors.right: parent.right
44         anchors.rightMargin: 30
45         side: "right"
46     }
47
48     Image {
49         y: 1057
50         source: "images/separator.png"
51     }
52
53     FanControl {
54         x: 259
55         y: 1092
56     }
57
58     Item {
59         anchors.horizontalCenter: parent.horizontalCenter
60         width: childrenRect.width
61         height: childrenRect.height
62         anchors.bottom: parent.bottom
63         anchors.bottomMargin: 40
64
65         Row {
66             spacing: 20
67
68             Column {
69                 spacing: 10
70
71                 ClimateButton { image: "fan_dir_down"; target: "fanDown" }
72                 ClimateButton { image: "fan_dir_right"; target: "fanRight" }
73                 ClimateButton { image: "fan_dir_up"; target: "fanUp" }
74             }
75
76             ClimateButton { y: 156; image: "fan_control_ac"; target: "fanAC" }
77             ClimateButton { y: 156; image: "fan_control_auto"; target: "fanAuto" }
78             ClimateButton { y: 156; image: "fan_control_circ"; target: "fanRecirc" }
79
80             Column {
81                 spacing: 10
82
83                 ClimateButton { image: "defrost_max"; target: "defrostMax" }
84                 ClimateButton { image: "defrost_rear"; target: "defrostRear" }
85                 ClimateButton { image: "defrost_front"; target: "defrostFront" }
86             }
87         }
88     }
89 }