1
0
mirror of https://github.com/wbbaddons/Tims-Chat.git synced 2024-12-22 21:40:08 +00:00

Use .default for hot-status

Thanks @Luzifr
This commit is contained in:
Tim Düsterhus 2012-02-07 17:39:24 +01:00
parent a8ae61b4e1
commit d3c2cc5a10

View File

@ -139,7 +139,7 @@ consoleMock ?=
# Immediatly scroll down when activating autoscroll # Immediatly scroll down when activating autoscroll
$('#timsChatAutoscroll').click (event) -> $('#timsChatAutoscroll').click (event) ->
$(this).removeClass('hot') $(this).parent().removeClass('default')
if $(this).data 'status' if $(this).data 'status'
$('.timsChatMessageContainer').scrollTop $('.timsChatMessageContainer ul').height() $('.timsChatMessageContainer').scrollTop $('.timsChatMessageContainer ul').height()
@oldScrollTop = $('.timsChatMessageContainer').scrollTop() @oldScrollTop = $('.timsChatMessageContainer').scrollTop()
@ -248,7 +248,7 @@ consoleMock ?=
if $('.timsChatMessageContainer').scrollTop() < @oldScrollTop if $('.timsChatMessageContainer').scrollTop() < @oldScrollTop
if $('#timsChatAutoscroll').data('status') is 1 if $('#timsChatAutoscroll').data('status') is 1
$('#timsChatAutoscroll').click() $('#timsChatAutoscroll').click()
$('#timsChatAutoscroll').addClass('hot').fadeOut('slow').fadeIn('slow') $('#timsChatAutoscroll').parent().addClass('default').fadeOut('slow').fadeIn('slow')
# Insert the messages # Insert the messages
for message in messages for message in messages