]> git.wh0rd.org - tt-rss.git/blobdiff - tt-rss.js
basic functionality pass 3
[tt-rss.git] / tt-rss.js
index 2cedbc0ebaa63714daf413990d8e39bfada4d12e..7e66998566ba7394bf7414e862e86696d2f600b9 100644 (file)
--- a/tt-rss.js
+++ b/tt-rss.js
@@ -90,12 +90,17 @@ function view_callback() {
 }
 
 
-function update_feed_list() {
+function update_feed_list(called_from_timer) {
+
+       if (called_from_timer != true) {
+               document.getElementById("feeds").innerHTML = "Updating feeds, please wait...";
+       }
 
        xmlhttp.open("GET", "backend.php?op=feeds", true);
        xmlhttp.onreadystatechange=feedlist_callback;
        xmlhttp.send(null);
 
+
 }
 
 function viewfeed(feed, skip, ext) {
@@ -135,10 +140,20 @@ function view(id,feed_id) {
 
 }
 
+function timeout() {
+
+       update_feed_list(true);
+
+       setTimeout("timeout()", 120*1000);
+
+}
+
 function init() {
 
        notify("init");
 
        update_feed_list();
 
+       setTimeout("timeout()", 120*1000);
+
 }