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

Side by Side Diff: cc/layers/layer_impl.cc

Issue 263653002: Move traced_value.* from cc/debug/ to base/debug/ (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Added BASE_EXPORT Created 6 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 | Annotate | Revision Log
« no previous file with comments | « cc/layers/heads_up_display_layer_impl.cc ('k') | cc/layers/picture_layer_impl.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 2012 The Chromium Authors. All rights reserved. 1 // Copyright 2012 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/layers/layer_impl.h" 5 #include "cc/layers/layer_impl.h"
6 6
7 #include "base/debug/trace_event.h" 7 #include "base/debug/trace_event.h"
8 #include "base/debug/traced_value.h"
8 #include "base/json/json_reader.h" 9 #include "base/json/json_reader.h"
9 #include "base/strings/stringprintf.h" 10 #include "base/strings/stringprintf.h"
10 #include "cc/animation/animation_registrar.h" 11 #include "cc/animation/animation_registrar.h"
11 #include "cc/animation/scrollbar_animation_controller.h" 12 #include "cc/animation/scrollbar_animation_controller.h"
12 #include "cc/base/math_util.h" 13 #include "cc/base/math_util.h"
13 #include "cc/debug/debug_colors.h" 14 #include "cc/debug/debug_colors.h"
14 #include "cc/debug/layer_tree_debug_state.h" 15 #include "cc/debug/layer_tree_debug_state.h"
15 #include "cc/debug/micro_benchmark_impl.h" 16 #include "cc/debug/micro_benchmark_impl.h"
16 #include "cc/debug/traced_value.h"
17 #include "cc/input/layer_scroll_offset_delegate.h" 17 #include "cc/input/layer_scroll_offset_delegate.h"
18 #include "cc/layers/layer_utils.h" 18 #include "cc/layers/layer_utils.h"
19 #include "cc/layers/painted_scrollbar_layer_impl.h" 19 #include "cc/layers/painted_scrollbar_layer_impl.h"
20 #include "cc/layers/quad_sink.h" 20 #include "cc/layers/quad_sink.h"
21 #include "cc/output/copy_output_request.h" 21 #include "cc/output/copy_output_request.h"
22 #include "cc/quads/debug_border_draw_quad.h" 22 #include "cc/quads/debug_border_draw_quad.h"
23 #include "cc/trees/layer_tree_host_common.h" 23 #include "cc/trees/layer_tree_host_common.h"
24 #include "cc/trees/layer_tree_impl.h" 24 #include "cc/trees/layer_tree_impl.h"
25 #include "cc/trees/layer_tree_settings.h" 25 #include "cc/trees/layer_tree_settings.h"
26 #include "cc/trees/proxy.h" 26 #include "cc/trees/proxy.h"
(...skipping 1381 matching lines...) Expand 10 before | Expand all | Expand 10 after
1408 1408
1409 void LayerImpl::RemoveDependentNeedsPushProperties() { 1409 void LayerImpl::RemoveDependentNeedsPushProperties() {
1410 num_dependents_need_push_properties_--; 1410 num_dependents_need_push_properties_--;
1411 DCHECK_GE(num_dependents_need_push_properties_, 0); 1411 DCHECK_GE(num_dependents_need_push_properties_, 0);
1412 1412
1413 if (!parent_should_know_need_push_properties() && parent_) 1413 if (!parent_should_know_need_push_properties() && parent_)
1414 parent_->RemoveDependentNeedsPushProperties(); 1414 parent_->RemoveDependentNeedsPushProperties();
1415 } 1415 }
1416 1416
1417 void LayerImpl::AsValueInto(base::DictionaryValue* state) const { 1417 void LayerImpl::AsValueInto(base::DictionaryValue* state) const {
1418 TracedValue::MakeDictIntoImplicitSnapshotWithCategory( 1418 base::debug::TracedValue::MakeDictIntoImplicitSnapshotWithCategory(
1419 TRACE_DISABLED_BY_DEFAULT("cc.debug"), 1419 TRACE_DISABLED_BY_DEFAULT("cc.debug"),
1420 state, 1420 state,
1421 "cc::LayerImpl", 1421 "cc::LayerImpl",
1422 LayerTypeAsString(), 1422 LayerTypeAsString(),
1423 this); 1423 this);
1424 state->SetInteger("layer_id", id()); 1424 state->SetInteger("layer_id", id());
1425 state->Set("bounds", MathUtil::AsValue(bounds_).release()); 1425 state->Set("bounds", MathUtil::AsValue(bounds_).release());
1426 state->Set("position", MathUtil::AsValue(position_).release()); 1426 state->Set("position", MathUtil::AsValue(position_).release());
1427 state->SetInteger("draws_content", DrawsContent()); 1427 state->SetInteger("draws_content", DrawsContent());
1428 state->SetInteger("gpu_memory_usage", GPUMemoryUsageInBytes()); 1428 state->SetInteger("gpu_memory_usage", GPUMemoryUsageInBytes());
(...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after
1505 scoped_ptr<base::Value> LayerImpl::AsValue() const { 1505 scoped_ptr<base::Value> LayerImpl::AsValue() const {
1506 scoped_ptr<base::DictionaryValue> state(new base::DictionaryValue()); 1506 scoped_ptr<base::DictionaryValue> state(new base::DictionaryValue());
1507 AsValueInto(state.get()); 1507 AsValueInto(state.get());
1508 return state.PassAs<base::Value>(); 1508 return state.PassAs<base::Value>();
1509 } 1509 }
1510 1510
1511 void LayerImpl::RunMicroBenchmark(MicroBenchmarkImpl* benchmark) { 1511 void LayerImpl::RunMicroBenchmark(MicroBenchmarkImpl* benchmark) {
1512 benchmark->RunOnLayer(this); 1512 benchmark->RunOnLayer(this);
1513 } 1513 }
1514 } // namespace cc 1514 } // namespace cc
OLDNEW
« no previous file with comments | « cc/layers/heads_up_display_layer_impl.cc ('k') | cc/layers/picture_layer_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698