Introduce concept of DockUser

Dreams and docking often refers to "user zero" or "system user".
But more generally, the special user for dreams or switching-to-on-docking
need not be user 0, and in fact won't be in certain modes. So this needs updating.

Test: the files mentioned in the topic
Bug: 257333623
Change-Id: If068aa79a770bed4abf3f7ca1859a95cd1eb4ecd
Merged-In: If068aa79a770bed4abf3f7ca1859a95cd1eb4ecd
This commit is contained in:
Adam Bookatz
2022-11-07 10:51:01 -08:00
parent e4b09e55ca
commit e5e232428d
11 changed files with 63 additions and 60 deletions

View File

@@ -1623,15 +1623,15 @@
<item>1</item>
</string-array>
<!-- Setting entries for timing out to user 0 when docked. -->
<string-array name="switch_to_user_zero_when_docked_timeout_entries">
<!-- Setting entries for timing out to the Dock User when docked. -->
<string-array name="switch_to_dock_user_when_docked_timeout_entries">
<item>Never</item>
<item>After 1 minute</item>
<item>After 5 minutes</item>
</string-array>
<!-- Setting values for timing out to user 0 when docked. [DO NOT TRANSLATE] -->
<string-array name="switch_to_user_zero_when_docked_timeout_values" translatable="false">
<!-- Setting values for timing out to the Dock User when docked. [DO NOT TRANSLATE] -->
<string-array name="switch_to_dock_user_when_docked_timeout_values" translatable="false">
<!-- Never -->
<item>0</item>
<!-- 1 minute -->

View File

@@ -7890,9 +7890,10 @@
<string name="user_lockscreen_settings">Lock screen settings</string>
<!-- 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>
<!-- 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] -->
<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] -->
<string name="user_confirm_remove_self_title">Delete yourself?</string>