vcl/qt5/QtInstanceBuilder.cxx | 1 + vcl/qt5/QtInstanceTreeView.cxx | 13 ++++++++++--- 2 files changed, 11 insertions(+), 3 deletions(-)
New commits: commit badce2cebc3c37f51254dc036d7c0a4601187f43 Author: Michael Weghorn <m.wegh...@posteo.de> AuthorDate: Tue May 27 09:38:02 2025 +0200 Commit: Michael Weghorn <m.wegh...@posteo.de> CommitDate: Tue May 27 11:56:21 2025 +0200 tdf#130857 qt weld: Support new toolbar tab page Declare support for the "View" -> "User Interface" dialog's new "Toolbars" tab page introduced in commit 4ab26f4ea0c627844531144a6a903c357a604a5e Date: Mon May 26 12:03:40 2025 +0200 Resolves tdf#158880 - Let users select multiple toolbars at once in QtInstanceBuilder. This makes the content of that tab page show up when using the qt6 VCL plugin with SAL_VCL_QT_USE_WELDED_WIDGETS=1. The toolbar visibility does not yet get toggled when (un)checking the corresponding checkbox, but that will be implemented in an upcoming commit. Change-Id: I3d0f4ec98c551a11c210f02800ef6d940aba96fe Reviewed-on: https://gerrit.libreoffice.org/c/core/+/185884 Reviewed-by: Michael Weghorn <m.wegh...@posteo.de> Tested-by: Jenkins diff --git a/vcl/qt5/QtInstanceBuilder.cxx b/vcl/qt5/QtInstanceBuilder.cxx index 73c3406ee4f5..bfa127afd902 100644 --- a/vcl/qt5/QtInstanceBuilder.cxx +++ b/vcl/qt5/QtInstanceBuilder.cxx @@ -87,6 +87,7 @@ bool QtInstanceBuilder::IsUIFileSupported(const OUString& rUIFile, const weld::W u"cui/ui/splitcellsdialog.ui"_ustr, u"cui/ui/tipofthedaydialog.ui"_ustr, u"cui/ui/toolbarmodedialog.ui"_ustr, + u"cui/ui/toolbartabpage.ui"_ustr, u"cui/ui/uitabpage.ui"_ustr, u"cui/ui/welcomedialog.ui"_ustr, u"cui/ui/whatsnewtabpage.ui"_ustr, commit 8190aefd1ff80fb8679febdadca784f551bf6f08 Author: Michael Weghorn <m.wegh...@posteo.de> AuthorDate: Tue May 27 09:09:49 2025 +0200 Commit: Michael Weghorn <m.wegh...@posteo.de> CommitDate: Tue May 27 11:56:07 2025 +0200 tdf#130857 qt weld: Implement QtInstanceTreeView::get_iter_index_in_parent This is used in the "View" -> "User Interface" dialog's new "Toolbars" tab page introduced in commit 4ab26f4ea0c627844531144a6a903c357a604a5e Date: Mon May 26 12:03:40 2025 +0200 Resolves tdf#158880 - Let users select multiple toolbars at once , so support it in preparation of declaring support for that tab page in an upcoming commit. Change-Id: If31f1b920d106432760d5b521f2dde02306c79f1 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/185883 Reviewed-by: Michael Weghorn <m.wegh...@posteo.de> Tested-by: Jenkins diff --git a/vcl/qt5/QtInstanceTreeView.cxx b/vcl/qt5/QtInstanceTreeView.cxx index 4da7958dde22..22398ec57e7f 100644 --- a/vcl/qt5/QtInstanceTreeView.cxx +++ b/vcl/qt5/QtInstanceTreeView.cxx @@ -438,10 +438,17 @@ int QtInstanceTreeView::get_iter_depth(const weld::TreeIter& rIter) const return nDepth; } -int QtInstanceTreeView::get_iter_index_in_parent(const weld::TreeIter&) const +int QtInstanceTreeView::get_iter_index_in_parent(const weld::TreeIter& rIter) const { - assert(false && "Not implemented yet"); - return -1; + SolarMutexGuard g; + + int nIndex; + GetQtInstance().RunInMainThread([&] { + const QModelIndex aIndex = modelIndex(rIter); + nIndex = aIndex.row(); + }); + + return nIndex; } int QtInstanceTreeView::iter_compare(const weld::TreeIter&, const weld::TreeIter&) const