Disable mouse wheel zoom so that the mouse wheel scrolls the webpage again.
authorphilipp <philipp@7aebc617-e5e2-0310-91dc-80fb5f6d2477>
Sun, 16 Dec 2012 13:40:44 +0000 (13:40 +0000)
committerphilipp <philipp@7aebc617-e5e2-0310-91dc-80fb5f6d2477>
Sun, 16 Dec 2012 13:40:44 +0000 (13:40 +0000)
git-svn-id: http://www.winterrodeln.org/svn/servermediawiki/mediawiki_extensions/wrmap/branches/2.0@1242 7aebc617-e5e2-0310-91dc-80fb5f6d2477

wrmap.js

index f2e7fa171a5de3d7c29896a0ae2b1e467603df2b..93ca3a803ce587b895fd80ea443b3c85cb821c84 100644 (file)
--- a/wrmap.js
+++ b/wrmap.js
@@ -66,12 +66,20 @@ function init_wrmap(i, jq_map) {
                        url: jq_sledrun.attr('data-url')
                })]);
        });
+
+       // disable mouse wheel zoom
+       var navigation_control = map.getControlsByClass('OpenLayers.Control.Navigation')[0];
+       navigation_control.disableZoomWheel();
+
+       // print sledrun name when mouse moves over it
        map.addControl(new OpenLayers.Control.SelectFeature(layer_sledruns, {
                hover: true,
                highlightOnly: true,
                autoActivate: true,
                renderIntent: "highlight"
        }));
+
+       // show popup when user clicks on a sledrun icon
        map.addControl(new OpenLayers.Control.SelectFeature(layer_sledruns, {
                autoActivate: true,
                toggle: true,