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

Skip to content
Commit e94b29da authored by Aurélien Pomini's avatar Aurélien Pomini Committed by Ching-Sung Li
Browse files

Avoid consecutive onVisibilityChanged calls

Calling directly onVisibilityChanged(...) from
WallpaperService#updateSurface bypasses the check that the visibility
actually changed. Instead we use doVisibilityChanged(...), which is a
wrapper to onVisibilityChanged that checks that the visibility actually
changed.

This prevents a bug that triggers two consecutive calls to
onVisibilitychanged(false). One of the call comes from engine.attach ->
updateSurface, the other one from picker -> resizePreview ->
updateSurface.

Flag: ACONFIG com.android.window.flags.no_consecutive_visibility_events DEVELOPMENT
Bug: 285631818
Bug: 313527496 (to be verified)
Test: manually check onVisibilityChanged(false) logs
Test: treehugger
Change-Id: I4fc189cdb9d4b4de36d88fe27ad651ddf0b40449
parent 7c182fd4
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment