equal
deleted
inserted
replaced
23 if (window.qml.address) { |
23 if (window.qml.address) { |
24 goToAddress() |
24 goToAddress() |
25 } else { |
25 } else { |
26 goToLatLng(new google.maps.LatLng(window.qml.lat,window.qml.lng)); |
26 goToLatLng(new google.maps.LatLng(window.qml.lat,window.qml.lng)); |
27 } |
27 } |
|
28 if (navigator.geolocation) { |
|
29 navigator.geolocation.getCurrentPosition(function(position) { |
|
30 initialLocation = new google.maps.LatLng(position.coords.latitude,position.coords.longitude); |
|
31 window.qml.lat = initialLocation.lat; |
|
32 window.qml.lng = initialLocation.lng; |
|
33 goToLatLng(initialLocation); |
|
34 }); |
|
35 } |
28 } |
36 } |
29 function goToAddress() { |
37 function goToAddress() { |
30 if (geocoder) { |
38 if (geocoder) { |
31 var req = { |
39 var req = { |
32 address: window.qml.address, |
40 address: window.qml.address, |