Settings screen should apply both primary and managed maximum
timeout policy, even separate profile challenge is enabled.
Bug: 27493348
Change-Id: Ia1ec1cafc7665c54816833af64e0f446a77a55b2
- Split per user version of getUserRestrictions into a separate method
in DPMS and make the per-user version return null if the admin
parameter is not a valid one.
- Update isAccessibilityServicePermittedByAdmin and
isInputMethodPermittedByAdmin to return false if the admin parameter
is not a valid one.
Bug: 27909087
Change-Id: I6f4cae6552cbfe02dc4a92b04eeeddf0314e0974
* renamed getPackageSuspended => isPackageSuspended
* does not return false for an error, instead throws
NameNotFoundException if the package could not be
found, or if there is an unknown RemoteException,
wraps it in a RuntimeException and rethrows.
Bug: 27532430
Bug: 22776761
Change-Id: Iee00600089b1c0556a3312b10456826464fa8f9f
Instead of always rebuilding the full ApplicationInfo for a
package when callers are only interested in the suspended status
add a new fast API in Packagemanager (which only checks the
suspended user setting for the requested package and returns
a boolean) and change the appropriate caller code too.
Bug: 26794775
Bug: 22776761
Change-Id: Ide8428ef734479360d5a8a75fd8e0ed8ddf2da7a
Add isInputMethodPermittedByAdmin and
isAccessibilityServicePermittedByAdmin APIs in DevicePolicyManager.
And update utility methods in RestrictedLockUtils to use the correct
userId when checking if disabled by admin.
Bug: 26897250
Bug: 26767564
Bug: 26966213
Change-Id: I0b74b3e57904a82f8ce72d856769d35b5e8403e5
Currently, it can be only used for checking the status of keyguard
notification features, made it generic so that it can be used for
other keyguard features like disable_fingerprint etc.
Change-Id: Ib2adfc12d7866cce248af78cc8b159cada9a6cad
Added util method checkIfMaximumTimeToLockIsSet in RestrictedLockUtils
to get the admin who set maximum time to lock. Also, made a few updates
to the javadocs of other methods.
Change-Id: Ide3048b277f854360aa92d975963b61dff2387bb
- This check is broken when there are no Admins on the device.
- Blocks enabling NotificationListenerServices in Settings.
Change-Id: I2c30daf2fc4632d55e84f0e499e3ceedbe162b98
When adding the padlock, a space is appended to the string which needs
to removed along with the padlock. And added more utility methods in
RestrictedLockUtils.
Change-Id: I33f976db23bfdd39d76c4201be0727bfafb00fd4
Added an utility method checkIfUninstallBlocked in
RestrictedLockUtils. Also updated setMenuItemAsDisabledByAdmin
to be able to remove the added padlock and color spans.
Change-Id: I7874f7097d09bc9ab127307f2a8a03a20560347c