OLD | NEW |
---|---|
(Empty) | |
1 // Copyright (c) 2014 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 UI_OZONE_COMMON_PLATFORM_WINDOW_BASE_H_ | |
6 #define UI_OZONE_COMMON_PLATFORM_WINDOW_BASE_H_ | |
7 | |
8 #include "ui/base/cursor/cursor.h" | |
9 #include "ui/gfx/geometry/rect.h" | |
10 #include "ui/gfx/native_widget_types.h" | |
11 #include "ui/ozone/ozone_export.h" | |
12 #include "ui/platform_window/platform_window.h" | |
13 | |
14 namespace gfx { | |
15 class Point; | |
16 class Rect; | |
17 } | |
18 | |
19 namespace ui { | |
20 | |
21 class PlatformWindowDelegate; | |
22 | |
23 // Platform window subclass with stubs for most window functions. | |
24 class OZONE_EXPORT PlatformWindowBase : public PlatformWindow { | |
sadrul
2014/07/14 22:58:07
I don't think we should have this. If we must, we
spang
2014/07/14 23:17:41
Please elaborate - what's the harm? Maximizing doe
sadrul
2014/07/15 16:53:10
The platforms that don't need maximize will have a
| |
25 public: | |
26 PlatformWindowBase(); | |
27 virtual ~PlatformWindowBase(); | |
28 | |
29 // PlatformWindow: | |
30 virtual void Show() OVERRIDE; | |
31 virtual void Hide() OVERRIDE; | |
32 virtual void Close() OVERRIDE; | |
33 virtual void SetCapture() OVERRIDE; | |
34 virtual void ReleaseCapture() OVERRIDE; | |
35 virtual void ToggleFullscreen() OVERRIDE; | |
36 virtual void Maximize() OVERRIDE; | |
37 virtual void Minimize() OVERRIDE; | |
38 virtual void Restore() OVERRIDE; | |
39 | |
40 private: | |
41 DISALLOW_COPY_AND_ASSIGN(PlatformWindowBase); | |
42 }; | |
43 | |
44 // This is just transitional code. Will be removed shortly. | |
45 class OZONE_EXPORT PlatformWindowCompat : public PlatformWindowBase { | |
46 public: | |
47 PlatformWindowCompat(PlatformWindowDelegate* delegate, | |
48 const gfx::Rect& bounds); | |
49 virtual ~PlatformWindowCompat(); | |
50 | |
51 // PlatformWindow: | |
52 virtual gfx::Rect GetBounds() OVERRIDE; | |
53 virtual void SetBounds(const gfx::Rect& bounds) OVERRIDE; | |
54 | |
55 private: | |
56 PlatformWindowDelegate* delegate_; | |
57 gfx::Rect bounds_; | |
58 | |
59 DISALLOW_COPY_AND_ASSIGN(PlatformWindowCompat); | |
60 }; | |
61 | |
62 } // namespace ui | |
63 | |
64 #endif // UI_OZONE_COMMON_PLATFORM_WINDOW_BASE_H_ | |
OLD | NEW |