]> git.wh0rd.org Git - tt-rss.git/commitdiff
add a knob to disable reload on js change
authorAndrew Dolgov <fox@madoka.volgo-balt.ru>
Mon, 25 Mar 2013 12:07:39 +0000 (16:07 +0400)
committerAndrew Dolgov <fox@madoka.volgo-balt.ru>
Mon, 25 Mar 2013 12:07:39 +0000 (16:07 +0400)
include/functions.php
js/tt-rss.js

index 32fc5ae2ad67f2c9ba1af18360a0a6a840bfe6fa..9a3ea4315779360bd2404ba6a9e850c5021d7dc6 100644 (file)
                $data['cdm_expanded'] = get_pref($link, 'CDM_EXPANDED');
 
                $data['dep_ts'] = calculate_dep_timestamp();
+               $data['reload_on_ts_change'] = !defined('_NO_RELOAD_ON_TS_CHANGE');
 
                if (file_exists(LOCK_DIRECTORY . "/update_daemon.lock")) {
 
index eaa1f3daf30852b3f913afb12e7eb6b1dbbb8363..54ac077f43deedbbc55fe1182dac8b67dbdbac87 100644 (file)
@@ -447,7 +447,7 @@ function parse_runtime_info(data) {
                }
 
                if (k == "dep_ts" && parseInt(getInitParam("dep_ts")) > 0) {
-                       if (parseInt(getInitParam("dep_ts")) < parseInt(v)) {
+                       if (parseInt(getInitParam("dep_ts")) < parseInt(v) && getInitParam("reload_on_ts_change")) {
                                window.location.reload();
                        }
                }