Ask the user to unlock the work profile before adding a work account.

If the work profile is locked, and the user tries to add a
work account from Settings:
Show the work profile security challenge.

BUG:28005200
Change-Id: I87ff25d9de94026b0d7ac307ea3a541e77989aa6
This commit is contained in:
Nicolas Prevot
2016-04-06 11:19:08 +01:00
parent 6452b84763
commit a599c8fd04
2 changed files with 35 additions and 14 deletions

View File

@@ -88,8 +88,8 @@ public final class ChooseLockSettingsHelper {
* @return true if one exists and we launched an activity to confirm it
* @see Activity#onActivityResult(int, int, android.content.Intent)
*/
boolean launchConfirmationActivity(int request, CharSequence title, boolean returnCredentials,
int userId) {
public boolean launchConfirmationActivity(int request, CharSequence title,
boolean returnCredentials, int userId) {
return launchConfirmationActivity(request, title, null, null,
returnCredentials, false, false, 0, Utils.enforceSameOwner(mActivity, userId));
}