Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit f4200e67 authored by xinying1's avatar xinying1 Committed by Ying Xin
Browse files

Fix the shadow problem caused by layer parent switching



When the parent of a layer changes, shadowRadius should
not be directly passed in the computBounds here.

When the layer's parent changes, for example, open an app
in freeform. If the app exits the current ActivityRecord, it will
trigger the recent task request screen capture of the
current app, temporarily switch the task of the app to
"Screenshot Parent", and then switch back. This operation
will cause the shadow of the task to be passed to the children layers
through CanDrawShadows, i.e., the shadow of non Container layer
is wrongly passed to its children layers.
Therefore, there is a problem in shadow drawing.

We should judge whether shadowRadius needs to be passed
at this time through CanDrawShadows. If not, pass 0.f.

Otherwise, the shadow will be painted repeatedly.

bug:215476160 in partnerissuetracker

Signed-off-by: default avatarxinying1 <xinying1@xiaomi.corp-partner.google.com>
Change-Id: Id4b6c8bcc79aa68f96d0c4c655ea853361ed1e7c
parent b86796a0
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment