From 49bc5bbc7bc97e4767955a283a4bfe560926eaba Mon Sep 17 00:00:00 2001 From: Stephen Paul Weber Date: Tue, 23 Jan 2024 13:35:45 -0500 Subject: [PATCH] Allow sending subject-only with thread --- .../java/eu/siacs/conversations/ui/ConversationFragment.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main/java/eu/siacs/conversations/ui/ConversationFragment.java b/src/main/java/eu/siacs/conversations/ui/ConversationFragment.java index 7604505c7df9534f47676ea519179182160fe30c..a19058c5dba5a2c596a33b519d086cbaea266532 100644 --- a/src/main/java/eu/siacs/conversations/ui/ConversationFragment.java +++ b/src/main/java/eu/siacs/conversations/ui/ConversationFragment.java @@ -945,7 +945,7 @@ public class ConversationFragment extends XmppFragment if (body == null) body = new SpannableStringBuilder(""); final Conversation conversation = this.conversation; final boolean hasSubject = binding.textinputSubject.getText().length() > 0; - if (conversation == null || body.length() == 0) { // (conversation.getThread() == null || !hasSubject))) https://issues.prosody.im/1838 + if (conversation == null || (body.length() == 0 && (conversation.getThread() == null || !hasSubject))) { binding.textSendButton.showContextMenu(0, 0); return; } @@ -3683,7 +3683,7 @@ public class ConversationFragment extends XmppFragment final Activity activity = getActivity(); if (activity != null) { this.binding.textSendButton.setImageDrawable( - SendButtonTool.getSendButtonImageResource(activity, action, status, text.length() > 0 || hasAttachments)); // || (c.getThread() != null && binding.textinputSubject.getText().length() > 0))); https://issues.prosody.im/1838 + SendButtonTool.getSendButtonImageResource(activity, action, status, text.length() > 0 || hasAttachments || (c.getThread() != null && binding.textinputSubject.getText().length() > 0))); } ViewGroup.LayoutParams params = binding.threadIdenticonLayout.getLayoutParams();