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

Side by Side Diff: services/ui/ws/server_window_compositor_frame_sink_manager.h

Issue 2683553004: Cleanup ServerWindowCompositorFrameSinkManager and FrameGenerator (Closed)
Patch Set: Created 3 years, 10 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 SERVICES_UI_WS_SERVER_WINDOW_COMPOSITOR_FRAME_SINK_MANAGER_H_ 5 #ifndef SERVICES_UI_WS_SERVER_WINDOW_COMPOSITOR_FRAME_SINK_MANAGER_H_
6 #define SERVICES_UI_WS_SERVER_WINDOW_COMPOSITOR_FRAME_SINK_MANAGER_H_ 6 #define SERVICES_UI_WS_SERVER_WINDOW_COMPOSITOR_FRAME_SINK_MANAGER_H_
7 7
8 #include "base/macros.h" 8 #include "base/macros.h"
9 #include "cc/ipc/compositor_frame.mojom.h" 9 #include "cc/ipc/compositor_frame.mojom.h"
10 #include "cc/ipc/display_compositor.mojom.h" 10 #include "cc/ipc/display_compositor.mojom.h"
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after
56 // Adds the provided |frame_sink_id| to this ServerWindow's associated 56 // Adds the provided |frame_sink_id| to this ServerWindow's associated
57 // CompositorFrameSink if possible. If this ServerWindow does not have 57 // CompositorFrameSink if possible. If this ServerWindow does not have
58 // an associated CompositorFrameSink then this method will recursively 58 // an associated CompositorFrameSink then this method will recursively
59 // walk up the window hierarchy and register itself with the first ancestor 59 // walk up the window hierarchy and register itself with the first ancestor
60 // that has a CompositorFrameSink of the same type. This method returns 60 // that has a CompositorFrameSink of the same type. This method returns
61 // the FrameSinkId that is the first composited ancestor of the ServerWindow 61 // the FrameSinkId that is the first composited ancestor of the ServerWindow
62 // assocaited with the provided |frame_sink_id|. 62 // assocaited with the provided |frame_sink_id|.
63 void AddChildFrameSinkId(const cc::FrameSinkId& frame_sink_id); 63 void AddChildFrameSinkId(const cc::FrameSinkId& frame_sink_id);
64 void RemoveChildFrameSinkId(const cc::FrameSinkId& frame_sink_id); 64 void RemoveChildFrameSinkId(const cc::FrameSinkId& frame_sink_id);
65 65
66 ServerWindow* window() { return window_; }
67
68 bool HasCompositorFrameSink() const;
69
70 gfx::Size GetLatestFrameSize() const; 66 gfx::Size GetLatestFrameSize() const;
71 cc::SurfaceId GetLatestSurfaceId() const;
72 void SetLatestSurfaceInfo(const cc::SurfaceInfo& surface_info); 67 void SetLatestSurfaceInfo(const cc::SurfaceInfo& surface_info);
73 68
74 void OnRootChanged(ServerWindow* old_root, ServerWindow* new_root); 69 void OnRootChanged(ServerWindow* old_root, ServerWindow* new_root);
75 70
76 private: 71 private:
77 friend class ServerWindowCompositorFrameSinkManagerTestApi; 72 friend class ServerWindowCompositorFrameSinkManagerTestApi;
78 friend class ServerWindowCompositorFrameSink; 73 friend class ServerWindowCompositorFrameSink;
79 74
80 ServerWindow* window_; 75 ServerWindow* window_;
81 76
82 std::unique_ptr<CompositorFrameSinkData> frame_sink_data_; 77 std::unique_ptr<CompositorFrameSinkData> frame_sink_data_;
83 78
84 DISALLOW_COPY_AND_ASSIGN(ServerWindowCompositorFrameSinkManager); 79 DISALLOW_COPY_AND_ASSIGN(ServerWindowCompositorFrameSinkManager);
85 }; 80 };
86 81
87 } // namespace ws 82 } // namespace ws
88 } // namespace ui 83 } // namespace ui
89 84
90 #endif // SERVICES_UI_WS_SERVER_WINDOW_COMPOSITOR_FRAME_SINK_MANAGER_H_ 85 #endif // SERVICES_UI_WS_SERVER_WINDOW_COMPOSITOR_FRAME_SINK_MANAGER_H_
OLDNEW
« no previous file with comments | « services/ui/ws/frame_generator.cc ('k') | services/ui/ws/server_window_compositor_frame_sink_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698