summaryrefslogtreecommitdiff
path: root/libs
diff options
context:
space:
mode:
authorDoris Liu <tianliu@google.com>2016-07-29 16:45:24 -0700
committerDoris Liu <tianliu@google.com>2016-08-01 21:42:15 +0000
commitc82e879e563ad692cabf19f61a08559c6220171e (patch)
tree52afc004a494c4185fca4cef1bace8df200cc6fa /libs
parent7dd40cd4117cb7cf57d37f04088e4c55be423c1c (diff)
downloadandroid-frameworks-base-c82e879e563ad692cabf19f61a08559c6220171e.tar.gz
android-frameworks-base-c82e879e563ad692cabf19f61a08559c6220171e.tar.xz
Put VD animators on paused list when RT stops drawing
When we stop scheduling for new frames on RenderThread, we should put the running animations on pause, rather than purge the list of the running animations, such that in the next full sync, the animations that were paused will continue to run. BUG: 30226711 Change-Id: I36ff6f5d26ffa7999f60ca0ff676a35157577dc2
Diffstat (limited to 'libs')
-rw-r--r--libs/hwui/AnimationContext.h2
-rw-r--r--libs/hwui/renderthread/CanvasContext.cpp2
2 files changed, 2 insertions, 2 deletions
diff --git a/libs/hwui/AnimationContext.h b/libs/hwui/AnimationContext.h
index 801fd87..11d305c 100644
--- a/libs/hwui/AnimationContext.h
+++ b/libs/hwui/AnimationContext.h
@@ -100,7 +100,7 @@ public:
ANDROID_API virtual void destroy();
- ANDROID_API virtual void detachAnimators() {}
+ ANDROID_API virtual void pauseAnimators() {}
private:
friend class AnimationHandle;
diff --git a/libs/hwui/renderthread/CanvasContext.cpp b/libs/hwui/renderthread/CanvasContext.cpp
index d68f0e3..30920a7 100644
--- a/libs/hwui/renderthread/CanvasContext.cpp
+++ b/libs/hwui/renderthread/CanvasContext.cpp
@@ -326,7 +326,7 @@ void CanvasContext::prepareTree(TreeInfo& info, int64_t* uiFrameInfo,
void CanvasContext::stopDrawing() {
mRenderThread.removeFrameCallback(this);
- mAnimationContext->detachAnimators();
+ mAnimationContext->pauseAnimators();
}
void CanvasContext::notifyFramePending() {