summaryrefslogtreecommitdiff
path: root/static/js/pichat.js
diff options
context:
space:
mode:
authordumpfmprod <dumpfmprod@ubuntu.(none)>2010-09-03 21:03:39 -0400
committerdumpfmprod <dumpfmprod@ubuntu.(none)>2010-09-03 21:03:39 -0400
commit622122468f565bfb1c52245affd07413c6aecca6 (patch)
treeddeb6cd30be6698ef0fcf539dc9920fe19e1cf7f /static/js/pichat.js
parent5215fa49a2c64d7c015e638f72bd7c4b280b0beb (diff)
sostler prod commit
Diffstat (limited to 'static/js/pichat.js')
-rw-r--r--static/js/pichat.js12
1 files changed, 5 insertions, 7 deletions
diff --git a/static/js/pichat.js b/static/js/pichat.js
index 7611edb..ef45935 100644
--- a/static/js/pichat.js
+++ b/static/js/pichat.js
@@ -440,11 +440,7 @@ function isDuplicateMessage(m) {
function refresh() {
var onSuccess = function(json) {
try {
- if (json.v && (typeof Version == 'undefined' || Version != json.v)) {
- location.reload();
- }
-
- Timestamp = json.timestamp;
+ Timestamp = json.timestamp;
$.map(json.messages, function(msg){ MessageContentCache[msg.msg_id.toString()] = msg.content })
@@ -624,7 +620,7 @@ function initChatThumb(){
$(this).attr("src", Imgs.chatThumb);
$(this).stop().animate(Anim.chatThumb, 'fast');
} else {
- $(this).stop().animate(Anim.chatThumbTiny, 'fast', 'swing',
+ $(this).delay(600).stop().animate(Anim.chatThumbTiny, 'fast', 'swing',
function(){
$(this).attr("src", Imgs.chatThumbDot)
$(this).animate(Anim.chatThumb, 0)
@@ -634,6 +630,7 @@ function initChatThumb(){
})
}
+
function paletteToChat(img){
var chatText = $("#msgInput").val()
if (chatText.length && chatText[chatText.length - 1] != " ")
@@ -1214,7 +1211,8 @@ var HasFocus = true;
function onFocus() {
HasFocus = true;
UnseenMsgCounter = 0;
- $('title').text(OrigTitle);
+ // Courtesy http://stackoverflow.com/questions/2952384/changing-the-window-title-when-focussing-the-window-doesnt-work-in-chrome
+ window.setTimeout(function () { $('title').text(OrigTitle); }, 100);
}
function onBlur() {