From 4256c764aee0777770466115a97420d9b55c23ac Mon Sep 17 00:00:00 2001 From: Luboš Luňák Date: Sat, 5 Mar 2022 11:23:38 +0100 Subject: do not pass XComponentContext to officecfg::...::get() calls MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit It's used only for the ConfigurationWrapper singleton, so it's used only the first time and then ignored. It also causes calls to comphelper::getProcessComponentContext() for every single invocation despite the value not being needed, and the calls may not be cheap (it's ~5% CPU during ODS save because relatively frequent calls to officecfg::Office::Common::Save::ODF::DefaultVersion::get()). Change-Id: I02c17a1a9cb498aeef220ddd5a0bde5523cb0ffb Reviewed-on: https://gerrit.libreoffice.org/c/core/+/131056 Tested-by: Jenkins Reviewed-by: Luboš Luňák --- include/svx/PaletteManager.hxx | 1 - include/svx/charmap.hxx | 1 - 2 files changed, 2 deletions(-) (limited to 'include/svx') diff --git a/include/svx/PaletteManager.hxx b/include/svx/PaletteManager.hxx index d67623555157..4e45df0012e6 100644 --- a/include/svx/PaletteManager.hxx +++ b/include/svx/PaletteManager.hxx @@ -47,7 +47,6 @@ class SVXCORE_DLLPUBLIC PaletteManager std::vector> m_Palettes; ColorSelectFunction maColorSelectFunction; - css::uno::Reference < css::uno::XComponentContext > m_context; std::unique_ptr m_pColorDlg; public: diff --git a/include/svx/charmap.hxx b/include/svx/charmap.hxx index 512b561ee997..faf5aea9b7e1 100644 --- a/include/svx/charmap.hxx +++ b/include/svx/charmap.hxx @@ -128,7 +128,6 @@ protected: std::deque maFavCharFontList; rtl::Reference m_xAccessible; - uno::Reference< uno::XComponentContext > mxContext; tools::Long nX; tools::Long nY; tools::Long m_nXGap; -- cgit