1
0
mirror of https://github.com/moparisthebest/k-9 synced 2024-11-27 11:42:16 -05:00

Break dependencies

This commit is contained in:
Jan Berkel 2014-12-12 13:35:36 +00:00
parent 0024f39bc6
commit 2e98ff56e5
13 changed files with 23 additions and 23 deletions

View File

@ -89,12 +89,13 @@ import com.fsck.k9.crypto.PgpData;
import com.fsck.k9.fragment.ProgressDialogFragment;
import com.fsck.k9.helper.ContactItem;
import com.fsck.k9.helper.Contacts;
import com.fsck.k9.helper.HtmlConverter;
import com.fsck.k9.mail.internet.HtmlConverter;
import com.fsck.k9.helper.IdentityHelper;
import com.fsck.k9.helper.Utility;
import com.fsck.k9.mail.Address;
import com.fsck.k9.mail.Body;
import com.fsck.k9.mail.Flag;
import com.fsck.k9.mail.internet.InsertableHtmlContent;
import com.fsck.k9.mail.Message;
import com.fsck.k9.mail.Message.RecipientType;
import com.fsck.k9.mail.MessagingException;

View File

@ -12,7 +12,7 @@ import android.widget.TextView;
import com.fsck.k9.R;
import com.fsck.k9.activity.Accounts;
import com.fsck.k9.activity.K9Activity;
import com.fsck.k9.helper.HtmlConverter;
import com.fsck.k9.mail.internet.HtmlConverter;
/**
* Displays a welcome message when no accounts have been created yet.

View File

@ -18,7 +18,7 @@ import java.util.List;
/**
* Helper class to access the contacts stored on the device.
*/
public class Contacts {
public class Contacts implements Address.Lookup {
/**
* The order in which the search results are returned by
* {@link #searchContacts(CharSequence)}.

View File

@ -20,11 +20,14 @@ import android.text.util.Rfc822Tokenizer;
import android.util.Log;
import com.fsck.k9.K9;
import com.fsck.k9.helper.Contacts;
import com.fsck.k9.helper.Utility;
public class Address {
public static interface Lookup {
String getNameForAddress(String address);
}
/**
* If the number of addresses exceeds this value the addresses aren't
* resolved to the names of Android contacts.
@ -34,7 +37,7 @@ public class Address {
* performance tests.
* </p>
*
* @see Address#toFriendly(Address[], Contacts)
* @see Address#toFriendly(Address[], com.fsck.k9.mail.Address.Lookup)
*/
private static final int TOO_MANY_ADDRESSES = 50;
@ -239,7 +242,7 @@ public class Address {
* @return
*/
public CharSequence toFriendly() {
return toFriendly((Contacts)null);
return toFriendly((Lookup)null);
}
/**
@ -254,7 +257,7 @@ public class Address {
* @return
* A "friendly" name for this {@link Address}.
*/
public CharSequence toFriendly(final Contacts contacts) {
public CharSequence toFriendly(final Lookup contacts) {
if (!K9.showCorrespondentNames()) {
return mAddress;
@ -281,11 +284,7 @@ public class Address {
return (!TextUtils.isEmpty(mPersonal)) ? mPersonal : mAddress;
}
public static CharSequence toFriendly(Address[] addresses) {
return toFriendly(addresses, null);
}
public static CharSequence toFriendly(Address[] addresses, Contacts contacts) {
public static CharSequence toFriendly(Address[] addresses, Lookup contacts) {
if (addresses == null) {
return null;
}

View File

@ -1,9 +1,11 @@
package com.fsck.k9.helper;
package com.fsck.k9.mail.internet;
import android.text.*;
import android.text.Html.TagHandler;
import android.util.Log;
import com.fsck.k9.K9;
import com.fsck.k9.helper.Regex;
import org.xml.sax.XMLReader;
import java.io.IOException;

View File

@ -1,4 +1,4 @@
package com.fsck.k9.activity;
package com.fsck.k9.mail.internet;
import java.io.Serializable;

View File

@ -5,7 +5,6 @@ import android.content.Context;
import android.util.Log;
import com.fsck.k9.K9;
import com.fsck.k9.R;
import com.fsck.k9.helper.HtmlConverter;
import com.fsck.k9.mail.*;
import com.fsck.k9.mail.Message.RecipientType;
import com.fsck.k9.mail.internet.BinaryTempFileBody.BinaryTempFileBodyInputStream;

View File

@ -4,8 +4,6 @@ import android.text.TextUtils;
import android.util.Log;
import com.fsck.k9.K9;
import com.fsck.k9.activity.InsertableHtmlContent;
import com.fsck.k9.helper.HtmlConverter;
import com.fsck.k9.mail.Body;
public class TextBodyBuilder {
@ -27,7 +25,7 @@ public class TextBodyBuilder {
/**
* Build the {@link Body} that will contain the text of the message.
*
* @return {@link TextBody} instance that contains the entered text and
* @return {@link com.fsck.k9.mail.internet.TextBody} instance that contains the entered text and
* possibly the quoted original message.
*/
public TextBody buildTextHtml() {

View File

@ -32,7 +32,7 @@ import com.fsck.k9.Account;
import com.fsck.k9.K9;
import com.fsck.k9.Account.MessageFormat;
import com.fsck.k9.activity.Search;
import com.fsck.k9.helper.HtmlConverter;
import com.fsck.k9.mail.internet.HtmlConverter;
import com.fsck.k9.helper.Utility;
import com.fsck.k9.mail.Address;
import com.fsck.k9.mail.Body;

View File

@ -10,7 +10,7 @@ import android.widget.Toast;
import com.fsck.k9.K9;
import com.fsck.k9.R;
import com.fsck.k9.helper.HtmlConverter;
import com.fsck.k9.mail.internet.HtmlConverter;
public class MessageWebView extends RigidWebView {

View File

@ -5,7 +5,6 @@ import java.io.FileOutputStream;
import java.io.InputStream;
import java.net.URL;
import java.net.URLConnection;
import java.net.URLDecoder;
import android.app.Activity;
import android.app.Fragment;
@ -47,7 +46,7 @@ import com.fsck.k9.fragment.MessageViewFragment;
import com.fsck.k9.helper.ClipboardManager;
import com.fsck.k9.helper.Contacts;
import com.fsck.k9.helper.FileHelper;
import com.fsck.k9.helper.HtmlConverter;
import com.fsck.k9.mail.internet.HtmlConverter;
import com.fsck.k9.helper.UrlEncodingHelper;
import com.fsck.k9.helper.Utility;
import com.fsck.k9.mail.Address;

View File

@ -7,7 +7,7 @@ import org.junit.experimental.theories.*;
import org.junit.runner.RunWith;
import com.fsck.k9.Account.QuoteStyle;
import com.fsck.k9.activity.InsertableHtmlContent;
import com.fsck.k9.activity.TextBodyBuilder;
class TestingTextBodyBuilder extends TextBodyBuilder {

View File

@ -1,5 +1,7 @@
package com.fsck.k9.helper;
import com.fsck.k9.mail.internet.HtmlConverter;
import junit.framework.TestCase;
import java.io.BufferedWriter;