Commit 31c81471 authored by Alexander.Trofimov's avatar Alexander.Trofimov

fix bug 32536

parent 87672d62
...@@ -1509,29 +1509,24 @@ ...@@ -1509,29 +1509,24 @@
/** @param event */ /** @param event */
asc_CEventsController.prototype._getCoordinates = function (event) { asc_CEventsController.prototype._getCoordinates = function (event) {
// ToDo стоит переделать // ToDo стоит переделать
if (event.coord) if (event.coord) {
return event.coord; return event.coord;
var offs = $(this.element).offset();
var x = event.pageX - offs.left;
var y = event.pageY - offs.top;
// ToDo возможно стоит переделать
if (AscBrowser.isRetina) {
x <<= 1;
y <<= 1;
} }
var offs = this.element.getBoundingClientRect();
var x = ((event.pageX * AscBrowser.zoom) >> 0) - offs.left;
var y = ((event.pageY * AscBrowser.zoom) >> 0) - offs.top;
return {x: x, y: y}; return {x: x, y: y};
}; };
asc_CEventsController.prototype._onTouchStart = function (event){ asc_CEventsController.prototype._onTouchStart = function (event) {
this.view.MobileTouchManager.onTouchStart(event); this.view.MobileTouchManager.onTouchStart(event);
}; };
asc_CEventsController.prototype._onTouchMove = function (event){ asc_CEventsController.prototype._onTouchMove = function (event) {
this.view.MobileTouchManager.onTouchMove(event); this.view.MobileTouchManager.onTouchMove(event);
}; };
asc_CEventsController.prototype._onTouchEnd = function (event){ asc_CEventsController.prototype._onTouchEnd = function (event) {
this.view.MobileTouchManager.onTouchEnd(event); this.view.MobileTouchManager.onTouchEnd(event);
}; };
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment