Add new constrainResolution option to olx.interaction.DefaultsOptions
This commit is contained in:
@@ -75,6 +75,7 @@ ol.interaction.defaults = function(opt_options) {
|
||||
var pinchZoom = options.pinchZoom !== undefined ? options.pinchZoom : true;
|
||||
if (pinchZoom) {
|
||||
interactions.push(new ol.interaction.PinchZoom({
|
||||
constrainResolution: options.constrainResolution,
|
||||
duration: options.zoomDuration
|
||||
}));
|
||||
}
|
||||
@@ -92,6 +93,7 @@ ol.interaction.defaults = function(opt_options) {
|
||||
options.mouseWheelZoom : true;
|
||||
if (mouseWheelZoom) {
|
||||
interactions.push(new ol.interaction.MouseWheelZoom({
|
||||
constrainResolution: options.constrainResolution,
|
||||
duration: options.zoomDuration
|
||||
}));
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user