Add changes lost in I467a8b4fa5cc610c3e1627f30631a55ecd6c91c1
This allows contacts to be created in a null device account without showing the
account chooser. It also shows the correct title in the action bar when viewing
device accounts.
Change-Id: I3ee096d1ed70d544fd719e930dcb49953c162eb3
diff --git a/src/com/android/contacts/activities/CompactContactEditorActivity.java b/src/com/android/contacts/activities/CompactContactEditorActivity.java
index f8c9c5c..3778400 100644
--- a/src/com/android/contacts/activities/CompactContactEditorActivity.java
+++ b/src/com/android/contacts/activities/CompactContactEditorActivity.java
@@ -64,6 +64,15 @@
// 3 used for ContactDeletionInteraction.RESULT_CODE_DELETED
public static final int RESULT_CODE_EDITED = 4;
+ /**
+ * The contact will be saved to the device local account when this is set for an insert. This
+ * is necessary because {@link android.accounts.Account} cannot be created with null values
+ * for the name and type and an Account is needed for
+ * {@link android.provider.ContactsContract.Intents.Insert#EXTRA_ACCOUNT}
+ */
+ public static final String EXTRA_SAVE_TO_DEVICE_FLAG =
+ "com.android.contacts.SAVE_TO_DEVICE_FLAG";
+
private static final String TAG_COMPACT_EDITOR = "compact_editor";
private static final String TAG_PHOTO_SELECTION = "photo_selector";