[OpenLayers-Users] Zooming with mouseWheel causes zooming by 2
levels instead of 1
Alessandro Ferrucci
alessandroferrucci at gmail.com
Tue Jun 8 19:21:45 EDT 2010
Hello,
I have a map and when I zoom using the mouse wheel the map zooms by 2 zoom
levels instead of 1 when I move the mouse wheel slightly.
instead if I double click the map or click up or down on the zoom control it
zooms in or out by 1 zoom level.
Here is the relevant code:
map = new OpenLayers.Map(
'map',
{
'maxResolution':'auto',
'tileSize':new OpenLayers.Size(200,200),
maxExtent: new OpenLayers.Bounds(-180, -90, 180,
90),
controls:[
new OpenLayers.Control.Navigation(),
new OpenLayers.Control.ArgParser(),
new OpenLayers.Control.Attribution(),
new OpenLayers.Control.PanZoomBar({ position:
new OpenLayers.Pixel(2, 15) }),
new OpenLayers.Control.Navigation(),
new OpenLayers.Control.Scale($('scale')),
new OpenLayers.Control.LayerSwitcher(),
new OpenLayers.Control.MousePosition(),
new OpenLayers.Control.Permalink()
]
}
);
layer0 = new OpenLayers.Layer.WMS(
"CIRA Base Layer", urlArray,
{
layers:'cira_base',
format:'image/png',
bgcolor: '#99B3CC'
},
{singleTile:false, transitionEffect: 'resize'}
);
map.addLayers([layer0]);
map.zoomToMaxExtent();
map.setCenter(new OpenLayers.LonLat(-100.42306,40.35960),1);
Any ideas as to why this would be happening?
thank you very much!
--
Signed,
Alessandro Ferrucci
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/openlayers-users/attachments/20100608/b4f2f0e0/attachment.html
More information about the Users
mailing list