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

Side by Side Diff: cc/layer_impl.cc

Issue 11830056: Enable accelerated animations for orphaned layers (Closed) Base URL: http://git.chromium.org/chromium/src.git@MakeLayerTreeHostAnimateLayersTakeWallClockTime
Patch Set: Fix nit Created 7 years, 11 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/layer_impl.h ('k') | cc/layer_tree_host.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 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/layer_impl.h" 5 #include "cc/layer_impl.h"
6 6
7 #include "base/debug/trace_event.h" 7 #include "base/debug/trace_event.h"
8 #include "base/stringprintf.h" 8 #include "base/stringprintf.h"
9 #include "base/values.h" 9 #include "base/values.h"
10 #include "cc/animation_registrar.h" 10 #include "cc/animation_registrar.h"
(...skipping 487 matching lines...) Expand 10 before | Expand all | Expand 10 after
498 void LayerImpl::OnTransformAnimated(const gfx::Transform& transform) 498 void LayerImpl::OnTransformAnimated(const gfx::Transform& transform)
499 { 499 {
500 setTransform(transform); 500 setTransform(transform);
501 } 501 }
502 502
503 bool LayerImpl::IsActive() const 503 bool LayerImpl::IsActive() const
504 { 504 {
505 return m_layerTreeImpl->IsActiveTree(); 505 return m_layerTreeImpl->IsActiveTree();
506 } 506 }
507 507
508 bool LayerImpl::IsOrphaned() const
509 {
510 return false;
511 }
512
508 void LayerImpl::setBounds(const gfx::Size& bounds) 513 void LayerImpl::setBounds(const gfx::Size& bounds)
509 { 514 {
510 if (m_bounds == bounds) 515 if (m_bounds == bounds)
511 return; 516 return;
512 517
513 m_bounds = bounds; 518 m_bounds = bounds;
514 519
515 if (masksToBounds()) 520 if (masksToBounds())
516 noteLayerPropertyChangedForSubtree(); 521 noteLayerPropertyChangedForSubtree();
517 else 522 else
(...skipping 345 matching lines...) Expand 10 before | Expand all | Expand 10 after
863 if (!m_scrollbarAnimationController) { 868 if (!m_scrollbarAnimationController) {
864 if (m_layerTreeImpl->settings().useLinearFadeScrollbarAnimator) 869 if (m_layerTreeImpl->settings().useLinearFadeScrollbarAnimator)
865 m_scrollbarAnimationController = createScrollbarAnimationControllerW ithFade(this); 870 m_scrollbarAnimationController = createScrollbarAnimationControllerW ithFade(this);
866 else 871 else
867 m_scrollbarAnimationController = ScrollbarAnimationController::creat e(this); 872 m_scrollbarAnimationController = ScrollbarAnimationController::creat e(this);
868 } 873 }
869 m_scrollbarAnimationController->setVerticalScrollbarLayer(scrollbarLayer); 874 m_scrollbarAnimationController->setVerticalScrollbarLayer(scrollbarLayer);
870 } 875 }
871 876
872 } // namespace cc 877 } // namespace cc
OLDNEW
« no previous file with comments | « cc/layer_impl.h ('k') | cc/layer_tree_host.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698