aboutsummaryrefslogtreecommitdiffstats
path: root/www/js/locate.js
diff options
context:
space:
mode:
Diffstat (limited to 'www/js/locate.js')
-rw-r--r--www/js/locate.js3
1 files changed, 3 insertions, 0 deletions
diff --git a/www/js/locate.js b/www/js/locate.js
index 7d4c713..cc92821 100644
--- a/www/js/locate.js
+++ b/www/js/locate.js
@@ -2,6 +2,7 @@
_.extend( FMS, {
Locate: function() { return {
locating: 0,
+ updating: 0,
lookup: function(q) {
var that = this;
@@ -72,6 +73,7 @@
updatePosition: function() {
console.log('updatePosition');
+ this.updating = 1;
var that = this;
this.update_watch_id = navigator.geolocation.watchPosition(
function(location) {
@@ -85,6 +87,7 @@
},
stopUpdating: function() {
+ this.updating = 0;
if ( this.update_watch_id ) {
navigator.geolocation.clearupdate_watch( this.watch_id );
delete this.update_watch_id;