a4fed335fd4282c1fec85ca1cd2ada54784bed2a
[mardrone] / mardrone / ConfigDialog.qml
1 import Qt 4.7
2 import com.meego 1.0
3 Page {
4         id:dialog
5         Flickable {
6           id: dialogscrolarea
7           anchors.top: parent.top
8           anchors.bottom: parent.bottom
9           width: parent.width
10           anchors.leftMargin:50;anchors.rightMargin:50
11
12       /*    anchors.horizontalCenter:parent.horizontalCenter */
13
14           contentHeight: dialogcontent.height
15           contentWidth: parent.width
16
17           Grid {
18               columns:2
19               id: dialogcontent
20         //      width: parent.width
21         anchors.left:parent.left;anchors.right:parent.right
22           anchors.leftMargin:50;anchors.rightMargin:50
23
24            spacing: 30
25            Text {
26               width:400
27               text: "Drone IP"
28
29            }
30            LineEdit {
31                   id: droneip
32                   width:300
33                   text: drone.confDroneIp
34                   onTextChanged:{drone.confDroneIp=text;}
35            }
36
37            Text {
38               text: "Video 640x480 / Full Screen"
39            }
40            Switch {
41               id: fullScreen
42         //      enabled:drone.confFullScreen
43               checked:drone.confFullScreen
44               anchors.right:parent.right
45         //      onEnabledChanged:{drone.confFullScreen=enabled;}
46               onCheckedChanged:{drone.confFullScreen=checked;}
47            }
48
49            Text {
50               text: "Show debug"
51            }
52            Switch {
53               id: showDebug
54           //    enabled:drone.confShowDebug
55               checked:drone.confShowDebug
56               anchors.right:parent.right
57 //              onEnabledChanged:{drone.confShowDebug=enabled;}
58               onCheckedChanged:{drone.confShowDebug=checked;}
59            }
60
61            Text {
62               text: "Show engine gauges"
63
64            }
65            Switch {
66               id: showGauges
67 //              enabled:drone.confShowGauges
68               checked:drone.confShowGauges
69               anchors.right:parent.right
70 //              onEnabledChanged:{drone.confShowGauges=enabled;}
71               onCheckedChanged:{drone.confShowGauges=checked;}
72            }
73
74            Text {
75               text: "Show horizon"
76
77            }
78            Switch {
79               id: showHorizon
80               checked:drone.confShowHorizon
81               anchors.right:parent.right
82               onCheckedChanged:{drone.onfconfShowHorizon=enabled;}
83            }
84
85            Text {
86               text: "Forward gain"
87            }
88
89            Slider {
90               id: forwardGain
91               anchors.right:parent.right
92               maximumValue:1.0
93       //        stepSize:0.01
94               steps:0.01
95               value:drone.confForwardGain
96               onValueChanged:{drone.confForwardGain=value;}
97            }
98            Text {
99               text: "Backward gain"
100            }
101
102            Slider {
103               id: backwardGain
104               anchors.right:parent.right
105               maximumValue:1.0
106         //      stepSize:0.01
107               steps:0.01
108               value:drone.confBackwardGain
109               onValueChanged:{drone.confBackwardGain=value;}
110            }
111
112            Text {
113               text: "Left gain"
114            }
115
116            Slider {
117               id: leftGain
118               anchors.right:parent.right
119               maximumValue:1.0
120          //     stepSize:0.01
121               steps:0.01
122               value:drone.confLeftGain
123               onValueChanged:{drone.confLeftGain=value;}
124            }
125
126            Text {
127               text: "Right gain"
128            }
129
130            Slider {
131               id: rightGain
132               anchors.right:parent.right
133               maximumValue:1.0
134          //     stepSize:0.01
135               steps:0.01
136               value:drone.confRightGain
137               onValueChanged:{drone.confRightGain=value;}
138            }
139
140           }
141        }
142      }