From 0fab27a23ef7f629e2b76e085bfeacb815b3b7a2 Mon Sep 17 00:00:00 2001 From: Julian Harnath Date: Fri, 13 Nov 2015 11:19:04 +0100 Subject: [PATCH] app_server: don't ignore invisible layers * When a layer has opacity 0, we can't just ignore it, we still have to play back its picture, even if the drawing will never appear on screen. This is because there might be nested layers and if they don't get blended, their references are not released. Also, it can be argued that state changes in the layer should be applied even if the layer is invisible (if we ignore it there, it would be inconsistent with other layers). This edge case of invisible layers could be optimized further, but it is rare enough anyway, so this should do. --- src/servers/app/Canvas.cpp | 3 --- 1 file changed, 3 deletions(-) diff --git a/src/servers/app/Canvas.cpp b/src/servers/app/Canvas.cpp index 55f273bf03..881eaaabce 100644 --- a/src/servers/app/Canvas.cpp +++ b/src/servers/app/Canvas.cpp @@ -243,9 +243,6 @@ Canvas::BlendLayer(Layer* layer) layer->Play(this); layer->ReleaseReference(); return; - } else if (layer->Opacity() == 0) { - layer->ReleaseReference(); - return; } UtilityBitmap* layerBitmap = layer->RenderToBitmap(this);