From 7bdbb8331c8341e6c3ea0b463f0a742d06972245 Mon Sep 17 00:00:00 2001 From: friendica Date: Wed, 25 Jul 2012 22:55:43 -0700 Subject: picking up the page load times a bit --- js/main.js | 39 +++++++++++++++++++++------------------ 1 file changed, 21 insertions(+), 18 deletions(-) (limited to 'js/main.js') diff --git a/js/main.js b/js/main.js index 1454dd0b5..bdc1c83e3 100644 --- a/js/main.js +++ b/js/main.js @@ -154,6 +154,27 @@ window.location.href=window.location.href } + + // start live update + + if($('#live-network').length) { src = 'network'; liveUpdate(); } + if($('#live-profile').length) { src = 'profile'; liveUpdate(); } + if($('#live-community').length) { src = 'community'; liveUpdate(); } + if($('#live-notes').length) { src = 'notes'; liveUpdate(); } + if($('#live-display').length) { + if(liking) { + liking = 0; + window.location.href=window.location.href + } + } + if($('#live-photos').length) { + if(liking) { + liking = 0; + window.location.href=window.location.href + } + } + + if(data.network == 0) { data.network = ''; $('#net-update').removeClass('show') @@ -188,24 +209,6 @@ }); - // start live update - - if($('#live-network').length) { src = 'network'; liveUpdate(); } - if($('#live-profile').length) { src = 'profile'; liveUpdate(); } - if($('#live-community').length) { src = 'community'; liveUpdate(); } - if($('#live-notes').length) { src = 'notes'; liveUpdate(); } - if($('#live-display').length) { - if(liking) { - liking = 0; - window.location.href=window.location.href - } - } - if($('#live-photos').length) { - if(liking) { - liking = 0; - window.location.href=window.location.href - } - } }) ; } -- cgit v1.2.3