summaryrefslogtreecommitdiff
path: root/packages/SystemUI/src/com/android/keyguard/KeyguardStatusViewController.java
diff options
context:
space:
mode:
authorMatt Pietal <mpietal@google.com>2021-04-07 14:02:22 -0400
committerMatt Pietal <mpietal@google.com>2021-04-12 06:48:48 -0400
commitb41253b7daf020a51226bc9af944c9f186709c14 (patch)
tree7df59e3756c7102d65fe9310c7223a842c52238f /packages/SystemUI/src/com/android/keyguard/KeyguardStatusViewController.java
parentd7440a1c688c484f5e7bde6615b198d1ee7956dd (diff)
Update to latest UX margins for clock... and much more
Remove old style clocks and all related code. Begin unraveling code supporting multiple layouts. Migrate plugin small/big clock support to the new clock areas. Fixes: 184073275 Test: atest KeyguardClockSwitchTest KeyguardClockSwitchControllerTest Change-Id: I38dc2a6df6a710c6da23cbb17fac8d28f3b84764
Diffstat (limited to 'packages/SystemUI/src/com/android/keyguard/KeyguardStatusViewController.java')
-rw-r--r--packages/SystemUI/src/com/android/keyguard/KeyguardStatusViewController.java35
1 files changed, 2 insertions, 33 deletions
diff --git a/packages/SystemUI/src/com/android/keyguard/KeyguardStatusViewController.java b/packages/SystemUI/src/com/android/keyguard/KeyguardStatusViewController.java
index 31ec00378135..fc80dbe021a7 100644
--- a/packages/SystemUI/src/com/android/keyguard/KeyguardStatusViewController.java
+++ b/packages/SystemUI/src/com/android/keyguard/KeyguardStatusViewController.java
@@ -18,15 +18,12 @@ package com.android.keyguard;
import android.os.UserHandle;
import android.util.Slog;
-import android.view.View;
import com.android.systemui.statusbar.notification.AnimatableProperty;
import com.android.systemui.statusbar.notification.PropertyAnimator;
import com.android.systemui.statusbar.notification.stack.AnimationProperties;
import com.android.systemui.statusbar.notification.stack.StackStateAnimator;
import com.android.systemui.statusbar.phone.DozeParameters;
-import com.android.systemui.statusbar.phone.NotificationIconAreaController;
-import com.android.systemui.statusbar.phone.NotificationIconContainer;
import com.android.systemui.statusbar.policy.ConfigurationController;
import com.android.systemui.statusbar.policy.KeyguardStateController;
import com.android.systemui.util.ViewController;
@@ -49,7 +46,6 @@ public class KeyguardStatusViewController extends ViewController<KeyguardStatusV
private final KeyguardClockSwitchController mKeyguardClockSwitchController;
private final KeyguardUpdateMonitor mKeyguardUpdateMonitor;
private final ConfigurationController mConfigurationController;
- private final NotificationIconAreaController mNotificationIconAreaController;
private final DozeParameters mDozeParameters;
private final KeyguardVisibilityHelper mKeyguardVisibilityHelper;
@@ -63,14 +59,12 @@ public class KeyguardStatusViewController extends ViewController<KeyguardStatusV
KeyguardStateController keyguardStateController,
KeyguardUpdateMonitor keyguardUpdateMonitor,
ConfigurationController configurationController,
- NotificationIconAreaController notificationIconAreaController,
DozeParameters dozeParameters) {
super(keyguardStatusView);
mKeyguardSliceViewController = keyguardSliceViewController;
mKeyguardClockSwitchController = keyguardClockSwitchController;
mKeyguardUpdateMonitor = keyguardUpdateMonitor;
mConfigurationController = configurationController;
- mNotificationIconAreaController = notificationIconAreaController;
mDozeParameters = dozeParameters;
mKeyguardVisibilityHelper = new KeyguardVisibilityHelper(mView, keyguardStateController,
dozeParameters);
@@ -87,7 +81,6 @@ public class KeyguardStatusViewController extends ViewController<KeyguardStatusV
protected void onViewAttached() {
mKeyguardUpdateMonitor.registerCallback(mInfoCallback);
mConfigurationController.addCallback(mConfigurationListener);
- updateAodIcons();
}
@Override
@@ -237,17 +230,6 @@ public class KeyguardStatusViewController extends ViewController<KeyguardStatusV
mKeyguardClockSwitchController.refresh();
}
- private void updateAodIcons() {
- NotificationIconContainer nic = (NotificationIconContainer)
- mView.findViewById(com.android.systemui.R.id.clock_notification_icon_container);
- if (mLockScreenMode == KeyguardUpdateMonitor.LOCK_SCREEN_MODE_NORMAL) {
- // alternate icon area is set in KeyguardClockSwitchController
- mNotificationIconAreaController.setupAodIcons(nic, mLockScreenMode);
- } else {
- nic.setVisibility(View.GONE);
- }
- }
-
private boolean shouldShowLogout() {
return mKeyguardUpdateMonitor.isLogoutEnabled()
&& KeyguardUpdateMonitor.getCurrentUser() != UserHandle.USER_SYSTEM;
@@ -271,16 +253,9 @@ public class KeyguardStatusViewController extends ViewController<KeyguardStatusV
@Override
public void onLockScreenModeChanged(int mode) {
mLockScreenMode = mode;
- mKeyguardClockSwitchController.updateLockScreenMode(mode);
mKeyguardSliceViewController.updateLockScreenMode(mode);
- if (mLockScreenMode == KeyguardUpdateMonitor.LOCK_SCREEN_MODE_LAYOUT_1) {
- mView.setCanShowOwnerInfo(false);
- mView.updateLogoutView(false);
- } else {
- mView.setCanShowOwnerInfo(true);
- mView.updateLogoutView(false);
- }
- updateAodIcons();
+ mView.setCanShowOwnerInfo(false);
+ mView.updateLogoutView(false);
}
@Override
@@ -294,11 +269,6 @@ public class KeyguardStatusViewController extends ViewController<KeyguardStatusV
}
@Override
- public void onTimeFormatChanged(String timeFormat) {
- mKeyguardClockSwitchController.refreshFormat(timeFormat);
- }
-
- @Override
public void onKeyguardVisibilityChanged(boolean showing) {
if (showing) {
if (DEBUG) Slog.v(TAG, "refresh statusview showing:" + showing);
@@ -320,7 +290,6 @@ public class KeyguardStatusViewController extends ViewController<KeyguardStatusV
@Override
public void onUserSwitchComplete(int userId) {
- mKeyguardClockSwitchController.refreshFormat();
mView.updateOwnerInfo();
mView.updateLogoutView(shouldShowLogout());
}