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

Side by Side Diff: chrome/browser/ui/gtk/avatar_menu_bubble_gtk.cc

Issue 152313003: Fix Linux/Gtk build after r247979 (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 10 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 unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/ui/gtk/avatar_menu_bubble_gtk.h" 5 #include "chrome/browser/ui/gtk/avatar_menu_bubble_gtk.h"
6 6
7 #include "base/i18n/rtl.h" 7 #include "base/i18n/rtl.h"
8 #include "base/strings/utf_string_conversions.h" 8 #include "base/strings/utf_string_conversions.h"
9 #include "chrome/browser/browser_process.h" 9 #include "chrome/browser/browser_process.h"
10 #include "chrome/browser/chrome_notification_types.h" 10 #include "chrome/browser/chrome_notification_types.h"
(...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after
86 InitContents(); 86 InitContents();
87 } 87 }
88 88
89 void AvatarMenuBubbleGtk::OpenProfile(size_t profile_index) { 89 void AvatarMenuBubbleGtk::OpenProfile(size_t profile_index) {
90 if (!bubble_) 90 if (!bubble_)
91 return; 91 return;
92 GdkModifierType modifier_state; 92 GdkModifierType modifier_state;
93 gtk_get_current_event_state(&modifier_state); 93 gtk_get_current_event_state(&modifier_state);
94 guint modifier_state_uint = modifier_state; 94 guint modifier_state_uint = modifier_state;
95 avatar_menu_->SwitchToProfile(profile_index, 95 avatar_menu_->SwitchToProfile(profile_index,
96 event_utils::DispositionFromGdkState(modifier_state_uint) == NEW_WINDOW); 96 event_utils::DispositionFromGdkState(modifier_state_uint) == NEW_WINDOW,
97 ProfileMetrics::SWITCH_PROFILE_ICON);
97 CloseBubble(); 98 CloseBubble();
98 } 99 }
99 100
100 void AvatarMenuBubbleGtk::EditProfile(size_t profile_index) { 101 void AvatarMenuBubbleGtk::EditProfile(size_t profile_index) {
101 if (!bubble_) 102 if (!bubble_)
102 return; 103 return;
103 avatar_menu_->EditProfile(profile_index); 104 avatar_menu_->EditProfile(profile_index);
104 CloseBubble(); 105 CloseBubble();
105 } 106 }
106 107
(...skipping 123 matching lines...) Expand 10 before | Expand all | Expand 10 after
230 if (bubble_) 231 if (bubble_)
231 gtk_widget_show_all(contents_); 232 gtk_widget_show_all(contents_);
232 } 233 }
233 234
234 void AvatarMenuBubbleGtk::CloseBubble() { 235 void AvatarMenuBubbleGtk::CloseBubble() {
235 if (bubble_) { 236 if (bubble_) {
236 bubble_->Close(); 237 bubble_->Close();
237 bubble_ = NULL; 238 bubble_ = NULL;
238 } 239 }
239 } 240 }
OLDNEW
« 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