diff options
Diffstat (limited to 'lib/scripts/subscriptions.js')
-rw-r--r-- | lib/scripts/subscriptions.js | 15 |
1 files changed, 6 insertions, 9 deletions
diff --git a/lib/scripts/subscriptions.js b/lib/scripts/subscriptions.js index 565ea33eb..b7bffb158 100644 --- a/lib/scripts/subscriptions.js +++ b/lib/scripts/subscriptions.js @@ -21,18 +21,15 @@ jQuery(function () { $form.find("input[name='sub_target']") .click( function () { - var $input = jQuery(this); - if (!$input.prop('checked')) { + var $this = jQuery(this), show_list; + if (!$this.prop('checked')) { return; } - if ($input.val().match(/:$/)) { - $list.parent().slideDown('fast'); - } else { - $list.parent().slideUp('fast'); - if ($list.prop('checked')) { - $digest.prop('checked', 'checked'); - } + show_list = $this.val().match(/:$/); + $list.parent().dw_toggle(show_list); + if (!show_list && $list.prop('checked')) { + $digest.prop('checked', 'checked'); } } ) |