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

Commit 83da1a1b authored by Lucas Dupin's avatar Lucas Dupin
Browse files

Always bind slice on background

Doing on the main thread will increase jank
when unlocking or waking up.

Fixes: 71543966
Test: runtest systemui-jank -c android.platform.systemui.tests.jank.SystemUiJankTests -m testAmbientWakeUp
Change-Id: I3b534425c85609a132d33905de18dbc36fd37f0d
parent 5459651b
Loading
Loading
Loading
Loading
+0 −4
Original line number Diff line number Diff line
@@ -98,9 +98,6 @@ public class KeyguardSliceView extends LinearLayout implements View.OnClickListe
    protected void onAttachedToWindow() {
        super.onAttachedToWindow();

        // Set initial content
        showSlice(Slice.bindSlice(getContext(), mKeyguardSliceUri));

        // Make sure we always have the most current slice
        mLiveData.observeForever(this);
    }
@@ -265,7 +262,6 @@ public class KeyguardSliceView extends LinearLayout implements View.OnClickListe

        if (wasObserving) {
            mLiveData.observeForever(this);
            showSlice(Slice.bindSlice(getContext(), mKeyguardSliceUri));
        }
    }