Loading res/values/arrays.xml +4 −4 Original line number Original line Diff line number Diff line Loading @@ -1623,15 +1623,15 @@ <item>1</item> <item>1</item> </string-array> </string-array> <!-- Setting entries for timing out to user 0 when docked. --> <!-- Setting entries for timing out to the Dock User when docked. --> <string-array name="switch_to_user_zero_when_docked_timeout_entries"> <string-array name="switch_to_dock_user_when_docked_timeout_entries"> <item>Never</item> <item>Never</item> <item>After 1 minute</item> <item>After 1 minute</item> <item>After 5 minutes</item> <item>After 5 minutes</item> </string-array> </string-array> <!-- Setting values for timing out to user 0 when docked. [DO NOT TRANSLATE] --> <!-- Setting values for timing out to the Dock User when docked. [DO NOT TRANSLATE] --> <string-array name="switch_to_user_zero_when_docked_timeout_values" translatable="false"> <string-array name="switch_to_dock_user_when_docked_timeout_values" translatable="false"> <!-- Never --> <!-- Never --> <item>0</item> <item>0</item> <!-- 1 minute --> <!-- 1 minute --> Loading res/values/strings.xml +3 −2 Original line number Original line Diff line number Diff line Loading @@ -7890,9 +7890,10 @@ <string name="user_lockscreen_settings">Lock screen settings</string> <string name="user_lockscreen_settings">Lock screen settings</string> <!-- User settings item to allow creating new users from locks screen [CHAR LIMIT=50] --> <!-- User settings item to allow creating new users from locks screen [CHAR LIMIT=50] --> <string name="user_add_on_lockscreen_menu">Add users from lock screen</string> <string name="user_add_on_lockscreen_menu">Add users from lock screen</string> <!-- User settings item to allow the system to automatically switch back to the admin user when <!-- TODO(b/257333623): HSUM has no 1:1 admin:dream relationship. There can even be >1 admin --> <!-- User settings item to allow the system to automatically switch back to the Dock User when the device is docked. [CHAR LIMIT=50] --> the device is docked. [CHAR LIMIT=50] --> <string name="switch_to_user_zero_when_docked">Switch to admin user when docked</string> <string name="switch_to_dock_user_when_docked">Switch to admin user when docked</string> <!-- User (self) removal confirmation title [CHAR LIMIT=30] --> <!-- User (self) removal confirmation title [CHAR LIMIT=30] --> <string name="user_confirm_remove_self_title">Delete yourself?</string> <string name="user_confirm_remove_self_title">Delete yourself?</string> res/xml/user_settings.xml +4 −4 Original line number Original line Diff line number Diff line Loading @@ -86,10 +86,10 @@ settings:allowDividerAbove="true"/> settings:allowDividerAbove="true"/> <com.android.settingslib.RestrictedPreference <com.android.settingslib.RestrictedPreference android:key="timeout_to_user_zero_preference" android:key="timeout_to_dock_user_preference" android:title="@string/switch_to_user_zero_when_docked" android:title="@string/switch_to_dock_user_when_docked" android:order="106" android:order="106" android:fragment="com.android.settings.users.TimeoutToUserZeroSettings" android:fragment="com.android.settings.users.TimeoutToDockUserSettings" settings:controller="com.android.settings.users.TimeoutToUserZeroPreferenceController"/> settings:controller="com.android.settings.users.TimeoutToDockUserPreferenceController"/> </PreferenceScreen> </PreferenceScreen> res/xml/user_timeout_to_user_zero_settings.xml→res/xml/user_timeout_to_dock_user_settings.xml +1 −1 Original line number Original line Diff line number Diff line Loading @@ -17,4 +17,4 @@ <PreferenceScreen <PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android" xmlns:android="http://schemas.android.com/apk/res/android" android:title="@string/switch_to_user_zero_when_docked"/> android:title="@string/switch_to_dock_user_when_docked"/> src/com/android/settings/display/ScreenSaverPreferenceController.java +4 −3 Original line number Original line Diff line number Diff line Loading @@ -39,9 +39,10 @@ public class ScreenSaverPreferenceController extends AbstractPreferenceControlle public boolean isAvailable() { public boolean isAvailable() { final boolean dreamsSupported = mContext.getResources().getBoolean( final boolean dreamsSupported = mContext.getResources().getBoolean( com.android.internal.R.bool.config_dreamsSupported); com.android.internal.R.bool.config_dreamsSupported); final boolean dreamsOnlyEnabledForSystemUser = mContext.getResources().getBoolean( final boolean dreamsOnlyEnabledForDockUser = mContext.getResources().getBoolean( com.android.internal.R.bool.config_dreamsOnlyEnabledForSystemUser); com.android.internal.R.bool.config_dreamsOnlyEnabledForDockUser); return dreamsSupported && (!dreamsOnlyEnabledForSystemUser || isSystemUser()); // TODO(b/257333623): Allow the Dock User to be non-SystemUser user in HSUM. return dreamsSupported && (!dreamsOnlyEnabledForDockUser || isSystemUser()); } } @Override @Override Loading Loading
res/values/arrays.xml +4 −4 Original line number Original line Diff line number Diff line Loading @@ -1623,15 +1623,15 @@ <item>1</item> <item>1</item> </string-array> </string-array> <!-- Setting entries for timing out to user 0 when docked. --> <!-- Setting entries for timing out to the Dock User when docked. --> <string-array name="switch_to_user_zero_when_docked_timeout_entries"> <string-array name="switch_to_dock_user_when_docked_timeout_entries"> <item>Never</item> <item>Never</item> <item>After 1 minute</item> <item>After 1 minute</item> <item>After 5 minutes</item> <item>After 5 minutes</item> </string-array> </string-array> <!-- Setting values for timing out to user 0 when docked. [DO NOT TRANSLATE] --> <!-- Setting values for timing out to the Dock User when docked. [DO NOT TRANSLATE] --> <string-array name="switch_to_user_zero_when_docked_timeout_values" translatable="false"> <string-array name="switch_to_dock_user_when_docked_timeout_values" translatable="false"> <!-- Never --> <!-- Never --> <item>0</item> <item>0</item> <!-- 1 minute --> <!-- 1 minute --> Loading
res/values/strings.xml +3 −2 Original line number Original line Diff line number Diff line Loading @@ -7890,9 +7890,10 @@ <string name="user_lockscreen_settings">Lock screen settings</string> <string name="user_lockscreen_settings">Lock screen settings</string> <!-- User settings item to allow creating new users from locks screen [CHAR LIMIT=50] --> <!-- User settings item to allow creating new users from locks screen [CHAR LIMIT=50] --> <string name="user_add_on_lockscreen_menu">Add users from lock screen</string> <string name="user_add_on_lockscreen_menu">Add users from lock screen</string> <!-- User settings item to allow the system to automatically switch back to the admin user when <!-- TODO(b/257333623): HSUM has no 1:1 admin:dream relationship. There can even be >1 admin --> <!-- User settings item to allow the system to automatically switch back to the Dock User when the device is docked. [CHAR LIMIT=50] --> the device is docked. [CHAR LIMIT=50] --> <string name="switch_to_user_zero_when_docked">Switch to admin user when docked</string> <string name="switch_to_dock_user_when_docked">Switch to admin user when docked</string> <!-- User (self) removal confirmation title [CHAR LIMIT=30] --> <!-- User (self) removal confirmation title [CHAR LIMIT=30] --> <string name="user_confirm_remove_self_title">Delete yourself?</string> <string name="user_confirm_remove_self_title">Delete yourself?</string>
res/xml/user_settings.xml +4 −4 Original line number Original line Diff line number Diff line Loading @@ -86,10 +86,10 @@ settings:allowDividerAbove="true"/> settings:allowDividerAbove="true"/> <com.android.settingslib.RestrictedPreference <com.android.settingslib.RestrictedPreference android:key="timeout_to_user_zero_preference" android:key="timeout_to_dock_user_preference" android:title="@string/switch_to_user_zero_when_docked" android:title="@string/switch_to_dock_user_when_docked" android:order="106" android:order="106" android:fragment="com.android.settings.users.TimeoutToUserZeroSettings" android:fragment="com.android.settings.users.TimeoutToDockUserSettings" settings:controller="com.android.settings.users.TimeoutToUserZeroPreferenceController"/> settings:controller="com.android.settings.users.TimeoutToDockUserPreferenceController"/> </PreferenceScreen> </PreferenceScreen>
res/xml/user_timeout_to_user_zero_settings.xml→res/xml/user_timeout_to_dock_user_settings.xml +1 −1 Original line number Original line Diff line number Diff line Loading @@ -17,4 +17,4 @@ <PreferenceScreen <PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android" xmlns:android="http://schemas.android.com/apk/res/android" android:title="@string/switch_to_user_zero_when_docked"/> android:title="@string/switch_to_dock_user_when_docked"/>
src/com/android/settings/display/ScreenSaverPreferenceController.java +4 −3 Original line number Original line Diff line number Diff line Loading @@ -39,9 +39,10 @@ public class ScreenSaverPreferenceController extends AbstractPreferenceControlle public boolean isAvailable() { public boolean isAvailable() { final boolean dreamsSupported = mContext.getResources().getBoolean( final boolean dreamsSupported = mContext.getResources().getBoolean( com.android.internal.R.bool.config_dreamsSupported); com.android.internal.R.bool.config_dreamsSupported); final boolean dreamsOnlyEnabledForSystemUser = mContext.getResources().getBoolean( final boolean dreamsOnlyEnabledForDockUser = mContext.getResources().getBoolean( com.android.internal.R.bool.config_dreamsOnlyEnabledForSystemUser); com.android.internal.R.bool.config_dreamsOnlyEnabledForDockUser); return dreamsSupported && (!dreamsOnlyEnabledForSystemUser || isSystemUser()); // TODO(b/257333623): Allow the Dock User to be non-SystemUser user in HSUM. return dreamsSupported && (!dreamsOnlyEnabledForDockUser || isSystemUser()); } } @Override @Override Loading