diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/phone/NotificationPanelViewController.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/NotificationPanelViewController.java index dcf5c6a5befef..aeeb95ffb7556 100644 --- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/NotificationPanelViewController.java +++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/NotificationPanelViewController.java @@ -120,6 +120,7 @@ import com.android.systemui.plugins.qs.QS; import com.android.systemui.plugins.statusbar.StatusBarStateController; import com.android.systemui.plugins.statusbar.StatusBarStateController.StateListener; import com.android.systemui.qs.QSDetailDisplayer; +import com.android.systemui.screenrecord.RecordingController; import com.android.systemui.shared.system.QuickStepContract; import com.android.systemui.statusbar.CommandQueue; import com.android.systemui.statusbar.FeatureFlags; @@ -335,6 +336,7 @@ public class NotificationPanelViewController extends PanelViewController { private final LockscreenShadeTransitionController mLockscreenShadeTransitionController; private final TapAgainViewController mTapAgainViewController; private final SplitShadeHeaderController mSplitShadeHeaderController; + private final RecordingController mRecordingController; private boolean mShouldUseSplitNotificationShade; // Current max allowed keyguard notifications determined by measuring the panel private int mMaxAllowedKeyguardNotifications; @@ -721,6 +723,7 @@ public class NotificationPanelViewController extends PanelViewController { FragmentService fragmentService, ContentResolver contentResolver, QuickAccessWalletController quickAccessWalletController, + RecordingController recordingController, @Main Executor uiExecutor, SecureSettings secureSettings, SplitShadeHeaderController splitShadeHeaderController, @@ -767,6 +770,7 @@ public class NotificationPanelViewController extends PanelViewController { mView.setAccessibilityPaneTitle(determineAccessibilityPaneTitle()); setPanelAlpha(255, false /* animate */); mCommandQueue = commandQueue; + mRecordingController = recordingController; mDisplayId = displayId; mPulseExpansionHandler = pulseExpansionHandler; mDozeParameters = dozeParameters; @@ -2411,7 +2415,8 @@ public class NotificationPanelViewController extends PanelViewController { // The padding on this area is large enough that we can use a cheaper clipping strategy mKeyguardStatusAreaClipBounds.set(left, top, right, bottom); clipStatusView = qsVisible; - radius = (int) MathUtils.lerp(mScreenCornerRadius, mScrimCornerRadius, + float screenCornerRadius = mRecordingController.isRecording() ? 0 : mScreenCornerRadius; + radius = (int) MathUtils.lerp(screenCornerRadius, mScrimCornerRadius, Math.min(top / (float) mScrimCornerRadius, 1f)); statusBarClipTop = top - mKeyguardStatusBar.getTop(); } diff --git a/packages/SystemUI/tests/src/com/android/systemui/statusbar/phone/NotificationPanelViewTest.java b/packages/SystemUI/tests/src/com/android/systemui/statusbar/phone/NotificationPanelViewTest.java index e8256ce05821d..3f9ea182fe3f3 100644 --- a/packages/SystemUI/tests/src/com/android/systemui/statusbar/phone/NotificationPanelViewTest.java +++ b/packages/SystemUI/tests/src/com/android/systemui/statusbar/phone/NotificationPanelViewTest.java @@ -97,6 +97,7 @@ import com.android.systemui.media.MediaHierarchyManager; import com.android.systemui.navigationbar.NavigationModeController; import com.android.systemui.plugins.FalsingManager; import com.android.systemui.qs.QSDetailDisplayer; +import com.android.systemui.screenrecord.RecordingController; import com.android.systemui.statusbar.CommandQueue; import com.android.systemui.statusbar.FeatureFlags; import com.android.systemui.statusbar.KeyguardAffordanceView; @@ -300,6 +301,8 @@ public class NotificationPanelViewTest extends SysuiTestCase { private NotificationRemoteInputManager mNotificationRemoteInputManager; @Mock private RemoteInputController mRemoteInputController; + @Mock + private RecordingController mRecordingController; private SysuiStatusBarStateController mStatusBarStateController; private NotificationPanelViewController mNotificationPanelViewController; @@ -438,6 +441,7 @@ public class NotificationPanelViewTest extends SysuiTestCase { mFragmentService, mContentResolver, mQuickAccessWalletController, + mRecordingController, new FakeExecutor(new FakeSystemClock()), mSecureSettings, mSplitShadeHeaderController,