Loading packages/SystemUI/src/com/android/systemui/privacy/PrivacyDialogControllerV2.kt +13 −1 Original line number Diff line number Diff line Loading @@ -278,7 +278,12 @@ class PrivacyDialogControllerV2( d.setShowForAllUsers(true) d.addOnDismissListener(onDialogDismissed) if (view != null) { dialogLaunchAnimator.showFromView(d, view) val controller = getPrivacyDialogController(view) if (controller == null) { d.show() } else { dialogLaunchAnimator.show(d, controller) } } else { d.show() } Loading @@ -291,6 +296,13 @@ class PrivacyDialogControllerV2( } } private fun getPrivacyDialogController(source: View): DialogLaunchAnimator.Controller? { val delegate = DialogLaunchAnimator.Controller.fromView(source) ?: return null return object : DialogLaunchAnimator.Controller by delegate { override fun shouldAnimateExit() = false } } /** Dismisses the dialog */ fun dismissDialog() { dialog?.dismiss() Loading packages/SystemUI/tests/src/com/android/systemui/privacy/PrivacyDialogControllerV2Test.kt +203 −207 File changed.Preview size limit exceeded, changes collapsed. Show changes Loading
packages/SystemUI/src/com/android/systemui/privacy/PrivacyDialogControllerV2.kt +13 −1 Original line number Diff line number Diff line Loading @@ -278,7 +278,12 @@ class PrivacyDialogControllerV2( d.setShowForAllUsers(true) d.addOnDismissListener(onDialogDismissed) if (view != null) { dialogLaunchAnimator.showFromView(d, view) val controller = getPrivacyDialogController(view) if (controller == null) { d.show() } else { dialogLaunchAnimator.show(d, controller) } } else { d.show() } Loading @@ -291,6 +296,13 @@ class PrivacyDialogControllerV2( } } private fun getPrivacyDialogController(source: View): DialogLaunchAnimator.Controller? { val delegate = DialogLaunchAnimator.Controller.fromView(source) ?: return null return object : DialogLaunchAnimator.Controller by delegate { override fun shouldAnimateExit() = false } } /** Dismisses the dialog */ fun dismissDialog() { dialog?.dismiss() Loading
packages/SystemUI/tests/src/com/android/systemui/privacy/PrivacyDialogControllerV2Test.kt +203 −207 File changed.Preview size limit exceeded, changes collapsed. Show changes