OLD | NEW |
1 // Copyright (c) 2011 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_CHROMEOS_PANELS_PANEL_SCROLLER_CONTAINER_H_ | 5 #ifndef CHROME_BROWSER_CHROMEOS_PANELS_PANEL_SCROLLER_CONTAINER_H_ |
6 #define CHROME_BROWSER_CHROMEOS_PANELS_PANEL_SCROLLER_CONTAINER_H_ | 6 #define CHROME_BROWSER_CHROMEOS_PANELS_PANEL_SCROLLER_CONTAINER_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include "base/basictypes.h" | 9 #include "base/basictypes.h" |
10 #include "base/compiler_specific.h" | 10 #include "base/compiler_specific.h" |
11 #include "ui/views/view.h" | 11 #include "ui/views/view.h" |
12 | 12 |
13 class PanelScroller; | 13 class PanelScroller; |
14 | 14 |
15 // This class wraps the contents of a panel in the panel scroller. It currently | 15 // This class wraps the contents of a panel in the panel scroller. It currently |
16 // doesn't do anything useful, but it just a placeholder. | 16 // doesn't do anything useful, but it just a placeholder. |
17 class PanelScrollerContainer : public views::View { | 17 class PanelScrollerContainer : public views::View { |
18 public: | 18 public: |
19 PanelScrollerContainer(PanelScroller* scroller, views::View* contents); | 19 PanelScrollerContainer(PanelScroller* scroller, views::View* contents); |
20 virtual ~PanelScrollerContainer(); | 20 virtual ~PanelScrollerContainer(); |
21 | 21 |
22 int HeaderSize() const; | 22 int HeaderSize() const; |
23 | 23 |
24 // view::View overrides. | 24 // view::View overrides. |
25 virtual gfx::Size GetPreferredSize() OVERRIDE; | 25 virtual gfx::Size GetPreferredSize() OVERRIDE; |
26 virtual void Layout() OVERRIDE; | 26 virtual void Layout() OVERRIDE; |
27 virtual void OnPaint(gfx::Canvas* canvas) OVERRIDE; | 27 virtual void OnPaint(gfx::CanvasSkia* canvas) OVERRIDE; |
28 | 28 |
29 private: | 29 private: |
30 // Non-owning pointer to our parent scroller object. | 30 // Non-owning pointer to our parent scroller object. |
31 PanelScroller* scroller_; | 31 PanelScroller* scroller_; |
32 | 32 |
33 views::View* contents_; | 33 views::View* contents_; |
34 | 34 |
35 DISALLOW_COPY_AND_ASSIGN(PanelScrollerContainer); | 35 DISALLOW_COPY_AND_ASSIGN(PanelScrollerContainer); |
36 }; | 36 }; |
37 | 37 |
38 #endif // CHROME_BROWSER_CHROMEOS_PANELS_PANEL_SCROLLER_CONTAINER_H_ | 38 #endif // CHROME_BROWSER_CHROMEOS_PANELS_PANEL_SCROLLER_CONTAINER_H_ |
OLD | NEW |