From 630225cac4d2ad0265a1583b15971c2200c46082 Mon Sep 17 00:00:00 2001 From: Beth Thibodeau Date: Tue, 4 Feb 2020 17:16:45 -0500 Subject: [PATCH] Add custom start dialog with options Use a custom dialog with options for recording audio and taps, instead of the standard media projection permissions dialog. Options will not be saved and both default to off. Since system audio isn't implemented yet the audio switch just shows the text for microphone audio. Also updated ongoing notification text to reflect whether audio is being recorded. Bug: 147490562 Test: manual, screenshots at https://drive.google.com/drive/folders/1jIyzmPDwt6oxVGAw319awdSafnoz8nmI?usp=sharing Change-Id: I2b012a6b8b6611c0d6fcada79ed5bdc009e24b17 --- packages/SystemUI/res/drawable/ic_touch.xml | 26 ++++ .../res/layout/screen_record_dialog.xml | 142 ++++++++++++++++++ packages/SystemUI/res/values/dimens.xml | 4 +- packages/SystemUI/res/values/strings.xml | 30 +++- .../screenrecord/RecordingService.java | 47 ++++-- .../screenrecord/ScreenRecordDialog.java | 126 +++++----------- 6 files changed, 270 insertions(+), 105 deletions(-) create mode 100644 packages/SystemUI/res/drawable/ic_touch.xml create mode 100644 packages/SystemUI/res/layout/screen_record_dialog.xml diff --git a/packages/SystemUI/res/drawable/ic_touch.xml b/packages/SystemUI/res/drawable/ic_touch.xml new file mode 100644 index 0000000000000..4f6698de5251f --- /dev/null +++ b/packages/SystemUI/res/drawable/ic_touch.xml @@ -0,0 +1,26 @@ + + + + + diff --git a/packages/SystemUI/res/layout/screen_record_dialog.xml b/packages/SystemUI/res/layout/screen_record_dialog.xml new file mode 100644 index 0000000000000..df576d83323f1 --- /dev/null +++ b/packages/SystemUI/res/layout/screen_record_dialog.xml @@ -0,0 +1,142 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +