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

Side by Side Diff: cc/trees/proxy_main.cc

Issue 1625473002: compositor-worker: blink->cc plumbing Base URL: https://chromium.googlesource.com/chromium/src.git@upstream-compositor-worker
Patch Set: Merge with landing of https://codereview.chromium.org/1599673002/ on master Created 4 years, 11 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 | « cc/trees/proxy_main.h ('k') | cc/trees/single_thread_proxy.h » ('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 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 #include "cc/trees/proxy_main.h" 5 #include "cc/trees/proxy_main.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <string> 8 #include <string>
9 9
10 #include "base/trace_event/trace_event.h" 10 #include "base/trace_event/trace_event.h"
(...skipping 385 matching lines...) Expand 10 before | Expand all | Expand 10 after
396 TRACE_EVENT0("cc", "ProxyMain::Stop"); 396 TRACE_EVENT0("cc", "ProxyMain::Stop");
397 DCHECK(IsMainThread()); 397 DCHECK(IsMainThread());
398 DCHECK(started_); 398 DCHECK(started_);
399 399
400 channel_main_->SynchronouslyCloseImpl(); 400 channel_main_->SynchronouslyCloseImpl();
401 401
402 layer_tree_host_ = nullptr; 402 layer_tree_host_ = nullptr;
403 started_ = false; 403 started_ = false;
404 } 404 }
405 405
406 void ProxyMain::SetMutator(LayerTreeMutator* mutator) {
407 TRACE_EVENT0("compositor-worker", "ThreadProxy::SetMutator");
408 channel_main_->InitializeMutatorOnImpl(mutator);
409 }
410
406 bool ProxyMain::SupportsImplScrolling() const { 411 bool ProxyMain::SupportsImplScrolling() const {
407 return true; 412 return true;
408 } 413 }
409 414
410 bool ProxyMain::MainFrameWillHappenForTesting() { 415 bool ProxyMain::MainFrameWillHappenForTesting() {
411 DCHECK(IsMainThread()); 416 DCHECK(IsMainThread());
412 bool main_frame_will_happen = false; 417 bool main_frame_will_happen = false;
413 { 418 {
414 DebugScopedSetMainThreadBlocked main_thread_blocked(task_runner_provider_); 419 DebugScopedSetMainThreadBlocked main_thread_blocked(task_runner_provider_);
415 CompletionEvent completion; 420 CompletionEvent completion;
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
456 return false; 461 return false;
457 channel_main_->SetNeedsCommitOnImpl(); 462 channel_main_->SetNeedsCommitOnImpl();
458 return true; 463 return true;
459 } 464 }
460 465
461 bool ProxyMain::IsMainThread() const { 466 bool ProxyMain::IsMainThread() const {
462 return task_runner_provider_->IsMainThread(); 467 return task_runner_provider_->IsMainThread();
463 } 468 }
464 469
465 } // namespace cc 470 } // namespace cc
OLDNEW
« no previous file with comments | « cc/trees/proxy_main.h ('k') | cc/trees/single_thread_proxy.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698