Welcome to mirror list, hosted at ThFree Co, Russian Federation.

dev.gajim.org/gajim/gajim.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'gajim/gtk/chat_stack.py')
-rw-r--r--gajim/gtk/chat_stack.py12
1 files changed, 11 insertions, 1 deletions
diff --git a/gajim/gtk/chat_stack.py b/gajim/gtk/chat_stack.py
index b2a861643..99988286d 100644
--- a/gajim/gtk/chat_stack.py
+++ b/gajim/gtk/chat_stack.py
@@ -519,6 +519,7 @@ class ChatStack(Gtk.Stack, EventHelper):
app.window.get_action('quote').set_enabled(online)
app.window.get_action('mention').set_enabled(online)
+ app.window.get_action('reply').set_enabled(online)
def _update_group_chat_actions(self, contact: GroupchatContact) -> None:
joined = contact.is_joined
@@ -543,6 +544,7 @@ class ChatStack(Gtk.Stack, EventHelper):
app.window.get_action('quote').set_enabled(joined)
app.window.get_action('mention').set_enabled(joined)
+ app.window.get_action('reply').set_enabled(joined)
app.window.get_action('retract-message').set_enabled(joined)
def _update_participant_actions(self,
@@ -766,6 +768,11 @@ class ChatStack(Gtk.Stack, EventHelper):
if correct_id is None:
return
+ reply_data = None
+ message_reply = self._message_action_box.get_reply_data()
+ if message_reply is not None:
+ reply_data, message = message_reply
+
chatstate = client.get_module('Chatstate').get_active_chatstate(
contact)
@@ -780,11 +787,14 @@ class ChatStack(Gtk.Stack, EventHelper):
chatstate=chatstate,
label=label,
control=self._chat_control,
- correct_id=correct_id)
+ correct_id=correct_id,
+ reply_data=reply_data)
client.send_message(message_)
self._message_action_box.msg_textview.clear()
+ if message_reply is not None:
+ self._message_action_box.disable_reply_mode()
app.storage.drafts.set(contact, '')
def get_last_message_id(self, contact: ChatContactT) -> str | None: