--- a/sprd/frameworks/base/packages/SystemUI/src/com/android/systemui/screenrecord/ScreenRecordDialog.java
+++ b/sprd/frameworks/base/packages/SystemUI/src/com/android/systemui/screenrecord/ScreenRecordDialog.java
@@ -86,7 +86,13 @@ public class ScreenRecordDialog extends Activity {
cancelBtn.setOnClickListener(v -> {
finish();
});
-
+ //modify by luoyalong 20210722 for remove dialog of record begin
+ if(true){
+ requestScreenCapture();
+ SystemProperties.set("persist.sys.recordst","true");//modify by luoyalong 20210703
+ finish();
+ }
+ //modify by luoyalong 20210722 for remove dialog of record end
Button startBtn = findViewById(R.id.button_start);
startBtn.setOnClickListener(v -> {
requestScreenCapture();
@@ -114,7 +120,8 @@ public class ScreenRecordDialog extends Activity {
private void requestScreenCapture() {
Context userContext = mCurrentUserContextTracker.getCurrentUserContext();
- boolean showTaps = mTapsSwitch.isChecked();
+ //modify by luoyalong 20210722 for remove dialog of record begin
+ boolean showTaps = false;//mTapsSwitch.isChecked();
/*UNISOC: add for bug 1343836 @{*/
if (getUsableSpace() <= 10485760) { //10MB 10 * 1024 * 1024
Toast.makeText(ScreenRecordDialog.this, R.string.screenrecord_failed_to_start, Toast.LENGTH_LONG)
@@ -122,20 +129,21 @@ public class ScreenRecordDialog extends Activity {
return;
}
/*}@*/
- ScreenRecordingAudioSource audioMode = mAudioSwitch.isChecked()
+ /*ScreenRecordingAudioSource audioMode = mAudioSwitch.isChecked()
? (ScreenRecordingAudioSource) mOptions.getSelectedItem()
- : NONE;
+ : NONE;*/
PendingIntent startIntent = PendingIntent.getForegroundService(userContext,
RecordingService.REQUEST_CODE,
RecordingService.getStartIntent(
userContext, RESULT_OK,
- audioMode.ordinal(), showTaps),
+ 2, showTaps),
PendingIntent.FLAG_UPDATE_CURRENT | PendingIntent.FLAG_IMMUTABLE);
PendingIntent stopIntent = PendingIntent.getService(userContext,
RecordingService.REQUEST_CODE,
RecordingService.getStopIntent(userContext),
PendingIntent.FLAG_UPDATE_CURRENT | PendingIntent.FLAG_IMMUTABLE);
mController.startCountdown(DELAY_MS, INTERVAL_MS, startIntent, stopIntent);
+ //modify by luoyalong 20210722 for remove dialog of record end
}