diff options
Diffstat (limited to 'modules-available')
-rw-r--r-- | modules-available/dnbd3/templates/page-serverlist.html | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/modules-available/dnbd3/templates/page-serverlist.html b/modules-available/dnbd3/templates/page-serverlist.html index 5ec3f5f9..b5588fc0 100644 --- a/modules-available/dnbd3/templates/page-serverlist.html +++ b/modules-available/dnbd3/templates/page-serverlist.html @@ -464,13 +464,14 @@ document.addEventListener('DOMContentLoaded', function () { var inactiveCount = 0; var updateSpeed = function() { if (hiddenProp && document[hiddenProp]) { - inactiveCount++; - return; - } - if (inactiveCount > 3) { - history.push(-1); + if (++inactiveCount > 30) + return; + } else { + if (inactiveCount > 30) { + history.push(-1); + } + inactiveCount = 0; } - inactiveCount = 0; $.ajax('?do=dnbd3&action=stats').done(function(elist) { var speedSum = 0; for (var k in elist) { @@ -548,7 +549,7 @@ document.addEventListener('DOMContentLoaded', function () { gctx.fillStyle = BAR_COLOR; } else { var v = Math.round((1 - part[i] / max) * 100); - gctx.fillRect(x - 10, v, 10, 100); + gctx.fillRect(x - 10, v, 9, 100); if (peakList[i]) { gctx.fillStyle = '#333'; gctx.fillText(formatBytes(part[i]) + "/s", x + 1, v); |