mirror of
https://github.com/konvajs/konva.git
synced 2026-03-03 16:58:33 +08:00
Merge pull request #581 from mihhail-lapushkin/master
Resolved compatibility issues with CocoonJS
This commit is contained in:
@@ -238,7 +238,7 @@
|
|||||||
|
|
||||||
Kinetic.Node.prototype.isDraggable = Kinetic.Node.prototype.getDraggable;
|
Kinetic.Node.prototype.isDraggable = Kinetic.Node.prototype.getDraggable;
|
||||||
|
|
||||||
var html = document.getElementsByTagName('html')[0];
|
var html = document.documentElement;
|
||||||
html.addEventListener('mouseup', Kinetic.DD._endDragBefore, true);
|
html.addEventListener('mouseup', Kinetic.DD._endDragBefore, true);
|
||||||
html.addEventListener('touchend', Kinetic.DD._endDragBefore, true);
|
html.addEventListener('touchend', Kinetic.DD._endDragBefore, true);
|
||||||
|
|
||||||
|
|||||||
@@ -598,7 +598,7 @@
|
|||||||
};
|
};
|
||||||
},
|
},
|
||||||
_getContentPosition: function() {
|
_getContentPosition: function() {
|
||||||
var rect = this.content.getBoundingClientRect();
|
var rect = this.content.getBoundingClientRect ? this.content.getBoundingClientRect() : { top: 0, left: 0 };
|
||||||
return {
|
return {
|
||||||
top: rect.top,
|
top: rect.top,
|
||||||
left: rect.left
|
left: rect.left
|
||||||
|
|||||||
Reference in New Issue
Block a user