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

Unified Diff: app/gtk_dnd_util.cc

Issue 1084003: Fix HTML5 effectAllowed and dragEffect on Chrome Linux. (Closed)
Patch Set: actual Created 10 years, 9 months 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
« no previous file with comments | « app/gtk_dnd_util.h ('k') | chrome/browser/gtk/tab_contents_drag_source.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: app/gtk_dnd_util.cc
diff --git a/app/gtk_dnd_util.cc b/app/gtk_dnd_util.cc
index 4d8694d7328a0f7e947f68ad9c408881e133dbe4..d6b0903be246db6d3b2d1359f722cd4b42da93c1 100644
--- a/app/gtk_dnd_util.cc
+++ b/app/gtk_dnd_util.cc
@@ -226,4 +226,15 @@ bool ExtractURIList(GtkSelectionData* selection_data, std::vector<GURL>* urls) {
return true;
}
+GdkDragAction WebDragOpToGdkDragAction(WebKit::WebDragOperationsMask op) {
+ GdkDragAction action = static_cast<GdkDragAction>(0);
+ if (op & WebKit::WebDragOperationCopy)
+ action = static_cast<GdkDragAction>(action | GDK_ACTION_COPY);
+ if (op & WebKit::WebDragOperationLink)
+ action = static_cast<GdkDragAction>(action | GDK_ACTION_LINK);
+ if (op & WebKit::WebDragOperationMove)
+ action = static_cast<GdkDragAction>(action | GDK_ACTION_MOVE);
+ return action;
+}
+
} // namespace gtk_dnd_util
« no previous file with comments | « app/gtk_dnd_util.h ('k') | chrome/browser/gtk/tab_contents_drag_source.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698