| OLD | NEW |
| 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 614 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 625 noteLayerSurfacePropertyChanged(); | 625 noteLayerSurfacePropertyChanged(); |
| 626 } | 626 } |
| 627 | 627 |
| 628 float LayerImpl::opacity() const | 628 float LayerImpl::opacity() const |
| 629 { | 629 { |
| 630 return m_opacity; | 630 return m_opacity; |
| 631 } | 631 } |
| 632 | 632 |
| 633 bool LayerImpl::opacityIsAnimating() const | 633 bool LayerImpl::opacityIsAnimating() const |
| 634 { | 634 { |
| 635 return m_layerAnimationController->isAnimatingProperty(ActiveAnimation::Opac
ity); | 635 return m_layerAnimationController->isAnimatingProperty(Animation::Opacity); |
| 636 } | 636 } |
| 637 | 637 |
| 638 void LayerImpl::setPosition(const gfx::PointF& position) | 638 void LayerImpl::setPosition(const gfx::PointF& position) |
| 639 { | 639 { |
| 640 if (m_position == position) | 640 if (m_position == position) |
| 641 return; | 641 return; |
| 642 | 642 |
| 643 m_position = position; | 643 m_position = position; |
| 644 noteLayerPropertyChangedForSubtree(); | 644 noteLayerPropertyChangedForSubtree(); |
| 645 } | 645 } |
| (...skipping 26 matching lines...) Expand all Loading... |
| 672 noteLayerSurfacePropertyChanged(); | 672 noteLayerSurfacePropertyChanged(); |
| 673 } | 673 } |
| 674 | 674 |
| 675 const gfx::Transform& LayerImpl::transform() const | 675 const gfx::Transform& LayerImpl::transform() const |
| 676 { | 676 { |
| 677 return m_transform; | 677 return m_transform; |
| 678 } | 678 } |
| 679 | 679 |
| 680 bool LayerImpl::transformIsAnimating() const | 680 bool LayerImpl::transformIsAnimating() const |
| 681 { | 681 { |
| 682 return m_layerAnimationController->isAnimatingProperty(ActiveAnimation::Tran
sform); | 682 return m_layerAnimationController->isAnimatingProperty(Animation::Transform)
; |
| 683 } | 683 } |
| 684 | 684 |
| 685 void LayerImpl::setContentBounds(const gfx::Size& contentBounds) | 685 void LayerImpl::setContentBounds(const gfx::Size& contentBounds) |
| 686 { | 686 { |
| 687 if (this->contentBounds() == contentBounds) | 687 if (this->contentBounds() == contentBounds) |
| 688 return; | 688 return; |
| 689 | 689 |
| 690 m_drawProperties.content_bounds = contentBounds; | 690 m_drawProperties.content_bounds = contentBounds; |
| 691 noteLayerPropertyChanged(); | 691 noteLayerPropertyChanged(); |
| 692 } | 692 } |
| (...skipping 129 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 822 if (m_layerTreeImpl->settings().useLinearFadeScrollbarAnimator) | 822 if (m_layerTreeImpl->settings().useLinearFadeScrollbarAnimator) |
| 823 m_scrollbarAnimationController = createScrollbarAnimationControllerW
ithFade(this); | 823 m_scrollbarAnimationController = createScrollbarAnimationControllerW
ithFade(this); |
| 824 else | 824 else |
| 825 m_scrollbarAnimationController = ScrollbarAnimationController::creat
e(this); | 825 m_scrollbarAnimationController = ScrollbarAnimationController::creat
e(this); |
| 826 } | 826 } |
| 827 m_scrollbarAnimationController->setVerticalScrollbarLayer(scrollbarLayer); | 827 m_scrollbarAnimationController->setVerticalScrollbarLayer(scrollbarLayer); |
| 828 m_scrollbarAnimationController->updateScrollOffset(this); | 828 m_scrollbarAnimationController->updateScrollOffset(this); |
| 829 } | 829 } |
| 830 | 830 |
| 831 } // namespace cc | 831 } // namespace cc |
| OLD | NEW |