Slightly faster PostHiding.makeButton().

This commit is contained in:
Mayhem 2013-12-14 19:53:03 +01:00
parent 8227d935cd
commit 4e0e881172

View File

@ -111,10 +111,12 @@ PostHiding =
$.event 'CloseMenu'
makeButton: (post, type) ->
span = $.el 'span',
textContent: "[\u00A0#{if type is 'hide' then '-' else '+'}\u00A0]"
a = $.el 'a',
className: "#{type}-reply-button"
innerHTML: "<span>[&nbsp;#{if type is 'hide' then '-' else '+'}&nbsp;]</span>"
href: 'javascript:;'
$.add a, span
$.on a, 'click', PostHiding.toggle
a