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

Commit 96eb5b72 authored by Bryan Mawhinney's avatar Bryan Mawhinney
Browse files

Fix live wallpaper not showing on lock screen after restore

A recent change in nyc-mr2 means that setWallpaperComponent will
promote any static system wallpaper to the lock screen.  If we don't
actually have a static lock wallpaper to restore, we need to explicitly
clear the lock wallpaper to have the live one show through

Test: manually using adb backup / restore
Bug: 35090402
Change-Id: I8a2c5ffbaefe172c9d78a9f746ab87d9bc6b7448
parent 5c148532
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
@@ -230,6 +230,11 @@ public class WallpaperBackupAgent extends BackupAgent {
                    Slog.i(TAG, "Using wallpaper service " + wpService);
                }
                mWm.setWallpaperComponent(wpService, UserHandle.USER_SYSTEM);
                if (!lockImageStage.exists()) {
                    // We have a live wallpaper and no static lock image,
                    // allow live wallpaper to show "through" on lock screen.
                    mWm.clear(FLAG_LOCK);
                }
            } else {
                if (DEBUG) {
                    Slog.v(TAG, "Can't use wallpaper service " + wpService);