[GTK] Move drag-and-drop code which can be shared with WebKit2 to WebCore
authormrobinson@webkit.org <mrobinson@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 29 Sep 2011 06:02:57 +0000 (06:02 +0000)
committermrobinson@webkit.org <mrobinson@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 29 Sep 2011 06:02:57 +0000 (06:02 +0000)
commitaad8819ef4850fcbf5d14370b2f636affcc3882e
treecf529d15ccb6344b058063cf7859baf0293d5633
parent51947456c4aeafb7f8b691f416d9bc5bed3d4cb5
[GTK] Move drag-and-drop code which can be shared with WebKit2 to WebCore
https://bugs.webkit.org/show_bug.cgi?id=66890

Source/WebCore:

Added a GtkDragAndDropHelper class to hold all the logic that is common
between WebKit1 and WebKit2. This will allow greater code sharing between
the two ports.

Reviewed by Philippe Normand.

No new tests. This patch should not change behavior.

* GNUmakefile.list.am: Added the GtkDragAndDropHelper to the sources list.
* platform/gtk/GtkDragAndDropHelper.cpp: Added.
* platform/gtk/GtkDragAndDropHelper.h: Added.

Source/WebKit/gtk:

Use the new GtkWidgetDragAndDropGlue class to hold the logic that will be
common between WebKit1 and WebKit2. Modify WebKitWebView to use this class.

Reviewed by Philippe Normand.

* WebCoreSupport/DragClientGtk.cpp:
(WebKit::DragClient::startDrag): Inform the drag-and-drop glue about the drag.
* webkit/webkitwebview.cpp: Use GtkWidgetDragAndDropGlue wherever this class was
maintaining drag-and-drop state itself.
* webkit/webkitwebviewprivate.h: Swap out the drag-and-drop state for an instance
of the glue class.

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@96299 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Source/WebCore/ChangeLog
Source/WebCore/GNUmakefile.list.am
Source/WebCore/platform/gtk/GtkDragAndDropHelper.cpp [new file with mode: 0644]
Source/WebCore/platform/gtk/GtkDragAndDropHelper.h [new file with mode: 0644]
Source/WebKit/gtk/ChangeLog
Source/WebKit/gtk/WebCoreSupport/DragClientGtk.cpp
Source/WebKit/gtk/webkit/webkitwebview.cpp
Source/WebKit/gtk/webkit/webkitwebviewprivate.h