Prevent the default browser behavior without stopping the event propagation.

This commit is contained in:
Frederic Junod
2012-03-14 10:30:03 +01:00
parent cf92ced1c8
commit a6119f6a75
4 changed files with 29 additions and 22 deletions

View File

@@ -172,7 +172,8 @@ OpenLayers.Handler.Drag = OpenLayers.Class(OpenLayers.Handler, {
this.down(evt);
this.callback("down", [evt.xy]);
OpenLayers.Event.stop(evt);
// prevent document dragging
OpenLayers.Event.preventDefault(evt);
if(!this.oldOnselectstart) {
this.oldOnselectstart = document.onselectstart ?