Interactive interface for browsing global, full-resolution satellite imagery
added date change on every range drag event
Benjamin15c106feb0c1
diff --git a/web/js/animation/wv.anim.rangeselect.js b/web/js/animation/wv.anim.rangeselect.jsindex 6eb8fc960..50a696b99 100644--- a/web/js/animation/wv.anim.rangeselect.js+++ b/web/js/animation/wv.anim.rangeselect.js@@ -60,8 +60,7 @@ wv.anim.rangeselect = wv.anim.rangeselect || function(models, config, ui) {rangeOpacity: 0.3,pinWidth: 5,height: 45,- onDrag: self.showDateOnDrag,- onDragStop: self.updateRange+ onDrag: self.updateRange};model.events.on('timeline-change', self.update);model.events.on('change', self.update);@@ -73,10 +72,6 @@ wv.anim.rangeselect = wv.anim.rangeselect || function(models, config, ui) {self.getLocationFromStringDate = function(date) {return timeline.x(new Date(date));};- self.showDateOnDrag = function(firstLocation, secondLocation) {- var date = timeline.x.invert(firstLocation);- timeline.pick.hoverDate(date);- };self.update = function() { // being called from timeline.config.jsvar props = self.updateOptions();self.reactComponent.setState(props);@@ -88,7 +83,7 @@ wv.anim.rangeselect = wv.anim.rangeselect || function(models, config, ui) {return $dataWidth;}return $elWidth;- }+ };self.updateOptions = function() {var max;var state = model.rangeState;@@ -105,8 +100,6 @@ wv.anim.rangeselect = wv.anim.rangeselect || function(models, config, ui) {var state = model.rangeState;state.startDate = wv.util.toISOStringDate(startDate) || 0;state.endDate = wv.util.toISOStringDate(endDate);-- timeline.ticks.label.remove();model.events.trigger('change');};self.init();