Add keybinding for toggling custom cooldown.
This commit is contained in:
parent
7b456ba9db
commit
62dfb5e8da
@ -196,6 +196,10 @@ Keybinds =
|
|||||||
when Conf['Next Post Quoting You']
|
when Conf['Next Post Quoting You']
|
||||||
return unless threadRoot and QuoteYou.db
|
return unless threadRoot and QuoteYou.db
|
||||||
QuoteYou.cb.seek 'following'
|
QuoteYou.cb.seek 'following'
|
||||||
|
when Conf['Toggle Cooldown']
|
||||||
|
return unless Conf['customCooldown']
|
||||||
|
return unless QR.nodes
|
||||||
|
QR.toggleCustomCooldown()
|
||||||
<% if (readJSON('/.tests_enabled')) { %>
|
<% if (readJSON('/.tests_enabled')) { %>
|
||||||
when 'v'
|
when 'v'
|
||||||
return unless threadRoot
|
return unless threadRoot
|
||||||
|
|||||||
@ -203,7 +203,7 @@ QR =
|
|||||||
QR.nodes.customCooldown.classList.toggle 'disabled', !enabled
|
QR.nodes.customCooldown.classList.toggle 'disabled', !enabled
|
||||||
|
|
||||||
toggleCustomCooldown: ->
|
toggleCustomCooldown: ->
|
||||||
enabled = $.hasClass @, 'disabled'
|
enabled = 'disabled' in QR.nodes.customCooldown.classList
|
||||||
QR.setCustomCooldown enabled
|
QR.setCustomCooldown enabled
|
||||||
$.set 'customCooldownEnabled', enabled
|
$.set 'customCooldownEnabled', enabled
|
||||||
|
|
||||||
|
|||||||
@ -996,6 +996,10 @@ Config =
|
|||||||
'Alt+Down'
|
'Alt+Down'
|
||||||
'Scroll to the next post that quotes you.'
|
'Scroll to the next post that quotes you.'
|
||||||
]
|
]
|
||||||
|
'Toggle Cooldown': [
|
||||||
|
'Shift+p'
|
||||||
|
'Toggle custom cooldown timer.'
|
||||||
|
]
|
||||||
|
|
||||||
updater:
|
updater:
|
||||||
checkbox:
|
checkbox:
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user