Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1060)

Unified Diff: third_party/WebKit/public/web/WebFrameWidget.h

Issue 2485693003: Drag-and-drop: DragEnter, DragOver, DragLeave, DragDrop (Closed)
Patch Set: Rebased. Created 4 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/public/web/WebFrameWidget.h
diff --git a/third_party/WebKit/public/web/WebFrameWidget.h b/third_party/WebKit/public/web/WebFrameWidget.h
index 48e8ebd3bb4f14d4431662f5cc22a38bad298797..c5b5bfaefa7cc7ceb95ffd1df269011ecdf5d552 100644
--- a/third_party/WebKit/public/web/WebFrameWidget.h
+++ b/third_party/WebKit/public/web/WebFrameWidget.h
@@ -32,11 +32,13 @@
#define WebFrameWidget_h
#include "../platform/WebCommon.h"
+#include "../platform/WebDragOperation.h"
#include "../platform/WebPageVisibilityState.h"
#include "public/web/WebWidget.h"
namespace blink {
+class WebDragData;
class WebLocalFrame;
class WebView;
class WebWidgetClient;
@@ -73,10 +75,29 @@ class WebFrameWidget : public WebWidget {
virtual void setBaseBackgroundColor(WebColor) = 0;
// Returns the local root of this WebFrameWidget.
- virtual WebLocalFrame* localRoot() = 0;
+ virtual WebLocalFrame* localRoot() const = 0;
// WebWidget implementation.
bool isWebFrameWidget() const final { return true; }
+
+ // Callback methods when a drag-and-drop operation is trying to drop something
+ // on the WebWidget.
+ virtual WebDragOperation dragTargetDragEnter(
+ const WebDragData&,
+ const WebPoint& pointInViewport,
+ const WebPoint& screenPoint,
+ WebDragOperationsMask operationsAllowed,
+ int modifiers) = 0;
+ virtual WebDragOperation dragTargetDragOver(
+ const WebPoint& pointInViewport,
+ const WebPoint& screenPoint,
+ WebDragOperationsMask operationsAllowed,
+ int modifiers) = 0;
+ virtual void dragTargetDragLeave() = 0;
+ virtual void dragTargetDrop(const WebDragData&,
+ const WebPoint& pointInViewport,
+ const WebPoint& screenPoint,
+ int modifiers) = 0;
};
} // namespace blink

Powered by Google App Engine
This is Rietveld 408576698