| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (c) 2010, Google Inc. All rights reserved. | 2 * Copyright (c) 2010, Google Inc. All rights reserved. |
| 3 * Copyright (C) 2008, 2011 Apple Inc. All Rights Reserved. | 3 * Copyright (C) 2008, 2011 Apple Inc. All Rights Reserved. |
| 4 * | 4 * |
| 5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
| 6 * modification, are permitted provided that the following conditions are | 6 * modification, are permitted provided that the following conditions are |
| 7 * met: | 7 * met: |
| 8 * | 8 * |
| 9 * * Redistributions of source code must retain the above copyright | 9 * * Redistributions of source code must retain the above copyright |
| 10 * notice, this list of conditions and the following disclaimer. | 10 * notice, this list of conditions and the following disclaimer. |
| (...skipping 468 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 479 CompositorAnimationTimeline* timeline) { | 479 CompositorAnimationTimeline* timeline) { |
| 480 if (ProgrammaticScrollAnimator* programmaticScrollAnimator = | 480 if (ProgrammaticScrollAnimator* programmaticScrollAnimator = |
| 481 existingProgrammaticScrollAnimator()) | 481 existingProgrammaticScrollAnimator()) |
| 482 programmaticScrollAnimator->layerForCompositedScrollingDidChange(timeline); | 482 programmaticScrollAnimator->layerForCompositedScrollingDidChange(timeline); |
| 483 if (ScrollAnimatorBase* scrollAnimator = existingScrollAnimator()) | 483 if (ScrollAnimatorBase* scrollAnimator = existingScrollAnimator()) |
| 484 scrollAnimator->layerForCompositedScrollingDidChange(timeline); | 484 scrollAnimator->layerForCompositedScrollingDidChange(timeline); |
| 485 } | 485 } |
| 486 | 486 |
| 487 bool ScrollableArea::scheduleAnimation() { | 487 bool ScrollableArea::scheduleAnimation() { |
| 488 if (HostWindow* window = getHostWindow()) { | 488 if (HostWindow* window = getHostWindow()) { |
| 489 window->scheduleAnimation(getWidget()); | 489 window->scheduleAnimation(getFrameViewBase()); |
| 490 return true; | 490 return true; |
| 491 } | 491 } |
| 492 return false; | 492 return false; |
| 493 } | 493 } |
| 494 | 494 |
| 495 void ScrollableArea::serviceScrollAnimations(double monotonicTime) { | 495 void ScrollableArea::serviceScrollAnimations(double monotonicTime) { |
| 496 bool requiresAnimationService = false; | 496 bool requiresAnimationService = false; |
| 497 if (ScrollAnimatorBase* scrollAnimator = existingScrollAnimator()) { | 497 if (ScrollAnimatorBase* scrollAnimator = existingScrollAnimator()) { |
| 498 scrollAnimator->tickAnimation(monotonicTime); | 498 scrollAnimator->tickAnimation(monotonicTime); |
| 499 if (scrollAnimator->hasAnimationThatRequiresService()) | 499 if (scrollAnimator->hasAnimationThatRequiresService()) |
| (...skipping 167 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 667 offset.y() - scrollOrigin().y()); | 667 offset.y() - scrollOrigin().y()); |
| 668 setScrollOffset(newOffset, CompositorScroll); | 668 setScrollOffset(newOffset, CompositorScroll); |
| 669 } | 669 } |
| 670 | 670 |
| 671 DEFINE_TRACE(ScrollableArea) { | 671 DEFINE_TRACE(ScrollableArea) { |
| 672 visitor->trace(m_scrollAnimator); | 672 visitor->trace(m_scrollAnimator); |
| 673 visitor->trace(m_programmaticScrollAnimator); | 673 visitor->trace(m_programmaticScrollAnimator); |
| 674 } | 674 } |
| 675 | 675 |
| 676 } // namespace blink | 676 } // namespace blink |
| OLD | NEW |