summaryrefslogtreecommitdiffstats
path: root/packages/SystemUI/src
diff options
context:
space:
mode:
authorGuang Zhu <guangzhu@google.com>2014-10-22 20:45:55 +0000
committerAndroid Git Automerger <android-git-automerger@android.com>2014-10-22 20:45:55 +0000
commit871cdeebdaf9469c97959d90c12e36140bb14f4a (patch)
tree4d4e7898a61d7fd3b8747a3cce21038ab7b3f483 /packages/SystemUI/src
parent96d3132bd0c57fbf8bb46624045fa1616452d346 (diff)
parent55bc7dc4288e2c2cdd0bd9c2d06c38e00d139d5c (diff)
downloadframeworks_base-871cdeebdaf9469c97959d90c12e36140bb14f4a.zip
frameworks_base-871cdeebdaf9469c97959d90c12e36140bb14f4a.tar.gz
frameworks_base-871cdeebdaf9469c97959d90c12e36140bb14f4a.tar.bz2
am 55bc7dc4: am ccbeb61a: Block monkey from creating user profiles
* commit '55bc7dc4288e2c2cdd0bd9c2d06c38e00d139d5c': Block monkey from creating user profiles
Diffstat (limited to 'packages/SystemUI/src')
-rw-r--r--packages/SystemUI/src/com/android/systemui/statusbar/policy/UserSwitcherController.java3
1 files changed, 3 insertions, 0 deletions
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/policy/UserSwitcherController.java b/packages/SystemUI/src/com/android/systemui/statusbar/policy/UserSwitcherController.java
index eb808c2..5c7909a 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/policy/UserSwitcherController.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/policy/UserSwitcherController.java
@@ -571,6 +571,9 @@ public class UserSwitcherController {
cancel();
} else {
dismiss();
+ if (ActivityManager.isUserAMonkey()) {
+ return;
+ }
UserInfo user = mUserManager.createSecondaryUser(
mContext.getString(R.string.user_new_user_name), 0 /* flags */);
if (user == null) {