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

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

Issue 1922393002: CC Animation: Unify ElementId in Blink Compositor Worker. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@player
Patch Set: Remove NextElementId. Created 4 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
« no previous file with comments | « cc/layers/layer_impl.h ('k') | cc/layers/layer_unittest.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 <stddef.h> 7 #include <stddef.h>
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <algorithm> 10 #include <algorithm>
(...skipping 979 matching lines...) Expand 10 before | Expand all | Expand 10 after
990 } 990 }
991 991
992 bool LayerImpl::HasPotentiallyRunningOpacityAnimation() const { 992 bool LayerImpl::HasPotentiallyRunningOpacityAnimation() const {
993 return layer_tree_impl_->HasPotentiallyRunningOpacityAnimation(this); 993 return layer_tree_impl_->HasPotentiallyRunningOpacityAnimation(this);
994 } 994 }
995 995
996 bool LayerImpl::OpacityIsAnimatingOnImplOnly() const { 996 bool LayerImpl::OpacityIsAnimatingOnImplOnly() const {
997 return layer_tree_impl_->OpacityIsAnimatingOnImplOnly(this); 997 return layer_tree_impl_->OpacityIsAnimatingOnImplOnly(this);
998 } 998 }
999 999
1000 void LayerImpl::SetElementId(uint64_t element_id) { 1000 void LayerImpl::SetElementId(ElementId element_id) {
1001 if (element_id == element_id_) 1001 if (element_id == element_id_)
1002 return; 1002 return;
1003 1003
1004 TRACE_EVENT1(TRACE_DISABLED_BY_DEFAULT("compositor-worker"), 1004 TRACE_EVENT1(TRACE_DISABLED_BY_DEFAULT("compositor-worker"),
1005 "LayerImpl::SetElementId", "id", element_id); 1005 "LayerImpl::SetElementId", "id", element_id);
1006 1006
1007 layer_tree_impl_->RemoveFromElementMap(this); 1007 layer_tree_impl_->RemoveFromElementMap(this);
1008 element_id_ = element_id; 1008 element_id_ = element_id;
1009 layer_tree_impl_->AddToElementMap(this); 1009 layer_tree_impl_->AddToElementMap(this);
1010 SetNeedsPushProperties(); 1010 SetNeedsPushProperties();
(...skipping 381 matching lines...) Expand 10 before | Expand all | Expand 10 after
1392 .layer_transforms_should_scale_layer_contents) { 1392 .layer_transforms_should_scale_layer_contents) {
1393 return default_scale; 1393 return default_scale;
1394 } 1394 }
1395 1395
1396 gfx::Vector2dF transform_scales = MathUtil::ComputeTransform2dScaleComponents( 1396 gfx::Vector2dF transform_scales = MathUtil::ComputeTransform2dScaleComponents(
1397 DrawTransform(), default_scale); 1397 DrawTransform(), default_scale);
1398 return std::max(transform_scales.x(), transform_scales.y()); 1398 return std::max(transform_scales.x(), transform_scales.y());
1399 } 1399 }
1400 1400
1401 } // namespace cc 1401 } // namespace cc
OLDNEW
« no previous file with comments | « cc/layers/layer_impl.h ('k') | cc/layers/layer_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698