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

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

Issue 1602343002: compositor-worker: cc->blink mutation plumbing (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@compositor-worker-ian-patch
Patch Set: Merge master + s/scoped_ptr/unique_ptr/ Created 4 years, 8 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_common.h ('k') | cc/trees/proxy_main.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 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_impl.h" 5 #include "cc/trees/proxy_impl.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <string> 8 #include <string>
9 9
10 #include "base/auto_reset.h" 10 #include "base/auto_reset.h"
(...skipping 492 matching lines...) Expand 10 before | Expand all | Expand 10 after
503 503
504 void ProxyImpl::ScheduledActionSendBeginMainFrame(const BeginFrameArgs& args) { 504 void ProxyImpl::ScheduledActionSendBeginMainFrame(const BeginFrameArgs& args) {
505 DCHECK(IsImplThread()); 505 DCHECK(IsImplThread());
506 unsigned int begin_frame_id = nextBeginFrameId++; 506 unsigned int begin_frame_id = nextBeginFrameId++;
507 benchmark_instrumentation::ScopedBeginFrameTask begin_frame_task( 507 benchmark_instrumentation::ScopedBeginFrameTask begin_frame_task(
508 benchmark_instrumentation::kSendBeginFrame, begin_frame_id); 508 benchmark_instrumentation::kSendBeginFrame, begin_frame_id);
509 std::unique_ptr<BeginMainFrameAndCommitState> begin_main_frame_state( 509 std::unique_ptr<BeginMainFrameAndCommitState> begin_main_frame_state(
510 new BeginMainFrameAndCommitState); 510 new BeginMainFrameAndCommitState);
511 begin_main_frame_state->begin_frame_id = begin_frame_id; 511 begin_main_frame_state->begin_frame_id = begin_frame_id;
512 begin_main_frame_state->begin_frame_args = args; 512 begin_main_frame_state->begin_frame_args = args;
513 begin_main_frame_state->begin_frame_callbacks =
514 layer_tree_host_impl_->ProcessLayerTreeMutations();
513 begin_main_frame_state->scroll_info = 515 begin_main_frame_state->scroll_info =
514 layer_tree_host_impl_->ProcessScrollDeltas(); 516 layer_tree_host_impl_->ProcessScrollDeltas();
515 begin_main_frame_state->memory_allocation_limit_bytes = 517 begin_main_frame_state->memory_allocation_limit_bytes =
516 layer_tree_host_impl_->memory_allocation_limit_bytes(); 518 layer_tree_host_impl_->memory_allocation_limit_bytes();
517 begin_main_frame_state->evicted_ui_resources = 519 begin_main_frame_state->evicted_ui_resources =
518 layer_tree_host_impl_->EvictedUIResourcesExist(); 520 layer_tree_host_impl_->EvictedUIResourcesExist();
519 // TODO(vmpstr): This needs to be fixed if 521 // TODO(vmpstr): This needs to be fixed if
520 // main_frame_before_activation_enabled is set, since we might run this code 522 // main_frame_before_activation_enabled is set, since we might run this code
521 // twice before recording a duration. crbug.com/469824 523 // twice before recording a duration. crbug.com/469824
522 last_begin_main_frame_args_ = begin_main_frame_state->begin_frame_args; 524 last_begin_main_frame_args_ = begin_main_frame_state->begin_frame_args;
(...skipping 159 matching lines...) Expand 10 before | Expand all | Expand 10 after
682 bool ProxyImpl::IsMainThreadBlocked() const { 684 bool ProxyImpl::IsMainThreadBlocked() const {
683 return task_runner_provider_->IsMainThreadBlocked(); 685 return task_runner_provider_->IsMainThreadBlocked();
684 } 686 }
685 687
686 ProxyImpl::BlockedMainCommitOnly& ProxyImpl::blocked_main_commit() { 688 ProxyImpl::BlockedMainCommitOnly& ProxyImpl::blocked_main_commit() {
687 DCHECK(IsMainThreadBlocked() && commit_completion_event_); 689 DCHECK(IsMainThreadBlocked() && commit_completion_event_);
688 return main_thread_blocked_commit_vars_unsafe_; 690 return main_thread_blocked_commit_vars_unsafe_;
689 } 691 }
690 692
691 } // namespace cc 693 } // namespace cc
OLDNEW
« no previous file with comments | « cc/trees/proxy_common.h ('k') | cc/trees/proxy_main.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698