Changed 'routeTo' image to real button in RoutingView
authorJanne Kiiski <janne.kiiski@ixonos.com>
Fri, 19 Nov 2010 09:19:31 +0000 (11:19 +0200)
committerJanne Kiiski <janne.kiiski@ixonos.com>
Fri, 19 Nov 2010 09:19:31 +0000 (11:19 +0200)
src/qmlui/RoutingView.qml

index 99f4849..5c9af18 100644 (file)
@@ -7,20 +7,16 @@ Item {
     height: panel.height
     width: panel.width
 
-    Image {
+    Button {
         id: routeTo
-        fillMode: Image.PreserveAspectFit
-        width: parent.width
-        source: "qrc:/res/images/route_to_cursor.png"
+        image: "qrc:/res/images/route_to_cursor.png"
+        width: height
         anchors.horizontalCenter: parent.horizontalCenter
         anchors.top: parent.top
 
-        MouseArea {
-            anchors.fill: parent
-            onClicked: {
-                console.log("clicked: Route to cursor")
-                engine.routeFromTo(map.gpsLocationLatitude, map.gpsLocationLongitude, map.centerLatitude, map.centerLongitude);
-            }
+        onButtonClicked: {
+            console.log("clicked: Route to cursor")
+            engine.routeFromTo(map.gpsLocationLatitude, map.gpsLocationLongitude, map.centerLatitude, map.centerLongitude);
         }
     }