diff options
Diffstat (limited to 'framework/inc')
29 files changed, 77 insertions, 106 deletions
diff --git a/framework/inc/dispatch/mailtodispatcher.hxx b/framework/inc/dispatch/mailtodispatcher.hxx index 91acd5b837de..72ad6396795e 100644 --- a/framework/inc/dispatch/mailtodispatcher.hxx +++ b/framework/inc/dispatch/mailtodispatcher.hxx @@ -76,14 +76,14 @@ class MailToDispatcher : // interfaces private: /// reference to global uno service manager which had created us - css::uno::Reference< css::lang::XMultiServiceFactory > m_xFactory; + css::uno::Reference< css::uno::XComponentContext > m_xContext; /* interface */ public: // ctor/dtor - MailToDispatcher( const css::uno::Reference< css::lang::XMultiServiceFactory >& xFactory ); - virtual ~MailToDispatcher( ); + MailToDispatcher( const css::uno::Reference< css::uno::XComponentContext >& rxContext ); + virtual ~MailToDispatcher( ); // XInterface, XTypeProvider, XServiceInfo FWK_DECLARE_XINTERFACE diff --git a/framework/inc/dispatch/popupmenudispatcher.hxx b/framework/inc/dispatch/popupmenudispatcher.hxx index b534a0797d13..f1ee756e09cc 100644 --- a/framework/inc/dispatch/popupmenudispatcher.hxx +++ b/framework/inc/dispatch/popupmenudispatcher.hxx @@ -94,7 +94,7 @@ class PopupMenuDispatcher : // interfaces public: // constructor / destructor - PopupMenuDispatcher( const css::uno::Reference< css::lang::XMultiServiceFactory >& xFactory ); + PopupMenuDispatcher( const css::uno::Reference< css::uno::XComponentContext >& xContext ); // XInterface, XTypeProvider, XServiceInfo FWK_DECLARE_XINTERFACE @@ -146,7 +146,7 @@ class PopupMenuDispatcher : // interfaces css::uno::WeakReference< css::frame::XFrame > m_xWeakFrame ; /// css::uno::WeakReference to frame (Don't use a hard css::uno::Reference. Owner can't delete us then!) css::uno::Reference< css::container::XNameAccess > m_xPopupCtrlQuery ; /// reference to query for popup controller css::uno::Reference< css::uri::XUriReferenceFactory > m_xUriRefFactory ; /// reference to the uri reference factory - css::uno::Reference< css::lang::XMultiServiceFactory > m_xFactory ; /// factory shared with our owner to create new services! + css::uno::Reference< css::uno::XComponentContext > m_xContext ; /// factory shared with our owner to create new services! IMPL_ListenerHashContainer m_aListenerContainer; /// hash table for listener at specified URLs sal_Bool m_bAlreadyDisposed ; /// Protection against multiple disposing calls. sal_Bool m_bActivateListener ; /// dispatcher is listener for frame activation diff --git a/framework/inc/dispatch/systemexec.hxx b/framework/inc/dispatch/systemexec.hxx index 3469e42a6b76..c0e2b641c7dc 100644 --- a/framework/inc/dispatch/systemexec.hxx +++ b/framework/inc/dispatch/systemexec.hxx @@ -78,13 +78,13 @@ class SystemExec : // interfaces private: /// reference to global uno service manager which had created us - css::uno::Reference< css::lang::XMultiServiceFactory > m_xFactory; + css::uno::Reference< css::uno::XComponentContext > m_xContext; /* interface */ public: // ctor/dtor - SystemExec( const css::uno::Reference< css::lang::XMultiServiceFactory >& xFactory ); + SystemExec( const css::uno::Reference< css::uno::XComponentContext >& rxContext ); virtual ~SystemExec( ); // XInterface, XTypeProvider, XServiceInfo diff --git a/framework/inc/framework/statusbarconfiguration.hxx b/framework/inc/framework/statusbarconfiguration.hxx index 2c405c797573..5204e670d43b 100644 --- a/framework/inc/framework/statusbarconfiguration.hxx +++ b/framework/inc/framework/statusbarconfiguration.hxx @@ -50,7 +50,7 @@ class FWE_DLLPUBLIC StatusBarConfiguration const ::com::sun::star::uno::Reference< ::com::sun::star::container::XIndexContainer >& rStatusbarConfiguration ); static sal_Bool StoreStatusBar( - const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory >& xServiceFactory, + const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext >& xContext, const ::com::sun::star::uno::Reference< ::com::sun::star::io::XOutputStream >& xOutputStream, const ::com::sun::star::uno::Reference< ::com::sun::star::container::XIndexAccess >& rStatusbarConfiguration ); }; diff --git a/framework/inc/framework/titlehelper.hxx b/framework/inc/framework/titlehelper.hxx index 959810b1d7c5..79e78077058e 100644 --- a/framework/inc/framework/titlehelper.hxx +++ b/framework/inc/framework/titlehelper.hxx @@ -31,6 +31,7 @@ #include <com/sun/star/uno/Reference.hxx> #include <com/sun/star/uno/XInterface.hpp> +#include <com/sun/star/uno/XComponentContext.hpp> #include <com/sun/star/lang/IllegalArgumentException.hpp> #include <com/sun/star/frame/XUntitledNumbers.hpp> #include <com/sun/star/frame/XTitle.hpp> @@ -75,7 +76,7 @@ class FWE_DLLPUBLIC TitleHelper : private ::cppu::BaseMutex //--------------------------------------- /** @short lightweight constructor. */ - TitleHelper(const css::uno::Reference< css::lang::XMultiServiceFactory >& xSMGR); + TitleHelper(const css::uno::Reference< css::uno::XComponentContext >& rxContext); //--------------------------------------- /** @short free all internaly used resources. @@ -182,7 +183,7 @@ class FWE_DLLPUBLIC TitleHelper : private ::cppu::BaseMutex private: /** points to the global uno service manager. */ - css::uno::Reference< css::lang::XMultiServiceFactory > m_xSMGR; + css::uno::Reference< css::uno::XComponentContext> m_xContext; /** reference to the outside UNO class using this helper. */ css::uno::WeakReference< css::uno::XInterface > m_xOwner; diff --git a/framework/inc/framework/toolboxconfiguration.hxx b/framework/inc/framework/toolboxconfiguration.hxx index 1e31bbb8dbac..b8282bc0b99f 100644 --- a/framework/inc/framework/toolboxconfiguration.hxx +++ b/framework/inc/framework/toolboxconfiguration.hxx @@ -42,7 +42,7 @@ class FWE_DLLPUBLIC ToolBoxConfiguration const ::com::sun::star::uno::Reference< ::com::sun::star::container::XIndexContainer >& rToolbarConfiguration ); static sal_Bool StoreToolBox( - const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory >& xServiceFactory, + const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext >& rxContext, const ::com::sun::star::uno::Reference< ::com::sun::star::io::XOutputStream >& rOutputStream, const ::com::sun::star::uno::Reference< ::com::sun::star::container::XIndexAccess >& rToolbarConfiguration ); }; diff --git a/framework/inc/general.h b/framework/inc/general.h index f131eacbb15b..3ab1556ed864 100644 --- a/framework/inc/general.h +++ b/framework/inc/general.h @@ -48,25 +48,6 @@ */ namespace css = ::com::sun::star; -namespace framework { - -//----------------------------------------------------------------------------- -/** Those macro is used to make it more clear where a synchronized block will start. - Because normal documentation code wont be recognized by some developers to be real - I need something where they are thinking about. - - At least this macro will do nothing ... it's empty. - But it should make the code more clear .-)) -*/ -#define SYNCHRONIZED_START - -//----------------------------------------------------------------------------- -/** Same then SYNCHRONIZED_START ... but instead it mark the end of such code block. -*/ -#define SYNCHRONIZED_END - -} // namespace framework - #endif // #ifndef __FRAMEWORK_GENERAL_H_ /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/framework/inc/helper/persistentwindowstate.hxx b/framework/inc/helper/persistentwindowstate.hxx index 86f63abeb17e..d9e1ae2fdfd5 100644 --- a/framework/inc/helper/persistentwindowstate.hxx +++ b/framework/inc/helper/persistentwindowstate.hxx @@ -117,7 +117,7 @@ class PersistentWindowState : // interfaces /** @short identify the application module, which is used behind the component of our frame. - @param xSMGR + @param rxContext needed to create needed uno resources. @param xFrame @@ -126,13 +126,13 @@ class PersistentWindowState : // interfaces @return [string] a module identifier for the current frame component. */ - static ::rtl::OUString implst_identifyModule(const css::uno::Reference< css::lang::XMultiServiceFactory >& xSMGR , + static ::rtl::OUString implst_identifyModule(const css::uno::Reference< css::uno::XComponentContext >& rxContext, const css::uno::Reference< css::frame::XFrame >& xFrame); //____________________________ /** @short retrieve the window state from the configuration. - @param xSMGR + @param rxContext needed to create the configuration access. @param sModuleName @@ -142,8 +142,8 @@ class PersistentWindowState : // interfaces @return [string] contains the information about position and size. */ - static ::rtl::OUString implst_getWindowStateFromConfig(const css::uno::Reference< css::lang::XMultiServiceFactory >& xSMGR , - const ::rtl::OUString& sModuleName); + static ::rtl::OUString implst_getWindowStateFromConfig(const css::uno::Reference< css::uno::XComponentContext >& rxContext , + const ::rtl::OUString& sModuleName); //____________________________ /** @short retrieve the window state from the container window. @@ -161,7 +161,7 @@ class PersistentWindowState : // interfaces //____________________________ /** @short restore the position and size on the container window. - @param xSMGR + @param rxContext needed to create the configuration access. @param sModuleName @@ -171,9 +171,9 @@ class PersistentWindowState : // interfaces @param sWindowState contains the information about position and size. */ - static void implst_setWindowStateOnConfig(const css::uno::Reference< css::lang::XMultiServiceFactory >& xSMGR , - const ::rtl::OUString& sModuleName , - const ::rtl::OUString& sWindowState ); + static void implst_setWindowStateOnConfig(const css::uno::Reference< css::uno::XComponentContext >& rxContext, + const ::rtl::OUString& sModuleName , + const ::rtl::OUString& sWindowState ); //____________________________ /** @short restore the position and size on the container window. diff --git a/framework/inc/jobs/configaccess.hxx b/framework/inc/jobs/configaccess.hxx index 30ef4f2a47d8..dd9386a19630 100644 --- a/framework/inc/jobs/configaccess.hxx +++ b/framework/inc/jobs/configaccess.hxx @@ -25,6 +25,7 @@ #include <general.h> #include <com/sun/star/lang/XMultiServiceFactory.hpp> +#include <com/sun/star/uno/XComponentContext.hpp> #include <rtl/ustring.hxx> #include <fwidllapi.h> @@ -65,7 +66,7 @@ class FWI_DLLPUBLIC ConfigAccess : public ThreadHelpBase reference to the uno service manager It's neccessary to instanciate own needed services. */ - css::uno::Reference< css::lang::XMultiServiceFactory > m_xSMGR; + css::uno::Reference< css::uno::XComponentContext > m_xContext; /** hold an opened configuration alive */ css::uno::Reference< css::uno::XInterface > m_xConfig; @@ -81,8 +82,8 @@ class FWI_DLLPUBLIC ConfigAccess : public ThreadHelpBase public: - ConfigAccess( const css::uno::Reference< css::lang::XMultiServiceFactory >& xSMGR , - const ::rtl::OUString& sRoot ); + ConfigAccess( const css::uno::Reference< css::uno::XComponentContext >& rxContext, + const ::rtl::OUString& sRoot ); virtual ~ConfigAccess(); virtual void open ( EOpenMode eMode ); diff --git a/framework/inc/jobs/helponstartup.hxx b/framework/inc/jobs/helponstartup.hxx index 86967201db69..4111c98bbae0 100644 --- a/framework/inc/jobs/helponstartup.hxx +++ b/framework/inc/jobs/helponstartup.hxx @@ -31,7 +31,7 @@ #include <com/sun/star/task/XJob.hpp> #include <com/sun/star/lang/XEventListener.hpp> #include <com/sun/star/container/XNameAccess.hpp> -#include <com/sun/star/frame/XModuleManager.hpp> +#include <com/sun/star/frame/XModuleManager2.hpp> namespace framework{ @@ -57,7 +57,7 @@ class HelpOnStartup : private ThreadHelpBase //....................................... /** @short such module manager is used to classify new opened documents. */ - css::uno::Reference< css::frame::XModuleManager > m_xModuleManager; + css::uno::Reference< css::frame::XModuleManager2 > m_xModuleManager; //....................................... /** @short is needed to locate a might open help frame. */ diff --git a/framework/inc/jobs/jobdata.hxx b/framework/inc/jobs/jobdata.hxx index acb107d9d8ac..5ca4691abb12 100644 --- a/framework/inc/jobs/jobdata.hxx +++ b/framework/inc/jobs/jobdata.hxx @@ -28,6 +28,7 @@ #include <general.h> #include <com/sun/star/lang/XMultiServiceFactory.hpp> +#include <com/sun/star/uno/XComponentContext.hpp> #include <com/sun/star/beans/NamedValue.hpp> #include <com/sun/star/frame/DispatchResultEvent.hpp> @@ -152,7 +153,7 @@ class JobData : private ThreadHelpBase We need it for creating of own uno services ... e.g. for opening the configuration. */ - css::uno::Reference< css::lang::XMultiServiceFactory > m_xSMGR; + css::uno::Reference< css::uno::XComponentContext > m_xContext; /** An instance of this class can be used in two different modes: @@ -224,7 +225,7 @@ class JobData : private ThreadHelpBase public: - JobData( const css::uno::Reference< css::lang::XMultiServiceFactory >& xSMGR ); + JobData( const css::uno::Reference< css::uno::XComponentContext >& rxContext ); JobData( const JobData& rCopy ); virtual ~JobData( ); @@ -250,10 +251,10 @@ class JobData : private ThreadHelpBase void setResult ( const JobResult& aResult ); void disableJob ( ); - static css::uno::Sequence< ::rtl::OUString > getEnabledJobsForEvent( const css::uno::Reference< css::lang::XMultiServiceFactory >& xSMGR , - const ::rtl::OUString& sEvent ); + static css::uno::Sequence< ::rtl::OUString > getEnabledJobsForEvent( const css::uno::Reference< css::uno::XComponentContext >& rxContext, + const ::rtl::OUString& sEvent ); - static void appendEnabledJobsForEvent( const css::uno::Reference< css::lang::XMultiServiceFactory >& xSMGR , + static void appendEnabledJobsForEvent( const css::uno::Reference< css::uno::XComponentContext >& rxContext, const ::rtl::OUString& sEvent , ::comphelper::SequenceAsVector< JobData::TJob2DocEventBinding >& lJobs ); diff --git a/framework/inc/jobs/jobexecutor.hxx b/framework/inc/jobs/jobexecutor.hxx index a0ab8f387fac..4b0f70f149c1 100644 --- a/framework/inc/jobs/jobexecutor.hxx +++ b/framework/inc/jobs/jobexecutor.hxx @@ -44,7 +44,7 @@ #include <com/sun/star/container/XContainerListener.hpp> #include <com/sun/star/lang/XEventListener.hpp> #include <com/sun/star/document/XEventListener.hpp> -#include <com/sun/star/frame/XModuleManager.hpp> +#include <com/sun/star/frame/XModuleManager2.hpp> #include <cppuhelper/weak.hxx> #include <rtl/ustring.hxx> @@ -77,7 +77,7 @@ class JobExecutor : public css::lang::XTypeProvider css::uno::Reference< css::lang::XMultiServiceFactory > m_xSMGR; /** reference to the module info service */ - css::uno::Reference< css::frame::XModuleManager > m_xModuleManager; + css::uno::Reference< css::frame::XModuleManager2 > m_xModuleManager; /** cached list of all registered event names of cfg for call optimization. */ OUStringList m_lEvents; diff --git a/framework/inc/macros/xserviceinfo.hxx b/framework/inc/macros/xserviceinfo.hxx index bcca5c25f6a0..6197bd3cec98 100644 --- a/framework/inc/macros/xserviceinfo.hxx +++ b/framework/inc/macros/xserviceinfo.hxx @@ -225,6 +225,10 @@ ________________________________________________________________________________ PRIVATE_DEFINE_XSERVICEINFO_NEWSTYLE( CLASS, XINTERFACECAST, SERVICENAME, IMPLEMENTATIONNAME ) \ PRIVATE_DEFINE_SINGLEFACTORY( CLASS ) +#define DEFINE_XSERVICEINFO_ONEINSTANCESERVICE_2( CLASS, XINTERFACECAST, SERVICENAME, IMPLEMENTATIONNAME ) \ + PRIVATE_DEFINE_XSERVICEINFO_NEWSTYLE( CLASS, XINTERFACECAST, SERVICENAME, IMPLEMENTATIONNAME ) \ + PRIVATE_DEFINE_ONEINSTANCEFACTORY( CLASS ) + //***************************************************************************************************************** // public // implementation of service initialize! diff --git a/framework/inc/services.h b/framework/inc/services.h index 70956ec6d9e4..e32de32c1ed3 100644 --- a/framework/inc/services.h +++ b/framework/inc/services.h @@ -34,34 +34,23 @@ namespace framework{ #define SERVICENAME_FRAMELOADERFACTORY DECLARE_ASCII("com.sun.star.frame.FrameLoaderFactory" ) #define SERVICENAME_FILTERFACTORY DECLARE_ASCII("com.sun.star.document.FilterFactory" ) #define SERVICENAME_PLUGINFRAME DECLARE_ASCII("com.sun.star.mozilla.Plugin" ) -#define SERVICENAME_BRIDGEFACTORY DECLARE_ASCII("com.sun.star.bridge.BridgeFactory" ) -#define SERVICENAME_MEDIATYPEDETECTIONHELPER DECLARE_ASCII("com.sun.star.frame.MediaTypeDetectionHelper" ) #define SERVICENAME_LOGINDIALOG DECLARE_ASCII("com.sun.star.framework.LoginDialog" ) #define SERVICENAME_CONFIGURATION DECLARE_ASCII("com.sun.star.configuration.ConfigurationRegistry" ) -#define SERVICENAME_VCLTOOLKIT DECLARE_ASCII("com.sun.star.awt.Toolkit" ) #define SERVICENAME_SIMPLEREGISTRY DECLARE_ASCII("com.sun.star.registry.SimpleRegistry" ) #define SERVICENAME_NESTEDREGISTRY DECLARE_ASCII("com.sun.star.registry.NestedRegistry" ) #define SERVICENAME_GENERICFRAMELOADER DECLARE_ASCII("com.sun.star.comp.office.FilterDetect" ) #define SERVICENAME_TYPEDETECTION DECLARE_ASCII("com.sun.star.document.TypeDetection" ) -#define SERVICENAME_DOCUMENTPROPERTIES DECLARE_ASCII("com.sun.star.document.DocumentProperties" ) #define SERVICENAME_CFGREGISTRY DECLARE_ASCII("com.sun.star.configuration.ConfigurationRegistry" ) // describe simple registry service for read access to configuration -#define SERVICENAME_CFGPROVIDER DECLARE_ASCII("com.sun.star.configuration.ConfigurationProvider" ) // describe cfg-provider service for fatoffice, network installation #define SERVICENAME_ADMINPROVIDER DECLARE_ASCII("com.sun.star.configuration.AdministrationProvider" ) // describe cfg-provider service for sun webtop #define SERVICENAME_CFGUPDATEACCESS DECLARE_ASCII("com.sun.star.configuration.ConfigurationUpdateAccess") // provides read/write access to the configuration #define SERVICENAME_CFGREADACCESS DECLARE_ASCII("com.sun.star.configuration.ConfigurationAccess" ) // provides readonly access to the configuration #define SERVICENAME_CONTENTHANDLER DECLARE_ASCII("com.sun.star.frame.ContentHandler" ) #define SERVICENAME_CONTENTHANDLERFACTORY DECLARE_ASCII("com.sun.star.frame.ContentHandlerFactory" ) #define SERVICENAME_STATUSINDICATORFACTORY DECLARE_ASCII("com.sun.star.task.StatusIndicatorFactory" ) -#define SERVICENAME_UIINTERACTIONHANDLER DECLARE_ASCII("com.sun.star.task.InteractionHandler" ) -#define SERVICENAME_JOBEXECUTOR DECLARE_ASCII("com.sun.star.task.JobExecutor" ) #define SERVICENAME_JOB DECLARE_ASCII("com.sun.star.task.Job" ) -#define SERVICENAME_DISPATCHRECORDERSUPPLIER DECLARE_ASCII("com.sun.star.frame.DispatchRecorderSupplier" ) #define SERVICENAME_DISPATCHRECORDER DECLARE_ASCII("com.sun.star.frame.DispatchRecorder" ) -#define SERVICENAME_SYSTEMSHELLEXECUTE DECLARE_ASCII("com.sun.star.system.SystemShellExecute" ) #define SERVICENAME_PROTOCOLHANDLER DECLARE_ASCII("com.sun.star.frame.ProtocolHandler" ) -#define SERVICENAME_SUBSTITUTEPATHVARIABLES DECLARE_ASCII("com.sun.star.util.PathSubstitution" ) #define SERVICENAME_PATHSETTINGS DECLARE_ASCII("com.sun.star.util.PathSettings" ) -#define SERVICENAME_DISPATCHHELPER DECLARE_ASCII("com.sun.star.frame.DispatchHelper" ) #define SERVICENAME_DETECTORFACTORY DECLARE_ASCII("com.sun.star.document.ExtendedTypeDetectionFactory" ) #define SERVICENAME_SCRIPTCONVERTER DECLARE_ASCII("com.sun.star.script.Converter" ) #define SERVICENAME_LAYOUTMANAGER DECLARE_ASCII("com.sun.star.frame.LayoutManager" ) @@ -69,7 +58,6 @@ namespace framework{ #define SERVICENAME_POPUPMENUCONTROLLER DECLARE_ASCII("com.sun.star.frame.PopupMenuController" ) #define SERVICENAME_UICOMMANDDESCRIPTION DECLARE_ASCII("com.sun.star.frame.UICommandDescription" ) #define SERVICENAME_UIELEMENTFACTORYMANAGER DECLARE_ASCII("com.sun.star.ui.UIElementFactoryManager" ) -#define SERVICENAME_MODULEMANAGER DECLARE_ASCII("com.sun.star.frame.ModuleManager" ) #define SERVICENAME_UICONFIGURATIONMANAGER DECLARE_ASCII("com.sun.star.ui.UIConfigurationManager" ) #define SERVICENAME_MODULEUICONFIGURATIONMANAGERSUPPLIER DECLARE_ASCII("com.sun.star.ui.ModuleUIConfigurationManagerSupplier" ) #define SERVICENAME_MODULEUICONFIGURATIONMANAGER DECLARE_ASCII("com.sun.star.ui.ModuleUIConfigurationManager" ) @@ -80,16 +68,12 @@ namespace framework{ #define SERVICENAME_GLOBALACCELERATORCONFIGURATION DECLARE_ASCII("com.sun.star.ui.GlobalAcceleratorConfiguration") #define SERVICENAME_MODULEACCELERATORCONFIGURATION DECLARE_ASCII("com.sun.star.ui.ModuleAcceleratorConfiguration") #define SERVICENAME_DOCUMENTACCELERATORCONFIGURATION DECLARE_ASCII("com.sun.star.ui.DocumentAcceleratorConfiguration") -#define SERVICENAME_SAXWRITER DECLARE_ASCII("com.sun.star.xml.sax.Writer" ) #define SERVICENAME_STORAGEFACTORY DECLARE_ASCII("com.sun.star.embed.StorageFactory" ) #define SERVICENAME_FILESYSTEMSTORAGEFACTORY DECLARE_ASCII("com.sun.star.embed.FileSystemStorageFactory" ) -#define SERVICENAME_TEMPFILE DECLARE_ASCII("com.sun.star.io.TempFile" ) #define SERVICENAME_PACKAGESTRUCTURECREATOR DECLARE_ASCII("com.sun.star.embed.PackageStructureCreator" ) #define SERVICENAME_TOOLBARFACTORY DECLARE_ASCII("com.sun.star.ui.ToolBarFactory" ) #define SERVICENAME_TOOLBARCONTROLLERFACTORY DECLARE_ASCII("com.sun.star.frame.ToolBarControllerFactory" ) #define SERVICENAME_LICENSE SERVICENAME_JOB -#define SERVICENAME_AUTORECOVERY DECLARE_ASCII("com.sun.star.frame.AutoRecovery" ) -#define SERVICENAME_GLOBALEVENTBROADCASTER DECLARE_ASCII("com.sun.star.frame.GlobalEventBroadcaster" ) #define SERVICENAME_STATUSBARFACTORY DECLARE_ASCII("com.sun.star.ui.StatusBarFactory" ) #define SERVICENAME_UICATEGORYDESCRIPTION DECLARE_ASCII("com.sun.star.ui.UICategoryDescription" ) #define SERVICENAME_STATUSBARCONTROLLERFACTORY DECLARE_ASCII("com.sun.star.frame.StatusbarControllerFactory" ) diff --git a/framework/inc/services/autorecovery.hxx b/framework/inc/services/autorecovery.hxx index 9f7c61c681c8..94347a0050ab 100644 --- a/framework/inc/services/autorecovery.hxx +++ b/framework/inc/services/autorecovery.hxx @@ -40,6 +40,7 @@ #include <com/sun/star/lang/XTypeProvider.hpp> #include <com/sun/star/lang/XServiceInfo.hpp> #include <com/sun/star/lang/XMultiServiceFactory.hpp> +#include <com/sun/star/frame/GlobalEventBroadcaster.hpp> #include <com/sun/star/frame/XDispatch.hpp> #include <com/sun/star/container/XNameAccess.hpp> #include <com/sun/star/document/XEventListener.hpp> @@ -344,7 +345,7 @@ class AutoRecovery : public css::lang::XTypeProvider /** @short holds the global event broadcaster alive, where we listen for new created documents. */ - css::uno::Reference< css::document::XEventBroadcaster > m_xNewDocBroadcaster; + css::uno::Reference< css::frame::XGlobalEventBroadcaster > m_xNewDocBroadcaster; //--------------------------------------- /** @short proxy weak binding to forward Events to ourself without diff --git a/framework/inc/services/layoutmanager.hxx b/framework/inc/services/layoutmanager.hxx index a757f261410c..3ff6ea106a9b 100644 --- a/framework/inc/services/layoutmanager.hxx +++ b/framework/inc/services/layoutmanager.hxx @@ -56,7 +56,7 @@ #include <com/sun/star/frame/XLayoutManager.hpp> #include <com/sun/star/ui/XUIConfigurationManager.hpp> #include <com/sun/star/ui/XUIConfiguration.hpp> -#include <com/sun/star/frame/XModuleManager.hpp> +#include <com/sun/star/frame/XModuleManager2.hpp> #include <com/sun/star/frame/XFrameActionListener.hpp> #include <com/sun/star/awt/XWindowListener.hpp> #include <com/sun/star/util/XURLTransformer.hpp> @@ -325,7 +325,7 @@ namespace framework UIElement m_aStatusBarElement; UIElement m_aProgressBarElement; com::sun::star::uno::Reference< ::com::sun::star::ui::XUIElement > m_xProgressBarBackup; - css::uno::Reference< ::com::sun::star::frame::XModuleManager > m_xModuleManager; + css::uno::Reference< ::com::sun::star::frame::XModuleManager2 > m_xModuleManager; css::uno::Reference< ::com::sun::star::ui::XUIElementFactory > m_xUIElementFactoryManager; css::uno::Reference< ::com::sun::star::container::XNameAccess > m_xPersistentWindowState; css::uno::Reference< ::com::sun::star::container::XNameAccess > m_xPersistentWindowStateSupplier; diff --git a/framework/inc/services/license.hxx b/framework/inc/services/license.hxx index b0bb81f11f06..399b07ce6e24 100644 --- a/framework/inc/services/license.hxx +++ b/framework/inc/services/license.hxx @@ -69,10 +69,10 @@ namespace framework public ::cppu::OWeakObject // => XWeak, XInterface { private: - css::uno::Reference< css::lang::XMultiServiceFactory > m_xFactory; + css::uno::Reference< css::uno::XComponentContext > m_xContext; sal_Bool m_bTerminate; public: - License( const com::sun::star::uno::Reference< com::sun::star::lang::XMultiServiceFactory >& rSMGR ); + License( const com::sun::star::uno::Reference< com::sun::star::uno::XComponentContext >& rxContext ); virtual ~License(); /** declaration of XInterface, XTypeProvider, XServiceInfo */ diff --git a/framework/inc/tabwin/tabwinfactory.hxx b/framework/inc/tabwin/tabwinfactory.hxx index a594b2a548a3..fb08f20aafbb 100644 --- a/framework/inc/tabwin/tabwinfactory.hxx +++ b/framework/inc/tabwin/tabwinfactory.hxx @@ -33,7 +33,7 @@ #include <com/sun/star/lang/XMultiServiceFactory.hpp> #include <com/sun/star/lang/XSingleComponentFactory.hpp> #include <com/sun/star/beans/PropertyValue.hpp> -#include <com/sun/star/awt/XToolkit.hpp> +#include <com/sun/star/awt/XToolkit2.hpp> #include <cppuhelper/implbase2.hxx> #include <rtl/ustring.hxx> @@ -57,7 +57,7 @@ class TabWinFactory : protected ThreadHelpBase private: ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory > m_xServiceManager; - ::com::sun::star::uno::Reference< ::com::sun::star::awt::XToolkit > m_xToolkit; + ::com::sun::star::uno::Reference< ::com::sun::star::awt::XToolkit2 > m_xToolkit; }; } diff --git a/framework/inc/uiconfiguration/globalsettings.hxx b/framework/inc/uiconfiguration/globalsettings.hxx index 49f39b1f3ca7..3b253d8100f0 100644 --- a/framework/inc/uiconfiguration/globalsettings.hxx +++ b/framework/inc/uiconfiguration/globalsettings.hxx @@ -47,7 +47,7 @@ namespace framework class GlobalSettings { public: - GlobalSettings( const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory >& rSrvMgr ); + GlobalSettings( const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext >& rxContext ); ~GlobalSettings(); enum UIElementType @@ -72,7 +72,7 @@ class GlobalSettings GlobalSettings(const GlobalSettings&); GlobalSettings& operator=(const GlobalSettings& ); - ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory > m_xSrvMgr; + ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext > m_xContext; }; } // namespace framework diff --git a/framework/inc/uiconfiguration/moduleuicfgsupplier.hxx b/framework/inc/uiconfiguration/moduleuicfgsupplier.hxx index 208c6308669d..4961ca8ad812 100644 --- a/framework/inc/uiconfiguration/moduleuicfgsupplier.hxx +++ b/framework/inc/uiconfiguration/moduleuicfgsupplier.hxx @@ -49,7 +49,7 @@ #include <com/sun/star/lang/XComponent.hpp> #include <com/sun/star/ui/XModuleUIConfigurationManagerSupplier.hpp> #include <com/sun/star/ui/XUIConfigurationManager.hpp> -#include <com/sun/star/frame/XModuleManager.hpp> +#include <com/sun/star/frame/XModuleManager2.hpp> #include <com/sun/star/embed/XStorage.hpp> #include <com/sun/star/embed/XTransactedObject.hpp> @@ -102,7 +102,7 @@ namespace framework com::sun::star::uno::Reference< com::sun::star::embed::XStorage > m_xDefaultCfgRootStorage; com::sun::star::uno::Reference< com::sun::star::embed::XStorage > m_xUserCfgRootStorage; com::sun::star::uno::Reference< com::sun::star::embed::XTransactedObject > m_xUserRootCommit; - com::sun::star::uno::Reference< ::com::sun::star::frame::XModuleManager > m_xModuleMgr; + com::sun::star::uno::Reference< ::com::sun::star::frame::XModuleManager2 > m_xModuleMgr; com::sun::star::uno::Reference< com::sun::star::lang::XMultiServiceFactory > m_xServiceManager; ::cppu::OMultiTypeInterfaceContainerHelper m_aListenerContainer; /// container for ALL Listener }; diff --git a/framework/inc/uiconfiguration/uicategorydescription.hxx b/framework/inc/uiconfiguration/uicategorydescription.hxx index 028452fb300b..bb3e73660f5b 100644 --- a/framework/inc/uiconfiguration/uicategorydescription.hxx +++ b/framework/inc/uiconfiguration/uicategorydescription.hxx @@ -43,7 +43,7 @@ namespace framework class UICategoryDescription : public UICommandDescription { public: - UICategoryDescription( const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory >& xServiceManager ); + UICategoryDescription( const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext >& rxContext ); virtual ~UICategoryDescription(); DECLARE_XSERVICEINFO diff --git a/framework/inc/uiconfiguration/windowstateconfiguration.hxx b/framework/inc/uiconfiguration/windowstateconfiguration.hxx index fbf1b20e6a75..d254d8d4005d 100644 --- a/framework/inc/uiconfiguration/windowstateconfiguration.hxx +++ b/framework/inc/uiconfiguration/windowstateconfiguration.hxx @@ -46,7 +46,7 @@ #include <com/sun/star/lang/XServiceInfo.hpp> #include <com/sun/star/lang/XTypeProvider.hpp> #include <com/sun/star/container/XNameAccess.hpp> -#include <com/sun/star/frame/XModuleManager.hpp> +#include <com/sun/star/frame/XModuleManager2.hpp> #include <cppuhelper/implbase2.hxx> #include <rtl/ustring.hxx> @@ -75,7 +75,7 @@ class WindowStateConfiguration : private ThreadHelpBase public ::cppu::WeakImplHelper2< ::com::sun::star::container::XNameAccess, css::lang::XServiceInfo> { public: - WindowStateConfiguration( const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory >& xServiceManager ); + WindowStateConfiguration( const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext >& rxContext ); virtual ~WindowStateConfiguration(); // XInterface, XTypeProvider, XServiceInfo @@ -110,10 +110,10 @@ class WindowStateConfiguration : private ThreadHelpBase ::std::equal_to< ::rtl::OUString > > ModuleToWindowStateConfigHashMap; private: - ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory > m_xServiceManager; + ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext> m_xContext; ModuleToWindowStateFileMap m_aModuleToFileHashMap; ModuleToWindowStateConfigHashMap m_aModuleToWindowStateHashMap; - ::com::sun::star::uno::Reference< ::com::sun::star::frame::XModuleManager > m_xModuleManager; + ::com::sun::star::uno::Reference< ::com::sun::star::frame::XModuleManager2 > m_xModuleManager; }; } // namespace framework diff --git a/framework/inc/uielement/uicommanddescription.hxx b/framework/inc/uielement/uicommanddescription.hxx index 8c5984ecc057..9f14a97c1875 100644 --- a/framework/inc/uielement/uicommanddescription.hxx +++ b/framework/inc/uielement/uicommanddescription.hxx @@ -45,8 +45,9 @@ #include <com/sun/star/lang/XServiceInfo.hpp> #include <com/sun/star/lang/XTypeProvider.hpp> +#include <com/sun/star/configuration/theDefaultProvider.hpp> #include <com/sun/star/container/XNameAccess.hpp> -#include <com/sun/star/frame/XModuleManager.hpp> +#include <com/sun/star/frame/XModuleManager2.hpp> #include <cppuhelper/implbase2.hxx> #include <rtl/ustring.hxx> @@ -58,7 +59,7 @@ class UICommandDescription : private ThreadHelpBase , com::sun::star::container::XNameAccess > { public: - UICommandDescription( const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory >& xServiceManager ); + UICommandDescription( const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext >& rxContext ); virtual ~UICommandDescription(); // XInterface, XTypeProvider, XServiceInfo @@ -92,16 +93,16 @@ public: ::std::equal_to< ::rtl::OUString > > UICommandsHashMap; protected: - UICommandDescription( const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory >& xServiceManager,bool ); + UICommandDescription( const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext>& rxContext, bool ); virtual ::com::sun::star::uno::Reference< ::com::sun::star::container::XNameAccess > impl_createConfigAccess(const ::rtl::OUString& _sName); void impl_fillElements(const sal_Char* _pName); sal_Bool m_bConfigRead; rtl::OUString m_aPrivateResourceURL; - ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory > m_xServiceManager; + ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext > m_xContext; ModuleToCommandFileMap m_aModuleToCommandFileMap; UICommandsHashMap m_aUICommandsHashMap; ::com::sun::star::uno::Reference< ::com::sun::star::container::XNameAccess > m_xGenericUICommands; - ::com::sun::star::uno::Reference< ::com::sun::star::frame::XModuleManager > m_xModuleManager; + ::com::sun::star::uno::Reference< ::com::sun::star::frame::XModuleManager2 > m_xModuleManager; }; } // namespace framework diff --git a/framework/inc/uifactory/addonstoolboxfactory.hxx b/framework/inc/uifactory/addonstoolboxfactory.hxx index 43097aa46119..d05f11c17c5f 100644 --- a/framework/inc/uifactory/addonstoolboxfactory.hxx +++ b/framework/inc/uifactory/addonstoolboxfactory.hxx @@ -33,7 +33,7 @@ #include <com/sun/star/lang/XMultiServiceFactory.hpp> #include <com/sun/star/beans/PropertyValue.hpp> #include <com/sun/star/ui/XUIElementFactory.hpp> -#include <com/sun/star/frame/XModuleManager.hpp> +#include <com/sun/star/frame/XModuleManager2.hpp> #include <com/sun/star/frame/XFrame.hpp> #include <com/sun/star/frame/XModel.hpp> @@ -62,7 +62,7 @@ class AddonsToolBoxFactory : protected ThreadHelpBase private: ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory > m_xServiceManager; - ::com::sun::star::uno::Reference< ::com::sun::star::frame::XModuleManager > m_xModuleManager; + ::com::sun::star::uno::Reference< ::com::sun::star::frame::XModuleManager2 > m_xModuleManager; }; } diff --git a/framework/inc/uifactory/factoryconfiguration.hxx b/framework/inc/uifactory/factoryconfiguration.hxx index d055fd6ee87e..9a2658c93cde 100644 --- a/framework/inc/uifactory/factoryconfiguration.hxx +++ b/framework/inc/uifactory/factoryconfiguration.hxx @@ -60,7 +60,7 @@ class ConfigurationAccess_ControllerFactory : // interfaces public ::cppu::WeakImplHelper1< ::com::sun::star::container::XContainerListener> { public: - ConfigurationAccess_ControllerFactory( ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory >& rServiceManager,const ::rtl::OUString& _sRoot,bool _bAskValue = false ); + ConfigurationAccess_ControllerFactory( const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext >& rxContext, const ::rtl::OUString& _sRoot,bool _bAskValue = false ); virtual ~ConfigurationAccess_ControllerFactory(); void readConfigurationData(); @@ -107,7 +107,6 @@ private: rtl::OUString m_aPropValue; rtl::OUString m_sRoot; MenuControllerMap m_aMenuControllerMap; - ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory > m_xServiceManager; ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory > m_xConfigProvider; ::com::sun::star::uno::Reference< ::com::sun::star::container::XNameAccess > m_xConfigAccess; ::com::sun::star::uno::Reference< ::com::sun::star::container::XContainerListener > m_xConfigAccessListener; diff --git a/framework/inc/uifactory/menubarfactory.hxx b/framework/inc/uifactory/menubarfactory.hxx index 135e6bad6c3f..d34025eb99fe 100644 --- a/framework/inc/uifactory/menubarfactory.hxx +++ b/framework/inc/uifactory/menubarfactory.hxx @@ -32,7 +32,7 @@ #include <com/sun/star/lang/XMultiServiceFactory.hpp> #include <com/sun/star/beans/PropertyValue.hpp> #include <com/sun/star/ui/XUIElementFactory.hpp> -#include <com/sun/star/frame/XModuleManager.hpp> +#include <com/sun/star/frame/XModuleManager2.hpp> #include <toolkit/awt/vclxmenu.hxx> #include <cppuhelper/implbase2.hxx> @@ -59,14 +59,14 @@ namespace framework ,const char* _pExtraMode ,const char* _pAsciiName ,const ::com::sun::star::uno::Reference< ::com::sun::star::ui::XUIElement >& _xMenuBar - ,const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XModuleManager >& _xModuleManager + ,const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XModuleManager2 >& _xModuleManager ,const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory >& _xServiceManager); protected: MenuBarFactory( const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory >& xServiceManager,bool ); ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory > m_xServiceManager; - ::com::sun::star::uno::Reference< ::com::sun::star::frame::XModuleManager > m_xModuleManager; + ::com::sun::star::uno::Reference< ::com::sun::star::frame::XModuleManager2 > m_xModuleManager; }; } diff --git a/framework/inc/uifactory/uielementfactorymanager.hxx b/framework/inc/uifactory/uielementfactorymanager.hxx index 99dc12f2a525..1f403e88e8b2 100644 --- a/framework/inc/uifactory/uielementfactorymanager.hxx +++ b/framework/inc/uifactory/uielementfactorymanager.hxx @@ -47,7 +47,7 @@ #include <com/sun/star/ui/XUIElementFactoryRegistration.hpp> #include <com/sun/star/container/XContainerListener.hpp> #include <com/sun/star/container/XNameAccess.hpp> -#include "com/sun/star/frame/XModuleManager.hpp" +#include "com/sun/star/frame/XModuleManager2.hpp" #include <cppuhelper/implbase1.hxx> #include <cppuhelper/implbase3.hxx> @@ -63,7 +63,7 @@ namespace framework public ::cppu::WeakImplHelper1< ::com::sun::star::container::XContainerListener> { public: - ConfigurationAccess_FactoryManager( ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory >& rServiceManager,const ::rtl::OUString& _sRoot ); + ConfigurationAccess_FactoryManager( const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext>& rxContext, const ::rtl::OUString& _sRoot ); virtual ~ConfigurationAccess_FactoryManager(); void readConfigurationData(); @@ -101,7 +101,6 @@ namespace framework rtl::OUString m_aPropFactory; ::rtl::OUString m_sRoot; FactoryManagerMap m_aFactoryManagerMap; - ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory > m_xServiceManager; ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory > m_xConfigProvider; ::com::sun::star::uno::Reference< ::com::sun::star::container::XNameAccess > m_xConfigAccess; ::com::sun::star::uno::Reference< ::com::sun::star::container::XContainerListener > m_xConfigListener; @@ -115,7 +114,7 @@ class UIElementFactoryManager : private ThreadHelpBase ::com::sun::star::ui::XUIElementFactoryRegistration> { public: - UIElementFactoryManager( const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory >& xServiceManager ); + UIElementFactoryManager( const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext >& rxContext ); virtual ~UIElementFactoryManager(); // XInterface, XTypeProvider, XServiceInfo @@ -133,8 +132,8 @@ class UIElementFactoryManager : private ThreadHelpBase private: sal_Bool m_bConfigRead; - ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory > m_xServiceManager; - ::com::sun::star::uno::Reference< ::com::sun::star::frame::XModuleManager > m_xModuleManager; + ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext > m_xContext; + ::com::sun::star::uno::Reference< ::com::sun::star::frame::XModuleManager2 > m_xModuleManager; ConfigurationAccess_FactoryManager* m_pConfigAccess; }; diff --git a/framework/inc/uifactory/windowcontentfactorymanager.hxx b/framework/inc/uifactory/windowcontentfactorymanager.hxx index 4711c1fa9120..c189218a32a3 100644 --- a/framework/inc/uifactory/windowcontentfactorymanager.hxx +++ b/framework/inc/uifactory/windowcontentfactorymanager.hxx @@ -35,7 +35,7 @@ #include <com/sun/star/lang/XServiceInfo.hpp> #include <com/sun/star/container/XNameAccess.hpp> -#include "com/sun/star/frame/XModuleManager.hpp" +#include "com/sun/star/frame/XModuleManager2.hpp" #include <cppuhelper/implbase2.hxx> #include <rtl/ustring.hxx> @@ -49,7 +49,7 @@ class WindowContentFactoryManager : private ThreadHelpBase com::sun::star::lang::XSingleComponentFactory> { public: - WindowContentFactoryManager( const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory >& xServiceManager ); + WindowContentFactoryManager( const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext>& rxContext ); virtual ~WindowContentFactoryManager(); // XInterface, XTypeProvider, XServiceInfo @@ -63,8 +63,7 @@ class WindowContentFactoryManager : private ThreadHelpBase private: sal_Bool m_bConfigRead; - ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory > m_xServiceManager; - ::com::sun::star::uno::Reference< ::com::sun::star::frame::XModuleManager > m_xModuleManager; + ::com::sun::star::uno::Reference< ::com::sun::star::frame::XModuleManager2 > m_xModuleManager; ConfigurationAccess_FactoryManager* m_pConfigAccess; }; diff --git a/framework/inc/xml/imagesconfiguration.hxx b/framework/inc/xml/imagesconfiguration.hxx index eda31f41571b..d08c3b1cd585 100644 --- a/framework/inc/xml/imagesconfiguration.hxx +++ b/framework/inc/xml/imagesconfiguration.hxx @@ -106,7 +106,7 @@ class ImagesConfiguration ImageListsDescriptor& rItems ); static sal_Bool StoreImages( - const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory >& xServiceFactory, + const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext >& rxContext, const ::com::sun::star::uno::Reference< ::com::sun::star::io::XOutputStream >& rOutputStream, const ImageListsDescriptor& rItems ); }; |