OLD | NEW |
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/views/frame/glass_browser_frame_view.h" | 5 #include "chrome/browser/ui/views/frame/glass_browser_frame_view.h" |
6 | 6 |
7 #include "base/prefs/pref_service.h" | 7 #include "base/prefs/pref_service.h" |
8 #include "base/strings/utf_string_conversions.h" | 8 #include "base/strings/utf_string_conversions.h" |
9 #include "chrome/app/chrome_command_ids.h" | 9 #include "chrome/app/chrome_command_ids.h" |
10 #include "chrome/app/chrome_dll_resource.h" | 10 #include "chrome/app/chrome_dll_resource.h" |
(...skipping 258 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
269 LayoutAvatar(); | 269 LayoutAvatar(); |
270 | 270 |
271 LayoutClientView(); | 271 LayoutClientView(); |
272 } | 272 } |
273 | 273 |
274 /////////////////////////////////////////////////////////////////////////////// | 274 /////////////////////////////////////////////////////////////////////////////// |
275 // GlassBrowserFrameView, views::ButtonListener overrides: | 275 // GlassBrowserFrameView, views::ButtonListener overrides: |
276 void GlassBrowserFrameView::ButtonPressed(views::Button* sender, | 276 void GlassBrowserFrameView::ButtonPressed(views::Button* sender, |
277 const ui::Event& event) { | 277 const ui::Event& event) { |
278 if (sender == new_avatar_button()) { | 278 if (sender == new_avatar_button()) { |
| 279 if (new_avatar_button()->IsMouseReleaseActionSuppressed()) |
| 280 return; |
279 browser_view()->ShowAvatarBubbleFromAvatarButton( | 281 browser_view()->ShowAvatarBubbleFromAvatarButton( |
280 BrowserWindow::AVATAR_BUBBLE_MODE_DEFAULT, | 282 BrowserWindow::AVATAR_BUBBLE_MODE_DEFAULT, |
281 signin::ManageAccountsParams()); | 283 signin::ManageAccountsParams()); |
282 } | 284 } |
283 } | 285 } |
284 | 286 |
285 /////////////////////////////////////////////////////////////////////////////// | 287 /////////////////////////////////////////////////////////////////////////////// |
286 // GlassBrowserFrameView, private: | 288 // GlassBrowserFrameView, private: |
287 | 289 |
288 // views::NonClientFrameView: | 290 // views::NonClientFrameView: |
(...skipping 298 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
587 static bool initialized = false; | 589 static bool initialized = false; |
588 if (!initialized) { | 590 if (!initialized) { |
589 for (int i = 0; i < kThrobberIconCount; ++i) { | 591 for (int i = 0; i < kThrobberIconCount; ++i) { |
590 throbber_icons_[i] = | 592 throbber_icons_[i] = |
591 ui::LoadThemeIconFromResourcesDataDLL(IDI_THROBBER_01 + i); | 593 ui::LoadThemeIconFromResourcesDataDLL(IDI_THROBBER_01 + i); |
592 DCHECK(throbber_icons_[i]); | 594 DCHECK(throbber_icons_[i]); |
593 } | 595 } |
594 initialized = true; | 596 initialized = true; |
595 } | 597 } |
596 } | 598 } |
OLD | NEW |