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

Skip to content
Commit a7dd276c authored by Aurélien Pomini's avatar Aurélien Pomini
Browse files

Deflake wallpaper color events

The main changes are:
  - do not get fetch the "wallpaper.mWhich" flag in advance before
    computing the color. Notify the with "wallpaper.mWhich" once the
    colors are computed. This way, we won't send colors for an outdated
    which flag if there is a migrattion while the colors are processed
  - do not send any color event for the old wallpaper if the wallpaper
    changes while the colors are computed
  - do not send color events for the fallback wallpaper if another
    wallpaper is changed.

This avoids some race conditions when wallpapers are set quickly with a
script (like in our tests).

Flag: NONE
Test: atest WallpaperManagerTest --iterations 100
Test: (note: those two tests is the sequence that caused failures in b/308757171) atest WallpaperManagerTest#setResource_homeScreen_homeLive_lockScreenUnset_setsLockToHomeAndUpdatesHome WallpaperManagerTest#invokeOnColorsChangedListenerTest_systemOnly --iterations 1000
Bug: 308757171

Change-Id: I5d38ef84ab5088a227b1b39f06296113fb6dea9c
parent 845d3abc
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