From fb4f2099f385079322b113d996b8e480f8480e75 Mon Sep 17 00:00:00 2001 From: Stephen Paul Weber Date: Tue, 19 Nov 2024 15:40:36 -0500 Subject: [PATCH] Use FixedURLSpan for xhtml-im (cherry picked from commit 0cfd3783eba44437713a2ca464f1eb22ee5a230b) --- src/main/java/eu/siacs/conversations/entities/Message.java | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/main/java/eu/siacs/conversations/entities/Message.java b/src/main/java/eu/siacs/conversations/entities/Message.java index 7f619b7bb..d2d2668f2 100644 --- a/src/main/java/eu/siacs/conversations/entities/Message.java +++ b/src/main/java/eu/siacs/conversations/entities/Message.java @@ -58,6 +58,7 @@ import eu.siacs.conversations.crypto.axolotl.AxolotlService; import eu.siacs.conversations.crypto.axolotl.FingerprintStatus; import eu.siacs.conversations.http.URL; import eu.siacs.conversations.services.AvatarService; +import eu.siacs.conversations.ui.text.FixedURLSpan; import eu.siacs.conversations.ui.util.MyLinkify; import eu.siacs.conversations.ui.util.PresenceSelector; import eu.siacs.conversations.ui.util.QuoteHelper; @@ -1151,6 +1152,7 @@ public class Message extends AbstractEntity implements AvatarService.Avatarable int i = spannable.length(); while(--i >= 0 && Character.isWhitespace(spannable.charAt(i))) { } spannableBody = (SpannableStringBuilder) spannable.subSequence(0, i+1); + FixedURLSpan.fix(spannableBody); } if (includeReplyTo && getInReplyTo() != null && getModerated() == null) {