From e0ae7daaac416e1030956f64cab397c4ef93139e Mon Sep 17 00:00:00 2001 From: ccd0 Date: Wed, 5 Dec 2018 13:22:36 -0800 Subject: [PATCH] Make site prefix optional, behind 'Show Site Prefix' preference in thread watcher menu. --- src/Monitoring/ThreadWatcher.coffee | 4 ++-- src/config/Config.coffee | 4 ++++ 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/src/Monitoring/ThreadWatcher.coffee b/src/Monitoring/ThreadWatcher.coffee index b3f77f7d5..5c6a16270 100644 --- a/src/Monitoring/ThreadWatcher.coffee +++ b/src/Monitoring/ThreadWatcher.coffee @@ -308,7 +308,7 @@ ThreadWatcher = {excerpt} = data excerpt or= "/#{boardID}/ - No.#{threadID}" - excerpt = ThreadWatcher.prefixes[siteID] + excerpt + excerpt = ThreadWatcher.prefixes[siteID] + excerpt if Conf['Show Site Prefix'] link = $.el 'a', href: SW[software]?.urls.thread({siteID, boardID, threadID}) or '' @@ -528,6 +528,6 @@ ThreadWatcher = $.addClass entry.el, 'disabled' entry.el.title += '\n[Remember Last Read Post is disabled.]' $.on input, 'change', $.cb.checked - $.on input, 'change', ThreadWatcher.refresh if name in ['Current Board', 'Show Unread Count'] + $.on input, 'change', ThreadWatcher.refresh if name in ['Current Board', 'Show Unread Count', 'Show Site Prefix'] $.on input, 'change', ThreadWatcher.fetchAuto if name in ['Show Unread Count', 'Auto Update Thread Watcher'] entry diff --git a/src/config/Config.coffee b/src/config/Config.coffee index 51dcb2a41..fdcc39acc 100644 --- a/src/config/Config.coffee +++ b/src/config/Config.coffee @@ -676,6 +676,10 @@ Config = true 'Show number of unread posts in watched threads.' ] + 'Show Site Prefix': [ + true + 'When multiple sites are shown in the thread watcher, add a prefix to board names to distinguish them.' + ] 'Require OP Quote Link': [ false 'For purposes of thread watcher highlighting, only consider posts with a quote link to the OP as replies to the OP.'