aboutsummaryrefslogtreecommitdiffstats
path: root/wee_slack.py
diff options
context:
space:
mode:
authorRyan Huber <rhuber@gmail.com>2017-02-22 11:38:43 -0800
committerRyan Huber <rhuber@gmail.com>2017-02-22 11:38:43 -0800
commit10cc1908d064256f35560fd1444d97fad6bf43cf (patch)
treea35499f7864e0c06eff738026d4c127720aa4154 /wee_slack.py
parentbfcd9dbb0a71b76a598b2ad46fc02abb098fc80d (diff)
downloadwee-slack-10cc1908d064256f35560fd1444d97fad6bf43cf.tar.gz
allow disabling of channel name typing indicator
Diffstat (limited to 'wee_slack.py')
-rw-r--r--wee_slack.py19
1 files changed, 13 insertions, 6 deletions
diff --git a/wee_slack.py b/wee_slack.py
index 218cb48..9bdb73c 100644
--- a/wee_slack.py
+++ b/wee_slack.py
@@ -996,10 +996,13 @@ class SlackChannel(object):
return True
return False
def formatted_name(self, style="default", typing=False, **kwargs):
- if not typing:
- prepend = "#"
+ if config.channel_name_typing_indicator:
+ if not typing:
+ prepend = "#"
+ else:
+ prepend = ">"
else:
- prepend = ">"
+ prepend = "#"
select = {
"default": prepend + self.slack_name,
"sidebar": prepend + self.slack_name,
@@ -1416,10 +1419,13 @@ class SlackMPDMChannel(SlackChannel):
self.name = "|".join("-".join(n.split("-")[1:-1]).split("--"))
def formatted_name(self, style="default", typing=False, **kwargs):
adjusted_name = "|".join("-".join(self.slack_name.split("-")[1:-1]).split("--"))
- if not typing:
- prepend = " "
+ if config.channel_name_typing_indicator:
+ if not typing:
+ prepend = "#"
+ else:
+ prepend = ">"
else:
- prepend = ">"
+ prepend = "#"
select = {
"default": adjusted_name,
"sidebar": prepend + adjusted_name,
@@ -2865,6 +2871,7 @@ class PluginConfig(object):
'thread_suffix_color': 'lightcyan',
'unhide_buffers_with_activity': 'false',
'short_buffer_names': 'false',
+ 'channel_name_typing_indicator': 'true',
'background_load_all_history': 'false',
'never_away': 'false',
'server_aliases': '',