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
On devices where non-system users are not allowed to dream, disable the
screen saver setting when the current user is not the system user.
Bug: 213906883
Test: atest ScreenSaverPreferenceControllerTest
Test: Manually with the following steps:
Step 1: On a device with the config setting
config_dreamsOnlyEnabledForSystemUser set to false, make sure that
non-system users can still access the screen saver setting.
Step 2: On a device with the config setting
config_dreamsOnlyEnabledForSystemUser setting is set to true, make sure
that non-system users can not access (or see) the screen saver setting.
Step 3: Make sure that system users can still see the screen saver
setting on a device where config_dreamsOnlyEnabledForSystemUser is set
to true.
Change-Id: I7e167ed5a1ea183c725ba89a57b8d0b372064b82
Having consistent import order will reduce chance of merge
conflict between internal and external master
Test: rebuild
Change-Id: I0b1a170967ddcce7f388603fd521f6ed1eeba30b
Reworked the way screensaver settings are laid out for O. Instead of
using the options menu and dialogs to navigate screensaver options,
there are now two rows: one row for the screensaver choice and
optionally its own settings, and one row for the "when to show" setting.
And now there's a nice obvious button you can press to preview your
choices.
Test: 'export ROBOTEST_FILTER="RadioButtonListFragmentTest";\
mmm -j20 packages/apps/Settings/tests/robotests'
Bug: 35031991
Change-Id: Ie7d2055fb45f6dfe72e34cb9598d9a25f7bee75a
When updating preferences managed through PreferenceController, the
fragment should skip prefs that are not available.
Bug: 32255863
Test: RunSettingsRoboTests
Change-Id: I2f9b6ddf8c78d40068dc18f07e60672dcba4474a
- Add a ProgressiveDisclosureMixin that contains all logic for collapse
preference list when it's too long
- Refactored PreferenceController's updateState to take a preference
instead of PreferenceScreen, because with progressive disclosure the
preference can either be in screen or the mixin. DashboardFragment is
responsible finding the preference before passing it to controller.
Bug: 32255863
Test: RunSettingsRoboTests
Change-Id: I6713abd61c954ce12732902e5b3ca4d4c0b1563e
- Added a activity-alias pointing to displaySettings as top level
setting item.
- Refactored all preference logic in DisplaySettings into
PreferenceControllers. During fragment onAttach it installs all
controllers, and during onResume it updates preference state. Each
controller listens to its own preference change event.
Bug: 31800242
Test: RunSettingsRoboTests
Change-Id: Ibc9bf200c5acce7c4ae9292340822afee27a3a28