only request total counters on initial update request
This commit is contained in:
parent
ab5eb26fba
commit
2bf6e0a824
|
@ -751,15 +751,17 @@
|
||||||
|
|
||||||
$omode = $_GET["omode"];
|
$omode = $_GET["omode"];
|
||||||
|
|
||||||
if (!$omode) $omode = "tfl";
|
if (!$omode) $omode = "tflc";
|
||||||
|
|
||||||
if (strchr($omode, "l")) getLabelCounters($link);
|
if (strchr($omode, "l")) getLabelCounters($link);
|
||||||
if (strchr($omode, "f")) getFeedCounters($link);
|
if (strchr($omode, "f")) getFeedCounters($link);
|
||||||
if (strchr($omode, "t")) getTagCounters($link);
|
if (strchr($omode, "t")) getTagCounters($link);
|
||||||
|
if (strchr($omode, "c")) {
|
||||||
if (get_pref($link, 'ENABLE_FEED_CATS')) {
|
if (get_pref($link, 'ENABLE_FEED_CATS')) {
|
||||||
getCategoryCounters($link);
|
getCategoryCounters($link);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
getGlobalCounters($link, $global_unread);
|
getGlobalCounters($link, $global_unread);
|
||||||
|
|
||||||
|
|
|
@ -199,7 +199,7 @@ function init() {
|
||||||
try {
|
try {
|
||||||
hideOrShowFeeds(document, getCookie("ttrss_vf_hreadf") == 1);
|
hideOrShowFeeds(document, getCookie("ttrss_vf_hreadf") == 1);
|
||||||
document.onkeydown = hotkey_handler;
|
document.onkeydown = hotkey_handler;
|
||||||
parent.setTimeout("timeout()", 1000);
|
parent.setTimeout("timeout()", 0);
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
exception_error("feedlist/init", e);
|
exception_error("feedlist/init", e);
|
||||||
}
|
}
|
||||||
|
|
|
@ -7,6 +7,7 @@ var active_title_text = "";
|
||||||
var current_subtitle = "";
|
var current_subtitle = "";
|
||||||
var daemon_enabled = false;
|
var daemon_enabled = false;
|
||||||
var _qfd_deleted_feed = 0;
|
var _qfd_deleted_feed = 0;
|
||||||
|
var firsttime_update = true;
|
||||||
|
|
||||||
/*@cc_on @*/
|
/*@cc_on @*/
|
||||||
/*@if (@_jscript_version >= 5)
|
/*@if (@_jscript_version >= 5)
|
||||||
|
@ -184,15 +185,21 @@ function scheduleFeedUpdate(force) {
|
||||||
|
|
||||||
var omode;
|
var omode;
|
||||||
|
|
||||||
|
if (firsttime_update) {
|
||||||
|
firsttime_update = false;
|
||||||
|
omode = "T";
|
||||||
|
} else {
|
||||||
if (display_tags) {
|
if (display_tags) {
|
||||||
omode = "t";
|
omode = "t";
|
||||||
} else {
|
} else {
|
||||||
omode = "fl";
|
omode = "flc";
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
query_str = query_str + "&omode=" + omode;
|
query_str = query_str + "&omode=" + omode;
|
||||||
query_str = query_str + "&uctr=" + global_unread;
|
query_str = query_str + "&uctr=" + global_unread;
|
||||||
|
|
||||||
|
|
||||||
if (xmlhttp_ready(xmlhttp)) {
|
if (xmlhttp_ready(xmlhttp)) {
|
||||||
xmlhttp.open("GET", query_str, true);
|
xmlhttp.open("GET", query_str, true);
|
||||||
xmlhttp.onreadystatechange=refetch_callback;
|
xmlhttp.onreadystatechange=refetch_callback;
|
||||||
|
|
Loading…
Reference in New Issue