mirror of
https://github.com/moparisthebest/k-9
synced 2024-12-24 08:38:51 -05:00
Split out a "clear the current message view" method
This commit is contained in:
parent
a3793ac651
commit
98f3909ecc
@ -583,14 +583,7 @@ public class MessageView extends K9Activity implements OnClickListener {
|
||||
if (K9.DEBUG)
|
||||
Log.d(K9.LOG_TAG, "MessageView displaying message " + mMessageReference);
|
||||
mAccount = Preferences.getPreferences(this).getAccount(mMessageReference.accountUuid);
|
||||
mTopView.setVisibility(View.GONE);
|
||||
mTopView.scrollTo(0, 0);
|
||||
mMessageContentView.scrollTo(0, 0);
|
||||
mHeaderContainer.setVisibility(View.GONE);
|
||||
|
||||
mMessageContentView.clearView();
|
||||
setLoadPictures(false);
|
||||
mAttachments.removeAllViews();
|
||||
clearMessageDisplay();
|
||||
findSurroundingMessagesUid();
|
||||
// start with fresh, empty PGP data
|
||||
mCryptoView.setCryptoData(null);
|
||||
@ -604,6 +597,17 @@ public class MessageView extends K9Activity implements OnClickListener {
|
||||
setupDisplayMessageButtons();
|
||||
}
|
||||
|
||||
private void clearMessageDisplay() {
|
||||
mTopView.setVisibility(View.GONE);
|
||||
mTopView.scrollTo(0, 0);
|
||||
mMessageContentView.scrollTo(0, 0);
|
||||
mHeaderContainer.setVisibility(View.GONE);
|
||||
|
||||
mMessageContentView.clearView();
|
||||
setLoadPictures(false);
|
||||
mAttachments.removeAllViews();
|
||||
}
|
||||
|
||||
private void setupDisplayMessageButtons() {
|
||||
mDelete.setEnabled(true);
|
||||
next.setEnabled(mNextMessage != null);
|
||||
|
Loading…
Reference in New Issue
Block a user