diff options
-rw-r--r-- | wee_slack.py | 18 |
1 files changed, 10 insertions, 8 deletions
diff --git a/wee_slack.py b/wee_slack.py index a7b0abe..e83f0ba 100644 --- a/wee_slack.py +++ b/wee_slack.py @@ -446,15 +446,17 @@ class Channel(object): self.active = False def set_typing(self, user): - self.typing[user] = time.time() - buffer_list_update_next() + if w.buffer_get_integer(self.channel_buffer, "hidden") == 0: + self.typing[user] = time.time() + buffer_list_update_next() def unset_typing(self, user): - try: - del self.typing[user] - buffer_list_update_next() - except: - pass + if w.buffer_get_integer(self.channel_buffer, "hidden") == 0: + try: + del self.typing[user] + buffer_list_update_next() + except: + pass def send_message(self, message): message = self.linkify_text(message) @@ -514,7 +516,7 @@ class Channel(object): return True if len(self.typing) > 0: self.typing = {} - buffer_list_update_next() + #buffer_list_update_next() return False def get_typing_list(self): |