提交 887fe9d4 编写于 作者: L Lebedev Konstantin 提交者: GitHub

Merge pull request #943 from FurnaceCMS/master

Handles inside polymer elements
...@@ -262,10 +262,9 @@ ...@@ -262,10 +262,9 @@
type = evt.type, type = evt.type,
touch = evt.touches && evt.touches[0], touch = evt.touches && evt.touches[0],
target = (touch || evt).target, target = (touch || evt).target,
originalTarget = target, originalTarget = evt.target.shadowRoot && evt.path[0] || target,
filter = options.filter; filter = options.filter;
if (type === 'mousedown' && evt.button !== 0 || options.disabled) { if (type === 'mousedown' && evt.button !== 0 || options.disabled) {
return; // only left button or enabled return; // only left button or enabled
} }
...@@ -1003,13 +1002,15 @@ ...@@ -1003,13 +1002,15 @@
return el; return el;
} }
} }
while (el !== ctx && (el = el.parentNode)); while (el = ('host' in el) ? el.host : el.parentNode)
} }
return null; return null;
} }
function _globalDragOver(/**Event*/evt) { function _globalDragOver(/**Event*/evt) {
if (evt.dataTransfer) { if (evt.dataTransfer) {
evt.dataTransfer.dropEffect = 'move'; evt.dataTransfer.dropEffect = 'move';
......
此差异已折叠。
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册