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 UI_VIEWS_BUBBLE_BUBBLE_FRAME_VIEW_H_ | 5 #ifndef UI_VIEWS_BUBBLE_BUBBLE_FRAME_VIEW_H_ |
6 #define UI_VIEWS_BUBBLE_BUBBLE_FRAME_VIEW_H_ | 6 #define UI_VIEWS_BUBBLE_BUBBLE_FRAME_VIEW_H_ |
7 | 7 |
8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
9 #include "base/compiler_specific.h" | 9 #include "base/compiler_specific.h" |
10 #include "base/gtest_prod_util.h" | 10 #include "base/gtest_prod_util.h" |
11 #include "ui/gfx/insets.h" | 11 #include "ui/gfx/insets.h" |
12 #include "ui/views/controls/button/button.h" | 12 #include "ui/views/controls/button/button.h" |
13 #include "ui/views/window/non_client_view.h" | 13 #include "ui/views/window/non_client_view.h" |
14 | 14 |
| 15 namespace gfx { |
| 16 class FontList; |
| 17 } |
| 18 |
15 namespace views { | 19 namespace views { |
16 | 20 |
17 class Label; | 21 class Label; |
18 class LabelButton; | 22 class LabelButton; |
19 class BubbleBorder; | 23 class BubbleBorder; |
20 | 24 |
21 // The non-client frame view of bubble-styled widgets. | 25 // The non-client frame view of bubble-styled widgets. |
22 class VIEWS_EXPORT BubbleFrameView : public NonClientFrameView, | 26 class VIEWS_EXPORT BubbleFrameView : public NonClientFrameView, |
23 public ButtonListener { | 27 public ButtonListener { |
24 public: | 28 public: |
(...skipping 11 matching lines...) Expand all Loading... |
36 virtual gfx::Rect GetBoundsForClientView() const OVERRIDE; | 40 virtual gfx::Rect GetBoundsForClientView() const OVERRIDE; |
37 virtual gfx::Rect GetWindowBoundsForClientBounds( | 41 virtual gfx::Rect GetWindowBoundsForClientBounds( |
38 const gfx::Rect& client_bounds) const OVERRIDE; | 42 const gfx::Rect& client_bounds) const OVERRIDE; |
39 virtual int NonClientHitTest(const gfx::Point& point) OVERRIDE; | 43 virtual int NonClientHitTest(const gfx::Point& point) OVERRIDE; |
40 virtual void GetWindowMask(const gfx::Size& size, | 44 virtual void GetWindowMask(const gfx::Size& size, |
41 gfx::Path* window_mask) OVERRIDE; | 45 gfx::Path* window_mask) OVERRIDE; |
42 virtual void ResetWindowControls() OVERRIDE; | 46 virtual void ResetWindowControls() OVERRIDE; |
43 virtual void UpdateWindowIcon() OVERRIDE; | 47 virtual void UpdateWindowIcon() OVERRIDE; |
44 virtual void UpdateWindowTitle() OVERRIDE; | 48 virtual void UpdateWindowTitle() OVERRIDE; |
45 | 49 |
| 50 // Set the FontList to be used for the title of the bubble. |
| 51 void SetTitleFontList(const gfx::FontList& font_list); |
| 52 |
46 // View overrides: | 53 // View overrides: |
47 virtual gfx::Insets GetInsets() const OVERRIDE; | 54 virtual gfx::Insets GetInsets() const OVERRIDE; |
48 virtual gfx::Size GetPreferredSize() const OVERRIDE; | 55 virtual gfx::Size GetPreferredSize() const OVERRIDE; |
49 virtual gfx::Size GetMinimumSize() const OVERRIDE; | 56 virtual gfx::Size GetMinimumSize() const OVERRIDE; |
50 virtual void Layout() OVERRIDE; | 57 virtual void Layout() OVERRIDE; |
51 virtual const char* GetClassName() const OVERRIDE; | 58 virtual const char* GetClassName() const OVERRIDE; |
52 virtual void ChildPreferredSizeChanged(View* child) OVERRIDE; | 59 virtual void ChildPreferredSizeChanged(View* child) OVERRIDE; |
53 virtual void OnThemeChanged() OVERRIDE; | 60 virtual void OnThemeChanged() OVERRIDE; |
54 virtual void OnNativeThemeChanged(const ui::NativeTheme* theme) OVERRIDE; | 61 virtual void OnNativeThemeChanged(const ui::NativeTheme* theme) OVERRIDE; |
55 | 62 |
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
105 // When supplied, this view is placed in the titlebar between the title and | 112 // When supplied, this view is placed in the titlebar between the title and |
106 // (x) close button. | 113 // (x) close button. |
107 View* titlebar_extra_view_; | 114 View* titlebar_extra_view_; |
108 | 115 |
109 DISALLOW_COPY_AND_ASSIGN(BubbleFrameView); | 116 DISALLOW_COPY_AND_ASSIGN(BubbleFrameView); |
110 }; | 117 }; |
111 | 118 |
112 } // namespace views | 119 } // namespace views |
113 | 120 |
114 #endif // UI_VIEWS_BUBBLE_BUBBLE_FRAME_VIEW_H_ | 121 #endif // UI_VIEWS_BUBBLE_BUBBLE_FRAME_VIEW_H_ |
OLD | NEW |