summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--packages/SystemUI/src/com/android/keyguard/KeyguardStatusView.java13
-rw-r--r--packages/SystemUI/src/com/android/keyguard/KeyguardStatusViewController.java23
-rw-r--r--packages/SystemUI/src/com/android/systemui/shade/NotificationPanelViewController.java4
-rw-r--r--packages/SystemUI/tests/src/com/android/keyguard/KeyguardStatusViewControllerBaseTest.java3
-rw-r--r--packages/SystemUI/tests/src/com/android/keyguard/KeyguardStatusViewControllerTest.java8
-rw-r--r--packages/SystemUI/tests/src/com/android/systemui/shade/NotificationPanelViewControllerBaseTest.java1
6 files changed, 1 insertions, 51 deletions
diff --git a/packages/SystemUI/src/com/android/keyguard/KeyguardStatusView.java b/packages/SystemUI/src/com/android/keyguard/KeyguardStatusView.java
index d8486029a903..073f33fe5245 100644
--- a/packages/SystemUI/src/com/android/keyguard/KeyguardStatusView.java
+++ b/packages/SystemUI/src/com/android/keyguard/KeyguardStatusView.java
@@ -33,7 +33,6 @@ import com.android.systemui.res.R;
import com.android.systemui.shade.TouchLogger;
import com.android.systemui.statusbar.CrossFadeHelper;
-import java.io.PrintWriter;
import java.util.Set;
/**
@@ -117,18 +116,6 @@ public class KeyguardStatusView extends GridLayout {
return TouchLogger.logDispatchTouch(TAG, ev, super.dispatchTouchEvent(ev));
}
- public void dump(PrintWriter pw, String[] args) {
- pw.println("KeyguardStatusView:");
- pw.println(" mDarkAmount: " + mDarkAmount);
- pw.println(" visibility: " + getVisibility());
- if (mClockView != null) {
- mClockView.dump(pw, args);
- }
- if (mKeyguardSlice != null) {
- mKeyguardSlice.dump(pw, args);
- }
- }
-
@Override
public ViewPropertyAnimator animate() {
if (Build.IS_DEBUGGABLE) {
diff --git a/packages/SystemUI/src/com/android/keyguard/KeyguardStatusViewController.java b/packages/SystemUI/src/com/android/keyguard/KeyguardStatusViewController.java
index 603a47e8d26e..63a4af949c8c 100644
--- a/packages/SystemUI/src/com/android/keyguard/KeyguardStatusViewController.java
+++ b/packages/SystemUI/src/com/android/keyguard/KeyguardStatusViewController.java
@@ -48,9 +48,7 @@ import com.android.app.animation.Interpolators;
import com.android.internal.jank.InteractionJankMonitor;
import com.android.keyguard.KeyguardClockSwitch.ClockSize;
import com.android.keyguard.logging.KeyguardLogger;
-import com.android.systemui.Dumpable;
import com.android.systemui.animation.ViewHierarchyAnimator;
-import com.android.systemui.dump.DumpManager;
import com.android.systemui.keyguard.MigrateClocksToBlueprint;
import com.android.systemui.keyguard.domain.interactor.KeyguardInteractor;
import com.android.systemui.plugins.clocks.ClockController;
@@ -70,15 +68,12 @@ import com.android.systemui.util.ViewController;
import kotlin.coroutines.CoroutineContext;
import kotlin.coroutines.EmptyCoroutineContext;
-import java.io.PrintWriter;
-
import javax.inject.Inject;
/**
* Injectable controller for {@link KeyguardStatusView}.
*/
-public class KeyguardStatusViewController extends ViewController<KeyguardStatusView> implements
- Dumpable {
+public class KeyguardStatusViewController extends ViewController<KeyguardStatusView> {
private static final boolean DEBUG = KeyguardConstants.DEBUG;
@VisibleForTesting static final String TAG = "KeyguardStatusViewController";
private static final long STATUS_AREA_HEIGHT_ANIMATION_MILLIS = 133;
@@ -108,7 +103,6 @@ public class KeyguardStatusViewController extends ViewController<KeyguardStatusV
private Boolean mSplitShadeEnabled = false;
private Boolean mStatusViewCentered = true;
- private DumpManager mDumpManager;
private final TransitionListenerAdapter mKeyguardStatusAlignmentTransitionListener =
new TransitionListenerAdapter() {
@@ -176,7 +170,6 @@ public class KeyguardStatusViewController extends ViewController<KeyguardStatusV
KeyguardLogger logger,
InteractionJankMonitor interactionJankMonitor,
KeyguardInteractor keyguardInteractor,
- DumpManager dumpManager,
PowerInteractor powerInteractor) {
super(keyguardStatusView);
mKeyguardSliceViewController = keyguardSliceViewController;
@@ -188,7 +181,6 @@ public class KeyguardStatusViewController extends ViewController<KeyguardStatusV
dozeParameters, screenOffAnimationController, /* animateYPos= */ true,
logger.getBuffer());
mInteractionJankMonitor = interactionJankMonitor;
- mDumpManager = dumpManager;
mKeyguardInteractor = keyguardInteractor;
mPowerInteractor = powerInteractor;
}
@@ -222,7 +214,6 @@ public class KeyguardStatusViewController extends ViewController<KeyguardStatusV
});
}
- mDumpManager.registerDumpable(getInstanceName(), this);
if (MigrateClocksToBlueprint.isEnabled()) {
startCoroutines(EmptyCoroutineContext.INSTANCE);
mView.setVisibility(View.GONE);
@@ -276,13 +267,6 @@ public class KeyguardStatusViewController extends ViewController<KeyguardStatusV
}
/**
- * Called in notificationPanelViewController to avoid leak
- */
- public void onDestroy() {
- mDumpManager.unregisterDumpable(getInstanceName());
- }
-
- /**
* Updates views on doze time tick.
*/
public void dozeTimeTick() {
@@ -604,11 +588,6 @@ public class KeyguardStatusViewController extends ViewController<KeyguardStatusV
return mKeyguardClockSwitchController.getClock();
}
- @Override
- public void dump(@NonNull PrintWriter pw, @NonNull String[] args) {
- mView.dump(pw, args);
- }
-
String getInstanceName() {
return TAG + "#" + hashCode();
}
diff --git a/packages/SystemUI/src/com/android/systemui/shade/NotificationPanelViewController.java b/packages/SystemUI/src/com/android/systemui/shade/NotificationPanelViewController.java
index 91bfae31559a..257390fae048 100644
--- a/packages/SystemUI/src/com/android/systemui/shade/NotificationPanelViewController.java
+++ b/packages/SystemUI/src/com/android/systemui/shade/NotificationPanelViewController.java
@@ -1305,10 +1305,6 @@ public final class NotificationPanelViewController implements ShadeSurface, Dump
/** Updates the StatusBarViewController and updates any that depend on it. */
public void updateStatusViewController() {
// Re-associate the KeyguardStatusViewController
- if (mKeyguardStatusViewController != null) {
- mKeyguardStatusViewController.onDestroy();
- }
-
if (MigrateClocksToBlueprint.isEnabled()) {
// Need a shared controller until mKeyguardStatusViewController can be removed from
// here, due to important state being set in that controller. Rebind in order to pick
diff --git a/packages/SystemUI/tests/src/com/android/keyguard/KeyguardStatusViewControllerBaseTest.java b/packages/SystemUI/tests/src/com/android/keyguard/KeyguardStatusViewControllerBaseTest.java
index 07504c732bc2..2b4fc5bd5cc5 100644
--- a/packages/SystemUI/tests/src/com/android/keyguard/KeyguardStatusViewControllerBaseTest.java
+++ b/packages/SystemUI/tests/src/com/android/keyguard/KeyguardStatusViewControllerBaseTest.java
@@ -26,7 +26,6 @@ import android.widget.FrameLayout;
import com.android.keyguard.logging.KeyguardLogger;
import com.android.systemui.SysuiTestCase;
-import com.android.systemui.dump.DumpManager;
import com.android.systemui.keyguard.data.repository.FakeKeyguardRepository;
import com.android.systemui.keyguard.domain.interactor.KeyguardInteractorFactory;
import com.android.systemui.kosmos.KosmosJavaAdapter;
@@ -59,7 +58,6 @@ public class KeyguardStatusViewControllerBaseTest extends SysuiTestCase {
@Mock protected KeyguardLogger mKeyguardLogger;
@Mock protected KeyguardStatusViewController mControllerMock;
@Mock protected ViewTreeObserver mViewTreeObserver;
- @Mock protected DumpManager mDumpManager;
protected FakeKeyguardRepository mFakeKeyguardRepository;
protected FakePowerRepository mFakePowerRepository;
@@ -90,7 +88,6 @@ public class KeyguardStatusViewControllerBaseTest extends SysuiTestCase {
mKeyguardLogger,
mKosmos.getInteractionJankMonitor(),
deps.getKeyguardInteractor(),
- mDumpManager,
PowerInteractorFactory.create(
mFakePowerRepository
).getPowerInteractor()) {
diff --git a/packages/SystemUI/tests/src/com/android/keyguard/KeyguardStatusViewControllerTest.java b/packages/SystemUI/tests/src/com/android/keyguard/KeyguardStatusViewControllerTest.java
index 0696a4b880d5..8e441a3db242 100644
--- a/packages/SystemUI/tests/src/com/android/keyguard/KeyguardStatusViewControllerTest.java
+++ b/packages/SystemUI/tests/src/com/android/keyguard/KeyguardStatusViewControllerTest.java
@@ -140,14 +140,6 @@ public class KeyguardStatusViewControllerTest extends KeyguardStatusViewControll
}
@Test
- public void correctlyDump() {
- mController.onInit();
- verify(mDumpManager).registerDumpable(eq(mController.getInstanceName()), eq(mController));
- mController.onDestroy();
- verify(mDumpManager, times(1)).unregisterDumpable(eq(mController.getInstanceName()));
- }
-
- @Test
public void onInit_addsOnLayoutChangeListenerToClockSwitch() {
when(mKeyguardStatusView.findViewById(R.id.status_view_media_container)).thenReturn(
mMediaHostContainer);
diff --git a/packages/SystemUI/tests/src/com/android/systemui/shade/NotificationPanelViewControllerBaseTest.java b/packages/SystemUI/tests/src/com/android/systemui/shade/NotificationPanelViewControllerBaseTest.java
index 56fb43d056a6..2803035f1b82 100644
--- a/packages/SystemUI/tests/src/com/android/systemui/shade/NotificationPanelViewControllerBaseTest.java
+++ b/packages/SystemUI/tests/src/com/android/systemui/shade/NotificationPanelViewControllerBaseTest.java
@@ -479,7 +479,6 @@ public class NotificationPanelViewControllerBaseTest extends SysuiTestCase {
mKeyguardLogger,
mKosmos.getInteractionJankMonitor(),
mKeyguardInteractor,
- mDumpManager,
mPowerInteractor));
when(mAuthController.isUdfpsEnrolled(anyInt())).thenReturn(false);