From e02798dc19401d8a121dafa9aa28dbe6332ec852 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Philipp=20H=C3=B6rist?= Date: Mon, 1 May 2017 17:52:19 +0200 Subject: [PATCH] Dont send chatstates to own resources --- src/chat_control.py | 3 +++ src/chat_control_base.py | 4 +++- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/src/chat_control.py b/src/chat_control.py index 1ba4a8672..acab47a51 100644 --- a/src/chat_control.py +++ b/src/chat_control.py @@ -1233,6 +1233,9 @@ class ChatControl(ChatControlBase): if contact and contact.sub in ('to', 'none'): return + if self.contact.jid == gajim.get_jid_from_account(self.account): + return + elif chatstate_setting == 'composing_only' and state != 'active' and\ state != 'composing': return diff --git a/src/chat_control_base.py b/src/chat_control_base.py index 1b461caaf..b6f3f9cbd 100644 --- a/src/chat_control_base.py +++ b/src/chat_control_base.py @@ -701,7 +701,9 @@ class ChatControlBase(MessageControl, ChatCommandProcessor, CommandTools): # refresh timers self.reset_kbd_mouse_timeout_vars() - if gajim.config.get('outgoing_chat_state_notifications') == 'disabled': + notifications = gajim.config.get('outgoing_chat_state_notifications') + if (self.contact.jid == gajim.get_jid_from_account(self.account) or + notifications == 'disabled'): chatstate = None label = self.get_seclabel()