mirror of
https://github.com/mozilla/pdf.js.git
synced 2025-04-22 16:18:08 +02:00
Merge pull request #14948 from Pldi23/drag&drop_not_work_from_mail
Set 'dropEffect' based on 'effectAllowed' for drag-and-drop in the viewer (issue 14942)
This commit is contained in:
commit
8fcdad022b
1 changed files with 2 additions and 1 deletions
|
@ -2185,7 +2185,8 @@ function webViewerInitialized() {
|
|||
appConfig.mainContainer.addEventListener("dragover", function (evt) {
|
||||
evt.preventDefault();
|
||||
|
||||
evt.dataTransfer.dropEffect = "move";
|
||||
evt.dataTransfer.dropEffect =
|
||||
evt.dataTransfer.effectAllowed === "copy" ? "copy" : "move";
|
||||
});
|
||||
appConfig.mainContainer.addEventListener("drop", function (evt) {
|
||||
evt.preventDefault();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue