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

Unified Diff: chrome/browser/gtk/tabs/tab_strip_gtk.cc

Issue 118127: Allow left clicks in the tab strip to initiate a drag of the window. (Closed)
Patch Set: Created 11 years, 7 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/gtk/tabs/tab_strip_gtk.cc
diff --git a/chrome/browser/gtk/tabs/tab_strip_gtk.cc b/chrome/browser/gtk/tabs/tab_strip_gtk.cc
index bdb526dea2535db0b3bb2e42c19d67f814a5871a..700f4923e37eb78fa5cc5fe3975a60be013a3887 100644
--- a/chrome/browser/gtk/tabs/tab_strip_gtk.cc
+++ b/chrome/browser/gtk/tabs/tab_strip_gtk.cc
@@ -1093,8 +1093,12 @@ void TabStripGtk::OnSizeAllocate(GtkWidget* widget, GtkAllocation* allocation,
// static
gboolean TabStripGtk::OnButtonPress(GtkWidget* widget, GdkEventButton* event,
TabStripGtk* tabstrip) {
- if (3 == event->button)
+ if (1 == event->button) {
+ gtk_window_begin_move_drag(GTK_WINDOW(gtk_widget_get_toplevel(widget)),
+ event->button, event->x_root, event->y_root, event->time);
+ } else if (3 == event->button) {
tabstrip->ShowContextMenu();
+ }
return TRUE;
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698