diff options
| -rw-r--r-- | core/res/res/values/config.xml | 4 | ||||
| -rw-r--r-- | core/res/res/values/symbols.xml | 1 | ||||
| -rw-r--r-- | services/core/java/com/android/server/am/ActivityManagerShellCommand.java | 11 |
3 files changed, 16 insertions, 0 deletions
diff --git a/core/res/res/values/config.xml b/core/res/res/values/config.xml index be0b51630053..d233e24e475e 100644 --- a/core/res/res/values/config.xml +++ b/core/res/res/values/config.xml @@ -2612,6 +2612,10 @@ <!-- True if the device supports split screen as a form of multi-window. --> <bool name="config_supportsSplitScreenMultiWindow">true</bool> + <!-- True if the device has no home screen. That is a launcher activity + where the user can launch other applications from. --> + <bool name="config_noHomeScreen">false</bool> + <!-- True if the device requires AppWidgetService even if it does not have the PackageManager.FEATURE_APP_WIDGETS feature --> <bool name="config_enableAppWidgetService">false</bool> diff --git a/core/res/res/values/symbols.xml b/core/res/res/values/symbols.xml index adca0522b108..eb248e510d11 100644 --- a/core/res/res/values/symbols.xml +++ b/core/res/res/values/symbols.xml @@ -312,6 +312,7 @@ <java-symbol type="bool" name="config_freeformWindowManagement" /> <java-symbol type="bool" name="config_supportsMultiWindow" /> <java-symbol type="bool" name="config_supportsSplitScreenMultiWindow" /> + <java-symbol type="bool" name="config_noHomeScreen" /> <java-symbol type="bool" name="config_guestUserEphemeral" /> <java-symbol type="bool" name="config_localDisplaysMirrorContent" /> <java-symbol type="integer" name="config_defaultDisplayDefaultColorMode" /> diff --git a/services/core/java/com/android/server/am/ActivityManagerShellCommand.java b/services/core/java/com/android/server/am/ActivityManagerShellCommand.java index 80df26b4ed42..aaad12c1f289 100644 --- a/services/core/java/com/android/server/am/ActivityManagerShellCommand.java +++ b/services/core/java/com/android/server/am/ActivityManagerShellCommand.java @@ -240,6 +240,8 @@ final class ActivityManagerShellCommand extends ShellCommand { return runSupportsSplitScreenMultiwindow(pw); case "update-appinfo": return runUpdateApplicationInfo(pw); + case "no-home-screen": + return runNoHomeScreen(pw); default: return handleDefaultCommands(cmd); } @@ -2386,6 +2388,15 @@ final class ActivityManagerShellCommand extends ShellCommand { return 0; } + int runNoHomeScreen(PrintWriter pw) throws RemoteException { + final Resources res = getResources(pw); + if (res == null) { + return -1; + } + pw.println(res.getBoolean(com.android.internal.R.bool.config_noHomeScreen)); + return 0; + } + private Resources getResources(PrintWriter pw) throws RemoteException { // system resources does not contain all the device configuration, construct it manually. Configuration config = mInterface.getConfiguration(); |