From 1a3923cdf448dcb1fc81b438ff42c0e4e9be7e59 Mon Sep 17 00:00:00 2001 From: Nikos Kouremenos Date: Tue, 19 Jul 2005 22:59:20 +0000 Subject: [PATCH] [aldafu] patch for disabling sending chat state notif --- src/common/config.py | 1 + src/tabbed_chat_window.py | 4 ++++ 2 files changed, 5 insertions(+) diff --git a/src/common/config.py b/src/common/config.py index 4634aef13..0698859a4 100644 --- a/src/common/config.py +++ b/src/common/config.py @@ -117,6 +117,7 @@ class Config: 'dictionary_url': [opt_str, 'http://dictionary.reference.com/search?q='], 'always_english_wikipedia': [opt_bool, False], 'use_dbus': [opt_bool, True], # allow control via dbus service + 'send_chat_state_notifications': [opt_bool, True], } __options_per_key = { diff --git a/src/tabbed_chat_window.py b/src/tabbed_chat_window.py index d5c4ec8ff..412352256 100644 --- a/src/tabbed_chat_window.py +++ b/src/tabbed_chat_window.py @@ -425,6 +425,10 @@ class TabbedChatWindow(chat.Chat): # False if peer does not support jep85 # 'ask' if we sent 'active' chatstate and are waiting for reply + # do nothing if config has typing notifications disabled + if not gajim.config.get('send_chat_state_notifications'): + return + jid = self.get_active_jid() if self.chatstates[jid] == False: