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

Commit 5f94c857 authored by Felipe Leme's avatar Felipe Leme
Browse files

Don't set mLockscreenWallpaper when wallpaper is not supported.

Bug: 138939803
Bug: 144862300

Test: a CtsAppTestCases:android.app.cts.WallpaperManagerTest

Merged-In: Ibb5dd6097939a5b50244ee3cec5ee09a1f5417cb
Change-Id: Ibb5dd6097939a5b50244ee3cec5ee09a1f5417cb
(cherry picked from commit e8d7b883b4e30572cd1d6d9655394ef05be93621)
parent 297a8423
Loading
Loading
Loading
Loading
+5 −2
Original line number Diff line number Diff line
@@ -344,6 +344,7 @@ public class StatusBar extends SystemUI implements DemoMode,
    private boolean mBrightnessMirrorVisible;
    protected BiometricUnlockController mBiometricUnlockController;
    protected LightBarController mLightBarController;
    @Nullable
    protected LockscreenWallpaper mLockscreenWallpaper;
    @VisibleForTesting
    protected AutoHideController mAutoHideController;
@@ -891,7 +892,7 @@ public class StatusBar extends SystemUI implements DemoMode,

        createNavigationBar(result);

        if (ENABLE_LOCKSCREEN_WALLPAPER) {
        if (ENABLE_LOCKSCREEN_WALLPAPER && mWallpaperSupported) {
            mLockscreenWallpaper = new LockscreenWallpaper(mContext, this, mHandler);
        }

@@ -2748,7 +2749,9 @@ public class StatusBar extends SystemUI implements DemoMode,

    @Override
    public void setLockscreenUser(int newUserId) {
        if (mLockscreenWallpaper != null) {
            mLockscreenWallpaper.setCurrentUser(newUserId);
        }
        mScrimController.setCurrentUser(newUserId);
        if (mWallpaperSupported) {
            mWallpaperChangedReceiver.onReceive(mContext, null);