Merge "Add color change listener to NSSL" into rvc-dev
This commit is contained in:
committed by
Android (Google) Code Review
commit
3924bc3dca
@@ -535,6 +535,12 @@ public class NotificationStackScrollLayout extends ViewGroup implements ScrollAd
|
|||||||
|
|
||||||
private int mWaterfallTopInset;
|
private int mWaterfallTopInset;
|
||||||
|
|
||||||
|
private SysuiColorExtractor.OnColorsChangedListener mOnColorsChangedListener =
|
||||||
|
(colorExtractor, which) -> {
|
||||||
|
final boolean useDarkText = mColorExtractor.getNeutralColors().supportsDarkText();
|
||||||
|
updateDecorViews(useDarkText);
|
||||||
|
};
|
||||||
|
|
||||||
@Inject
|
@Inject
|
||||||
public NotificationStackScrollLayout(
|
public NotificationStackScrollLayout(
|
||||||
@Named(VIEW_CONTEXT) Context context,
|
@Named(VIEW_CONTEXT) Context context,
|
||||||
@@ -662,6 +668,7 @@ public class NotificationStackScrollLayout extends ViewGroup implements ScrollAd
|
|||||||
mStatusbarStateController = statusBarStateController;
|
mStatusbarStateController = statusBarStateController;
|
||||||
initializeForegroundServiceSection(fgsFeatureController);
|
initializeForegroundServiceSection(fgsFeatureController);
|
||||||
mUiEventLogger = uiEventLogger;
|
mUiEventLogger = uiEventLogger;
|
||||||
|
mColorExtractor.addOnColorsChangedListener(mOnColorsChangedListener);
|
||||||
}
|
}
|
||||||
|
|
||||||
private void initializeForegroundServiceSection(
|
private void initializeForegroundServiceSection(
|
||||||
@@ -728,9 +735,6 @@ public class NotificationStackScrollLayout extends ViewGroup implements ScrollAd
|
|||||||
@Override
|
@Override
|
||||||
@ShadeViewRefactor(RefactorComponent.SHADE_VIEW)
|
@ShadeViewRefactor(RefactorComponent.SHADE_VIEW)
|
||||||
public void onThemeChanged() {
|
public void onThemeChanged() {
|
||||||
final boolean useDarkText = mColorExtractor.getNeutralColors().supportsDarkText();
|
|
||||||
updateDecorViews(useDarkText);
|
|
||||||
|
|
||||||
updateFooter();
|
updateFooter();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user