diff --git a/src/com/fsck/k9/activity/MessageList.java b/src/com/fsck/k9/activity/MessageList.java index 30c99fd68..276e4f95d 100644 --- a/src/com/fsck/k9/activity/MessageList.java +++ b/src/com/fsck/k9/activity/MessageList.java @@ -978,7 +978,8 @@ public class MessageList extends K9FragmentActivity implements MessageListFragme menu.findItem(R.id.search).setVisible(false); menu.findItem(R.id.search_remote).setVisible(false); - if (mDisplayMode == DisplayMode.MESSAGE_VIEW || mMessageListFragment == null) { + if (mDisplayMode == DisplayMode.MESSAGE_VIEW || mMessageListFragment == null || + !mMessageListFragment.isInitialized()) { menu.findItem(R.id.check_mail).setVisible(false); menu.findItem(R.id.set_sort).setVisible(false); menu.findItem(R.id.select_all).setVisible(false); diff --git a/src/com/fsck/k9/fragment/MessageListFragment.java b/src/com/fsck/k9/fragment/MessageListFragment.java index e1ba5a831..3334721fe 100644 --- a/src/com/fsck/k9/fragment/MessageListFragment.java +++ b/src/com/fsck/k9/fragment/MessageListFragment.java @@ -920,7 +920,6 @@ public class MessageListFragment extends SherlockFragment implements OnItemClick updateFooterView(); } - mController = MessagingController.getInstance(getActivity().getApplication()); mListView.setAdapter(mAdapter); } @@ -3349,4 +3348,8 @@ public class MessageListFragment extends SherlockFragment implements OnItemClick public boolean isSingleFolderMode() { return mSingleFolderMode; } + + public boolean isInitialized() { + return mInitialized; + } }