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

Commit fe12d0f8 authored by Riddle Hsu's avatar Riddle Hsu
Browse files

Set wallpaper to invisible only if it is not visible-requested

After transition animation is done, the wallpaper may be still
visible, then it is unnecessary to always commit as invisible.

Bug: 183165393
Test: Swipe from landscape app to portrait home
Change-Id: I20936aa51d210f49824987936ca65d4cdc97e33f
parent 91aea8eb
Loading
Loading
Loading
Loading
+3 −1
Original line number Original line Diff line number Diff line
@@ -274,9 +274,11 @@ class WallpaperController {
    void hideDeferredWallpapersIfNeededLegacy() {
    void hideDeferredWallpapersIfNeededLegacy() {
        for (int i = mWallpaperTokens.size() - 1; i >= 0; i--) {
        for (int i = mWallpaperTokens.size() - 1; i >= 0; i--) {
            final WallpaperWindowToken token = mWallpaperTokens.get(i);
            final WallpaperWindowToken token = mWallpaperTokens.get(i);
            if (!token.isVisibleRequested()) {
                token.commitVisibility(false);
                token.commitVisibility(false);
            }
            }
        }
        }
    }


    void hideWallpapers(final WindowState winGoingAway) {
    void hideWallpapers(final WindowState winGoingAway) {
        if (mWallpaperTarget != null
        if (mWallpaperTarget != null