diff options
author | sadrul@chromium.org <sadrul@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2014-06-05 03:11:47 +0000 |
---|---|---|
committer | sadrul@chromium.org <sadrul@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2014-06-05 03:11:47 +0000 |
commit | 9034a2852384f40f23305e108ee7f23ab5dc7ff3 (patch) | |
tree | 5b2e6a7e049b39227168cbc1f2e90104897f7439 /ash/desktop_background | |
parent | 71a04b9c149ecbbf096bf651f03c4803860f8334 (diff) | |
download | chromium_src-9034a2852384f40f23305e108ee7f23ab5dc7ff3.zip chromium_src-9034a2852384f40f23305e108ee7f23ab5dc7ff3.tar.gz chromium_src-9034a2852384f40f23305e108ee7f23ab5dc7ff3.tar.bz2 |
compositor: Tick the UI animations from cc, instead of from timer callbacks.
Update the animations in the UI in response to the animation step in the compositor,
instead of from a timer callback. This should make it more difficult for rogue UI
animations to negatively impact the system too much.
BUG=371071
R=ajuma@chromium.org, sky@chromium.org
Review URL: https://codereview.chromium.org/291843012
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@274988 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'ash/desktop_background')
-rw-r--r-- | ash/desktop_background/desktop_background_controller_unittest.cc | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/ash/desktop_background/desktop_background_controller_unittest.cc b/ash/desktop_background/desktop_background_controller_unittest.cc index 4e87be6..609ea14 100644 --- a/ash/desktop_background/desktop_background_controller_unittest.cc +++ b/ash/desktop_background/desktop_background_controller_unittest.cc @@ -53,13 +53,13 @@ void RunAnimationForWidget(views::Widget* widget) { ui::Layer* layer = widget->GetNativeView()->layer(); ui::LayerAnimatorTestController controller(layer->GetAnimator()); - gfx::AnimationContainerElement* element = layer->GetAnimator(); // Multiple steps are required to complete complex animations. // TODO(vollick): This should not be necessary. crbug.com/154017 while (controller.animator()->is_animating()) { controller.StartThreadedAnimationsIfNeeded(); base::TimeTicks step_time = controller.animator()->last_step_time(); - element->Step(step_time + base::TimeDelta::FromMilliseconds(1000)); + layer->GetAnimator()->Step(step_time + + base::TimeDelta::FromMilliseconds(1000)); } } |