From 8e6f99e22bc69e95647857cce247341061b60b07 Mon Sep 17 00:00:00 2001 From: Amith Yamasani Date: Wed, 24 Apr 2013 14:21:06 -0700 Subject: [PATCH] Rename limited users to restricted profiles Bug: 8705996 Change-Id: Ibf6a2e0e14ce095758fb9be982710b584b76f15d --- res/values/strings.xml | 10 ++++++++-- src/com/android/settings/users/UserSettings.java | 8 ++++++-- 2 files changed, 14 insertions(+), 4 deletions(-) diff --git a/res/values/strings.xml b/res/values/strings.xml index 318df631137..e4244227491 100644 --- a/res/values/strings.xml +++ b/res/values/strings.xml @@ -4369,7 +4369,7 @@ Only the phone\'s owner can manage users. - Limited users cannot add accounts + Restricted profiles cannot add accounts Delete %1$s from this device @@ -4381,6 +4381,8 @@ Delete yourself? Remove user? + + Remove profile? You will lose your space and data on this tablet. You can\'t undo this action. @@ -4389,6 +4391,10 @@ This user\'s space and data will disappear from this tablet. You can\'t undo this action. This user\'s space and data will disappear from this phone. You can\'t undo this action. + + This profile\'s space and data will disappear from this tablet. You can\'t undo this action. + + This profile\'s space and data will disappear from this phone. You can\'t undo this action. Adding new user\u2026 @@ -4468,7 +4474,7 @@ Controlled by %1$s - This app is not supported in limited users + This app is not supported in restricted profiles This app can access your accounts diff --git a/src/com/android/settings/users/UserSettings.java b/src/com/android/settings/users/UserSettings.java index 2fc043eea39..962f7b82619 100644 --- a/src/com/android/settings/users/UserSettings.java +++ b/src/com/android/settings/users/UserSettings.java @@ -383,10 +383,14 @@ public class UserSettings extends SettingsPreferenceFragment Dialog dlg = new AlertDialog.Builder(getActivity()) .setTitle(UserHandle.myUserId() == mRemovingUserId ? R.string.user_confirm_remove_self_title - : R.string.user_confirm_remove_title) + : (mUserManager.getUserInfo(mRemovingUserId).isRestricted() + ? R.string.user_profile_confirm_remove_title + : R.string.user_confirm_remove_title)) .setMessage(UserHandle.myUserId() == mRemovingUserId ? R.string.user_confirm_remove_self_message - : R.string.user_confirm_remove_message) + : (mUserManager.getUserInfo(mRemovingUserId).isRestricted() + ? R.string.user_profile_confirm_remove_message + : R.string.user_confirm_remove_message)) .setPositiveButton(R.string.user_delete_button, new DialogInterface.OnClickListener() { public void onClick(DialogInterface dialog, int which) {