summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndy Shaw <andy.shaw@qt.io>2019-10-10 08:08:24 +0200
committerAndy Shaw <andy.shaw@qt.io>2019-10-11 10:02:17 +0200
commit51228eb249a178ada6ebd2ccd5e662bcd7bd2c60 (patch)
treed949c154fe2cee5c6aa79ebb9ad7b1fe11ddb5ab
parent13a336137a77bcc17fcdeaade3900a25a4e61e74 (diff)
Don't modify the allowed actions as they are correct already
By not modifying the allowed actions instead of just setting it to be the MoveAction will enable dragging from a webpage to another webpage to work correctly. Otherwise it will potentially reject the drag because it is seen only as a move, whereas it wouldn't be possible to really move from one webpage to another as the original source cannot be deleted. Change-Id: I34105d10e7d1dc831016c33c9c6cfc544c4e084b Reviewed-by: Jüri Valdmann <juri.valdmann@qt.io>
-rw-r--r--src/core/web_contents_adapter.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/core/web_contents_adapter.cpp b/src/core/web_contents_adapter.cpp
index ca2479965..d1fe786f6 100644
--- a/src/core/web_contents_adapter.cpp
+++ b/src/core/web_contents_adapter.cpp
@@ -1414,8 +1414,7 @@ void WebContentsAdapter::startDragging(QObject *dragSource, const content::DropD
});
QMimeData *mimeData = mimeDataFromDropData(*m_currentDropData);
- if (handleDropDataFileContents(dropData, mimeData))
- allowedActions = Qt::MoveAction;
+ handleDropDataFileContents(dropData, mimeData);
drag->setMimeData(mimeData);
if (!pixmap.isNull()) {