From 01fc78d2a5893ce3fe2fb573de7cf147a6c7eeba Mon Sep 17 00:00:00 2001 From: Daniel Gultsch Date: Sat, 5 Oct 2019 22:05:03 +0200 Subject: [PATCH] disable context menu on failed jingle files. fixes #3556 --- .../java/eu/siacs/conversations/ui/ConversationFragment.java | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/main/java/eu/siacs/conversations/ui/ConversationFragment.java b/src/main/java/eu/siacs/conversations/ui/ConversationFragment.java index 161e5bf42..c0ec6d790 100644 --- a/src/main/java/eu/siacs/conversations/ui/ConversationFragment.java +++ b/src/main/java/eu/siacs/conversations/ui/ConversationFragment.java @@ -1044,6 +1044,10 @@ public class ConversationFragment extends XmppFragment implements EditMessage.Ke return; } + if (m.getStatus() == Message.STATUS_RECEIVED && t != null && (t.getStatus() == Transferable.STATUS_CANCELLED || t.getStatus() == Transferable.STATUS_FAILED)) { + return; + } + final boolean deleted = m.isDeleted(); final boolean encrypted = m.getEncryption() == Message.ENCRYPTION_DECRYPTION_FAILED || m.getEncryption() == Message.ENCRYPTION_PGP;