From bd9cf8f9d2df3dea41513fa2061c5f8920d44a5b Mon Sep 17 00:00:00 2001 From: Robert Horvath Date: Wed, 4 May 2022 17:17:43 +0200 Subject: [PATCH] Improve LogAccessDialogActivity's rotation handling 1. Do not dismiss the dialog on configuration change, such as rotation. When the device was rotated, the dialog was automatically dismissed as the activity was destroyed & recreated in the new configuration. 2. Wrap the dialog content view in a ScrolLView In landscape orientation (and smaller phone screens), the dialog content may not fit entirely on the screen. By wrapping it in a ScrollView, all the dialog text and buttons can still be accessed in landscape / smaller screens. Bug: 231436416 Test: Manual, on adt3 Test: On phone emulator in light/dark mode & different orientations Change-Id: Ibf3ecf93a237783ce4909a24a959c3ea243ab766 --- ..._access_user_consent_dialog_permission.xml | 143 ++++++++++-------- .../logcat/LogAccessDialogActivity.java | 2 +- 2 files changed, 77 insertions(+), 68 deletions(-) diff --git a/core/res/res/layout/log_access_user_consent_dialog_permission.xml b/core/res/res/layout/log_access_user_consent_dialog_permission.xml index 1a395b9fc30f9..3da14c8f18860 100644 --- a/core/res/res/layout/log_access_user_consent_dialog_permission.xml +++ b/core/res/res/layout/log_access_user_consent_dialog_permission.xml @@ -16,77 +16,86 @@ ** limitations under the License. */ --> - - - - - - - - + -