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 #ifndef CHROME_BROWSER_UI_VIEWS_BROWSER_ACTION_VIEW_H_ | 5 #ifndef CHROME_BROWSER_UI_VIEWS_BROWSER_ACTION_VIEW_H_ |
6 #define CHROME_BROWSER_UI_VIEWS_BROWSER_ACTION_VIEW_H_ | 6 #define CHROME_BROWSER_UI_VIEWS_BROWSER_ACTION_VIEW_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "chrome/browser/extensions/image_loading_tracker.h" | 10 #include "chrome/browser/extensions/image_loading_tracker.h" |
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
70 gfx::Canvas* GetIconWithBadge(); | 70 gfx::Canvas* GetIconWithBadge(); |
71 | 71 |
72 // Overridden from views::View: | 72 // Overridden from views::View: |
73 virtual void Layout() OVERRIDE; | 73 virtual void Layout() OVERRIDE; |
74 virtual void GetAccessibleState(ui::AccessibleViewState* state) OVERRIDE; | 74 virtual void GetAccessibleState(ui::AccessibleViewState* state) OVERRIDE; |
75 virtual gfx::Size GetPreferredSize() OVERRIDE; | 75 virtual gfx::Size GetPreferredSize() OVERRIDE; |
76 | 76 |
77 protected: | 77 protected: |
78 // Overridden from views::View to paint the badge on top of children. | 78 // Overridden from views::View to paint the badge on top of children. |
79 virtual void PaintChildren(gfx::Canvas* canvas) OVERRIDE; | 79 virtual void PaintChildren(gfx::Canvas* canvas) OVERRIDE; |
80 virtual void ViewHierarchyChanged(bool is_add, | |
81 View* parent, | |
82 View* child) OVERRIDE; | |
83 | 80 |
84 private: | 81 private: |
85 // The Browser object this view is associated with. | 82 // The Browser object this view is associated with. |
86 Browser* browser_; | 83 Browser* browser_; |
87 | 84 |
88 // Usually a container for this view. | 85 // Usually a container for this view. |
89 Delegate* delegate_; | 86 Delegate* delegate_; |
90 | 87 |
91 // The button this view contains. | 88 // The button this view contains. |
92 BrowserActionButton* button_; | 89 BrowserActionButton* button_; |
(...skipping 127 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
220 | 217 |
221 // Responsible for running the menu. | 218 // Responsible for running the menu. |
222 scoped_ptr<views::MenuRunner> menu_runner_; | 219 scoped_ptr<views::MenuRunner> menu_runner_; |
223 | 220 |
224 friend class base::DeleteHelper<BrowserActionButton>; | 221 friend class base::DeleteHelper<BrowserActionButton>; |
225 | 222 |
226 DISALLOW_COPY_AND_ASSIGN(BrowserActionButton); | 223 DISALLOW_COPY_AND_ASSIGN(BrowserActionButton); |
227 }; | 224 }; |
228 | 225 |
229 #endif // CHROME_BROWSER_UI_VIEWS_BROWSER_ACTION_VIEW_H_ | 226 #endif // CHROME_BROWSER_UI_VIEWS_BROWSER_ACTION_VIEW_H_ |
OLD | NEW |