mirror of
https://github.com/oxen-io/session-android.git
synced 2025-02-17 13:38:26 +00:00
Stop linkifying addresses.
Address linkification on Android is pretty busted, and the docs acknowledge it (see Linkify#MAP_ADDRESSES). Safest thing to do at the moment is remove it. Looks like we may be able to get better address linkification on API >= 28, but adding it will be more involved. Fixes #7730
This commit is contained in:
parent
13c72779af
commit
20c896413b
@ -569,7 +569,8 @@ public class ConversationItem extends LinearLayout
|
||||
}
|
||||
|
||||
private SpannableString linkifyMessageBody(SpannableString messageBody, boolean shouldLinkifyAllLinks) {
|
||||
boolean hasLinks = Linkify.addLinks(messageBody, shouldLinkifyAllLinks ? Linkify.ALL : 0);
|
||||
int linkPattern = Linkify.WEB_URLS | Linkify.EMAIL_ADDRESSES | Linkify.PHONE_NUMBERS;
|
||||
boolean hasLinks = Linkify.addLinks(messageBody, shouldLinkifyAllLinks ? linkPattern : 0);
|
||||
|
||||
if (hasLinks) {
|
||||
URLSpan[] urlSpans = messageBody.getSpans(0, messageBody.length(), URLSpan.class);
|
||||
|
Loading…
x
Reference in New Issue
Block a user