diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2024-10-10 09:39:14 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2024-10-16 07:38:45 +0200 |
commit | 7f42f031ed1b9f374f3fcba9c814dc5862492026 (patch) | |
tree | 96c46bce70ed5538f884e5aacf1357fcc5a7632c /vcl/unx | |
parent | 34b95e12a839cbcf4818bbb0b2ce26b85999e856 (diff) |
tdf#100894 speed up style tree creation
by using bulk_insert_for_each() more aggressively.
Reduces the open time from several minutes to 18s on my machine.
I had to pass down a flag, because the gtk and the gen weld
backends work differently, and the gen backend absolutely
has to know up front if the inserter function is going to
call set_text, otherwise it asserts in SvTreeListBox::SetEntryText
Change-Id: I84750888c0a80f4041cfe024e6570dd94f6d09db
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/174757
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'vcl/unx')
-rw-r--r-- | vcl/unx/gtk3/gtkinst.cxx | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/vcl/unx/gtk3/gtkinst.cxx b/vcl/unx/gtk3/gtkinst.cxx index 8ebd7625b259..c7a460656f07 100644 --- a/vcl/unx/gtk3/gtkinst.cxx +++ b/vcl/unx/gtk3/gtkinst.cxx @@ -15320,7 +15320,8 @@ public: virtual void bulk_insert_for_each(int nSourceCount, const std::function<void(weld::TreeIter&, int nSourceIndex)>& func, const weld::TreeIter* pParent, - const std::vector<int>* pFixedWidths) override + const std::vector<int>* pFixedWidths, + bool /*bGoingToSetText*/) override { GtkInstanceTreeIter* pGtkIter = const_cast<GtkInstanceTreeIter*>(static_cast<const GtkInstanceTreeIter*>(pParent)); |