Merge "Import translations. DO NOT MERGE"
diff --git a/src/com/android/mail/ui/AbstractActivityController.java b/src/com/android/mail/ui/AbstractActivityController.java
index f1bf4ef..8a6f79e 100644
--- a/src/com/android/mail/ui/AbstractActivityController.java
+++ b/src/com/android/mail/ui/AbstractActivityController.java
@@ -66,7 +66,6 @@
import com.android.mail.providers.UIProvider.AutoAdvance;
import com.android.mail.providers.UIProvider.ConversationColumns;
import com.android.mail.providers.UIProvider.FolderCapabilities;
-import com.android.mail.ui.ViewMode.ModeChangeListener;
import com.android.mail.utils.LogUtils;
import com.android.mail.utils.Utils;
import com.google.common.collect.ImmutableList;
@@ -100,11 +99,14 @@
public abstract class AbstractActivityController implements ActivityController,
ConversationListener, OnScrollListener {
// Keys for serialization of various information in Bundles.
+ /** Tag for {@link #mAccount} */
private static final String SAVED_ACCOUNT = "saved-account";
+ /** Tag for {@link #mFolder} */
private static final String SAVED_FOLDER = "saved-folder";
+ /** Tag for {@link #mCurrentConversation} */
private static final String SAVED_CONVERSATION = "saved-conversation";
- // Batch conversations stored in the Bundle using this key.
- private static final String SAVED_CONVERSATIONS = "saved-conversations";
+ /** Tag for {@link #mSelectedSet} */
+ private static final String SAVED_SELECTED_SET = "saved-selected-set";
/** Tag used when loading a wait fragment */
protected static final String TAG_WAIT = "wait-fragment";
@@ -772,7 +774,7 @@
outState.putParcelable(SAVED_CONVERSATION, mCurrentConversation);
}
if (!mSelectedSet.isEmpty()) {
- outState.putParcelable(SAVED_CONVERSATIONS, mSelectedSet);
+ outState.putParcelable(SAVED_SELECTED_SET, mSelectedSet);
}
}
@@ -959,16 +961,12 @@
mSelectedSet.clear();
return;
}
- final ConversationSelectionSet selectedSet = savedState.getParcelable(SAVED_CONVERSATIONS);
+ final ConversationSelectionSet selectedSet = savedState.getParcelable(SAVED_SELECTED_SET);
if (selectedSet == null || selectedSet.isEmpty()) {
mSelectedSet.clear();
return;
}
-
- // putAll will take care of calling our registered onSetPopulated method
- // FIXME: disabled until we correctly handle selection set bringup when list fragment
- // does not yet exist (b/6268401)
- //mSelectedSet.putAll(selectedSet);
+ mSelectedSet.putAll(selectedSet);
}
@Override
diff --git a/src/com/android/mail/ui/ConversationSelectionSet.java b/src/com/android/mail/ui/ConversationSelectionSet.java
index d6b61bb..84c8d8d 100644
--- a/src/com/android/mail/ui/ConversationSelectionSet.java
+++ b/src/com/android/mail/ui/ConversationSelectionSet.java
@@ -225,7 +225,12 @@
return mInternalMap.values();
}
- /** @see java.util.HashMap#putAll(java.util.Map) */
+ /**
+ * Puts all conversations given in the input argument into the selection set. If there are
+ * any listeners they are notified once after adding <em>all</em> conversations to the selection
+ * set.
+ * @see java.util.HashMap#putAll(java.util.Map)
+ */
public void putAll(ConversationSelectionSet other) {
if (other == null) {
return;