From ac6ce5dfac8d891c9a7e5b55162e19124a26811c Mon Sep 17 00:00:00 2001 From: max-m Date: Sat, 3 Dec 2011 21:23:13 +0100 Subject: [PATCH] Fixed topic animation. --- file/js/TimWolla.WCF.Chat.js | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/file/js/TimWolla.WCF.Chat.js b/file/js/TimWolla.WCF.Chat.js index d6f4e55..5a81c71 100644 --- a/file/js/TimWolla.WCF.Chat.js +++ b/file/js/TimWolla.WCF.Chat.js @@ -46,9 +46,17 @@ if (typeof TimWolla.WCF == 'undefined') TimWolla.WCF = {}; type: 'POST', success: $.proxy(function (data, textStatus, jqXHR) { // set new topic - $('#topic').text(data.topic); - if (data.topic == '') $('#topic').wcfBlindOut(); - else $('#topic').wcfBlindIn(); + if (data.topic == '') { + $('#topic').wcfBlindOut('vertical', function() { + $('#topic').text(''); + }); + } else { + if($('#topic').text() != "") $('#topic').text(data.topic); + else { + $('#topic').text(data.topic); + $('#topic').wcfBlindIn(); + } + } // set page-title $('title').text(this.titleTemplate.fetch(data));