offapi/UnoApi_offapi.mk | 1 offapi/com/sun/star/drawing/framework/XModuleController.idl | 38 ---------- sd/IwyuFilter_sd.yaml | 1 sd/source/ui/framework/configuration/ResourceFactoryManager.cxx | 3 sd/source/ui/framework/module/ModuleController.cxx | 4 - sd/source/ui/inc/DrawController.hxx | 4 - sd/source/ui/inc/framework/ModuleController.hxx | 12 +-- sd/source/ui/unoidl/DrawController.cxx | 2 8 files changed, 10 insertions(+), 55 deletions(-)
New commits: commit c9c217a07324146d60fe1b759cece0e108e99e8d Author: Noel Grandin <noelgran...@gmail.com> AuthorDate: Tue Jun 17 19:55:56 2025 +0200 Commit: Noel Grandin <noel.gran...@collabora.co.uk> CommitDate: Thu Jun 19 17:18:03 2025 +0200 [API CHANGE] remove drawing::framework::XModuleController this is internal to sd, no need to use UNO here Change-Id: I40c73356be2352a7e1f7738c92e4363fd5823da2 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/186710 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.gran...@collabora.co.uk> diff --git a/offapi/UnoApi_offapi.mk b/offapi/UnoApi_offapi.mk index 4ecf261816f6..39b64c5a61be 100644 --- a/offapi/UnoApi_offapi.mk +++ b/offapi/UnoApi_offapi.mk @@ -2397,7 +2397,6 @@ $(eval $(call gb_UnoApi_add_idlfiles,offapi,com/sun/star/drawing/framework,\ XConfiguration \ XConfigurationChangeListener \ XConfigurationChangeRequest \ - XModuleController \ XPane \ XPane2 \ XResource \ diff --git a/offapi/com/sun/star/drawing/framework/XModuleController.idl b/offapi/com/sun/star/drawing/framework/XModuleController.idl deleted file mode 100644 index 8d9d9b3a9d7b..000000000000 --- a/offapi/com/sun/star/drawing/framework/XModuleController.idl +++ /dev/null @@ -1,38 +0,0 @@ -/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ -/* - * This file is part of the LibreOffice project. - * - * This Source Code Form is subject to the terms of the Mozilla Public - * License, v. 2.0. If a copy of the MPL was not distributed with this - * file, You can obtain one at http://mozilla.org/MPL/2.0/. - * - * This file incorporates work covered by the following license notice: - * - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed - * with this work for additional information regarding copyright - * ownership. The ASF licenses this file to you under the Apache - * License, Version 2.0 (the "License"); you may not use this file - * except in compliance with the License. You may obtain a copy of - * the License at http://www.apache.org/licenses/LICENSE-2.0 . - */ - -module com { module sun { module star { module drawing { module framework { - -interface XView; - -/** The module controller is responsible for loading a module (ad-don, - plugin, whatever the name) when it is first used. - <p>For this there is a list in the sd::framework::ModuleController class.</p> -*/ -interface XModuleController -{ - /** When the specified resource is requested for the first time then - create a new instance of the associated factory service. - */ - void requestResource ([in] string sResourceTypeURL); -}; - -}; }; }; }; }; // ::com::sun::star::drawing::framework - -/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/sd/IwyuFilter_sd.yaml b/sd/IwyuFilter_sd.yaml index a202e9ff9fa9..fbe5fa61388b 100644 --- a/sd/IwyuFilter_sd.yaml +++ b/sd/IwyuFilter_sd.yaml @@ -231,7 +231,6 @@ excludelist: - sal/types.h sd/source/ui/inc/framework/ModuleController.hxx: # base class has to be a complete type - - com/sun/star/drawing/framework/XModuleController.hpp - com/sun/star/lang/XInitialization.hpp sd/source/ui/inc/framework/Pane.hxx: # base class has to be a complete type diff --git a/sd/source/ui/framework/configuration/ResourceFactoryManager.cxx b/sd/source/ui/framework/configuration/ResourceFactoryManager.cxx index ffcb02310756..4cc97078dd70 100644 --- a/sd/source/ui/framework/configuration/ResourceFactoryManager.cxx +++ b/sd/source/ui/framework/configuration/ResourceFactoryManager.cxx @@ -19,6 +19,7 @@ #include "ResourceFactoryManager.hxx" #include <DrawController.hxx> +#include <framework/ModuleController.hxx> #include <tools/wldcrd.hxx> #include <com/sun/star/drawing/framework/XResourceFactory.hpp> #include <com/sun/star/lang/IllegalArgumentException.hpp> @@ -155,7 +156,7 @@ Reference<XResourceFactory> ResourceFactoryManager::GetFactory ( if ( ! xFactory.is() && mxControllerManager.is()) { - Reference<XModuleController> xModuleController(mxControllerManager->getModuleController()); + rtl::Reference<ModuleController> xModuleController(mxControllerManager->getModuleController()); if (xModuleController.is()) { // Ask the module controller to provide a factory of the diff --git a/sd/source/ui/framework/module/ModuleController.cxx b/sd/source/ui/framework/module/ModuleController.cxx index 1e53089d7c6b..4a56f07c9422 100644 --- a/sd/source/ui/framework/module/ModuleController.cxx +++ b/sd/source/ui/framework/module/ModuleController.cxx @@ -121,9 +121,7 @@ void ModuleController::InstantiateStartupServices() } } -//----- XModuleController ----------------------------------------------------- - -void SAL_CALL ModuleController::requestResource (const OUString& rsResourceURL) +void ModuleController::requestResource (const OUString& rsResourceURL) { auto iFactory = maResourceToFactoryMap.find(rsResourceURL); if (iFactory == maResourceToFactoryMap.end()) diff --git a/sd/source/ui/inc/DrawController.hxx b/sd/source/ui/inc/DrawController.hxx index 7f444c881123..3f5b4306f01a 100644 --- a/sd/source/ui/inc/DrawController.hxx +++ b/sd/source/ui/inc/DrawController.hxx @@ -26,7 +26,6 @@ #include <com/sun/star/view/XFormLayerAccess.hpp> #include <com/sun/star/drawing/XDrawView.hpp> #include <com/sun/star/drawing/XSlideSorterSelectionSupplier.hpp> -#include <com/sun/star/drawing/framework/XModuleController.hpp> #include <com/sun/star/lang/XServiceInfo.hpp> #include <comphelper/uno3.hxx> #include <cppuhelper/implbase.hxx> @@ -213,8 +212,7 @@ public: SD_DLLPUBLIC const rtl::Reference<sd::framework::ConfigurationController> & getConfigurationController(); - css::uno::Reference<css::drawing::framework::XModuleController> - getModuleController(); + rtl::Reference<sd::framework::ModuleController> getModuleController(); // XSlideSorterSelectionSupplier virtual css::uno::Any SAL_CALL getSlideSorterSelection( ) override; diff --git a/sd/source/ui/inc/framework/ModuleController.hxx b/sd/source/ui/inc/framework/ModuleController.hxx index 0dc0aded37b9..2237ec0632cf 100644 --- a/sd/source/ui/inc/framework/ModuleController.hxx +++ b/sd/source/ui/inc/framework/ModuleController.hxx @@ -19,7 +19,6 @@ #pragma once -#include <com/sun/star/drawing/framework/XModuleController.hpp> #include <com/sun/star/lang/XInitialization.hpp> #include <comphelper/compbase.hxx> #include <cppuhelper/weakref.hxx> @@ -31,9 +30,7 @@ namespace sd { class DrawController; } namespace sd::framework { -typedef comphelper::WeakComponentImplHelper < - css::drawing::framework::XModuleController - > ModuleControllerInterfaceBase; +typedef comphelper::WeakComponentImplHelper <> ModuleControllerInterfaceBase; /** The ModuleController has two tasks: @@ -61,9 +58,10 @@ public: virtual void disposing(std::unique_lock<std::mutex>&) override; - // XModuleController - - virtual void SAL_CALL requestResource(const OUString& rsResourceURL) override; + /** When the specified resource is requested for the first time then + create a new instance of the associated factory service. + */ + void requestResource(const OUString& rsResourceURL); private: rtl::Reference<::sd::DrawController> mxController; diff --git a/sd/source/ui/unoidl/DrawController.cxx b/sd/source/ui/unoidl/DrawController.cxx index 366a752ead96..1dfee591dc68 100644 --- a/sd/source/ui/unoidl/DrawController.cxx +++ b/sd/source/ui/unoidl/DrawController.cxx @@ -558,7 +558,7 @@ const rtl::Reference<framework::ConfigurationController> & return mxConfigurationController; } -Reference<XModuleController> DrawController::getModuleController() +rtl::Reference<framework::ModuleController> DrawController::getModuleController() { ThrowIfDisposed();