fdo#46808, Convert SfxFrameLoader service to new style
Change-Id: I6cdef298d69fef388e79b241abbe3a9a03d61492
This commit is contained in:
@@ -59,7 +59,6 @@ namespace framework{
|
|||||||
|
|
||||||
#define IMPLEMENTATIONNAME_DESKTOP DECLARE_ASCII("com.sun.star.comp.framework.Desktop" )
|
#define IMPLEMENTATIONNAME_DESKTOP DECLARE_ASCII("com.sun.star.comp.framework.Desktop" )
|
||||||
#define IMPLEMENTATIONNAME_URLTRANSFORMER DECLARE_ASCII("com.sun.star.comp.framework.URLTransformer" )
|
#define IMPLEMENTATIONNAME_URLTRANSFORMER DECLARE_ASCII("com.sun.star.comp.framework.URLTransformer" )
|
||||||
#define IMPLEMENTATIONNAME_GENERICFRAMELOADER DECLARE_ASCII("com.sun.star.comp.office.FrameLoader" )
|
|
||||||
#define IMPLEMENTATIONNAME_MEDIATYPEDETECTIONHELPER DECLARE_ASCII("com.sun.star.comp.framework.MediaTypeDetectionHelper")
|
#define IMPLEMENTATIONNAME_MEDIATYPEDETECTIONHELPER DECLARE_ASCII("com.sun.star.comp.framework.MediaTypeDetectionHelper")
|
||||||
#define IMPLEMENTATIONNAME_OXT_HANDLER DECLARE_ASCII("com.sun.star.comp.framework.OXTFileHandler" )
|
#define IMPLEMENTATIONNAME_OXT_HANDLER DECLARE_ASCII("com.sun.star.comp.framework.OXTFileHandler" )
|
||||||
#define IMPLEMENTATIONNAME_SFXTERMINATOR DECLARE_ASCII("com.sun.star.comp.sfx2.SfxTerminateListener" )
|
#define IMPLEMENTATIONNAME_SFXTERMINATOR DECLARE_ASCII("com.sun.star.comp.sfx2.SfxTerminateListener" )
|
||||||
|
@@ -52,6 +52,7 @@
|
|||||||
#include <com/sun/star/awt/XWindow2.hpp>
|
#include <com/sun/star/awt/XWindow2.hpp>
|
||||||
#include <com/sun/star/awt/XTopWindow.hpp>
|
#include <com/sun/star/awt/XTopWindow.hpp>
|
||||||
#include <com/sun/star/frame/Desktop.hpp>
|
#include <com/sun/star/frame/Desktop.hpp>
|
||||||
|
#include <com/sun/star/frame/OfficeFrameLoader.hpp>
|
||||||
#include <com/sun/star/frame/XModel.hpp>
|
#include <com/sun/star/frame/XModel.hpp>
|
||||||
#include <com/sun/star/frame/XFrameLoader.hpp>
|
#include <com/sun/star/frame/XFrameLoader.hpp>
|
||||||
#include <com/sun/star/frame/XSynchronousFrameLoader.hpp>
|
#include <com/sun/star/frame/XSynchronousFrameLoader.hpp>
|
||||||
@@ -1194,7 +1195,7 @@ css::uno::Reference< css::uno::XInterface > LoadEnv::impl_searchLoader()
|
|||||||
{
|
{
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
return m_xContext->getServiceManager()->createInstanceWithContext(IMPLEMENTATIONNAME_GENERICFRAMELOADER, m_xContext);
|
return css::frame::OfficeFrameLoader::create(m_xContext);
|
||||||
}
|
}
|
||||||
catch(const css::uno::RuntimeException&)
|
catch(const css::uno::RuntimeException&)
|
||||||
{ throw; }
|
{ throw; }
|
||||||
|
@@ -198,6 +198,7 @@ $(eval $(call gb_UnoApi_add_idlfiles_nohdl,offapi,offapi/com/sun/star/frame,\
|
|||||||
LayoutManager \
|
LayoutManager \
|
||||||
MediaTypeDetectionHelper \
|
MediaTypeDetectionHelper \
|
||||||
ModuleManager \
|
ModuleManager \
|
||||||
|
OfficeFrameLoader \
|
||||||
SessionListener \
|
SessionListener \
|
||||||
StartModule \
|
StartModule \
|
||||||
TaskCreator \
|
TaskCreator \
|
||||||
|
37
offapi/com/sun/star/frame/OfficeFrameLoader.idl
Normal file
37
offapi/com/sun/star/frame/OfficeFrameLoader.idl
Normal file
@@ -0,0 +1,37 @@
|
|||||||
|
/* -*- 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 .
|
||||||
|
*/
|
||||||
|
#ifndef __com_sun_star_frame_OfficeFrameLoader_idl__
|
||||||
|
#define __com_sun_star_frame_OfficeFrameLoader_idl__
|
||||||
|
|
||||||
|
#include <com/sun/star/frame/XSynchronousFrameLoader.idl>
|
||||||
|
|
||||||
|
|
||||||
|
module com { module sun { module star { module frame {
|
||||||
|
|
||||||
|
/**
|
||||||
|
@since LibreOffice 4.2
|
||||||
|
*/
|
||||||
|
service OfficeFrameLoader : XSynchronousFrameLoader;
|
||||||
|
|
||||||
|
|
||||||
|
}; }; }; };
|
||||||
|
|
||||||
|
#endif
|
||||||
|
|
||||||
|
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
|
@@ -681,8 +681,9 @@ Sequence< OUString > SAL_CALL SfxFrameLoader_Impl::getSupportedServiceNames() th
|
|||||||
Sequence< OUString > SfxFrameLoader_Impl::impl_getStaticSupportedServiceNames()
|
Sequence< OUString > SfxFrameLoader_Impl::impl_getStaticSupportedServiceNames()
|
||||||
{
|
{
|
||||||
::osl::MutexGuard aGuard( ::osl::Mutex::getGlobalMutex() );
|
::osl::MutexGuard aGuard( ::osl::Mutex::getGlobalMutex() );
|
||||||
Sequence< OUString > seqServiceNames( 1 );
|
Sequence< OUString > seqServiceNames( 2 );
|
||||||
seqServiceNames.getArray() [0] = OUString( "com.sun.star.frame.SynchronousFrameLoader" );
|
seqServiceNames.getArray() [0] = OUString( "com.sun.star.frame.SynchronousFrameLoader" );
|
||||||
|
seqServiceNames.getArray() [1] = OUString( "com.sun.star.frame.OfficeFrameLoader" );
|
||||||
return seqServiceNames ;
|
return seqServiceNames ;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -38,6 +38,7 @@
|
|||||||
</implementation>
|
</implementation>
|
||||||
<implementation name="com.sun.star.comp.office.FrameLoader">
|
<implementation name="com.sun.star.comp.office.FrameLoader">
|
||||||
<service name="com.sun.star.frame.SynchronousFrameLoader"/>
|
<service name="com.sun.star.frame.SynchronousFrameLoader"/>
|
||||||
|
<service name="com.sun.star.frame.OfficeFrameLoader"/>
|
||||||
</implementation>
|
</implementation>
|
||||||
<implementation name="com.sun.star.comp.sfx2.AppDispatchProvider">
|
<implementation name="com.sun.star.comp.sfx2.AppDispatchProvider">
|
||||||
<service name="com.sun.star.frame.ProtocolHandler"/>
|
<service name="com.sun.star.frame.ProtocolHandler"/>
|
||||||
|
Reference in New Issue
Block a user