diff --git a/src/com/fsck/k9/MessagingController.java b/src/com/fsck/k9/MessagingController.java index 8012d0844..0c98225ce 100644 --- a/src/com/fsck/k9/MessagingController.java +++ b/src/com/fsck/k9/MessagingController.java @@ -118,7 +118,7 @@ public class MessagingController implements Runnable { } catch (Exception e) { if (Config.LOGV) { - Log.v(Email.LOG_TAG, "Error running command", e); + Log.v(k9.LOG_TAG, "Error running command", e); } } mBusy = false; @@ -211,7 +211,7 @@ public class MessagingController implements Runnable { */ for (Folder localFolder : localFolders) { String localFolderName = localFolder.getName(); - if (localFolderName.equalsIgnoreCase(Email.INBOX) || + if (localFolderName.equalsIgnoreCase(k9.INBOX) || localFolderName.equals(account.getTrashFolderName()) || localFolderName.equals(account.getOutboxFolderName()) || localFolderName.equals(account.getDraftsFolderName()) || @@ -293,7 +293,7 @@ public class MessagingController implements Runnable { mApplication); LocalFolder localFolder = (LocalFolder) localStore.getFolder(folder); localFolder.setVisibleLimit(localFolder.getVisibleLimit() - + Email.VISIBLE_LIMIT_INCREMENT); + + k9.VISIBLE_LIMIT_INCREMENT); synchronizeMailbox(account, folder, listener); } catch (MessagingException me) { @@ -309,7 +309,7 @@ public class MessagingController implements Runnable { localStore.resetVisibleLimits(); } catch (MessagingException e) { - Log.e(Email.LOG_TAG, "Unable to reset visible limits", e); + Log.e(k9.LOG_TAG, "Unable to reset visible limits", e); } } } @@ -402,8 +402,8 @@ public class MessagingController implements Runnable { Open the folder Upload any local messages that are marked as PENDING_UPLOAD (Drafts, Sent, Trash) Get the message count - Get the list of the newest Email.DEFAULT_VISIBLE_LIMIT messages - getMessages(messageCount - Email.DEFAULT_VISIBLE_LIMIT, messageCount) + Get the list of the newest k9.DEFAULT_VISIBLE_LIMIT messages + getMessages(messageCount - k9.DEFAULT_VISIBLE_LIMIT, messageCount) See if we have each message locally, if not fetch it's flags and envelope Get and update the unread count for the folder Update the remote flags of any messages we have locally with an internal date @@ -531,7 +531,7 @@ s * critical data as fast as possible, and then we'll fill in the de } } catch (Exception e) { - Log.e(Email.LOG_TAG, + Log.e(k9.LOG_TAG, "Error while storing downloaded message.", e); } @@ -735,7 +735,7 @@ s * critical data as fast as possible, and then we'll fill in the de } catch (Exception e) { if (Config.LOGV) { - Log.v(Email.LOG_TAG, "synchronizeMailbox", e); + Log.v(k9.LOG_TAG, "synchronizeMailbox", e); } for (MessagingListener l : mListeners) { l.synchronizeMailboxFailed( @@ -766,7 +766,7 @@ s * critical data as fast as possible, and then we'll fill in the de } catch (MessagingException me) { if (Config.LOGV) { - Log.v(Email.LOG_TAG, "processPendingCommands", me); + Log.v(k9.LOG_TAG, "processPendingCommands", me); } /* * Ignore any exceptions from the commands. Commands will be processed @@ -1213,7 +1213,7 @@ s * critical data as fast as possible, and then we'll fill in the de } catch (MessagingException me) { if (Config.LOGV) { - Log.v(Email.LOG_TAG, "", me); + Log.v(k9.LOG_TAG, "", me); } for (MessagingListener l : mListeners) { l.loadAttachmentFailed(account, message, part, tag, me.getMessage()); @@ -1400,7 +1400,7 @@ s * critical data as fast as possible, and then we'll fill in the de catch (Exception e) { // TODO if (Config.LOGV) { - Log.v(Email.LOG_TAG, "emptyTrash"); + Log.v(k9.LOG_TAG, "emptyTrash"); } } } @@ -1432,7 +1432,7 @@ s * critical data as fast as possible, and then we'll fill in the de } for (Account account : accounts) { sendPendingMessagesSynchronous(account); - synchronizeMailboxSynchronous(account, Email.INBOX); + synchronizeMailboxSynchronous(account, k9.INBOX); } for (MessagingListener l : mListeners) { l.checkMailFinished(context, account); @@ -1462,7 +1462,7 @@ s * critical data as fast as possible, and then we'll fill in the de processPendingCommands(account); } catch (MessagingException e) { - Log.e(Email.LOG_TAG, "Unable to save message as draft.", e); + Log.e(k9.LOG_TAG, "Unable to save message as draft.", e); } } diff --git a/src/com/fsck/k9/Preferences.java b/src/com/fsck/k9/Preferences.java index c0be583be..75b75364a 100644 --- a/src/com/fsck/k9/Preferences.java +++ b/src/com/fsck/k9/Preferences.java @@ -116,7 +116,7 @@ public class Preferences { public void dump() { if (Config.LOGV) { for (String key : mSharedPreferences.getAll().keySet()) { - Log.v(Email.LOG_TAG, key + " = " + mSharedPreferences.getAll().get(key)); + Log.v(k9.LOG_TAG, key + " = " + mSharedPreferences.getAll().get(key)); } } } diff --git a/src/com/fsck/k9/activity/Accounts.java b/src/com/fsck/k9/activity/Accounts.java index 0e34a0d18..3010eaf20 100644 --- a/src/com/fsck/k9/activity/Accounts.java +++ b/src/com/fsck/k9/activity/Accounts.java @@ -25,7 +25,7 @@ import android.widget.AdapterView.AdapterContextMenuInfo; import android.widget.AdapterView.OnItemClickListener; import com.fsck.k9.Account; -import com.fsck.k9.Email; +import com.fsck.k9.k9; import com.fsck.k9.MessagingController; import com.fsck.k9.Preferences; import com.fsck.k9.R; @@ -152,7 +152,7 @@ public class Accounts extends ListActivity implements OnItemClickListener, OnCli // Ignore } mSelectedContextAccount.delete(Preferences.getPreferences(Accounts.this)); - Email.setServicesEnabled(Accounts.this); + k9.setServicesEnabled(Accounts.this); refresh(); } }) @@ -269,7 +269,7 @@ public class Accounts extends ListActivity implements OnItemClickListener, OnCli LocalStore localStore = (LocalStore) Store.getInstance( account.getLocalStoreUri(), getApplication()); - LocalFolder localFolder = (LocalFolder) localStore.getFolder(Email.INBOX); + LocalFolder localFolder = (LocalFolder) localStore.getFolder(k9.INBOX); if (localFolder.exists()) { unreadMessageCount = localFolder.getUnreadMessageCount(); } diff --git a/src/com/fsck/k9/activity/Debug.java b/src/com/fsck/k9/activity/Debug.java index 1c1314ae3..8c4c51809 100644 --- a/src/com/fsck/k9/activity/Debug.java +++ b/src/com/fsck/k9/activity/Debug.java @@ -10,7 +10,7 @@ import android.widget.CompoundButton; import android.widget.TextView; import android.widget.CompoundButton.OnCheckedChangeListener; -import com.fsck.k9.Email; +import com.fsck.k9.k9; import com.fsck.k9.Preferences; import com.fsck.k9.R; @@ -39,17 +39,17 @@ public class Debug extends Activity implements OnCheckedChangeListener { mVersionView.setText(String.format(getString(R.string.debug_version_fmt).toString(), getString(R.string.build_number))); - mEnableDebugLoggingView.setChecked(Email.DEBUG); - mEnableSensitiveLoggingView.setChecked(Email.DEBUG_SENSITIVE); + mEnableDebugLoggingView.setChecked(k9.DEBUG); + mEnableSensitiveLoggingView.setChecked(k9.DEBUG_SENSITIVE); } public void onCheckedChanged(CompoundButton buttonView, boolean isChecked) { if (buttonView.getId() == R.id.debug_logging) { - Email.DEBUG = isChecked; - mPreferences.setEnableDebugLogging(Email.DEBUG); + k9.DEBUG = isChecked; + mPreferences.setEnableDebugLogging(k9.DEBUG); } else if (buttonView.getId() == R.id.sensitive_logging) { - Email.DEBUG_SENSITIVE = isChecked; - mPreferences.setEnableSensitiveLogging(Email.DEBUG_SENSITIVE); + k9.DEBUG_SENSITIVE = isChecked; + mPreferences.setEnableSensitiveLogging(k9.DEBUG_SENSITIVE); } } diff --git a/src/com/fsck/k9/activity/FolderMessageList.java b/src/com/fsck/k9/activity/FolderMessageList.java index 36d75cf41..e511932ef 100644 --- a/src/com/fsck/k9/activity/FolderMessageList.java +++ b/src/com/fsck/k9/activity/FolderMessageList.java @@ -33,7 +33,7 @@ import android.widget.Toast; import android.widget.ExpandableListView.ExpandableListContextMenuInfo; import com.fsck.k9.Account; -import com.fsck.k9.Email; +import com.fsck.k9.k9; import com.fsck.k9.MessagingController; import com.fsck.k9.MessagingListener; import com.fsck.k9.R; @@ -700,7 +700,7 @@ public class FolderMessageList extends ExpandableListActivity { } mHandler.progress(false); if (Config.LOGV) { - Log.v(Email.LOG_TAG, "listFoldersFailed " + message); + Log.v(k9.LOG_TAG, "listFoldersFailed " + message); } } @@ -731,7 +731,7 @@ public class FolderMessageList extends ExpandableListActivity { mFolders.add(holder); } holder.name = folder.getName(); - if (holder.name.equalsIgnoreCase(Email.INBOX)) { + if (holder.name.equalsIgnoreCase(k9.INBOX)) { holder.displayName = getString(R.string.special_mailbox_name_inbox); } else { @@ -749,7 +749,7 @@ public class FolderMessageList extends ExpandableListActivity { folder.close(false); } catch (MessagingException me) { - Log.e(Email.LOG_TAG, "Folder.getUnreadMessageCount() failed", me); + Log.e(k9.LOG_TAG, "Folder.getUnreadMessageCount() failed", me); } } @@ -763,7 +763,7 @@ public class FolderMessageList extends ExpandableListActivity { */ // if (mRestoredState != null) { // if (Config.LOGV) { -// Log.v(Email.LOG_TAG, "Attempting to restore list state"); +// Log.v(k9.LOG_TAG, "Attempting to restore list state"); // } // Parcelable listViewState = // mListView.onRestoreInstanceState(mListViewState); @@ -1199,9 +1199,9 @@ public class FolderMessageList extends ExpandableListActivity { public int compareTo(FolderInfoHolder o) { String s1 = this.name; String s2 = o.name; - if (Email.INBOX.equalsIgnoreCase(s1)) { + if (k9.INBOX.equalsIgnoreCase(s1)) { return -1; - } else if (Email.INBOX.equalsIgnoreCase(s2)) { + } else if (k9.INBOX.equalsIgnoreCase(s2)) { return 1; } else return s1.toUpperCase().compareTo(s2.toUpperCase()); @@ -1248,7 +1248,7 @@ public class FolderMessageList extends ExpandableListActivity { } catch (MessagingException me) { if (Config.LOGV) { - Log.v(Email.LOG_TAG, "Unable to load message info", me); + Log.v(k9.LOG_TAG, "Unable to load message info", me); } } } diff --git a/src/com/fsck/k9/activity/MessageCompose.java b/src/com/fsck/k9/activity/MessageCompose.java index a804b4c88..a4a037dca 100644 --- a/src/com/fsck/k9/activity/MessageCompose.java +++ b/src/com/fsck/k9/activity/MessageCompose.java @@ -37,7 +37,7 @@ import android.widget.Toast; import android.widget.AutoCompleteTextView.Validator; import com.fsck.k9.Account; -import com.fsck.k9.Email; +import com.fsck.k9.k9; import com.fsck.k9.EmailAddressAdapter; import com.fsck.k9.EmailAddressValidator; import com.fsck.k9.MessagingController; @@ -379,7 +379,7 @@ public class MessageCompose extends Activity implements OnClickListener, OnFocus String type = intent.getType(); Uri stream = (Uri) intent.getParcelableExtra(Intent.EXTRA_STREAM); if (stream != null && type != null) { - if (MimeUtility.mimeTypeMatches(type, Email.ACCEPTABLE_ATTACHMENT_SEND_TYPES)) { + if (MimeUtility.mimeTypeMatches(type, k9.ACCEPTABLE_ATTACHMENT_SEND_TYPES)) { addAttachment(stream); } } @@ -599,7 +599,7 @@ public class MessageCompose extends Activity implements OnClickListener, OnFocus message = createMessage(); } catch (MessagingException me) { - Log.e(Email.LOG_TAG, "Failed to create new message for send or save.", me); + Log.e(k9.LOG_TAG, "Failed to create new message for send or save.", me); throw new RuntimeException("Failed to create a new message for send or save.", me); } @@ -699,7 +699,7 @@ public class MessageCompose extends Activity implements OnClickListener, OnFocus private void onAddAttachment() { Intent i = new Intent(Intent.ACTION_GET_CONTENT); i.addCategory(Intent.CATEGORY_OPENABLE); - i.setType(Email.ACCEPTABLE_ATTACHMENT_SEND_TYPES[0]); + i.setType(k9.ACCEPTABLE_ATTACHMENT_SEND_TYPES[0]); startActivityForResult(Intent.createChooser(i, null), ACTIVITY_REQUEST_PICK_ATTACHMENT); } diff --git a/src/com/fsck/k9/activity/MessageView.java b/src/com/fsck/k9/activity/MessageView.java index 9f2605374..40a4aea2b 100644 --- a/src/com/fsck/k9/activity/MessageView.java +++ b/src/com/fsck/k9/activity/MessageView.java @@ -45,7 +45,7 @@ import android.widget.TextView; import android.widget.Toast; import com.fsck.k9.Account; -import com.fsck.k9.Email; +import com.fsck.k9.k9; import com.fsck.k9.MessagingController; import com.fsck.k9.MessagingListener; import com.fsck.k9.R; @@ -623,19 +623,19 @@ public class MessageView extends Activity Button attachmentDownload = (Button)view.findViewById(R.id.download); if ((!MimeUtility.mimeTypeMatches(attachment.contentType, - Email.ACCEPTABLE_ATTACHMENT_VIEW_TYPES)) + k9.ACCEPTABLE_ATTACHMENT_VIEW_TYPES)) || (MimeUtility.mimeTypeMatches(attachment.contentType, - Email.UNACCEPTABLE_ATTACHMENT_VIEW_TYPES))) { + k9.UNACCEPTABLE_ATTACHMENT_VIEW_TYPES))) { attachmentView.setVisibility(View.GONE); } if ((!MimeUtility.mimeTypeMatches(attachment.contentType, - Email.ACCEPTABLE_ATTACHMENT_DOWNLOAD_TYPES)) + k9.ACCEPTABLE_ATTACHMENT_DOWNLOAD_TYPES)) || (MimeUtility.mimeTypeMatches(attachment.contentType, - Email.UNACCEPTABLE_ATTACHMENT_DOWNLOAD_TYPES))) { + k9.UNACCEPTABLE_ATTACHMENT_DOWNLOAD_TYPES))) { attachmentDownload.setVisibility(View.GONE); } - if (attachment.size > Email.MAX_ATTACHMENT_DOWNLOAD_SIZE) { + if (attachment.size > k9.MAX_ATTACHMENT_DOWNLOAD_SIZE) { attachmentView.setVisibility(View.GONE); attachmentDownload.setVisibility(View.GONE); } @@ -690,7 +690,7 @@ public class MessageView extends Activity } catch (MessagingException me) { if (Config.LOGV) { - Log.v(Email.LOG_TAG, "loadMessageForViewHeadersAvailable", me); + Log.v(k9.LOG_TAG, "loadMessageForViewHeadersAvailable", me); } } } @@ -747,7 +747,7 @@ public class MessageView extends Activity } catch (Exception e) { if (Config.LOGV) { - Log.v(Email.LOG_TAG, "loadMessageForViewBodyAvailable", e); + Log.v(k9.LOG_TAG, "loadMessageForViewBodyAvailable", e); } } } diff --git a/src/com/fsck/k9/activity/Welcome.java b/src/com/fsck/k9/activity/Welcome.java index c42091f8a..008414416 100644 --- a/src/com/fsck/k9/activity/Welcome.java +++ b/src/com/fsck/k9/activity/Welcome.java @@ -2,7 +2,7 @@ package com.fsck.k9.activity; import com.fsck.k9.Account; -import com.fsck.k9.Email; +import com.fsck.k9.k9; import com.fsck.k9.Preferences; import android.app.Activity; @@ -26,7 +26,7 @@ public class Welcome extends Activity { Account[] accounts = Preferences.getPreferences(this).getAccounts(); if (accounts.length == 1) { - FolderMessageList.actionHandleAccount(this, accounts[0], Email.INBOX); + FolderMessageList.actionHandleAccount(this, accounts[0], k9.INBOX); } else { startActivity(new Intent(this, Accounts.class)); } diff --git a/src/com/fsck/k9/activity/setup/AccountSettings.java b/src/com/fsck/k9/activity/setup/AccountSettings.java index dad494a6b..da9096406 100644 --- a/src/com/fsck/k9/activity/setup/AccountSettings.java +++ b/src/com/fsck/k9/activity/setup/AccountSettings.java @@ -14,7 +14,7 @@ import android.preference.Preference; import android.preference.RingtonePreference; import com.fsck.k9.Account; -import com.fsck.k9.Email; +import com.fsck.k9.k9; import com.fsck.k9.Preferences; import com.fsck.k9.R; @@ -156,7 +156,7 @@ public class AccountSettings extends PreferenceActivity { SharedPreferences prefs = mAccountRingtone.getPreferenceManager().getSharedPreferences(); mAccount.setRingtone(prefs.getString(PREFERENCE_RINGTONE, null)); mAccount.save(Preferences.getPreferences(this)); - Email.setServicesEnabled(this); + k9.setServicesEnabled(this); } @Override diff --git a/src/com/fsck/k9/activity/setup/AccountSetupBasics.java b/src/com/fsck/k9/activity/setup/AccountSetupBasics.java index 38f842a6e..69e4612c9 100644 --- a/src/com/fsck/k9/activity/setup/AccountSetupBasics.java +++ b/src/com/fsck/k9/activity/setup/AccountSetupBasics.java @@ -27,7 +27,7 @@ import android.widget.CheckBox; import android.widget.EditText; import com.fsck.k9.Account; -import com.fsck.k9.Email; +import com.fsck.k9.k9; import com.fsck.k9.EmailAddressValidator; import com.fsck.k9.Preferences; import com.fsck.k9.R; @@ -262,7 +262,7 @@ public class AccountSetupBasics extends Activity if (mDefaultView.isChecked()) { Preferences.getPreferences(this).setDefaultAccount(mAccount); } - Email.setServicesEnabled(this); + k9.setServicesEnabled(this); AccountSetupNames.actionSetNames(this, mAccount); finish(); } @@ -361,7 +361,7 @@ public class AccountSetupBasics extends Activity } } catch (Exception e) { - Log.e(Email.LOG_TAG, "Error while trying to load provider settings.", e); + Log.e(k9.LOG_TAG, "Error while trying to load provider settings.", e); } return null; } diff --git a/src/com/fsck/k9/activity/setup/AccountSetupNames.java b/src/com/fsck/k9/activity/setup/AccountSetupNames.java index 874fe2f93..65706aaba 100644 --- a/src/com/fsck/k9/activity/setup/AccountSetupNames.java +++ b/src/com/fsck/k9/activity/setup/AccountSetupNames.java @@ -15,7 +15,7 @@ import android.widget.Button; import android.widget.EditText; import com.fsck.k9.Account; -import com.fsck.k9.Email; +import com.fsck.k9.k9; import com.fsck.k9.Preferences; import com.fsck.k9.R; import com.fsck.k9.Utility; @@ -89,7 +89,7 @@ public class AccountSetupNames extends Activity implements OnClickListener { } mAccount.setName(mName.getText().toString()); mAccount.save(Preferences.getPreferences(this)); - FolderMessageList.actionHandleAccount(this, mAccount, Email.INBOX); + FolderMessageList.actionHandleAccount(this, mAccount, k9.INBOX); finish(); } diff --git a/src/com/fsck/k9/activity/setup/AccountSetupOptions.java b/src/com/fsck/k9/activity/setup/AccountSetupOptions.java index 46c7a9b42..ebaa74830 100644 --- a/src/com/fsck/k9/activity/setup/AccountSetupOptions.java +++ b/src/com/fsck/k9/activity/setup/AccountSetupOptions.java @@ -12,7 +12,7 @@ import android.widget.CheckBox; import android.widget.Spinner; import com.fsck.k9.Account; -import com.fsck.k9.Email; +import com.fsck.k9.k9; import com.fsck.k9.Preferences; import com.fsck.k9.R; @@ -88,7 +88,7 @@ public class AccountSetupOptions extends Activity implements OnClickListener { if (mDefaultView.isChecked()) { Preferences.getPreferences(this).setDefaultAccount(mAccount); } - Email.setServicesEnabled(this); + k9.setServicesEnabled(this); AccountSetupNames.actionSetNames(this, mAccount); finish(); } diff --git a/src/com/fsck/k9/mail/Address.java b/src/com/fsck/k9/mail/Address.java index 17a4f003b..9b64631d8 100644 --- a/src/com/fsck/k9/mail/Address.java +++ b/src/com/fsck/k9/mail/Address.java @@ -16,7 +16,7 @@ import org.apache.james.mime4j.field.address.parser.ParseException; import android.util.Config; import android.util.Log; -import com.fsck.k9.Email; +import com.fsck.k9.k9; import com.fsck.k9.Utility; import com.fsck.k9.mail.internet.MimeUtility; @@ -74,7 +74,7 @@ public class Address { Mailbox mailbox = (Mailbox)address; addresses.add(new Address(mailbox.getLocalPart() + "@" + mailbox.getDomain())); } else { - Log.e(Email.LOG_TAG, "Unknown address type from Mime4J: " + Log.e(k9.LOG_TAG, "Unknown address type from Mime4J: " + address.getClass().toString()); } diff --git a/src/com/fsck/k9/mail/internet/BinaryTempFileBody.java b/src/com/fsck/k9/mail/internet/BinaryTempFileBody.java index e69dd1d7a..771c17c5e 100644 --- a/src/com/fsck/k9/mail/internet/BinaryTempFileBody.java +++ b/src/com/fsck/k9/mail/internet/BinaryTempFileBody.java @@ -13,7 +13,7 @@ import org.apache.commons.io.IOUtils; import android.util.Config; import android.util.Log; -import com.fsck.k9.Email; +import com.fsck.k9.k9; import com.fsck.k9.codec.binary.Base64OutputStream; import com.fsck.k9.mail.Body; import com.fsck.k9.mail.MessagingException; diff --git a/src/com/fsck/k9/mail/internet/MimeUtility.java b/src/com/fsck/k9/mail/internet/MimeUtility.java index a347cebec..2066eb8d6 100644 --- a/src/com/fsck/k9/mail/internet/MimeUtility.java +++ b/src/com/fsck/k9/mail/internet/MimeUtility.java @@ -15,7 +15,7 @@ import org.apache.james.mime4j.util.CharsetUtil; import android.util.Log; -import com.fsck.k9.Email; +import com.fsck.k9.k9; import com.fsck.k9.mail.Body; import com.fsck.k9.mail.BodyPart; import com.fsck.k9.mail.Message; @@ -176,7 +176,7 @@ public class MimeUtility { * If we are not able to process the body there's nothing we can do about it. Return * null and let the upper layers handle the missing content. */ - Log.e(Email.LOG_TAG, "Unable to getTextFromPart", e); + Log.e(k9.LOG_TAG, "Unable to getTextFromPart", e); } return null; } diff --git a/src/com/fsck/k9/mail/store/ImapResponseParser.java b/src/com/fsck/k9/mail/store/ImapResponseParser.java index 3c0717f6b..f20f0b099 100644 --- a/src/com/fsck/k9/mail/store/ImapResponseParser.java +++ b/src/com/fsck/k9/mail/store/ImapResponseParser.java @@ -14,7 +14,7 @@ import java.util.Date; import android.util.Config; import android.util.Log; -import com.fsck.k9.Email; +import com.fsck.k9.k9; import com.fsck.k9.FixedLengthInputStream; import com.fsck.k9.PeekableInputStream; import com.fsck.k9.mail.MessagingException; @@ -55,8 +55,8 @@ public class ImapResponseParser { readTokens(response); } if (Config.LOGD) { - if (Email.DEBUG) { - Log.d(Email.LOG_TAG, "<<< " + response.toString()); + if (k9.DEBUG) { + Log.d(k9.LOG_TAG, "<<< " + response.toString()); } } return response; diff --git a/src/com/fsck/k9/mail/store/ImapStore.java b/src/com/fsck/k9/mail/store/ImapStore.java index a2fe1c9c5..43266e52d 100644 --- a/src/com/fsck/k9/mail/store/ImapStore.java +++ b/src/com/fsck/k9/mail/store/ImapStore.java @@ -31,7 +31,7 @@ import javax.net.ssl.SSLException; import android.util.Config; import android.util.Log; -import com.fsck.k9.Email; +import com.fsck.k9.k9; import com.fsck.k9.PeekableInputStream; import com.fsck.k9.Utility; import com.fsck.k9.mail.AuthenticationFailedException; @@ -707,7 +707,7 @@ public class ImapStore extends Store { } catch (MessagingException e) { if (Config.LOGV) { - Log.v(Email.LOG_TAG, "Error handling message", e); + Log.v(k9.LOG_TAG, "Error handling message", e); } message.setBody(null); } @@ -1191,12 +1191,12 @@ public class ImapStore extends Store { mOut.write('\n'); mOut.flush(); if (Config.LOGD) { - if (Email.DEBUG) { - if (sensitive && !Email.DEBUG_SENSITIVE) { - Log.d(Email.LOG_TAG, ">>> " + if (k9.DEBUG) { + if (sensitive && !k9.DEBUG_SENSITIVE) { + Log.d(k9.LOG_TAG, ">>> " + "[Command Hidden, Enable Sensitive Debug Logging To Show]"); } else { - Log.d(Email.LOG_TAG, ">>> " + commandToSend); + Log.d(k9.LOG_TAG, ">>> " + commandToSend); } } } diff --git a/src/com/fsck/k9/mail/store/LocalStore.java b/src/com/fsck/k9/mail/store/LocalStore.java index 41bd6e9d5..bc5eeb991 100644 --- a/src/com/fsck/k9/mail/store/LocalStore.java +++ b/src/com/fsck/k9/mail/store/LocalStore.java @@ -25,7 +25,7 @@ import android.net.Uri; import android.util.Config; import android.util.Log; -import com.fsck.k9.Email; +import com.fsck.k9.k9; import com.fsck.k9.Utility; import com.fsck.k9.codec.binary.Base64OutputStream; import com.fsck.k9.mail.Address; @@ -85,7 +85,7 @@ public class LocalStore extends Store { if (mDb.getVersion() != DB_VERSION) { if (mDb.getVersion() < 18) { if (Config.LOGV) { - Log.v(Email.LOG_TAG, String.format("Upgrading database from %d to %d", mDb + Log.v(k9.LOG_TAG, String.format("Upgrading database from %d to %d", mDb .getVersion(), 18)); } mDb.execSQL("DROP TABLE IF EXISTS folders"); @@ -233,7 +233,7 @@ public class LocalStore extends Store { public void resetVisibleLimits() { ContentValues cv = new ContentValues(); - cv.put("visible_limit", Integer.toString(Email.DEFAULT_VISIBLE_LIMIT)); + cv.put("visible_limit", Integer.toString(k9.DEFAULT_VISIBLE_LIMIT)); mDb.update("folders", cv, null, null); } @@ -1100,7 +1100,7 @@ public class LocalStore extends Store { } } catch (MessagingException me) { - Log.e(Email.LOG_TAG, "Unable to update LocalStore unread message count", + Log.e(k9.LOG_TAG, "Unable to update LocalStore unread message count", me); throw new RuntimeException(me); } diff --git a/src/com/fsck/k9/mail/store/Pop3Store.java b/src/com/fsck/k9/mail/store/Pop3Store.java index 3c739880b..c3782efed 100644 --- a/src/com/fsck/k9/mail/store/Pop3Store.java +++ b/src/com/fsck/k9/mail/store/Pop3Store.java @@ -24,7 +24,7 @@ import javax.net.ssl.SSLException; import android.util.Config; import android.util.Log; -import com.fsck.k9.Email; +import com.fsck.k9.k9; import com.fsck.k9.Utility; import com.fsck.k9.mail.AuthenticationFailedException; import com.fsck.k9.mail.FetchProfile; @@ -731,8 +731,8 @@ public class Pop3Store extends Store { } while ((d = mIn.read()) != -1); String ret = sb.toString(); if (Config.LOGD) { - if (Email.DEBUG) { - Log.d(Email.LOG_TAG, "<<< " + ret); + if (k9.DEBUG) { + Log.d(k9.LOG_TAG, "<<< " + ret); } } return ret; @@ -740,8 +740,8 @@ public class Pop3Store extends Store { private void writeLine(String s) throws IOException { if (Config.LOGD) { - if (Email.DEBUG) { - Log.d(Email.LOG_TAG, ">>> " + s); + if (k9.DEBUG) { + Log.d(k9.LOG_TAG, ">>> " + s); } } mOut.write(s.getBytes()); diff --git a/src/com/fsck/k9/mail/transport/SmtpTransport.java b/src/com/fsck/k9/mail/transport/SmtpTransport.java index 61df80898..d6c8052b3 100644 --- a/src/com/fsck/k9/mail/transport/SmtpTransport.java +++ b/src/com/fsck/k9/mail/transport/SmtpTransport.java @@ -21,7 +21,7 @@ import javax.net.ssl.SSLException; import android.util.Config; import android.util.Log; -import com.fsck.k9.Email; +import com.fsck.k9.k9; import com.fsck.k9.PeekableInputStream; import com.fsck.k9.codec.binary.Base64; import com.fsck.k9.mail.Address; @@ -144,8 +144,8 @@ public class SmtpTransport extends Transport { localHost = localAddress.getHostName(); } catch (Exception e) { if (Config.LOGD) { - if (Email.DEBUG) { - Log.d(Email.LOG_TAG, "Unable to look up localhost"); + if (k9.DEBUG) { + Log.d(k9.LOG_TAG, "Unable to look up localhost"); } } } @@ -277,8 +277,8 @@ public class SmtpTransport extends Transport { } String ret = sb.toString(); if (Config.LOGD) { - if (Email.DEBUG) { - Log.d(Email.LOG_TAG, "<<< " + ret); + if (k9.DEBUG) { + Log.d(k9.LOG_TAG, "<<< " + ret); } } return ret; @@ -286,8 +286,8 @@ public class SmtpTransport extends Transport { private void writeLine(String s) throws IOException { if (Config.LOGD) { - if (Email.DEBUG) { - Log.d(Email.LOG_TAG, ">>> " + s); + if (k9.DEBUG) { + Log.d(k9.LOG_TAG, ">>> " + s); } } mOut.write(s.getBytes()); diff --git a/src/com/fsck/k9/mail/transport/StatusOutputStream.java b/src/com/fsck/k9/mail/transport/StatusOutputStream.java index 2a3da086c..c97e08e2e 100644 --- a/src/com/fsck/k9/mail/transport/StatusOutputStream.java +++ b/src/com/fsck/k9/mail/transport/StatusOutputStream.java @@ -4,7 +4,7 @@ import java.io.FilterOutputStream; import java.io.IOException; import java.io.OutputStream; -import com.fsck.k9.Email; +import com.fsck.k9.k9; import android.util.Config; import android.util.Log; @@ -22,7 +22,7 @@ public class StatusOutputStream extends FilterOutputStream { mCount++; if (Config.LOGV) { if (mCount % 1024 == 0) { - Log.v(Email.LOG_TAG, "# " + mCount); + Log.v(k9.LOG_TAG, "# " + mCount); } } } diff --git a/src/com/fsck/k9/provider/AttachmentProvider.java b/src/com/fsck/k9/provider/AttachmentProvider.java index 81df530c6..70e0dbb2c 100644 --- a/src/com/fsck/k9/provider/AttachmentProvider.java +++ b/src/com/fsck/k9/provider/AttachmentProvider.java @@ -22,7 +22,7 @@ import android.util.Config; import android.util.Log; import com.fsck.k9.Account; -import com.fsck.k9.Email; +import com.fsck.k9.k9; import com.fsck.k9.Utility; import com.fsck.k9.mail.internet.MimeUtility; diff --git a/src/com/fsck/k9/service/MailService.java b/src/com/fsck/k9/service/MailService.java index 3879548c7..b0a76db84 100644 --- a/src/com/fsck/k9/service/MailService.java +++ b/src/com/fsck/k9/service/MailService.java @@ -18,7 +18,7 @@ import android.text.TextUtils; import android.net.Uri; import com.fsck.k9.Account; -import com.fsck.k9.Email; +import com.fsck.k9.k9; import com.fsck.k9.MessagingController; import com.fsck.k9.MessagingListener; import com.fsck.k9.Preferences; @@ -59,20 +59,20 @@ public class MailService extends Service { MessagingController.getInstance(getApplication()).addListener(mListener); if (ACTION_CHECK_MAIL.equals(intent.getAction())) { if (Config.LOGV) { - Log.v(Email.LOG_TAG, "***** MailService *****: checking mail"); + Log.v(k9.LOG_TAG, "***** MailService *****: checking mail"); } MessagingController.getInstance(getApplication()).checkMail(this, null, mListener); } else if (ACTION_CANCEL.equals(intent.getAction())) { if (Config.LOGV) { - Log.v(Email.LOG_TAG, "***** MailService *****: cancel"); + Log.v(k9.LOG_TAG, "***** MailService *****: cancel"); } cancel(); stopSelf(startId); } else if (ACTION_RESCHEDULE.equals(intent.getAction())) { if (Config.LOGV) { - Log.v(Email.LOG_TAG, "***** MailService *****: reschedule"); + Log.v(k9.LOG_TAG, "***** MailService *****: reschedule"); } reschedule(); stopSelf(startId); @@ -170,7 +170,7 @@ public class MailService extends Service { } else { Account account1 = accountsWithNewMail.keySet().iterator().next(); int totalNewMails = accountsWithNewMail.get(account1); - Intent i = FolderMessageList.actionHandleAccountIntent(context, account1, Email.INBOX); + Intent i = FolderMessageList.actionHandleAccountIntent(context, account1, k9.INBOX); PendingIntent pi = PendingIntent.getActivity(context, 0, i, 0); notif.setLatestEventInfo(context, getString(R.string.notification_new_title), getString(R.string.notification_new_one_account_fmt, totalNewMails,