Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 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 | |
| 3 // found in the LICENSE file. | |
| 4 | |
| 5 #ifndef CHROME_BROWSER_UI_PANELS_NATIVE_PANEL_STACK_H_ | |
| 6 #define CHROME_BROWSER_UI_PANELS_NATIVE_PANEL_STACK_H_ | |
| 7 | |
| 8 #include "ui/gfx/native_widget_types.h" | |
| 9 | |
| 10 class StackedPanelCollection; | |
| 11 namespace gfx { | |
| 12 class Rect; | |
| 13 } | |
| 14 | |
| 15 // An interface that encapsulates the platform-specific behaviors that are | |
| 16 // needed to support multiple panels that are stacked together. A native | |
| 17 // window might be created to enclose all the panels in the stack. The lifetime | |
| 18 // of the class that implements this interface is managed by itself. | |
| 19 class NativePanelStack { | |
| 20 friend class StackedPanelCollection; | |
| 21 | |
| 22 public: | |
| 23 // The StackedPanelCollection instance is passed and owned by the | |
| 24 // NativePanelStack instance that is being created. | |
| 25 static NativePanelStack* Create(StackedPanelCollection* stack); | |
| 26 virtual ~NativePanelStack() {} | |
| 27 | |
| 28 protected: | |
| 29 virtual void Close() = 0; | |
|
Dmitry Titov
2013/01/10 00:16:24
Could you add a comment about who and when calls t
jianli
2013/01/10 02:05:37
Done.
| |
| 30 virtual void OnPanelAddedOrRemoved() = 0; | |
|
Dmitry Titov
2013/01/10 00:16:24
This feels like it should get a Panel* argument, t
jianli
2013/01/10 02:05:37
Done.
| |
| 31 virtual gfx::NativeWindow GetNativeWindow() const = 0; | |
| 32 virtual void SetBounds(const gfx::Rect& bounds) = 0; | |
|
Dmitry Titov
2013/01/10 00:16:24
SetBounds - also a comment would be useful about w
jianli
2013/01/10 02:05:37
Done.
| |
| 33 }; | |
| 34 | |
| 35 #endif // CHROME_BROWSER_UI_PANELS_NATIVE_PANEL_STACK_H_ | |
| OLD | NEW |