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
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);
}
if (wasObserving) {
mLiveData.observeForever(this);
- showSlice(Slice.bindSlice(getContext(), mKeyguardSliceUri));
}
}