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

Take care of notify status

This commit is contained in:
Tim Düsterhus 2011-12-27 14:45:25 +01:00
parent b024554c29
commit 3b5fa3d95a

View File

@ -157,7 +157,7 @@ TimWolla.WCF ?= {}
dataType: 'json' dataType: 'json'
type: 'POST' type: 'POST'
success: $.proxy((data, textStatus, jqXHR) -> success: $.proxy((data, textStatus, jqXHR) ->
if (!@isActive) if (!@isActive && $('#chatNotify').data('status') is 1)
@newMessageCount += data.messages.length @newMessageCount += data.messages.length
if (@newMessageCount > 0) if (@newMessageCount > 0)
@timeout = setTimeout $.proxy(() -> @timeout = setTimeout $.proxy(() ->