Made background updater more robust to state changes
With raceconditions, the background of notifications could become colored when dozing. Change-Id: Ib39f873e6dce40e97a8df06dec281733a8ae2fd9 Fixes: 29331596
This commit is contained in:
@@ -1963,9 +1963,9 @@ public class NotificationStackScrollLayout extends ViewGroup
|
||||
}
|
||||
|
||||
private void applyCurrentBackgroundBounds() {
|
||||
if (!mFadingOut) {
|
||||
mScrimController.setExcludedBackgroundArea(mCurrentBounds);
|
||||
}
|
||||
mScrimController.setExcludedBackgroundArea(
|
||||
mFadingOut || mParentFadingOut || mAmbientState.isDark() ? null
|
||||
: mCurrentBounds);
|
||||
invalidate();
|
||||
}
|
||||
|
||||
@@ -3843,11 +3843,7 @@ public class NotificationStackScrollLayout extends ViewGroup
|
||||
}
|
||||
|
||||
private void updateFadingState() {
|
||||
if (mFadingOut || mParentFadingOut || mAmbientState.isDark()) {
|
||||
mScrimController.setExcludedBackgroundArea(null);
|
||||
} else {
|
||||
applyCurrentBackgroundBounds();
|
||||
}
|
||||
applyCurrentBackgroundBounds();
|
||||
updateSrcDrawing();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user