From 296c90d688eabffba6f4be72a317a5aaf7db5b6d Mon Sep 17 00:00:00 2001 From: tehcneko Date: Sun, 30 Nov 2025 19:14:30 +0800 Subject: [PATCH] WebUI: Fix row selection by Shift key with virtual list enabled Fixes #23336. PR #23543. --- src/webui/www/private/scripts/dynamicTable.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/webui/www/private/scripts/dynamicTable.js b/src/webui/www/private/scripts/dynamicTable.js index e8cfa0755..09f7fc50e 100644 --- a/src/webui/www/private/scripts/dynamicTable.js +++ b/src/webui/www/private/scripts/dynamicTable.js @@ -761,13 +761,13 @@ window.qBittorrent.DynamicTable ??= (() => { } let select = false; - for (const tr of this.getTrs()) { - if ((tr.rowId === rowId1) || (tr.rowId === rowId2)) { + for (const row of this.getFilteredAndSortedRows()) { + if ((row.rowId === rowId1) || (row.rowId === rowId2)) { select = !select; - this.selectedRows.push(tr.rowId); + this.selectedRows.push(row.rowId); } else if (select) { - this.selectedRows.push(tr.rowId); + this.selectedRows.push(row.rowId); } } this.setRowClass();