From da497f26d747038b53caf71a05c72ebf591bbdf0 Mon Sep 17 00:00:00 2001 From: Maria Garcia Puyol Date: Thu, 17 Mar 2016 22:52:44 +0000 Subject: [PATCH] Revert "Dialog for emergency info" This reverts commit ae49edbdfd79c3ccc2ae135690a35f4d57c8aaed. Change-Id: I01a4b5966b380d967588bd0411e80d6bcd431fd1 --- res/values/strings.xml | 6 ++---- res/xml/user_settings.xml | 3 ++- .../android/settings/users/UserSettings.java | 20 ++----------------- 3 files changed, 6 insertions(+), 23 deletions(-) diff --git a/res/values/strings.xml b/res/values/strings.xml index 53b0c92ee9f..4992d6b316d 100644 --- a/res/values/strings.xml +++ b/res/values/strings.xml @@ -5388,10 +5388,6 @@ All apps and data in this session will be deleted. Remove - - Information you enter here can help first responders in an emergency. It is stored on your device only, but anyone can read it from the emergency dialer without unlocking your phone. - - Continue Turn on phone calls @@ -5409,6 +5405,8 @@ Call and SMS history will be shared with this user. Emergency information + + Accessible by anyone from the emergency dialer without unlocking your phone Allow apps and content diff --git a/res/xml/user_settings.xml b/res/xml/user_settings.xml index b89f7668eaf..8d20f31d90a 100644 --- a/res/xml/user_settings.xml +++ b/res/xml/user_settings.xml @@ -38,5 +38,6 @@ + android:title="@string/emergency_info_title" + android:summary="@string/emergency_info_subtitle"/> diff --git a/src/com/android/settings/users/UserSettings.java b/src/com/android/settings/users/UserSettings.java index 8e3dccf6371..4b060a0dc61 100644 --- a/src/com/android/settings/users/UserSettings.java +++ b/src/com/android/settings/users/UserSettings.java @@ -115,7 +115,6 @@ public class UserSettings extends SettingsPreferenceFragment private static final int DIALOG_NEED_LOCKSCREEN = 7; private static final int DIALOG_CONFIRM_EXIT_GUEST = 8; private static final int DIALOG_USER_PROFILE_EDITOR = 9; - private static final int DIALOG_EMERGENCY_INFO_CONSENT = 10; private static final int MESSAGE_UPDATE_LIST = 1; private static final int MESSAGE_SETUP_USER = 2; @@ -609,22 +608,6 @@ public class UserSettings extends SettingsPreferenceFragment android.os.Process.myUserHandle()); return dlg; } - case DIALOG_EMERGENCY_INFO_CONSENT : { - Dialog dlg = new AlertDialog.Builder(context) - .setTitle(R.string.emergency_info_title) - .setMessage(R.string.user_emergency_info_consent) - .setPositiveButton(R.string.emergency_info_continue, - new DialogInterface.OnClickListener() { - @Override - public void onClick(DialogInterface dialog, int which) { - Intent intent = new Intent(ACTION_EDIT_EMERGENCY_INFO); - startActivity(intent); - } - }) - .setNegativeButton(android.R.string.cancel, null) - .create(); - return dlg; - } default: return null; } @@ -963,7 +946,8 @@ public class UserSettings extends SettingsPreferenceFragment onAddUserClicked(USER_TYPE_USER); } } else if (pref == mEmergencyInfoPreference) { - showDialog(DIALOG_EMERGENCY_INFO_CONSENT); + Intent intent = new Intent(ACTION_EDIT_EMERGENCY_INFO); + startActivity(intent); } return false; }