diff --git a/backend.php b/backend.php index 71bbcea40..223842f34 100644 --- a/backend.php +++ b/backend.php @@ -534,9 +534,9 @@ print "
"; - print "
$updated_fmt, - Toggle unread + print "
$updated_fmt $id +
"; print " ctr.offsetHeight && + e.offsetTop + e.offsetHeight >= ctr.scrollTop && + e.offsetTop + e.offsetHeight <= ctr.scrollTop + ctr.offsetHeight) { + + ids.push(e.id.replace("RROW-", "")); + + } + + } + + e = e.nextSibling; + } + + debug("cdmWatchdog, ids= " + ids.toString()); + + if (ids.length > 0 && xmlhttp_ready(xmlhttp_rpc)) { + + for (var i = 0; i < ids.length; i++) { + var e = document.getElementById("RROW-" + ids[i]); + if (e) { + e.className = e.className.replace("Unread", ""); + } + } + + var query = "backend.php?op=rpc&subop=catchupSelected&ids=" + + param_escape(ids.toString()) + "&cmode=0"; + +/* xmlhttp_rpc.open("GET", query, true); + xmlhttp_rpc.onreadystatechange=all_counters_callback; + xmlhttp_rpc.send(null); */ + + } + + _cdm_wd_timeout = window.setTimeout("cdmWatchdog()", 5000); + + } catch (e) { + exception_error(e, "cdmWatchdog"); + } + +}