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

Side by Side Diff: blimp/client/app/linux/blimp_display_manager.h

Issue 2241623002: blimp: Move compositing, input and render widget feature to client/core. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 4 months 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
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 BLIMP_CLIENT_APP_LINUX_BLIMP_DISPLAY_MANAGER_H_ 5 #ifndef BLIMP_CLIENT_APP_LINUX_BLIMP_DISPLAY_MANAGER_H_
6 #define BLIMP_CLIENT_APP_LINUX_BLIMP_DISPLAY_MANAGER_H_ 6 #define BLIMP_CLIENT_APP_LINUX_BLIMP_DISPLAY_MANAGER_H_
7 7
8 #include <memory> 8 #include <memory>
9 9
10 #include "base/macros.h" 10 #include "base/macros.h"
11 #include "blimp/client/feature/compositor/blimp_compositor_manager.h" 11 #include "blimp/client/core/compositor/compositor_deps_provider.h"
nyquist 2016/08/12 07:34:28 Needed?
Khushal 2016/08/13 00:03:21 Oh not anymore. Done.
12 #include "blimp/client/core/contents/blimp_contents_manager.h"
12 #include "ui/platform_window/platform_window_delegate.h" 13 #include "ui/platform_window/platform_window_delegate.h"
13 14
14 namespace gfx { 15 namespace gfx {
15 class Size; 16 class Size;
16 } 17 }
17 18
18 namespace ui { 19 namespace ui {
19 class PlatformWindow; 20 class PlatformWindow;
20 } 21 }
21 22
22 namespace blimp { 23 namespace blimp {
23 namespace client { 24 namespace client {
24 25 class BlimpContentsImpl;
25 class BlimpCompositorManager; 26 class CompositorDepsProvider;
nyquist 2016/08/12 07:34:28 Needed?
Khushal 2016/08/13 00:03:21 Done.
26 class RenderWidgetFeature; 27 class RenderWidgetFeature;
27 class TabControlFeature; 28 class TabControlFeature;
28 29
29 class BlimpDisplayManagerDelegate { 30 class BlimpDisplayManagerDelegate {
30 public: 31 public:
31 virtual void OnClosed() = 0; 32 virtual void OnClosed() = 0;
32 }; 33 };
33 34
34 class BlimpDisplayManager : public ui::PlatformWindowDelegate, 35 class BlimpDisplayManager : public ui::PlatformWindowDelegate {
35 BlimpCompositorManagerClient {
36 public: 36 public:
37 BlimpDisplayManager(const gfx::Size& window_size, 37 BlimpDisplayManager(const gfx::Size& window_size,
38 BlimpDisplayManagerDelegate* delegate, 38 BlimpDisplayManagerDelegate* delegate,
39 RenderWidgetFeature* render_widget_feature, 39 RenderWidgetFeature* render_widget_feature,
40 TabControlFeature* tab_control_feature); 40 TabControlFeature* tab_control_feature);
41 ~BlimpDisplayManager() override; 41 ~BlimpDisplayManager() override;
42 42
43 // ui::PlatformWindowDelegate: 43 // ui::PlatformWindowDelegate:
44 void OnBoundsChanged(const gfx::Rect& new_bounds) override; 44 void OnBoundsChanged(const gfx::Rect& new_bounds) override;
45 void OnDamageRect(const gfx::Rect& damaged_region) override; 45 void OnDamageRect(const gfx::Rect& damaged_region) override;
46 void DispatchEvent(ui::Event* event) override; 46 void DispatchEvent(ui::Event* event) override;
47 void OnCloseRequest() override; 47 void OnCloseRequest() override;
48 void OnClosed() override; 48 void OnClosed() override;
49 void OnWindowStateChanged(ui::PlatformWindowState new_state) override; 49 void OnWindowStateChanged(ui::PlatformWindowState new_state) override;
50 void OnLostCapture() override; 50 void OnLostCapture() override;
51 void OnAcceleratedWidgetAvailable(gfx::AcceleratedWidget widget, 51 void OnAcceleratedWidgetAvailable(gfx::AcceleratedWidget widget,
52 float device_pixel_ratio) override; 52 float device_pixel_ratio) override;
53 void OnAcceleratedWidgetDestroyed() override; 53 void OnAcceleratedWidgetDestroyed() override;
54 void OnActivationChanged(bool active) override; 54 void OnActivationChanged(bool active) override;
55 55
56 private: 56 private:
57 // BlimpCompositorManagerClient implementation.
58 void OnSwapBuffersCompleted() override;
59 void DidCommitAndDrawFrame() override;
60
61 float device_pixel_ratio_; 57 float device_pixel_ratio_;
62 58
63 BlimpDisplayManagerDelegate* delegate_; 59 BlimpDisplayManagerDelegate* delegate_;
64 TabControlFeature* tab_control_feature_; 60 TabControlFeature* tab_control_feature_;
65 61
66 std::unique_ptr<BlimpCompositorManager> blimp_compositor_manager_; 62 BlimpContentsManager blimp_contents_manager_;
nyquist 2016/08/12 07:34:28 Will this become BlimpClientContext possibly in th
Khushal 2016/08/13 00:03:21 Yup. That looks like where we should be asking bli
63 std::unique_ptr<BlimpContentsImpl> blimp_contents_;
67 std::unique_ptr<ui::PlatformWindow> platform_window_; 64 std::unique_ptr<ui::PlatformWindow> platform_window_;
68 65
69 DISALLOW_COPY_AND_ASSIGN(BlimpDisplayManager); 66 DISALLOW_COPY_AND_ASSIGN(BlimpDisplayManager);
70 }; 67 };
71 68
72 } // namespace client 69 } // namespace client
73 } // namespace blimp 70 } // namespace blimp
74 71
75 #endif // BLIMP_CLIENT_APP_LINUX_BLIMP_DISPLAY_MANAGER_H_ 72 #endif // BLIMP_CLIENT_APP_LINUX_BLIMP_DISPLAY_MANAGER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698