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

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

Issue 421183003: Revert of Add builders for tracing event's structural arguments (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 4 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 | Annotate | Revision Log
« no previous file with comments | « cc/trees/layer_tree_host.h ('k') | cc/trees/layer_tree_host_impl.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 2011 The Chromium Authors. All rights reserved. 1 // Copyright 2011 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/layer_tree_host.h" 5 #include "cc/trees/layer_tree_host.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <stack> 8 #include <stack>
9 #include <string> 9 #include <string>
10 10
11 #include "base/atomic_sequence_num.h" 11 #include "base/atomic_sequence_num.h"
12 #include "base/bind.h" 12 #include "base/bind.h"
13 #include "base/command_line.h" 13 #include "base/command_line.h"
14 #include "base/debug/trace_event.h" 14 #include "base/debug/trace_event.h"
15 #include "base/debug/trace_event_argument.h"
16 #include "base/message_loop/message_loop.h" 15 #include "base/message_loop/message_loop.h"
17 #include "base/metrics/histogram.h" 16 #include "base/metrics/histogram.h"
18 #include "base/stl_util.h" 17 #include "base/stl_util.h"
19 #include "base/strings/string_number_conversions.h" 18 #include "base/strings/string_number_conversions.h"
20 #include "cc/animation/animation_registrar.h" 19 #include "cc/animation/animation_registrar.h"
21 #include "cc/animation/layer_animation_controller.h" 20 #include "cc/animation/layer_animation_controller.h"
22 #include "cc/base/math_util.h" 21 #include "cc/base/math_util.h"
23 #include "cc/debug/devtools_instrumentation.h" 22 #include "cc/debug/devtools_instrumentation.h"
24 #include "cc/debug/rendering_stats_instrumentation.h" 23 #include "cc/debug/rendering_stats_instrumentation.h"
25 #include "cc/input/layer_selection_bound.h" 24 #include "cc/input/layer_selection_bound.h"
(...skipping 1121 matching lines...) Expand 10 before | Expand all | Expand 10 after
1147 // Top controls are only used in threaded mode. 1146 // Top controls are only used in threaded mode.
1148 proxy_->ImplThreadTaskRunner()->PostTask( 1147 proxy_->ImplThreadTaskRunner()->PostTask(
1149 FROM_HERE, 1148 FROM_HERE,
1150 base::Bind(&TopControlsManager::UpdateTopControlsState, 1149 base::Bind(&TopControlsManager::UpdateTopControlsState,
1151 top_controls_manager_weak_ptr_, 1150 top_controls_manager_weak_ptr_,
1152 constraints, 1151 constraints,
1153 current, 1152 current,
1154 animate)); 1153 animate));
1155 } 1154 }
1156 1155
1157 void LayerTreeHost::AsValueInto(base::debug::TracedValue* state) const { 1156 scoped_ptr<base::Value> LayerTreeHost::AsValue() const {
1158 state->BeginDictionary("proxy"); 1157 scoped_ptr<base::DictionaryValue> state(new base::DictionaryValue());
1159 proxy_->AsValueInto(state); 1158 state->Set("proxy", proxy_->AsValue().release());
1160 state->EndDictionary(); 1159 return state.PassAs<base::Value>();
1161 } 1160 }
1162 1161
1163 void LayerTreeHost::AnimateLayers(base::TimeTicks monotonic_time) { 1162 void LayerTreeHost::AnimateLayers(base::TimeTicks monotonic_time) {
1164 if (!settings_.accelerated_animation_enabled || 1163 if (!settings_.accelerated_animation_enabled ||
1165 animation_registrar_->active_animation_controllers().empty()) 1164 animation_registrar_->active_animation_controllers().empty())
1166 return; 1165 return;
1167 1166
1168 TRACE_EVENT0("cc", "LayerTreeHost::AnimateLayers"); 1167 TRACE_EVENT0("cc", "LayerTreeHost::AnimateLayers");
1169 1168
1170 AnimationRegistrar::AnimationControllerMap copy = 1169 AnimationRegistrar::AnimationControllerMap copy =
(...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after
1285 swap_promise_list_.push_back(swap_promise.Pass()); 1284 swap_promise_list_.push_back(swap_promise.Pass());
1286 } 1285 }
1287 1286
1288 void LayerTreeHost::BreakSwapPromises(SwapPromise::DidNotSwapReason reason) { 1287 void LayerTreeHost::BreakSwapPromises(SwapPromise::DidNotSwapReason reason) {
1289 for (size_t i = 0; i < swap_promise_list_.size(); i++) 1288 for (size_t i = 0; i < swap_promise_list_.size(); i++)
1290 swap_promise_list_[i]->DidNotSwap(reason); 1289 swap_promise_list_[i]->DidNotSwap(reason);
1291 swap_promise_list_.clear(); 1290 swap_promise_list_.clear();
1292 } 1291 }
1293 1292
1294 } // namespace cc 1293 } // namespace cc
OLDNEW
« no previous file with comments | « cc/trees/layer_tree_host.h ('k') | cc/trees/layer_tree_host_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698