Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(3)

Side by Side Diff: ash/wm/panel_frame_view.h

Issue 11363250: Allow Chrome apps to create Ash Panels (apps v2) (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 8 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
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_PANEL_FRAME_VIEW_H_ 5 #ifndef ASH_WM_PANEL_FRAME_VIEW_H_
6 #define ASH_WM_PANEL_FRAME_VIEW_H_ 6 #define ASH_WM_PANEL_FRAME_VIEW_H_
7 7
8 #include "ash/ash_export.h" 8 #include "ash/ash_export.h"
9 #include "base/basictypes.h" 9 #include "base/basictypes.h"
10 #include "ui/aura/aura_export.h" 10 #include "ui/aura/aura_export.h"
11 #include "ui/views/window/non_client_view.h" 11 #include "ui/views/window/non_client_view.h"
12 #include "ui/views/controls/button/button.h" // ButtonListener 12 #include "ui/views/controls/button/button.h" // ButtonListener
13 13
14 namespace views { 14 namespace views {
15 class ImageButton; 15 class ImageButton;
16 } 16 }
17 17
18 namespace ash { 18 namespace ash {
19 19
20 class FramePainter; 20 class FramePainter;
21 21
22 class ASH_EXPORT PanelFrameView : public views::NonClientFrameView, 22 class ASH_EXPORT PanelFrameView : public views::NonClientFrameView,
23 public views::ButtonListener { 23 public views::ButtonListener {
24 public: 24 public:
25 explicit PanelFrameView(views::Widget* frame); 25 PanelFrameView(views::Widget* frame, bool show_header);
26 virtual ~PanelFrameView(); 26 virtual ~PanelFrameView();
27 27
28 private: 28 private:
29 void InitFramePainter(views::Widget* frame);
30
29 // Overridden from views::NonClientFrameView: 31 // Overridden from views::NonClientFrameView:
30 virtual gfx::Rect GetBoundsForClientView() const OVERRIDE; 32 virtual gfx::Rect GetBoundsForClientView() const OVERRIDE;
31 virtual gfx::Rect GetWindowBoundsForClientBounds( 33 virtual gfx::Rect GetWindowBoundsForClientBounds(
32 const gfx::Rect& client_bounds) const OVERRIDE; 34 const gfx::Rect& client_bounds) const OVERRIDE;
33 virtual int NonClientHitTest(const gfx::Point& point) OVERRIDE; 35 virtual int NonClientHitTest(const gfx::Point& point) OVERRIDE;
34 virtual void GetWindowMask(const gfx::Size& size, 36 virtual void GetWindowMask(const gfx::Size& size,
35 gfx::Path* window_mask) OVERRIDE; 37 gfx::Path* window_mask) OVERRIDE;
36 virtual void ResetWindowControls() OVERRIDE; 38 virtual void ResetWindowControls() OVERRIDE;
37 virtual void UpdateWindowIcon() OVERRIDE; 39 virtual void UpdateWindowIcon() OVERRIDE;
38 virtual void UpdateWindowTitle() OVERRIDE; 40 virtual void UpdateWindowTitle() OVERRIDE;
(...skipping 12 matching lines...) Expand all
51 views::ImageButton* close_button_; 53 views::ImageButton* close_button_;
52 views::ImageButton* minimize_button_; 54 views::ImageButton* minimize_button_;
53 gfx::Rect client_view_bounds_; 55 gfx::Rect client_view_bounds_;
54 56
55 DISALLOW_COPY_AND_ASSIGN(PanelFrameView); 57 DISALLOW_COPY_AND_ASSIGN(PanelFrameView);
56 }; 58 };
57 59
58 } 60 }
59 61
60 #endif // ASH_WM_PANEL_FRAME_VIEW_H_ 62 #endif // ASH_WM_PANEL_FRAME_VIEW_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698