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 ASH_WM_CUSTOM_FRAME_VIEW_ASH_H_ | 5 #ifndef ASH_WM_CUSTOM_FRAME_VIEW_ASH_H_ |
6 #define ASH_WM_CUSTOM_FRAME_VIEW_ASH_H_ | 6 #define ASH_WM_CUSTOM_FRAME_VIEW_ASH_H_ |
7 | 7 |
8 #include "ash/ash_export.h" | 8 #include "ash/ash_export.h" |
9 #include "base/memory/scoped_ptr.h" | 9 #include "base/memory/scoped_ptr.h" |
10 #include "ui/views/controls/button/button.h" // ButtonListener | 10 #include "ui/views/controls/button/button.h" // ButtonListener |
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
65 | 65 |
66 // views::View overrides: | 66 // views::View overrides: |
67 virtual gfx::Size GetPreferredSize() OVERRIDE; | 67 virtual gfx::Size GetPreferredSize() OVERRIDE; |
68 virtual void Layout() OVERRIDE; | 68 virtual void Layout() OVERRIDE; |
69 virtual std::string GetClassName() const OVERRIDE; | 69 virtual std::string GetClassName() const OVERRIDE; |
70 virtual void OnPaint(gfx::Canvas* canvas) OVERRIDE; | 70 virtual void OnPaint(gfx::Canvas* canvas) OVERRIDE; |
71 virtual gfx::Size GetMinimumSize() OVERRIDE; | 71 virtual gfx::Size GetMinimumSize() OVERRIDE; |
72 | 72 |
73 // views::ButtonListener overrides: | 73 // views::ButtonListener overrides: |
74 virtual void ButtonPressed(views::Button* sender, | 74 virtual void ButtonPressed(views::Button* sender, |
75 const views::Event& event) OVERRIDE; | 75 const ui::Event& event) OVERRIDE; |
76 | 76 |
77 private: | 77 private: |
78 // Height from top of window to top of client area. | 78 // Height from top of window to top of client area. |
79 int NonClientTopBorderHeight() const; | 79 int NonClientTopBorderHeight() const; |
80 | 80 |
81 // Not owned. | 81 // Not owned. |
82 views::Widget* frame_; | 82 views::Widget* frame_; |
83 | 83 |
84 views::ImageButton* maximize_button_; | 84 views::ImageButton* maximize_button_; |
85 views::ImageButton* close_button_; | 85 views::ImageButton* close_button_; |
86 views::ImageButton* window_icon_; | 86 views::ImageButton* window_icon_; |
87 | 87 |
88 scoped_ptr<FramePainter> frame_painter_; | 88 scoped_ptr<FramePainter> frame_painter_; |
89 | 89 |
90 DISALLOW_COPY_AND_ASSIGN(CustomFrameViewAsh); | 90 DISALLOW_COPY_AND_ASSIGN(CustomFrameViewAsh); |
91 }; | 91 }; |
92 | 92 |
93 } // namespace ash | 93 } // namespace ash |
94 | 94 |
95 #endif // ASH_WM_CUSTOM_FRAME_VIEW_ASH_H_ | 95 #endif // ASH_WM_CUSTOM_FRAME_VIEW_ASH_H_ |
OLD | NEW |