Schedule conditional formating repaint after filtering is completedcp-22.05.19-1
commitdcd369ceff53c77ba26b91f580d3be2ea105a132
authorSzymon Kłos <szymon.klos@collabora.com>
Wed, 13 Sep 2023 12:57:23 +0000 (13 14:57 +0200)
committerCaolán McNamara <caolan.mcnamara@collabora.com>
Mon, 18 Sep 2023 20:28:49 +0000 (18 22:28 +0200)
tree2968ebc7095c9a2a616a0cde3963e9d5ef765ca0
parent57e9c6309c52b194ff9350818ff2b3724255ed4a
Schedule conditional formating repaint after filtering is completed

When we have sheet with lots of data with applied conditional formatting
and that data is used with autofilter feature - filtering is very slow.
That was caused by repaints synchronously called on every row show/hide.

ScConditionalFormat::DoRepaint()   called by ScFormulaListener callback
...
ScDocument::Broadcast
ScColumn::BroadcastRows
ScTable::SetRowHidden
ScTable::DBShowRows

This patch schedules repaint in the Idle so we do that after all changes
are already applied.

Change-Id: If0876ada0f336a41b69560db6a581d6e24d7ac16
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/156897
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com>
(cherry picked from commit c838c24a7e1eee9709789aab99b242f0a0c8c419)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/156969
sc/inc/conditio.hxx
sc/qa/unit/subsequent_filters_test2.cxx
sc/source/core/data/conditio.cxx