Changed shared link title

This commit is contained in:
M66B 2022-07-21 16:03:07 +02:00
parent f57ab8e363
commit 9949c8e7f5
2 changed files with 6 additions and 2 deletions

View File

@ -6364,13 +6364,13 @@ public class AdapterMessage extends RecyclerView.Adapter<AdapterMessage.ViewHold
if (!TextUtils.isEmpty(message.subject))
result.put("subject", message.subject);
String link = "message://email.faircode.eu/link/#" + message.id;
String link = message.getLink();
Document document = JsoupEx.parse(file);
HtmlHelper.truncate(document, HtmlHelper.MAX_SHARE_TEXT_SIZE);
Element a = document.createElement("a");
a.text(context.getString(R.string.app_name));
a.text(link);
a.attr("href", link);
document.body().appendElement("p").appendChild(a);

View File

@ -261,6 +261,10 @@ public class EntityMessage implements Serializable {
return "<" + UUID.randomUUID() + "@" + domain + '>';
}
String getLink() {
return "message://email.faircode.eu/link/#" + id;
}
boolean isPlainOnly() {
return (this.plain_only != null && (this.plain_only & 1) != 0);
}