Arrange elements so we can get mouse events on controls while preventing the default (scroll) behavior on touch devices. r=elemoine (closes #3091)
git-svn-id: http://svn.openlayers.org/trunk/openlayers@11365 dc9f47b5-9b13-0410-9fdd-eb0c1a62fdaf
This commit is contained in:
@@ -156,9 +156,7 @@ OpenLayers.Handler.Drag = OpenLayers.Class(OpenLayers.Handler, {
|
||||
this.down(evt);
|
||||
this.callback("down", [evt.xy]);
|
||||
|
||||
if (evt.type === "mousedown") {
|
||||
OpenLayers.Event.stop(evt);
|
||||
}
|
||||
OpenLayers.Event.stop(evt);
|
||||
|
||||
if(!this.oldOnselectstart) {
|
||||
this.oldOnselectstart = document.onselectstart ?
|
||||
@@ -204,9 +202,7 @@ OpenLayers.Handler.Drag = OpenLayers.Class(OpenLayers.Handler, {
|
||||
this.interval);
|
||||
}
|
||||
this.dragging = true;
|
||||
if (evt.type === "touchmove") {
|
||||
OpenLayers.Event.stop(evt);
|
||||
}
|
||||
|
||||
this.move(evt);
|
||||
this.callback("move", [evt.xy]);
|
||||
if(!this.oldOnselectstart) {
|
||||
|
||||
Reference in New Issue
Block a user