Interactive interface for browsing global, full-resolution satellite imagery
running-data selector fix #459
Benjaminaeb0662a28ec
diff --git a/web/js/map/wv.map.runningdata.js b/web/js/map/wv.map.runningdata.jsindex 0ea831bb6..d05b1040a 100644--- a/web/js/map/wv.map.runningdata.js+++ b/web/js/map/wv.map.runningdata.js@@ -157,7 +157,7 @@ wv.map.runningdata = wv.map.runningdata || function(models) {**/self.getPalette = function(id) {- return $('#' + id);+ return $(document.getElementById(id));};/*@@ -224,6 +224,7 @@ wv.map.runningdata = wv.map.runningdata || function(models) {var palette;var legend;var layerId;+if (!layer.wv) {return;}@@ -234,6 +235,7 @@ wv.map.runningdata = wv.map.runningdata || function(models) {}legends = models.palettes.getLegends(layerId);hex = wv.util.rgbaToHex(data[0], data[1], data[2], data[3]);+_.each(legends, function(legend) {if (legend) {self.createRunnerFromLegend(legend, hex);@@ -294,6 +296,7 @@ wv.map.runningdata = wv.map.runningdata || function(models) {*/self.createRunnerFromLegend = function(legend, hex) {var paletteInfo;+if (legend.type === 'continuous' || legend.type === 'discrete') {paletteInfo = self.getDataLabel(legend, hex);if (paletteInfo) {@@ -415,7 +418,6 @@ wv.map.runningdata = wv.map.runningdata || function(models) {margin = (($paletteCaseWidth - $paletteWidth) / 2);location = ($paletteWidth * percent + margin);-$paletteLabel.text(data.label);labelWidth = wv.util.getTextWidth(data.label, 'Lucida Sans');labelMargin = self.getLabelMarginLeft(labelWidth, $paletteWidth, location);@@ -443,4 +445,4 @@ wv.map.runningdata = wv.map.runningdata || function(models) {}};self.init();-};\ No newline at end of file+};