summaryrefslogtreecommitdiff
path: root/libs/hwui/LayerCache.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'libs/hwui/LayerCache.cpp')
-rw-r--r--libs/hwui/LayerCache.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/libs/hwui/LayerCache.cpp b/libs/hwui/LayerCache.cpp
index d6703f2e5c47..60d4f4fe6bb5 100644
--- a/libs/hwui/LayerCache.cpp
+++ b/libs/hwui/LayerCache.cpp
@@ -33,7 +33,7 @@ namespace uirenderer {
LayerCache::LayerCache(): mSize(0), mMaxSize(MB(DEFAULT_LAYER_CACHE_SIZE)) {
char property[PROPERTY_VALUE_MAX];
- if (property_get(PROPERTY_LAYER_CACHE_SIZE, property, NULL) > 0) {
+ if (property_get(PROPERTY_LAYER_CACHE_SIZE, property, nullptr) > 0) {
INIT_LOGD(" Setting layer cache size to %sMB", property);
setMaxSize(MB(atof(property)));
} else {
@@ -84,7 +84,7 @@ void LayerCache::deleteLayer(Layer* layer) {
layer->getFbo());
mSize -= layer->getWidth() * layer->getHeight() * 4;
layer->state = Layer::kState_DeletedFromCache;
- layer->decStrong(0);
+ layer->decStrong(nullptr);
}
}
@@ -97,7 +97,7 @@ void LayerCache::clear() {
}
Layer* LayerCache::get(RenderState& renderState, const uint32_t width, const uint32_t height) {
- Layer* layer = NULL;
+ Layer* layer = nullptr;
LayerEntry entry(width, height);
ssize_t index = mCache.indexOf(entry);