summaryrefslogtreecommitdiff
path: root/libs/hwui/renderthread/DrawFrameTask.cpp
diff options
context:
space:
mode:
authorBill Yi <byi@google.com>2015-02-19 14:31:36 -0800
committerBill Yi <byi@google.com>2015-02-19 14:31:36 -0800
commit4fecab570da64a1956352aedf1b3245d3ba26030 (patch)
tree4986924779f175b20662b8f41144fdb5f40d40b2 /libs/hwui/renderthread/DrawFrameTask.cpp
parent644ebc8800ad5e2fa1c239bd65a2cf6a88e6556b (diff)
parent32acf753e8989766f67fd5300d3eb467f707cc79 (diff)
Merge commit '32acf753e8989766f67fd5300d3eb467f707cc79' into HEAD
Diffstat (limited to 'libs/hwui/renderthread/DrawFrameTask.cpp')
-rw-r--r--libs/hwui/renderthread/DrawFrameTask.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/libs/hwui/renderthread/DrawFrameTask.cpp b/libs/hwui/renderthread/DrawFrameTask.cpp
index dd34e095738d..97b31a95f278 100644
--- a/libs/hwui/renderthread/DrawFrameTask.cpp
+++ b/libs/hwui/renderthread/DrawFrameTask.cpp
@@ -132,6 +132,12 @@ bool DrawFrameTask::syncFrameState(TreeInfo& info) {
mLayers.clear();
mContext->prepareTree(info);
+ // This is after the prepareTree so that any pending operations
+ // (RenderNode tree state, prefetched layers, etc...) will be flushed.
+ if (CC_UNLIKELY(!mContext->hasSurface())) {
+ mSyncResult |= kSync_LostSurfaceRewardIfFound;
+ }
+
if (info.out.hasAnimations) {
if (info.out.requiresUiRedraw) {
mSyncResult |= kSync_UIRedrawRequired;