Android-Framework 默认屏蔽多任务按键,添加控制属性控制

一、环境

高通865 Android 10

二、代码修改

device/qcom/qssi/system.prop

+# Disable recent key
+persist.recentkey.disable=1

1-屏蔽多任务按键
0-打开多任务按键
frameworks/base/services/core/java/com/android/server/policy/PhoneWindowManager.java
@@ -2770,7 +2770,8 @@ public class PhoneWindowManager implements WindowManagerPolicy {
             }
             return 0;
         } else if (keyCode == KeyEvent.KEYCODE_APP_SWITCH) {
-            if (!keyguardOn) {
+			String recentKeyEnable = SystemProperties.get("persist.recentkey.disable");
+            if (!keyguardOn && "0".equals(recentKeyEnable)) {
                 if (down && repeatCount == 0) {
                     preloadRecentApps();
                 } else if (!down) {

你可能感兴趣的:(Android系统,android)