log viewer: add heuristic for triggering a new limit load early

Less latency for the user

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
This commit is contained in:
Thomas Lamprecht 2021-11-24 18:26:22 +01:00
parent 4e95d1e906
commit 1eb5c21d91

View File

@ -161,7 +161,9 @@ Ext.define('Proxmox.panel.LogView', {
let { start, limit } = viewModel.get('params');
if (viewStart < start || viewEnd > start + limit) {
let margin = start < 20 ? 0 : 20;
if (viewStart < start + margin || viewEnd > start + limit - margin) {
me.updateStart(false, line);
}
},