[Webkit-unassigned] [Bug 177791] [ToT] Web process occasionally crashes when dropping into MDN's DataTransferItemList.add() demo
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Mon Oct 2 17:08:44 PDT 2017
https://bugs.webkit.org/show_bug.cgi?id=177791
--- Comment #1 from Wenson Hsieh <wenson_hsieh at apple.com> ---
Here's a reduced test case.
<!DOCTYPE html>
<style>
div {
padding: 15px;
border: 1px solid black;
font-size: 60px;
font-family: -apple-system;
}
</style>
<body>
<div draggable="true" id="source">source</div>
<div id="target">target</div>
</body>
<script type="text/javascript">
source.addEventListener("dragstart", event => event.dataTransfer.items.add(event.target.id, "text/plain"));
source.addEventListener("dragend", event => event.dataTransfer.items.remove(0));
target.addEventListener("dragover", event => event.preventDefault());
target.addEventListener("drop", event => {
for (const item of event.dataTransfer.items) {
if (item.kind == "string" && item.type === "text/plain") {
item.getAsString(string => event.target.appendChild(document.getElementById(string)));
break;
}
}
event.preventDefault();
});
</script>
Drag the source onto the target. I can't reproduce 100% of the time, but it happens every so often...
--
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20171003/b7e067fb/attachment-0001.html>
More information about the webkit-unassigned
mailing list