]> git.wh0rd.org Git - tt-rss.git/commitdiff
new option: FEEDS_FRAME_REFRESH (sort-of closes #12)
authorAndrew Dolgov <fox@madoka.spb.ru>
Fri, 3 Feb 2006 08:35:30 +0000 (09:35 +0100)
committerAndrew Dolgov <fox@madoka.spb.ru>
Fri, 3 Feb 2006 08:35:30 +0000 (09:35 +0100)
backend.php
config.php-dist
tt-rss.js

index de31a0f9757dffc7736ee679525c36ae14516e01..3ba723d2eb4f42ef183ec67775df0b05bcf33f9b 100644 (file)
@@ -59,6 +59,8 @@
                } else {
                        setcookie("ttrss_vf_hreadf", 0);
                }  
+
+               setcookie('ttrss_vf_refresh', FEEDS_FRAME_REFRESH);
        }
 
        $fetch = $_GET["fetch"];
index 1051199202c43c757dd4450d7072c8c8f7f5a676..db739a75072622dddc91bf4b43a17b6ec6c6c5ad 100644 (file)
@@ -70,6 +70,9 @@
 
        define('TMP_DIRECTORY', '/tmp');
        // Directory for temporary files
+
+       define('FEEDS_FRAME_REFRESH', 600);
+       // Auto refresh interval for feeds frame (in seconds)
        
        // vim:ft=php
 ?>
index 545d7915d6df98758fb849414ebc2dbc03297b54..6e2778882ccf761381d81dbade729ebce2adddbe 100644 (file)
--- a/tt-rss.js
+++ b/tt-rss.js
@@ -253,7 +253,12 @@ function viewfeed(feed, skip, subop) {
 
 function timeout() {
        scheduleFeedUpdate(false);
-       setTimeout("timeout()", 900*1000);
+
+       var refresh_time = getCookie('ttrss_vf_refresh');
+
+       if (!refresh_time) refresh_time = 600;
+
+       setTimeout("timeout()", refresh_time*1000);
 }
 
 function resetSearch() {