summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author Caitlin Shkuratov <caitlinshk@google.com> 2023-06-22 16:03:08 +0000
committer Caitlin Shkuratov <caitlinshk@google.com> 2023-06-26 15:11:46 +0000
commiteda7ede2354c2693c280e569ea48eb9e0e515ed9 (patch)
treedf01a80faba9f1239743b4d919d265d1cd38fb65
parentd7abdd7204eec8ade7a82536c75ca3c0e282355a (diff)
[CS] Move KeyguardBottomAreaView's provider to ShadeModule.
This isn't the *best* location for this provider, but it's where it has to be (for now) because that's where NotificationPanelView is provided. Bug: 277762009 Test: manual: verify keyguard bottom area gets re-inflated on font change and still works correctly after font change (lockscreen shortcuts still work, bottom area text updates based on events) Change-Id: Ieb2a3e0af7adac6d470f3c610babafd9fa4cf579
-rw-r--r--packages/SystemUI/src/com/android/systemui/shade/ShadeModule.kt15
-rw-r--r--packages/SystemUI/src/com/android/systemui/statusbar/phone/dagger/StatusBarViewModule.java18
2 files changed, 15 insertions, 18 deletions
diff --git a/packages/SystemUI/src/com/android/systemui/shade/ShadeModule.kt b/packages/SystemUI/src/com/android/systemui/shade/ShadeModule.kt
index a2b93516695a..0154b493bd0c 100644
--- a/packages/SystemUI/src/com/android/systemui/shade/ShadeModule.kt
+++ b/packages/SystemUI/src/com/android/systemui/shade/ShadeModule.kt
@@ -49,6 +49,7 @@ import com.android.systemui.statusbar.NotificationShelfController
import com.android.systemui.statusbar.notification.row.dagger.NotificationShelfComponent
import com.android.systemui.statusbar.notification.shelf.ui.viewbinder.NotificationShelfViewBinderWrapperControllerImpl
import com.android.systemui.statusbar.notification.stack.NotificationStackScrollLayout
+import com.android.systemui.statusbar.phone.KeyguardBottomAreaView
import com.android.systemui.statusbar.phone.StatusIconContainer
import com.android.systemui.statusbar.phone.TapAgainView
import com.android.systemui.statusbar.policy.BatteryController
@@ -165,6 +166,20 @@ abstract class ShadeModule {
return notificationShadeWindowView.findViewById(R.id.notification_panel)
}
+ /**
+ * Constructs a new, unattached [KeyguardBottomAreaView].
+ *
+ * Note that this is explicitly _not_ a singleton, as we want to be able to reinflate it
+ */
+ @Provides
+ fun providesKeyguardBottomAreaView(
+ npv: NotificationPanelView,
+ layoutInflater: LayoutInflater,
+ ): KeyguardBottomAreaView {
+ return layoutInflater.inflate(R.layout.keyguard_bottom_area, npv, false)
+ as KeyguardBottomAreaView
+ }
+
@Provides
@SysUISingleton
fun providesLightRevealScrim(
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/dagger/StatusBarViewModule.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/dagger/StatusBarViewModule.java
index 6b0746f08df0..421bdc69cb24 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/dagger/StatusBarViewModule.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/dagger/StatusBarViewModule.java
@@ -16,22 +16,17 @@
package com.android.systemui.statusbar.phone.dagger;
-import android.view.LayoutInflater;
-
import com.android.keyguard.KeyguardUpdateMonitor;
-import com.android.systemui.R;
import com.android.systemui.dagger.qualifiers.Main;
import com.android.systemui.dump.DumpManager;
import com.android.systemui.flags.FeatureFlags;
import com.android.systemui.plugins.statusbar.StatusBarStateController;
-import com.android.systemui.shade.NotificationPanelView;
import com.android.systemui.shade.NotificationPanelViewController;
import com.android.systemui.shade.ShadeExpansionStateManager;
import com.android.systemui.shade.ShadeViewController;
import com.android.systemui.statusbar.CommandQueue;
import com.android.systemui.statusbar.OperatorNameViewController;
import com.android.systemui.statusbar.events.SystemStatusAnimationScheduler;
-import com.android.systemui.statusbar.phone.KeyguardBottomAreaView;
import com.android.systemui.statusbar.phone.NotificationIconAreaController;
import com.android.systemui.statusbar.phone.StatusBarBoundsProvider;
import com.android.systemui.statusbar.phone.StatusBarHideIconsForBouncerManager;
@@ -145,17 +140,4 @@ public abstract class StatusBarViewModule {
statusBarWindowStateController,
keyguardUpdateMonitor);
}
-
- /**
- * Constructs a new, unattached {@link KeyguardBottomAreaView}.
- *
- * Note that this is explicitly _not_ a singleton, as we want to be able to reinflate it
- */
- @Provides
- public static KeyguardBottomAreaView providesKeyguardBottomAreaView(
- NotificationPanelView npv, LayoutInflater layoutInflater) {
- return (KeyguardBottomAreaView) layoutInflater.inflate(R
- .layout.keyguard_bottom_area, npv, false);
- }
-
}