1
0
mirror of https://github.com/moparisthebest/k-9 synced 2024-12-25 00:58:50 -05:00

Added mInboxFolderName and mOutboxFolderName fields

This commit is contained in:
bitblaster 2011-04-05 02:08:10 -07:00 committed by Jesse Vincent
parent 0174988d27
commit 50b906aef7

View File

@ -80,11 +80,13 @@ public class Account implements BaseAccount {
private long mLatestOldMessageSeenTime;
private boolean mNotifyNewMail;
private boolean mNotifySelfNewMail;
private String mInboxFolderName;
private String mDraftsFolderName;
private String mSentFolderName;
private String mTrashFolderName;
private String mArchiveFolderName;
private String mSpamFolderName;
private String mOutboxFolderName;
private String mAutoExpandFolderName;
private FolderMode mFolderDisplayMode;
private FolderMode mFolderSyncMode;
@ -180,7 +182,8 @@ public class Account implements BaseAccount {
mEnableMoveButtons = false;
mIsSignatureBeforeQuotedText = false;
mExpungePolicy = EXPUNGE_IMMEDIATELY;
mAutoExpandFolderName = "INBOX";
mAutoExpandFolderName = K9.INBOX;
mInboxFolderName = K9.INBOX;
mMaxPushFolders = 10;
mChipColor = (new Random()).nextInt(0xffffff) + 0xff000000;
goToUnreadMessageSearch = false;
@ -246,11 +249,13 @@ public class Account implements BaseAccount {
mNotifySelfNewMail = prefs.getBoolean(mUuid + ".notifySelfNewMail", true);
mNotifySync = prefs.getBoolean(mUuid + ".notifyMailCheck", false);
mDeletePolicy = prefs.getInt(mUuid + ".deletePolicy", 0);
mInboxFolderName = prefs.getString(mUuid + ".inboxFolderName", K9.INBOX);
mDraftsFolderName = prefs.getString(mUuid + ".draftsFolderName", "Drafts");
mSentFolderName = prefs.getString(mUuid + ".sentFolderName", "Sent");
mTrashFolderName = prefs.getString(mUuid + ".trashFolderName", "Trash");
mArchiveFolderName = prefs.getString(mUuid + ".archiveFolderName", "Archive");
mSpamFolderName = prefs.getString(mUuid + ".spamFolderName", "Spam");
mOutboxFolderName = prefs.getString(mUuid + ".outboxFolderName", "Outbox");
mExpungePolicy = prefs.getString(mUuid + ".expungePolicy", EXPUNGE_IMMEDIATELY);
mSyncRemoteDeletions = prefs.getBoolean(mUuid + ".syncRemoteDeletions", true);
@ -270,8 +275,7 @@ public class Account implements BaseAccount {
compressionMap.put(type, useCompression);
}
mAutoExpandFolderName = prefs.getString(mUuid + ".autoExpandFolderName",
"INBOX");
mAutoExpandFolderName = prefs.getString(mUuid + ".autoExpandFolderName", K9.INBOX);
mAccountNumber = prefs.getInt(mUuid + ".accountNumber", 0);
@ -394,6 +398,7 @@ public class Account implements BaseAccount {
editor.remove(mUuid + ".trashFolderName");
editor.remove(mUuid + ".archiveFolderName");
editor.remove(mUuid + ".spamFolderName");
editor.remove(mUuid + ".outboxFolderName");
editor.remove(mUuid + ".autoExpandFolderName");
editor.remove(mUuid + ".accountNumber");
editor.remove(mUuid + ".vibrate");
@ -485,11 +490,13 @@ public class Account implements BaseAccount {
editor.putBoolean(mUuid + ".notifySelfNewMail", mNotifySelfNewMail);
editor.putBoolean(mUuid + ".notifyMailCheck", mNotifySync);
editor.putInt(mUuid + ".deletePolicy", mDeletePolicy);
editor.putString(mUuid + ".inboxFolderName", mInboxFolderName);
editor.putString(mUuid + ".draftsFolderName", mDraftsFolderName);
editor.putString(mUuid + ".sentFolderName", mSentFolderName);
editor.putString(mUuid + ".trashFolderName", mTrashFolderName);
editor.putString(mUuid + ".archiveFolderName", mArchiveFolderName);
editor.putString(mUuid + ".spamFolderName", mSpamFolderName);
editor.putString(mUuid + ".outboxFolderName", mOutboxFolderName);
editor.putString(mUuid + ".autoExpandFolderName", mAutoExpandFolderName);
editor.putInt(mUuid + ".accountNumber", mAccountNumber);
editor.putString(mUuid + ".hideButtonsEnum", mScrollMessageViewButtons.name());
@ -762,7 +769,7 @@ public class Account implements BaseAccount {
public boolean isSpecialFolder(String folderName) {
if (folderName != null && (folderName.equalsIgnoreCase(K9.INBOX) ||
if (folderName != null && (folderName.equalsIgnoreCase(getInboxFolderName()) ||
folderName.equals(getTrashFolderName()) ||
folderName.equals(getDraftsFolderName()) ||
folderName.equals(getArchiveFolderName()) ||
@ -824,7 +831,11 @@ public class Account implements BaseAccount {
}
public synchronized String getOutboxFolderName() {
return K9.OUTBOX;
return mOutboxFolderName;
}
public synchronized void setOutboxFolderName(String outboxFolderName) {
mOutboxFolderName = outboxFolderName;
}
public synchronized String getAutoExpandFolderName() {
@ -1303,6 +1314,15 @@ public class Account implements BaseAccount {
public void setCryptoAutoSignature(boolean cryptoAutoSignature) {
mCryptoAutoSignature = cryptoAutoSignature;
}
public String getInboxFolderName() {
return mInboxFolderName;
}
public void setInboxFolderName(String mInboxFolderName) {
this.mInboxFolderName = mInboxFolderName;
}
public synchronized boolean syncRemoteDeletions() {
return mSyncRemoteDeletions;
}