Bug 40401

Summary: REGRESSION: [Qt] When dragging onto a page that handles the drag in Javascript it will be a move and not a copy by default
Product: WebKit Reporter: qt-info
Component: WebKit QtAssignee: Nobody <webkit-unassigned>
Status: CLOSED FIXED    
Severity: Normal CC: abarth, eric, hausmann, webkit.review.bot
Priority: P2 Keywords: Qt, QtTriaged
Version: 528+ (Nightly build)   
Hardware: All   
OS: All   
Attachments:
Description Flags
Example HTML
none
Suggested patch none

Description qt-info 2010-06-09 22:26:26 PDT
Created attachment 58328 [details]
Example HTML

[Qt] When dragging onto a page that handles the drag in Javascript it will be a move and not a copy by default.  This is fine in Qt 4.6.3, but not in Qt 4.7.0.

Attached is a test html file, just drag a file into the draggable area (you should see some debug in the window) and then drop, this will cause the file to be deleted as it was a move event.  Whereas in Qt 4.6.3 it was a copy event.

The attached patch solves the problem by using the more correct acceptProposedAction() instead of accept().
Comment 1 qt-info 2010-06-09 22:28:19 PDT
Created attachment 58329 [details]
Suggested patch
Comment 2 Simon Hausmann 2010-06-10 00:48:34 PDT
Confirmed on X11, too.
Comment 3 Simon Hausmann 2010-06-10 00:52:27 PDT
Andy's patch is correct
Comment 4 Simon Hausmann 2010-06-10 01:03:19 PDT
Committed r60942: <http://trac.webkit.org/changeset/60942>
Comment 5 Simon Hausmann 2010-06-10 01:22:46 PDT
Revision r60942 cherry-picked into qtwebkit-2.0 with commit 0f40b3b53c931a8161babfd2335067de0970dfd5
Comment 6 WebKit Review Bot 2010-06-10 01:42:24 PDT
http://trac.webkit.org/changeset/60942 might have broken Chromium Linux Release
The following changes are on the blame list:
http://trac.webkit.org/changeset/60942
http://trac.webkit.org/changeset/60943