Chromium Code Reviews| Index: cc/test/layer_tree_host_remote_for_testing.cc |
| diff --git a/cc/test/layer_tree_host_remote_for_testing.cc b/cc/test/layer_tree_host_remote_for_testing.cc |
| index 25dc9e571d9935c9825ca2928e74bf96a45f17d0..dfeb5ef7c19d1e9ce97df667cf7192756061f756 100644 |
| --- a/cc/test/layer_tree_host_remote_for_testing.cc |
| +++ b/cc/test/layer_tree_host_remote_for_testing.cc |
| @@ -295,26 +295,25 @@ void LayerTreeHostRemoteForTesting::RemoteHostNeedsMainFrame() { |
| void LayerTreeHostRemoteForTesting::ProcessRemoteCompositorUpdate( |
| std::unique_ptr<CompositorProtoState> compositor_proto_state) { |
|
Khushal
2016/10/14 20:12:31
Can you add a DCHECK at the beginning of this meth
|
| - pending_compositor_proto_state_ = std::move(compositor_proto_state); |
| + std::unique_ptr<CompositorProtoState> pending_compositor_proto_state = |
|
Khushal
2016/10/14 20:12:31
Don't really need this temp var.
|
| + std::move(compositor_proto_state); |
| + |
| + // Deserialize the update from the remote host into client side LTH in |
| + // process. This bypasses the network layer. |
| + // We can patch test only layer data that are not serialized after the |
|
Khushal
2016/10/14 20:12:31
I would say do it in this patch itself. This was a
xingliu
2016/10/17 16:26:49
Done. Please help to take a look if the patch logi
|
| + // deserialization. |
| + const proto::LayerTreeHost& layer_tree_host_proto = |
| + pending_compositor_proto_state->compositor_message->layer_tree_host(); |
| + compositor_state_deserializer_->DeserializeCompositorUpdate( |
| + layer_tree_host_proto); |
| } |
| void LayerTreeHostRemoteForTesting::UpdateStateOnInProcessHost() { |
|
Khushal
2016/10/14 20:12:31
Remove this method.
xingliu
2016/10/17 16:26:49
Done.
|
| - // When the InProcess host asks us to update, we de-serialize the update from |
| - // the remote host. |
| - if (pending_compositor_proto_state_) { |
| - const proto::LayerTreeHost& layer_tree_host_proto = |
| - pending_compositor_proto_state_->compositor_message->layer_tree_host(); |
| - compositor_state_deserializer_->DeserializeCompositorUpdate( |
| - layer_tree_host_proto); |
| - |
| - pending_compositor_proto_state_ = nullptr; |
| - |
| // The only case where the remote host would give a compositor update is if |
| // they wanted the main frame to go till the commit pipeline stage. So |
| // request one to make sure that the in process main frame also goes till |
| // the commit step. |
| layer_tree_host_in_process_->SetNeedsCommit(); |
|
Khushal
2016/10/14 20:12:31
Move this to ProcessRemoteCompositorUpdate. The ai
|
| - } |
| } |
| } // namespace cc |