diff options
author | Kenny Guy <kennyguy@google.com> | 2014-04-02 13:29:20 +0100 |
---|---|---|
committer | Kenny Guy <kennyguy@google.com> | 2014-04-02 13:44:50 +0100 |
commit | 2a764949c943681a4d25a17a0b203a0127a4a486 (patch) | |
tree | 5cacb4e3be3f0c47e25f4e98389110310622e4b0 /cmds | |
parent | 30cac644f161433fca92ca65edcb26b351a04e5a (diff) | |
download | frameworks_base-2a764949c943681a4d25a17a0b203a0127a4a486.zip frameworks_base-2a764949c943681a4d25a17a0b203a0127a4a486.tar.gz frameworks_base-2a764949c943681a4d25a17a0b203a0127a4a486.tar.bz2 |
Rename related users to profiles.
Rename the related user concept as profiles.
When returning profiles of a user include the
user as a profile of itself.
Change-Id: Id5d4f29017b7ca6844632ce643f10331ad733e1d
Diffstat (limited to 'cmds')
-rw-r--r-- | cmds/pm/src/com/android/commands/pm/Pm.java | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/cmds/pm/src/com/android/commands/pm/Pm.java b/cmds/pm/src/com/android/commands/pm/Pm.java index f415c85..5454b46 100644 --- a/cmds/pm/src/com/android/commands/pm/Pm.java +++ b/cmds/pm/src/com/android/commands/pm/Pm.java @@ -1033,18 +1033,18 @@ public final class Pm { public void runCreateUser() { String name; - int relatedUserId = -1; + int userId = -1; int flags = 0; String opt; while ((opt = nextOption()) != null) { - if ("--relatedTo".equals(opt)) { + if ("--profileOf".equals(opt)) { String optionData = nextOptionData(); if (optionData == null || !isNumber(optionData)) { System.err.println("Error: no USER_ID specified"); showUsage(); return; } else { - relatedUserId = Integer.parseInt(optionData); + userId = Integer.parseInt(optionData); } } else if ("--managed".equals(opt)) { flags |= UserInfo.FLAG_MANAGED_PROFILE; @@ -1062,14 +1062,14 @@ public final class Pm { name = arg; try { UserInfo info = null; - if (relatedUserId < 0) { + if (userId < 0) { info = mUm.createUser(name, flags); } else { if (Process.myUid() != 0) { System.err.println("Error: not running as root."); return; } - info = mUm.createRelatedUser(name, flags, relatedUserId); + info = mUm.createProfileForUser(name, flags, userId); } if (info != null) { System.out.println("Success: created user id " + info.id); |