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

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

Issue 2886873002: Only send the FrameSinkId to client when it is necessary (Closed)
Patch Set: Address review issues. Created 3 years, 7 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
« no previous file with comments | « services/ui/test_wm/test_wm.cc ('k') | services/ui/ws/test_change_tracker.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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_TEST_CHANGE_TRACKER_H_ 5 #ifndef SERVICES_UI_WS_TEST_CHANGE_TRACKER_H_
6 #define SERVICES_UI_WS_TEST_CHANGE_TRACKER_H_ 6 #define SERVICES_UI_WS_TEST_CHANGE_TRACKER_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <string> 10 #include <string>
(...skipping 126 matching lines...) Expand 10 before | Expand all | Expand 10 after
137 ~TestChangeTracker(); 137 ~TestChangeTracker();
138 138
139 void set_delegate(Delegate* delegate) { delegate_ = delegate; } 139 void set_delegate(Delegate* delegate) { delegate_ = delegate; }
140 140
141 std::vector<Change>* changes() { return &changes_; } 141 std::vector<Change>* changes() { return &changes_; }
142 142
143 // Each of these functions generate a Change. There is one per 143 // Each of these functions generate a Change. There is one per
144 // WindowTreeClient function. 144 // WindowTreeClient function.
145 void OnEmbed(ClientSpecificId client_id, 145 void OnEmbed(ClientSpecificId client_id,
146 mojom::WindowDataPtr root, 146 mojom::WindowDataPtr root,
147 bool drawn, 147 bool drawn);
148 const cc::FrameSinkId& frame_sink_id);
149 void OnEmbeddedAppDisconnected(Id window_id); 148 void OnEmbeddedAppDisconnected(Id window_id);
150 void OnUnembed(Id window_id); 149 void OnUnembed(Id window_id);
151 void OnCaptureChanged(Id new_capture_window_id, Id old_capture_window_id); 150 void OnCaptureChanged(Id new_capture_window_id, Id old_capture_window_id);
152 void OnFrameSinkIdAllocated(Id window_id, 151 void OnFrameSinkIdAllocated(Id window_id,
153 const cc::FrameSinkId& frame_sink_id); 152 const cc::FrameSinkId& frame_sink_id);
154 void OnTransientWindowAdded(Id window_id, Id transient_window_id); 153 void OnTransientWindowAdded(Id window_id, Id transient_window_id);
155 void OnTransientWindowRemoved(Id window_id, Id transient_window_id); 154 void OnTransientWindowRemoved(Id window_id, Id transient_window_id);
156 void OnWindowBoundsChanged( 155 void OnWindowBoundsChanged(
157 Id window_id, 156 Id window_id,
158 const gfx::Rect& old_bounds, 157 const gfx::Rect& old_bounds,
(...skipping 17 matching lines...) Expand all
176 uint32_t window_id); 175 uint32_t window_id);
177 void OnWindowSharedPropertyChanged( 176 void OnWindowSharedPropertyChanged(
178 Id window_id, 177 Id window_id,
179 const std::string& name, 178 const std::string& name,
180 const base::Optional<std::vector<uint8_t>>& data); 179 const base::Optional<std::vector<uint8_t>>& data);
181 void OnWindowFocused(Id window_id); 180 void OnWindowFocused(Id window_id);
182 void OnWindowCursorChanged(Id window_id, const ui::CursorData& cursor); 181 void OnWindowCursorChanged(Id window_id, const ui::CursorData& cursor);
183 void OnChangeCompleted(uint32_t change_id, bool success); 182 void OnChangeCompleted(uint32_t change_id, bool success);
184 void OnTopLevelCreated(uint32_t change_id, 183 void OnTopLevelCreated(uint32_t change_id,
185 mojom::WindowDataPtr window_data, 184 mojom::WindowDataPtr window_data,
186 bool drawn, 185 bool drawn);
187 const cc::FrameSinkId& frame_sink_id);
188 void OnWindowSurfaceChanged(Id window_id, 186 void OnWindowSurfaceChanged(Id window_id,
189 const cc::SurfaceInfo& surface_info); 187 const cc::SurfaceInfo& surface_info);
190 188
191 private: 189 private:
192 void AddChange(const Change& change); 190 void AddChange(const Change& change);
193 191
194 Delegate* delegate_; 192 Delegate* delegate_;
195 std::vector<Change> changes_; 193 std::vector<Change> changes_;
196 194
197 DISALLOW_COPY_AND_ASSIGN(TestChangeTracker); 195 DISALLOW_COPY_AND_ASSIGN(TestChangeTracker);
198 }; 196 };
199 197
200 } // namespace ws 198 } // namespace ws
201 199
202 } // namespace ui 200 } // namespace ui
203 201
204 #endif // SERVICES_UI_WS_TEST_CHANGE_TRACKER_H_ 202 #endif // SERVICES_UI_WS_TEST_CHANGE_TRACKER_H_
OLDNEW
« no previous file with comments | « services/ui/test_wm/test_wm.cc ('k') | services/ui/ws/test_change_tracker.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698