Treating Join request as a regular save/reload.
Bug: 3362504
Change-Id: I5b5d97ed07c25e3a349d47b812efeb113d52a685
diff --git a/src/com/android/contacts/editor/ContactEditorFragment.java b/src/com/android/contacts/editor/ContactEditorFragment.java
index ea9506d..2ab897d 100644
--- a/src/com/android/contacts/editor/ContactEditorFragment.java
+++ b/src/com/android/contacts/editor/ContactEditorFragment.java
@@ -874,6 +874,7 @@
saveMode == SaveMode.HOME);
break;
case SaveMode.RELOAD:
+ case SaveMode.JOIN:
if (success && contactLookupUri != null) {
// If this was in INSERT, we are changing into an EDIT now.
// If it already was an EDIT, we are changing to the new Uri now
@@ -881,6 +882,11 @@
load(Intent.ACTION_EDIT, contactLookupUri, null);
mStatus = Status.LOADING;
getLoaderManager().restartLoader(LOADER_DATA, null, mDataLoaderListener);
+
+ // If it was a JOIN, we are now ready to bring up the join activity.
+ if (saveMode == SaveMode.JOIN) {
+ showJoinAggregateActivity(contactLookupUri);
+ }
}
break;
case SaveMode.SPLIT:
@@ -892,14 +898,6 @@
}
mStatus = Status.EDITING;
break;
-
- case SaveMode.JOIN:
- setEnabled(true);
- if (success) {
- showJoinAggregateActivity(contactLookupUri);
- }
- mStatus = Status.EDITING;
- break;
}
}
diff --git a/src/com/android/contacts/widget/IndexerListAdapter.java b/src/com/android/contacts/widget/IndexerListAdapter.java
index d264254..4cd7af0 100644
--- a/src/com/android/contacts/widget/IndexerListAdapter.java
+++ b/src/com/android/contacts/widget/IndexerListAdapter.java
@@ -20,7 +20,6 @@
import android.view.ViewGroup;
import android.widget.ListView;
import android.widget.SectionIndexer;
-import android.widget.TextView;
/**
* A list adapter that supports section indexer and a pinned header.