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

Unified Diff: chrome/browser/gtk/bookmark_bar_gtk.cc

Issue 548067: Allow link drags from the star, bookmarks bar, and bookmark bar menus (Closed)
Patch Set: Created 10 years, 11 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.cc ('k') | chrome/browser/gtk/bookmark_manager_gtk.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/gtk/bookmark_bar_gtk.cc
diff --git a/chrome/browser/gtk/bookmark_bar_gtk.cc b/chrome/browser/gtk/bookmark_bar_gtk.cc
index d28972e9ca6fe732411f5facb07b0628cc530936..62edacf60ec97a51019c2acbfe081d9097b4d435 100644
--- a/chrome/browser/gtk/bookmark_bar_gtk.cc
+++ b/chrome/browser/gtk/bookmark_bar_gtk.cc
@@ -757,11 +757,14 @@ GtkWidget* BookmarkBarGtk::CreateBookmarkButton(const BookmarkNode* node) {
bookmark_utils::ConfigureButtonForNode(node, model_, button, theme_provider_);
// The tool item is also a source for dragging
- gtk_drag_source_set(button, GDK_BUTTON1_MASK,
- NULL, 0, GDK_ACTION_MOVE);
+ gtk_drag_source_set(button, GDK_BUTTON1_MASK, NULL, 0,
+ static_cast<GdkDragAction>(GDK_ACTION_MOVE | GDK_ACTION_COPY));
int target_mask = GtkDndUtil::CHROME_BOOKMARK_ITEM;
- if (node->is_url())
- target_mask |= GtkDndUtil::TEXT_URI_LIST | GtkDndUtil::TEXT_PLAIN;
+ if (node->is_url()) {
+ target_mask |= GtkDndUtil::TEXT_URI_LIST |
+ GtkDndUtil::TEXT_PLAIN |
+ GtkDndUtil::NETSCAPE_URL;
+ }
GtkDndUtil::SetSourceTargetListFromCodeMask(button, target_mask);
g_signal_connect(G_OBJECT(button), "drag-begin",
G_CALLBACK(&OnButtonDragBegin), this);
« no previous file with comments | « app/gtk_dnd_util.cc ('k') | chrome/browser/gtk/bookmark_manager_gtk.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698