mirror of
https://github.com/M66B/FairEmail.git
synced 2026-03-31 14:17:03 +02:00
Improved reply/forward handling
This commit is contained in:
@@ -24,7 +24,6 @@ import android.graphics.Bitmap;
|
||||
import android.graphics.BitmapFactory;
|
||||
import android.graphics.drawable.BitmapDrawable;
|
||||
import android.graphics.drawable.Drawable;
|
||||
import android.text.Html;
|
||||
import android.text.TextUtils;
|
||||
import android.util.Base64;
|
||||
|
||||
@@ -47,7 +46,6 @@ import java.io.InputStream;
|
||||
import java.io.OutputStream;
|
||||
import java.net.URL;
|
||||
import java.util.Arrays;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
import java.util.regex.Matcher;
|
||||
import java.util.regex.Pattern;
|
||||
@@ -246,17 +244,6 @@ public class HtmlHelper {
|
||||
}
|
||||
}
|
||||
|
||||
static String getQuote(Context context, long id, boolean sanitize) throws IOException {
|
||||
EntityMessage message = DB.getInstance(context).message().getMessage(id);
|
||||
if (message == null)
|
||||
return null;
|
||||
String html = EntityMessage.read(context, id);
|
||||
return String.format("<p>%s %s:</p>\n<blockquote>%s</blockquote>",
|
||||
Html.escapeHtml(new Date(message.received).toString()),
|
||||
Html.escapeHtml(MessageHelper.formatAddresses(message.from)),
|
||||
sanitize ? sanitize(html, true) : getBody(html));
|
||||
}
|
||||
|
||||
static String getPreview(String body) {
|
||||
String text = (body == null ? null : Jsoup.parse(body).text());
|
||||
return (text == null ? null : text.substring(0, Math.min(text.length(), PREVIEW_SIZE)));
|
||||
|
||||
Reference in New Issue
Block a user