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

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

Issue 2762043005: cc : Delete target id and content target id from transform nodes (Closed)
Patch Set: blink changes Created 3 years, 9 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
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 "base/trace_event/trace_event_argument.h" 5 #include "base/trace_event/trace_event_argument.h"
6 #include "cc/base/math_util.h" 6 #include "cc/base/math_util.h"
7 #include "cc/layers/layer.h" 7 #include "cc/layers/layer.h"
8 #include "cc/trees/property_tree.h" 8 #include "cc/trees/property_tree.h"
9 #include "cc/trees/transform_node.h" 9 #include "cc/trees/transform_node.h"
10 #include "ui/gfx/geometry/point3_f.h" 10 #include "ui/gfx/geometry/point3_f.h"
(...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after
101 transform_origin.z()); 101 transform_origin.z());
102 } 102 }
103 103
104 void TransformNode::AsValueInto(base::trace_event::TracedValue* value) const { 104 void TransformNode::AsValueInto(base::trace_event::TracedValue* value) const {
105 value->SetInteger("id", id); 105 value->SetInteger("id", id);
106 value->SetInteger("parent_id", parent_id); 106 value->SetInteger("parent_id", parent_id);
107 value->SetInteger("owning_layer_id", owning_layer_id); 107 value->SetInteger("owning_layer_id", owning_layer_id);
108 MathUtil::AddToTracedValue("pre_local", pre_local, value); 108 MathUtil::AddToTracedValue("pre_local", pre_local, value);
109 MathUtil::AddToTracedValue("local", local, value); 109 MathUtil::AddToTracedValue("local", local, value);
110 MathUtil::AddToTracedValue("post_local", post_local, value); 110 MathUtil::AddToTracedValue("post_local", post_local, value);
111 // TODO(sunxd): make frameviewer work without target_id
112 value->SetInteger("target_id", 0);
113 value->SetInteger("content_target_id", 0);
114 value->SetInteger("source_node_id", source_node_id); 111 value->SetInteger("source_node_id", source_node_id);
115 value->SetInteger("sorting_context_id", sorting_context_id); 112 value->SetInteger("sorting_context_id", sorting_context_id);
116 MathUtil::AddToTracedValue("scroll_offset", scroll_offset, value); 113 MathUtil::AddToTracedValue("scroll_offset", scroll_offset, value);
117 MathUtil::AddToTracedValue("snap_amount", snap_amount, value); 114 MathUtil::AddToTracedValue("snap_amount", snap_amount, value);
118 } 115 }
119 116
120 TransformCachedNodeData::TransformCachedNodeData() 117 TransformCachedNodeData::TransformCachedNodeData()
121 : target_id(-1), content_target_id(-1), is_showing_backface(false) {} 118 : is_showing_backface(false) {}
122 119
123 TransformCachedNodeData::TransformCachedNodeData( 120 TransformCachedNodeData::TransformCachedNodeData(
124 const TransformCachedNodeData& other) = default; 121 const TransformCachedNodeData& other) = default;
125 122
126 TransformCachedNodeData::~TransformCachedNodeData() {} 123 TransformCachedNodeData::~TransformCachedNodeData() {}
127 124
128 bool TransformCachedNodeData::operator==( 125 bool TransformCachedNodeData::operator==(
129 const TransformCachedNodeData& other) const { 126 const TransformCachedNodeData& other) const {
130 return from_screen == other.from_screen && to_screen == other.to_screen && 127 return from_screen == other.from_screen && to_screen == other.to_screen &&
131 target_id == other.target_id &&
132 content_target_id == other.content_target_id &&
133 is_showing_backface == other.is_showing_backface; 128 is_showing_backface == other.is_showing_backface;
134 } 129 }
135 130
136 } // namespace cc 131 } // namespace cc
OLDNEW
« no previous file with comments | « cc/trees/transform_node.h ('k') | third_party/WebKit/Source/platform/graphics/compositing/PropertyTreeManager.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698