aboutsummaryrefslogtreecommitdiff
path: root/templates/longpolling.julius
diff options
context:
space:
mode:
authorGravatar Joey Hess <joey@kitenet.net>2012-07-29 03:23:17 -0400
committerGravatar Joey Hess <joey@kitenet.net>2012-07-29 03:23:17 -0400
commit62dac858807da8fb62ce55adbed84cfe582367b2 (patch)
treeca84c8b1eac3a35c576e9ff7117b53c1ffd5c2e0 /templates/longpolling.julius
parente96107caf3745d658a36e0ad7716dd07a57657a2 (diff)
update the sidebar by long polling
Needs to use a different NotificationBroadcaster, and not replace the whole sidebar div, but instead add in new content. However, it's 3:30 am.
Diffstat (limited to 'templates/longpolling.julius')
-rw-r--r--templates/longpolling.julius8
1 files changed, 4 insertions, 4 deletions
diff --git a/templates/longpolling.julius b/templates/longpolling.julius
index 926249a35..95425d615 100644
--- a/templates/longpolling.julius
+++ b/templates/longpolling.julius
@@ -9,7 +9,7 @@
numerrs=0;
-$.LongPoll = (function() {
+$.LongPoll#{ident} = (function() {
return {
send : function() {
$.ajax({
@@ -17,7 +17,7 @@ $.LongPoll = (function() {
'dataType': 'html',
'success': function(data, status, jqxhr) {
$('##{ident}').replaceWith(data);
- setTimeout($.LongPoll.send, #{show delay});
+ setTimeout($.LongPoll#{ident}.send, #{show delay});
numerrs=0;
},
'error': function(jqxhr, msg, e) {
@@ -26,7 +26,7 @@ $.LongPoll = (function() {
window.close();
}
else {
- setTimeout($.LongPoll.send, #{show delay});
+ setTimeout($.LongPoll#{ident}.send, #{show delay});
}
},
});
@@ -35,7 +35,7 @@ $.LongPoll = (function() {
}());
$(document).bind('ready.app', function() {
- setTimeout($.LongPoll.send, #{show startdelay});
+ setTimeout($.LongPoll#{ident}.send, #{show startdelay});
});
})( jQuery );