Setting lastMoveEvt in dragmove so it is accessible in both touch and mouse environments. r=erilem (closes #2936)
git-svn-id: http://svn.openlayers.org/trunk/openlayers@11671 dc9f47b5-9b13-0410-9fdd-eb0c1a62fdaf
This commit is contained in:
@@ -192,6 +192,7 @@ OpenLayers.Handler.Drag = OpenLayers.Class(OpenLayers.Handler, {
|
|||||||
* {Boolean} Let the event propagate.
|
* {Boolean} Let the event propagate.
|
||||||
*/
|
*/
|
||||||
dragmove: function (evt) {
|
dragmove: function (evt) {
|
||||||
|
this.lastMoveEvt = evt;
|
||||||
if (this.started && !this.timeoutId && (evt.xy.x != this.last.x ||
|
if (this.started && !this.timeoutId && (evt.xy.x != this.last.x ||
|
||||||
evt.xy.y != this.last.y)) {
|
evt.xy.y != this.last.y)) {
|
||||||
if(this.documentDrag === true && this.documentEvents) {
|
if(this.documentDrag === true && this.documentEvents) {
|
||||||
@@ -349,7 +350,6 @@ OpenLayers.Handler.Drag = OpenLayers.Class(OpenLayers.Handler, {
|
|||||||
* {Boolean} Let the event propagate.
|
* {Boolean} Let the event propagate.
|
||||||
*/
|
*/
|
||||||
mousemove: function(evt) {
|
mousemove: function(evt) {
|
||||||
this.lastMoveEvt = evt;
|
|
||||||
return this.dragmove(evt);
|
return this.dragmove(evt);
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user