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

Commit 6e6af2c7 authored by Jason Monk's avatar Jason Monk
Browse files

Protect against crash on user switch

Somehow one of the tiles doesn't have a view yet. Assume that this
is a transient part of the tiles getting recreated and that the skipped
tile will get picked up in the next layout.

Change-Id: Ia1370d66119bfcfa7b00bd087bcb0d72a072666a
Fixes: 31394359
parent 7b68411d
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -160,6 +160,10 @@ public class QSAnimator implements Callback, PageListener, Listener, OnLayoutCha

        for (QSTile<?> tile : tiles) {
            QSTileBaseView tileView = mQsPanel.getTileView(tile);
            if (tileView == null) {
                Log.e(TAG, "tileView is null " + tile.getTileSpec());
                continue;
            }
            final TextView label = ((QSTileView) tileView).getLabel();
            final View tileIcon = tileView.getIcon().getIconView();
            if (count < mNumQuickTiles && mAllowFancy) {