summaryrefslogtreecommitdiffstats
path: root/libs
diff options
context:
space:
mode:
authorJohn Reck <jreck@google.com>2014-02-14 16:59:37 -0800
committerJohn Reck <jreck@google.com>2014-02-14 16:59:37 -0800
commita39dd595791b41222ab310b5e8a76a64faa8ba5c (patch)
treeb60558f824d7c502819bb0da687872bc00f811a4 /libs
parentd63b4314b85e982a1d70d4064af59851f476dd36 (diff)
downloadframeworks_base-a39dd595791b41222ab310b5e8a76a64faa8ba5c.zip
frameworks_base-a39dd595791b41222ab310b5e8a76a64faa8ba5c.tar.gz
frameworks_base-a39dd595791b41222ab310b5e8a76a64faa8ba5c.tar.bz2
Refcounting is hard
Bug: 12994941 Change-Id: I6285ff818fc696dbe504174b98a54cb1d00b445c
Diffstat (limited to 'libs')
-rw-r--r--libs/hwui/DeferredLayerUpdater.cpp1
-rw-r--r--libs/hwui/DeferredLayerUpdater.h2
2 files changed, 2 insertions, 1 deletions
diff --git a/libs/hwui/DeferredLayerUpdater.cpp b/libs/hwui/DeferredLayerUpdater.cpp
index ed05d04..5d3d393 100644
--- a/libs/hwui/DeferredLayerUpdater.cpp
+++ b/libs/hwui/DeferredLayerUpdater.cpp
@@ -31,7 +31,6 @@ DeferredLayerUpdater::DeferredLayerUpdater(Layer* layer, OpenGLRenderer* rendere
, mLayer(layer)
, mRenderer(renderer)
, mCaches(Caches::getInstance()) {
- mCaches.resourceCache.incrementRefcount(mLayer);
mWidth = mLayer->layer.getWidth();
mHeight = mLayer->layer.getHeight();
mBlend = mLayer->isBlend();
diff --git a/libs/hwui/DeferredLayerUpdater.h b/libs/hwui/DeferredLayerUpdater.h
index 0350eef..9800c2f 100644
--- a/libs/hwui/DeferredLayerUpdater.h
+++ b/libs/hwui/DeferredLayerUpdater.h
@@ -34,6 +34,8 @@ namespace uirenderer {
// of a render pass
class DeferredLayerUpdater {
public:
+ // Note that DeferredLayerUpdater assumes it is taking ownership of the layer
+ // and will not call incrementRef on it as a result.
ANDROID_API DeferredLayerUpdater(Layer* layer, OpenGLRenderer* renderer = 0);
ANDROID_API ~DeferredLayerUpdater();