Commit Graph

150 Commits

Author SHA1 Message Date
Jason Monk
c1cc9fefa8 Allow clicking on guest user
This is needed since the user switch will be hidden by default in
QS and will show up once multi-user has been activated in some way.

Test: click on guest
Bug: 37152893
Change-Id: I351a5d95e9e8a5e47e388d9f0611924b077754da
2017-06-30 11:29:40 -04:00
Maurice Lam
2eb170cd6f Clean up choose lock intent creation
Consolidated the many variants of ChooseLock*.createIntent, so that
it will take the same set of arguments.

Also modified SetupChooseLock*.createIntent to modifyIntentForSetup,
which will take the intent created by ChooseLock* and modify it for
use with setup.

Test: cd tests/robotests && mma
Change-Id: I5ff033f459c33ec9980872a536b3996d89f2bbbb
2017-05-12 15:35:20 -07:00
Doris Ling
81f22e88f9 Update text for Users & accounts page.
- add back the summary loader for UserSettings
- remove "configure" preference category
- add summary for Auto sync data and update the title

Change-Id: Ia00397f775f86d0e160a54783a8518847fce8de8
Bug: 36540644
Test: builds
2017-03-23 12:56:33 -07:00
Doris Ling
ed0fc506a3 Removed emergency info and add user when locked from Users settings.
In new IA, Emergency Info and Add user when locked has been moved to
Users & accounts page.

Change-Id: I1a1e4bd801936b654d8a4ede7cfc64e2ac285019
Fix: 33703736
Test: make SettingsTests
2017-02-24 12:38:57 -08:00
Fan Zhang
c6ca314c0b Log source with visibility change
- Add a method in VisibilityLoggerMixin to log visible event using
  LogMaker, which allows logging additional FIELD_CONTEXT field.
- In Utils.startFragment, add current page's metricsCategory as an extra
  to next page.
- In next page's onResume(), extract the previous page's metricsCategory
  and send it to VisibilityLoggerMixin.visible()
- Update all caller with additional paramters

Change-Id: I8e1f2597fa465b7d3aa16fa1d21c052a3219694a
Fix: 35359289
Test: RunSettingsRoboTests
2017-02-15 17:17:19 -08:00
Fan Zhang
7520e81ab5 Update top level menu items summary text.
- Use static summary for most items
- Move summary for user setting to user&account setting

Bug: 34975053
Test: RunSettingsRoboTests
Change-Id: I9bf87267778dc5933f97f5d3b9ae0f4f0b8da1a8
2017-02-09 15:22:47 -08:00
Lei Yu
3a21de9349 Merge "Add NPE check for method assignDefaultPhoto in Utils.java" 2016-12-28 22:28:10 +00:00
jackqdyulei
8164c64edc Add NPE check for method assignDefaultPhoto in Utils.java
When user press back button while adding user, app may crash because
of null context. In this cl, I add NPE check for context in method
assignDefaultPhoto and change this method to return boolean value.
If the return value is false, then stop the following steps(e.g.
creating a dialog after pressing button may also cause crash.)

Bug: 33829308
Test: make -j40 RunSettingsRoboTests
Change-Id: I811b92c268fb20f8c43ab3b0a9ceebe76f5d83be
2016-12-28 11:30:54 -08:00
Doris Ling
34a4c804f8 Removed emergency info and add user when locked from Users settings.
If new IA is enabled,  Emergency Info and Add user when locked has been moved to
Users & accounts page, so Users page should not show them.

Also fix the issue that update for the add user when locked switch does
not persist correctly.

Change-Id: I26d9f59d0f4bf3fd36a7d07d13f95127b40a8a3e
Fix: 33703736
Test: make RunSettingsRoboTests
2016-12-27 16:35:22 -08:00
Sudheer Shanka
acb1a61f3f Update usage of ActivityManagerNative.
Bug: 30977067
Test: N/A
Change-Id: I46e37a09cff059d2784a819bc2651d6973fbd268
2016-11-14 12:59:11 -08:00
Tamas Berghammer
265d3c2a0c Update package names to work with the proto3 compiler
Bug: b/28974522
Change-Id: I5f3adf4946ee4ba1e09e4f40afe83c151405972a
2016-11-08 14:06:17 +00:00
Doris Ling
86e1df9bd9 Add Auto sync account data to account dashboard.
Add auto sync to User & accounts dashboard, and update
UserSettings to use the emergency info and add user when locked
controllers.

Test: RunSettingsRoboTests
Bug: 31801423
Change-Id: Ibf5a886276a9aa8f53c548036aecfd6c4d759ae3
2016-11-01 11:28:36 -07:00
Doris Ling
c7e2ed8e79 Add Emergency info and Add user when locked to account dashboard.
Add two items to User & accounts dashboard, and refractor
UserCapabilities so that it can be accessed in the new controller.

Test: RunSettingsRoboTests
Bug: 31801423
Change-Id: Ib446ad6c99d4cc6405a17cf82d2d86e044870b73
2016-10-27 15:48:52 -07:00
Fan Zhang
66b573ad5a Add display settings dashboard to new IA.
- 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
2016-10-10 18:26:29 -07:00
Stephen Chen
94d0b1674c Fix icon loading in EditUserInfo dialog on orientation change.
UserSettings loads icons asynchronously, so an incorrect icon is loaded
on orientation change.

Bug: 30088727
Change-Id: I29b15ede4f7c3ca7e67b035a086271eccd075426
Fixes: 30088727
Test: Visual inspection
2016-10-05 18:06:03 -07:00
Fan Zhang
d65184faef Log visibility change for DialogCreatable in Settings.
Bug: 30681529
Test: adb logcat -b events | egrep "(sysui_|notification_)"
Test: make RunSettingsRoboTests
Change-Id: I51754d258ba1ddfae24323681f21cd02de4dbb4e
2016-09-21 16:30:32 -07:00
Maurice Lam
0b9da48d9f Merge "Position fingerprint progress in the center on landscape" into nyc-mr1-dev am: 497704a2cf am: b62638e83b
am: ce6a2356ad

Change-Id: I3c0a875966275473a8d411ca444e29fae22c7357
2016-08-24 16:16:50 +00:00
Yoshinori Hirano
9224414477 Show summary of "Add user" item
am: 2ce843b00e

Change-Id: I413ab13bbf58b7100348d20c02aeeff850a84639
2016-08-23 23:25:05 +00:00
Fan Zhang
6507613ebc Log visibility change for all fragments.
Bug: 30681771
Test: SettingsUnitTests

Refactor visibility logging from InstrumentedFragment into a mixin. And
apply mixin in remaining fragments.

Change-Id: Ibbb59904336254a3e4bb9e8c7d0b36e5a6bc2622
2016-08-18 14:04:13 -07:00
Yoshinori Hirano
2ce843b00e Show summary of "Add user" item
The summary of "Add user" item is not displayed.
To show it, useAdminDisabledSummary should be false.

Bug: 30005296
Change-Id: Ia33cab4d671f42bd971acbf5523da1c4d21948e1
2016-07-22 20:09:28 +00:00
Jason Monk
01333561c1 Merge \\\"Pre-setup restrictions\\\" into nyc-dev am: 5a3d1c17f2 am: 69ce586155
am: ef7473f012

Change-Id: Ib55e973570b0fd439f26c39d273d273d7808e2a1
2016-07-19 20:59:10 +00:00
Jason Monk
69ce586155 Merge \"Pre-setup restrictions\" into nyc-dev
am: 5a3d1c17f2

Change-Id: I0bc7e426b0dfc4d233b9caa263e5361f94dbf6f2
2016-07-19 20:39:18 +00:00
Jason Monk
fab3a5ba85 Pre-setup restrictions
- Don't let user settings run

Bug: 29194585
Change-Id: Ia9c46c7ba04ce2809304bebe8a4c5cdac2108611
2016-06-30 13:16:20 -04:00
mariagpuyol
376265b967 Make Emergency info searchable in Settings am: 6056eba0e7
am: eb086f075e

Change-Id: Ib1bdfce801a0efae131779df7b6b907760dedf47
2016-06-24 17:27:54 +00:00
mariagpuyol
6056eba0e7 Make Emergency info searchable in Settings
Bug:27925442
Change-Id: I1318592b09f7cf1daf538edd02321cb6557b289e
2016-06-24 16:42:11 +00:00
Sudheer Shanka
29056b98f8 Make guest field unselectable only if it is not disabled by admin.
Change-Id: I01c45b686477615134e98428b673fe9bb2ab7b0b
Fixes: 29178926
2016-06-14 18:07:15 +00:00
Fyodor Kupolov
77865ec827 Make prefs without an action unselectable
Setting selectable=false is required for proper A11y. Otherwise Talkback
will inform the user that the item can be activated.

Bug: 29025567
Change-Id: I2b61c622c2d69fa83640f7822349613f51f849d5
2016-06-02 10:39:33 -07:00
Julia Reynolds
8bda21a9d4 Fix NPE in user settings.
Bug: 28337026
Change-Id: I437874e8dd605b9a19318aafecf292303ee3ad58
2016-04-29 08:42:01 -04:00
Sudheer Shanka
71caf698b4 Set user icon to default when updating profile without photo
If the user photo was deleted in the Myself contact, the change
was not reflected neither in Settings/Users nor in expanded
status bar. This was because the ProfileUpdateReceiver did not
handle the case where the updated image was null (deleted).
Fixed by assigning default user icon in UserManager if no photo
found in the profile update.

AOSP change: https://android-review.googlesource.com/#/c/153137

Bug: 28031914
Change-Id: I2f452f78dcf777414f50b133b1a9cee334bbd9a8
2016-04-14 16:56:15 -07:00
Udam Saini
e20deea711 Merge "Prevents users from being added if device is not provisioned" into nyc-dev 2016-03-31 20:13:40 +00:00
mariagpuyol
6ca8940880 Use same task for Settings>Users and EmergencyInfo
Bug:27859534
Change-Id: I0ea4e56e4f6daacfd478336444aceeb84d8bfe5d
2016-03-30 18:21:48 -07:00
Fyodor Kupolov
5b469f6a73 Merge "Disable Add user until Setup prompt is shown" into nyc-dev 2016-03-29 16:45:59 +00:00
Fyodor Kupolov
fe6cb6dac7 Disable Add user until Setup prompt is shown
Bug: 27848426
Change-Id: Ibbc0ac0aad8298252dfc460a10a87955fc3e713d
2016-03-28 16:44:51 -07:00
mariagpuyol
bd5c83f8b9 Add flags to emergency info intent
Bug:27859534
Change-Id: I3ff0aea7b0115a22c0a4a853d8fc83a7ae7adc20
2016-03-28 14:49:38 -07:00
Udam Saini
679f7ad07e Prevents users from being added if device is not provisioned
Also added a utility function for checking provisioning, instead of
repeating code for this check in several places.

bug:26156445
Change-Id: I9f4a280dd0cdf889f892e386dbf6a3fdb2a052ef
2016-03-25 13:33:57 -07:00
Sudheer Shanka
b5c92147ce Add more policy transparency for disallow_remove_user restriction.
Bug: 27784015
Change-Id: I2386efbf521ee8e73326006e78b0146341745e2b
2016-03-22 17:24:07 -07:00
Maria Garcia Puyol
c35b08b4b3 Merge "Revert "Dialog for emergency info"" into nyc-dev 2016-03-18 15:06:02 +00:00
Maria Garcia Puyol
da497f26d7 Revert "Dialog for emergency info"
This reverts commit ae49edbdfd.

Change-Id: I01a4b5966b380d967588bd0411e80d6bcd431fd1
2016-03-17 22:52:44 +00:00
Sudheer Shanka
f6c5128763 Merge "Update user capabilities in onResume." into nyc-dev 2016-03-15 23:32:26 +00:00
Sudheer Shanka
aa524ae581 Update user capabilities in onResume.
Bug: 27641648
Change-Id: I85a6362a20885defa450760a3fbb16e124630434
2016-03-14 17:23:13 -07:00
mariagpuyol
ae49edbdfd Dialog for emergency info
Bug:27621394
Change-Id: I894f5526d05c84eec81e9fe87a105f466195073d
2016-03-11 21:06:23 -08:00
Fyodor Kupolov
8c9120b9cc First time populate user list in onCreate
Call updateUserList from onCreate instead of onResume during initialization.
This will suppress unnecessary animations.

Bug: 27527929

Change-Id: Ia420f41894b2033fb7f02de01168ccd2c6331588
2016-03-07 13:08:49 -08:00
Fyodor Kupolov
52ae05314d Do not allow removing current user if it's in a call
Bug: 20652663
Change-Id: I2eb91bc73259e25b3fa68337df2a0576a438244a
2016-02-24 15:56:13 -08:00
Sudheer Shanka
29737ad910 Part2 - Don't add padlock if the restriction is not set by admin.
Bug: 26687435
Change-Id: I85ef42e1ff1216791d1393a975e8559191b3781f
2016-02-19 19:24:34 +00:00
mariagpuyol
fe19bc3d4b Show emergency info preference for all users
Change-Id: I8bfcedb8a15c9ca0194f5f526dd288857c19a1de
2016-02-18 10:27:41 -08:00
Fyodor Kupolov
889bc3de82 Remove switching from Users menu
Bug: 26562786
Change-Id: Id0f26621b8356c3161dee861b0215b01d48007c9
2016-02-16 13:38:34 -08:00
mariagpuyol
60435fc81d Add Emergency Info preference to user settings
Bug: 26831671
Change-Id: I345fc9b9a54991de35c657e05cf3f08f21445f4c
2016-01-28 15:04:32 -08:00
Daniel Sandler
ba9b20dae0 Merge "Revert "Add Emergency Info preference to user settings"" 2016-01-28 14:24:14 +00:00
Daniel Sandler
0def4c45b2 Revert "Add Emergency Info preference to user settings"
This reverts commit 0401388028.

Bug: 26831671
Change-Id: Ibe5ae3c7da400efb389f905b1111f029b6a8bfaf
2016-01-28 03:30:08 +00:00
Chris Wren
9d1bfd1e8d port settings over to new metrics enum
Change-Id: I0b3efd2f4db773ccbc52bfe59ee8eb0dab9584fb
2016-01-27 10:58:58 -05:00