2 import com.nokia.meego 1.0
7 orientationLock: PageOrientation.LockPortrait
11 // width: rootWindow.width
14 width: rootWindow.width / 3
18 if (text.match("Start")) {
19 console.log("match start")
20 if (!demonio.demonio_start()) {
24 } else if (text.match("Stop")) {
25 console.log("match stop")
26 if (!demonio.demonio_stop()) {
38 width: mainPage.width / 4
39 anchors.verticalCenter: method_button.verticalCenter
43 width: mainPage.width * 1 / 3
47 checked: gps.getPositioningMethod() == "cell" ? true : false
48 onClicked: gps.setPositioningMethod("cell")
53 checked: gps.getPositioningMethod() == "all" ? true : false
54 onClicked: gps.setPositioningMethod("all")
59 checked: gps.getPositioningMethod() == "gps" ? true : false
60 onClicked: gps.setPositioningMethod("gps")
68 width: rootWindow.width / 4
69 anchors.verticalCenter: timeout_slider.verticalCenter
73 width: rootWindow.width / 4
74 valueIndicatorVisible: true
78 value: gps.getTimeOut()
82 text: timeout_slider.value + " seg."
83 width: rootWindow.width / 4
84 anchors.verticalCenter: timeout_slider.verticalCenter
87 target: timeout_slider
89 timeout_value.text = timeout_slider.value + " seg."
90 gps.setTimeOut(timeout_slider.value)
98 width: rootWindow.width / 4
99 anchors.verticalCenter: interval_slider.verticalCenter
103 width: rootWindow.width / 4
104 valueIndicatorVisible: true
108 value: gps.getInterval() / 60
112 text: interval_slider.value + " min."
113 width: rootWindow.width / 4
114 anchors.verticalCenter: interval_slider.verticalCenter
117 target: interval_slider
119 interval_value.text = interval_slider.value + " min."
120 gps.setInterval(interval_slider.value*60)
128 width: rootWindow.width / 4
129 anchors.verticalCenter: connect_switch.verticalCenter
133 width: rootWindow.width / 4
134 checked: latitude.getAutoConnect() ? true : false
136 connect_value.text = checked
137 latitude.setAutoConnect(checked)
142 text: connect_switch.checked
143 width: rootWindow.width / 4
144 anchors.verticalCenter: connect_switch.verticalCenter
150 text: "Daemon at boot time"
151 width: rootWindow.width / 4
152 anchors.verticalCenter: daemon_switch.verticalCenter
156 width: rootWindow.width / 4
157 checked: latitude.getDaemonMode() ? true : false
159 daemon_value.text = checked
160 latitude.setDaemonMode(checked) }
164 text: daemon_switch.checked
165 width: rootWindow.width / 4
166 anchors.verticalCenter: daemon_switch.verticalCenter
173 if (demonio.demonio_status()) {
174 do_staff.text = "Stop"
175 do_staff.enabled = true;
177 do_staff.text = "Start"
178 do_staff.enabled = true;
187 do_staff.text = "..."
188 do_staff.enabled = false;
189 if (!demonio.demonio_stop()) {
190 gps.stopUpdates(true)
198 pageStack.push(login)
205 latitude.setCurrentLocation(gps.getCurrentLatitude(),
206 gps.getCurrentLongitude(),
207 gps.getCurrentAccuracy())
208 latitude.sendCurrentLocation()
216 orientationLock: PageOrientation.LockPortrait
220 height: parent.height
221 contentWidth: webView.width
222 contentHeight: webView.height
225 url: latitude.getUserAuthorization()
226 preferredWidth: parent.width
227 preferredHeight: parent.height
230 flickable.contentY = 0;
231 if (url.toString().match("ServiceLogin")) {
232 console.log("* QML WebView go w/2,0")
233 flickable.contentX = width/2;
235 console.log("* QML WebView go 0,0")
236 flickable.contentX = 0;