OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 #ifndef CHROME_BROWSER_UI_VIEWS_AVATAR_MENU_BUBBLE_VIEW_H_ | 5 #ifndef CHROME_BROWSER_UI_VIEWS_AVATAR_MENU_BUBBLE_VIEW_H_ |
6 #define CHROME_BROWSER_UI_VIEWS_AVATAR_MENU_BUBBLE_VIEW_H_ | 6 #define CHROME_BROWSER_UI_VIEWS_AVATAR_MENU_BUBBLE_VIEW_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 20 matching lines...) Expand all Loading... |
31 public views::LinkListener, | 31 public views::LinkListener, |
32 public BubbleDelegate, | 32 public BubbleDelegate, |
33 public AvatarMenuModelObserver { | 33 public AvatarMenuModelObserver { |
34 public: | 34 public: |
35 explicit AvatarMenuBubbleView(Browser* browser); | 35 explicit AvatarMenuBubbleView(Browser* browser); |
36 virtual ~AvatarMenuBubbleView(); | 36 virtual ~AvatarMenuBubbleView(); |
37 | 37 |
38 // views::View implementation. | 38 // views::View implementation. |
39 virtual gfx::Size GetPreferredSize() OVERRIDE; | 39 virtual gfx::Size GetPreferredSize() OVERRIDE; |
40 virtual void Layout() OVERRIDE; | 40 virtual void Layout() OVERRIDE; |
41 virtual bool AcceleratorPressed( | 41 virtual bool AcceleratorPressed(const ui::Accelerator& accelerator) OVERRIDE; |
42 const views::Accelerator& accelerator) OVERRIDE; | |
43 | 42 |
44 // views::ButtonListener implementation. | 43 // views::ButtonListener implementation. |
45 virtual void ButtonPressed(views::Button* sender, | 44 virtual void ButtonPressed(views::Button* sender, |
46 const views::Event& event) OVERRIDE; | 45 const views::Event& event) OVERRIDE; |
47 | 46 |
48 // views::LinkListener implementation. | 47 // views::LinkListener implementation. |
49 virtual void LinkClicked(views::Link* source, int event_flags) OVERRIDE; | 48 virtual void LinkClicked(views::Link* source, int event_flags) OVERRIDE; |
50 | 49 |
51 // BubbleDelegate implementation. | 50 // BubbleDelegate implementation. |
52 virtual void BubbleShown() OVERRIDE; | 51 virtual void BubbleShown() OVERRIDE; |
53 virtual void BubbleClosing(Bubble* bubble, bool closed_by_escape) OVERRIDE; | 52 virtual void BubbleClosing(Bubble* bubble, bool closed_by_escape) OVERRIDE; |
54 virtual bool CloseOnEscape() OVERRIDE; | 53 virtual bool CloseOnEscape() OVERRIDE; |
55 virtual bool FadeInOnShow() OVERRIDE; | 54 virtual bool FadeInOnShow() OVERRIDE; |
56 | 55 |
57 // AvatarMenuModelObserver implementation. | 56 // AvatarMenuModelObserver implementation. |
58 virtual void OnAvatarMenuModelChanged( | 57 virtual void OnAvatarMenuModelChanged( |
59 AvatarMenuModel* avatar_menu_model) OVERRIDE; | 58 AvatarMenuModel* avatar_menu_model) OVERRIDE; |
60 | 59 |
61 private: | 60 private: |
62 views::Link* add_profile_link_; | 61 views::Link* add_profile_link_; |
63 scoped_ptr<AvatarMenuModel> avatar_menu_model_; | 62 scoped_ptr<AvatarMenuModel> avatar_menu_model_; |
64 Browser* browser_; | 63 Browser* browser_; |
65 std::vector<views::CustomButton*> item_views_; | 64 std::vector<views::CustomButton*> item_views_; |
66 views::Separator* separator_; | 65 views::Separator* separator_; |
67 | 66 |
68 DISALLOW_COPY_AND_ASSIGN(AvatarMenuBubbleView); | 67 DISALLOW_COPY_AND_ASSIGN(AvatarMenuBubbleView); |
69 }; | 68 }; |
70 | 69 |
71 #endif // CHROME_BROWSER_UI_VIEWS_AVATAR_MENU_BUBBLE_VIEW_H_ | 70 #endif // CHROME_BROWSER_UI_VIEWS_AVATAR_MENU_BUBBLE_VIEW_H_ |
OLD | NEW |