summaryrefslogtreecommitdiff
path: root/static/main_map.js
diff options
context:
space:
mode:
Diffstat (limited to 'static/main_map.js')
-rw-r--r--static/main_map.js6
1 files changed, 6 insertions, 0 deletions
diff --git a/static/main_map.js b/static/main_map.js
index 5305495..d803025 100644
--- a/static/main_map.js
+++ b/static/main_map.js
@@ -105,6 +105,12 @@ function loadLayersFromJSON(layer_markers, layer_vectors, geo_objects){
}
}
+/* zoom to an area */
+function zoomToArea(top, left, bottom, right){
+ var bounds = new OpenLayers.Bounds(left, bottom, right, top);
+ map.zoomToExtent(bounds, true);
+}
+
/* zoom to a desired category */
function zoomToCategory(categorie_ids){
updateCheckedCategories();