[Libreoffice-commits] core.git: 2 commits - embedserv/source extensions/source postprocess/qa shell/source
Stephan Bergmann
sbergman at redhat.com
Tue Mar 24 10:09:52 PDT 2015
embedserv/source/embed/servprov.cxx | 60 +------
embedserv/source/inc/servprov.hxx | 25 +--
extensions/source/ole/servprov.cxx | 90 +++++++----
extensions/source/ole/servprov.hxx | 43 +++--
postprocess/qa/services.cxx | 177 +++++++++++++++++++++--
shell/source/win32/SysShentry.cxx | 2
shell/source/win32/simplemail/smplmail.component | 2
shell/source/win32/simplemail/smplmailentry.cxx | 2
shell/source/win32/simplemail/smplmailsuppl.cxx | 2
shell/source/win32/syssh.component | 2
10 files changed, 276 insertions(+), 129 deletions(-)
New commits:
commit 131c9beffe61ae1e556417dd1169284be92bccd1
Author: Stephan Bergmann <sbergman at redhat.com>
Date: Tue Mar 17 12:27:03 2015 +0100
CppunitTest_services: Check that XServiceInfo and .component data matches
Change-Id: I660c261a90d0ce7ace045f97e28808bc924fefd9
diff --git a/postprocess/qa/services.cxx b/postprocess/qa/services.cxx
index 019a8c3..c6ed5dc 100644
--- a/postprocess/qa/services.cxx
+++ b/postprocess/qa/services.cxx
@@ -34,6 +34,7 @@
#include <com/sun/star/reflection/XServiceConstructorDescription.hpp>
#include <com/sun/star/reflection/XServiceTypeDescription2.hpp>
#include <cppuhelper/exc_hlp.hxx>
+#include <rtl/strbuf.hxx>
#include <test/bootstrapfixture.hxx>
#include <vcl/svapp.hxx>
@@ -43,6 +44,56 @@ OString msg(OUString const & string) {
return OUStringToOString(string, osl_getThreadTextEncoding());
}
+OString msg(css::uno::Sequence<OUString> const & strings) {
+ OStringBuffer buf("{");
+ for (sal_Int32 i = 0; i != strings.getLength(); ++i) {
+ if (i != 0) {
+ buf.append(", ");
+ }
+ buf.append('"');
+ buf.append(msg(strings[i]));
+ buf.append('"');
+ }
+ buf.append('}');
+ return buf.makeStringAndClear();
+}
+
+bool unique(css::uno::Sequence<OUString> const & strings) {
+ // Assumes small sequences for which quadratic algorithm is acceptable:
+ for (sal_Int32 i = 0; i < strings.getLength() - 1; ++i) {
+ for (sal_Int32 j = i + 1; j != strings.getLength(); ++j) {
+ if (strings[j] == strings[i]) {
+ return false;
+ }
+ }
+ }
+ return true;
+}
+
+bool contains(
+ css::uno::Sequence<OUString> const & strings, OUString const & string)
+{
+ for (sal_Int32 i = 0; i != strings.getLength(); ++i) {
+ if (string == strings[i]) {
+ return true;
+ }
+ }
+ return false;
+}
+
+bool contains(
+ css::uno::Sequence<OUString> const & strings1,
+ css::uno::Sequence<OUString> const & strings2)
+{
+ // Assumes small sequences for which quadratic algorithm is acceptable:
+ for (sal_Int32 i = 0; i != strings2.getLength(); ++i) {
+ if (!contains(strings1, strings2[i])) {
+ return false;
+ }
+ }
+ return true;
+}
+
class Test: public test::BootstrapFixture {
public:
void test();
@@ -54,6 +105,8 @@ public:
private:
void createInstance(
OUString const & name, bool withArguments,
+ OUString const & implementationName,
+ css::uno::Sequence<OUString> const & serviceNames,
std::vector<css::uno::Reference<css::lang::XComponent>> * components);
};
@@ -93,13 +146,18 @@ void Test::test() {
serviceName(theServiceName),
defaultConstructor(theDefaultConstructor)
{}
- OUString serviceName;
- bool defaultConstructor;
+ OUString const serviceName;
+ bool const defaultConstructor;
};
struct Implementation {
- Implementation(css::uno::Reference<css::lang::XServiceInfo> theFactory):
- factory(theFactory), accumulationBased(false) {}
- css::uno::Reference<css::lang::XServiceInfo> factory;
+ Implementation(
+ css::uno::Reference<css::lang::XServiceInfo> const & theFactory,
+ css::uno::Sequence<OUString> const & theServiceNames):
+ factory(theFactory), serviceNames(theServiceNames),
+ accumulationBased(false)
+ {}
+ css::uno::Reference<css::lang::XServiceInfo> const factory;
+ css::uno::Sequence<OUString> const serviceNames;
std::vector<Constructor> constructors;
bool accumulationBased;
};
@@ -124,7 +182,7 @@ void Test::test() {
if (desc.is()) {
CPPUNIT_ASSERT_MESSAGE(
(OString(
- "no implementations of singlie-interface--based \""
+ "no implementations of single-interface--based \""
+ msg(serviceNames[i]) + "\"")
.getStr()),
!desc->isSingleInterfaceBased());
@@ -141,7 +199,16 @@ void Test::test() {
OUString name(j->getImplementationName());
auto k = impls.find(name);
if (k == impls.end()) {
- k = impls.insert(std::make_pair(name, Implementation(j)))
+ css::uno::Sequence<OUString> servs(
+ j->getSupportedServiceNames());
+ CPPUNIT_ASSERT_MESSAGE(
+ (OString(
+ "implementation \"" + msg(name)
+ + "\" supports non-unique " + msg(servs))
+ .getStr()),
+ unique(servs));
+ k = impls.insert(
+ std::make_pair(name, Implementation(j, servs)))
.first;
} else {
CPPUNIT_ASSERT_MESSAGE(
@@ -151,6 +218,13 @@ void Test::test() {
.getStr()),
j == k->second.factory);
}
+ CPPUNIT_ASSERT_MESSAGE(
+ (OString(
+ "implementation \"" + msg(name) + "\" supports "
+ + msg(k->second.serviceNames) + " but not \""
+ + msg(serviceNames[i]) + "\"")
+ .getStr()),
+ contains(k->second.serviceNames, serviceNames[i]));
if (desc.is()) {
if (desc->isSingleInterfaceBased()) {
if (serviceImpls2.size() == 1) {
@@ -187,7 +261,8 @@ void Test::test() {
{
if (i.second.constructors.empty()) {
if (i.second.accumulationBased) {
- createInstance(i.first, false, &comps);
+ createInstance(
+ i.first, false, i.first, i.second.serviceNames, &comps);
} else {
std::cout
<< "no obvious way to instantiate implementation \""
@@ -196,7 +271,8 @@ void Test::test() {
} else {
for (auto const & j: i.second.constructors) {
createInstance(
- j.serviceName, !j.defaultConstructor, &comps);
+ j.serviceName, !j.defaultConstructor, i.first,
+ i.second.serviceNames, &comps);
}
}
}
@@ -209,6 +285,8 @@ void Test::test() {
void Test::createInstance(
OUString const & name, bool withArguments,
+ OUString const & implementationName,
+ css::uno::Sequence<OUString> const & serviceNames,
std::vector<css::uno::Reference<css::lang::XComponent>> * components)
{
assert(components != nullptr);
@@ -226,18 +304,93 @@ void Test::createInstance(
css::uno::Any a(cppu::getCaughtException());
CPPUNIT_FAIL(
OString(
- "creating \"" + msg(name) + "\" caused "
- + msg(a.getValueTypeName()) + " \"" + msg(e.Message) + "\"")
+ "instantiating \"" + msg(implementationName) + "\" via \""
+ + msg(name) + "\" caused " + msg(a.getValueTypeName()) + " \""
+ + msg(e.Message) + "\"")
.getStr());
}
CPPUNIT_ASSERT_MESSAGE(
- (OString("creating \"" + msg(name) + "\" returned null reference")
+ (OString(
+ "instantiating \"" + msg(implementationName) + "\" via \""
+ + msg(name) + "\" returned null reference")
.getStr()),
inst.is());
css::uno::Reference<css::lang::XComponent> comp(inst, css::uno::UNO_QUERY);
if (comp.is()) {
components->push_back(comp);
}
+ css::uno::Reference<css::lang::XServiceInfo> info(
+ inst, css::uno::UNO_QUERY);
+ CPPUNIT_ASSERT_MESSAGE(
+ (OString(
+ "instantiating \"" + msg(implementationName) + "\" via \""
+ + msg(name) + "\" does not provide XServiceInfo")
+ .getStr()),
+ info.is());
+ OUString expImpl(implementationName);
+ css::uno::Sequence<OUString> expServs(serviceNames);
+ // Special cases:
+ if (name == "com.sun.star.comp.configuration.ConfigurationProvider") {
+ // Instantiating a ConfigurationProvider with no or empty args must
+ // return theDefaultProvider:
+ expImpl = "com.sun.star.comp.configuration.DefaultProvider";
+ expServs = {"com.sun.star.configuration.DefaultProvider"};
+ } else if (name == "com.sun.star.datatransfer.clipboard.SystemClipboard") {
+ // SystemClipboard is a wrapper returning either a platform-specific or
+ // the generic VCLGenericClipboard:
+#if defined WNT
+ expImpl = "com.sun.star.datatransfer.clipboard.ClipboardW32";
+#else
+ expImpl = "com.sun.star.datatransfer.VCLGenericClipboard";
+#endif
+#if !defined WNT
+ } else if (name == "com.sun.star.comp.datatransfer.dnd.OleDragSource_V1"
+ || name == "com.sun.star.datatransfer.dnd.XdndSupport")
+ {
+ expImpl = "com.sun.star.datatransfer.dnd.VclGenericDragSource";
+ expServs = {"com.sun.star.datatransfer.dnd.GenericDragSource"};
+ } else if (name == "com.sun.star.comp.datatransfer.dnd.OleDropTarget_V1"
+ || name == "com.sun.star.datatransfer.dnd.XdndDropTarget")
+ {
+ expImpl = "com.sun.star.datatransfer.dnd.VclGenericDropTarget";
+ expServs = {"com.sun.star.datatransfer.dnd.GenericDropTarget"};
+#endif
+ } else if (name == "com.sun.star.ui.dialogs.FolderPicker") {
+ // FolderPicker is a wrapper returning either a platform-specific or the
+ // generic OfficeFolderPicker:
+#if defined WNT
+ expImpl = "com.sun.star.ui.dialogs.Win32FolderPicker";
+ expServs = {"com.sun.star.ui.dialogs.SystemFolderPicker"};
+#else
+ expImpl = "com.sun.star.svtools.OfficeFolderPicker";
+ expServs = {"com.sun.star.ui.dialogs.OfficeFolderPicker"};
+#endif
+ }
+ CPPUNIT_ASSERT_EQUAL_MESSAGE(
+ (OString(
+ "instantiating \"" + msg(implementationName) + "\" via \""
+ + msg(name) + "\" reports wrong implementation name")
+ .getStr()),
+ expImpl, info->getImplementationName());
+ css::uno::Sequence<OUString> servs(info->getSupportedServiceNames());
+ CPPUNIT_ASSERT_MESSAGE(
+ (OString(
+ "instantiating \"" + msg(implementationName) + "\" via \""
+ + msg(name) + "\" reports non-unique " + msg(servs))
+ .getStr()),
+ unique(servs));
+ // Some implementations like "com.sun.star.comp.Calc.SpreadsheetDocument"
+ // report sub-services like
+ // "com.sun.star.sheet.SpreadsheetDocumentSettings", and
+ // "com.sun.star.document.OfficeDocument" that are not listed in the
+ // .component file, so check for containment instead of equality:
+ CPPUNIT_ASSERT_MESSAGE(
+ (OString(
+ "instantiating \"" + msg(implementationName) + "\" via \""
+ + msg(name) + "\" reports " + msg(servs) + " different from "
+ + msg(expServs))
+ .getStr()),
+ contains(servs, expServs));
}
CPPUNIT_TEST_SUITE_REGISTRATION(Test);
commit c6dcd7b7f392ef47b2e66445239ce867e51d5adb
Author: Stephan Bergmann <sbergman at redhat.com>
Date: Tue Mar 24 15:22:35 2015 +0100
Fix various Windows-only XServiceInfo implementations
...to match what is recorded in the .component files
Change-Id: Ibc5bb0575f3869317e4d14614cf1dad0af728ddc
diff --git a/embedserv/source/embed/servprov.cxx b/embedserv/source/embed/servprov.cxx
index 006b4ed..775a31f 100644
--- a/embedserv/source/embed/servprov.cxx
+++ b/embedserv/source/embed/servprov.cxx
@@ -24,8 +24,7 @@
#include "servprov.hxx"
#include "embeddoc.hxx"
#include <com/sun/star/lang/XMultiServiceFactory.hpp>
-#include <cppuhelper/typeprovider.hxx>
-#include <cppuhelper/queryinterface.hxx>
+#include <cppuhelper/supportsservice.hxx>
#include <osl/diagnose.h>
#include <osl/mutex.hxx>
#include <osl/thread.h>
@@ -121,62 +120,25 @@ EmbedServer_Impl::~EmbedServer_Impl()
}
}
-// XInterface --------------------------------------------------
-uno::Any SAL_CALL
-EmbedServer_Impl::queryInterface(
- const uno::Type& aType )
- throw(
- uno::RuntimeException
- )
+OUString EmbedServer_Impl::getImplementationName()
+ throw (css::uno::RuntimeException, std::exception)
{
- uno::Any a=
- ::cppu::queryInterface(
- aType, static_cast<lang::XTypeProvider*>(this));
- if( a == uno::Any())
- return OWeakObject::queryInterface( aType);
- else
- return a;
+ return OUString("com.sun.star.comp.ole.EmbedServer");
}
-void SAL_CALL EmbedServer_Impl::acquire( ) throw(uno::RuntimeException)
+sal_Bool EmbedServer_Impl::supportsService(OUString const & ServiceName)
+ throw (css::uno::RuntimeException, std::exception)
{
- OWeakObject::acquire();
+ return cppu::supportsService(this, ServiceName);
}
-void SAL_CALL EmbedServer_Impl::release( ) throw (uno::RuntimeException)
+css::uno::Sequence<OUString> EmbedServer_Impl::getSupportedServiceNames()
+ throw (css::uno::RuntimeException, std::exception)
{
- OWeakObject::release();
+ return css::uno::Sequence<OUString>{
+ "com.sun.star.document.OleEmbeddedServerRegistration"};
}
-
-// XTypeProvider --------------------------------------------------
-uno::Sequence< uno::Type > SAL_CALL
-EmbedServer_Impl::getTypes( )
- throw(
- uno::RuntimeException
- )
-{
- static ::cppu::OTypeCollection *pCollection = 0;
- if( ! pCollection )
- {
- ::osl::MutexGuard guard( ::osl::Mutex::getGlobalMutex() );
- if( ! pCollection )
- {
- static ::cppu::OTypeCollection collection(
- cppu::UnoType<uno::XWeak>::get(),
- cppu::UnoType<lang::XTypeProvider>::get() );
- pCollection = &collection;
- }
- }
- return (*pCollection).getTypes();
-}
-
-uno::Sequence< sal_Int8 > SAL_CALL EmbedServer_Impl::getImplementationId() throw(uno::RuntimeException)
-{
- return css::uno::Sequence<sal_Int8>();
-}
-
-
// EmbedProviderFactory_Impl
EmbedProviderFactory_Impl::EmbedProviderFactory_Impl(const uno::Reference<lang::XMultiServiceFactory>& xFactory, const GUID* pGuid)
diff --git a/embedserv/source/inc/servprov.hxx b/embedserv/source/inc/servprov.hxx
index 1c0a012..c74458d 100644
--- a/embedserv/source/inc/servprov.hxx
+++ b/embedserv/source/inc/servprov.hxx
@@ -25,29 +25,26 @@
#include <com/sun/star/uno/Reference.h>
#include <com/sun/star/uno/Sequence.h>
#include <com/sun/star/uno/XInterface.hpp>
-#include <com/sun/star/lang/XTypeProvider.hpp>
-#include <cppuhelper/weak.hxx>
+#include <com/sun/star/lang/XServiceInfo.hpp>
+#include <cppuhelper/implbase.hxx>
class EmbedProviderFactory_Impl;
-class EmbedServer_Impl : public ::cppu::OWeakObject, ::com::sun::star::lang::XTypeProvider
+class EmbedServer_Impl: public cppu::WeakImplHelper<css::lang::XServiceInfo>
{
public:
EmbedServer_Impl( const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory > &xFactory );
virtual ~EmbedServer_Impl();
- // XInterface
- virtual ::com::sun::star::uno::Any SAL_CALL queryInterface( const ::com::sun::star::uno::Type& aType )
- throw(::com::sun::star::uno::RuntimeException);
- virtual void SAL_CALL acquire() throw ();
- virtual void SAL_CALL release() throw ();
-
- // XTypeProvider
- virtual ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Type > SAL_CALL getTypes( )
- throw(::com::sun::star::uno::RuntimeException);
- virtual ::com::sun::star::uno::Sequence< sal_Int8 > SAL_CALL getImplementationId()
- throw(::com::sun::star::uno::RuntimeException);
+ OUString SAL_CALL getImplementationName()
+ throw (css::uno::RuntimeException, std::exception) SAL_OVERRIDE;
+
+ sal_Bool SAL_CALL supportsService(OUString const & ServiceName)
+ throw (css::uno::RuntimeException, std::exception) SAL_OVERRIDE;
+
+ css::uno::Sequence<OUString> SAL_CALL getSupportedServiceNames()
+ throw (css::uno::RuntimeException, std::exception) SAL_OVERRIDE;
protected:
diff --git a/extensions/source/ole/servprov.cxx b/extensions/source/ole/servprov.cxx
index 39f4c64..d49414d 100644
--- a/extensions/source/ole/servprov.cxx
+++ b/extensions/source/ole/servprov.cxx
@@ -30,6 +30,7 @@
#include "unoobjw.hxx"
#include "oleobjw.hxx"
#include <cppuhelper/queryinterface.hxx>
+#include <cppuhelper/supportsservice.hxx>
using namespace cppu;
using namespace osl;
@@ -424,6 +425,30 @@ Any SAL_CALL OleConverter_Impl2::createBridge(const Any& modelDepObject,
return ret;
}
+OUString OleConverter_Impl2::getImplementationName()
+ throw (css::uno::RuntimeException, std::exception)
+{
+ return m_nUnoWrapperClass == INTERFACE_OLE_WRAPPER_IMPL
+ ? OUString("com.sun.star.comp.ole.OleConverter2")
+ : OUString("com.sun.star.comp.ole.OleConverterVar1");
+}
+
+sal_Bool OleConverter_Impl2::supportsService(OUString const & ServiceName)
+ throw (css::uno::RuntimeException, std::exception)
+{
+ return cppu::supportsService(this, ServiceName);
+}
+
+css::uno::Sequence<OUString> OleConverter_Impl2::getSupportedServiceNames()
+ throw (css::uno::RuntimeException, std::exception)
+{
+ return m_nUnoWrapperClass == INTERFACE_OLE_WRAPPER_IMPL
+ ? css::uno::Sequence<OUString>{
+ "com.sun.star.bridge.OleBridgeSupplier2",
+ "com.sun.star.bridge.oleautomation.BridgeSupplier"}
+ : css::uno::Sequence<OUString>{
+ "com.sun.star.bridge.OleBridgeSupplierVar1"};
+}
// XInitialize ------------------------------------------------------------------------------
// the first argument is an XMultiServiceFactory if at all
@@ -496,10 +521,24 @@ Sequence< OUString > SAL_CALL OleClient_Impl::getAvailableServiceNames() thro
return ret;
}
-
OUString OleClient_Impl::getImplementationName()
+ throw (css::uno::RuntimeException, std::exception)
+{
+ return OUString("com.sun.star.comp.ole.OleClient");
+}
+
+sal_Bool OleClient_Impl::supportsService(OUString const & ServiceName)
+ throw (css::uno::RuntimeException, std::exception)
+{
+ return cppu::supportsService(this, ServiceName);
+}
+
+css::uno::Sequence<OUString> OleClient_Impl::getSupportedServiceNames()
+ throw (css::uno::RuntimeException, std::exception)
{
- return OUString(reinterpret_cast<const sal_Unicode*>(L"com.sun.star.comp.ole.OleClient"));
+ return css::uno::Sequence<OUString>{
+ "com.sun.star.bridge.OleObjectFactory",
+ "com.sun.star.bridge.oleautomation.Factory"};
}
Reference<XInterface> SAL_CALL OleClient_Impl::createInstance(const OUString& ServiceSpecifier) throw (Exception, RuntimeException )
@@ -612,48 +651,27 @@ OleServer_Impl::~OleServer_Impl()
m_wrapperList.pop_front();
}
}
-// XInterface --------------------------------------------------
-Any SAL_CALL OleServer_Impl::queryInterface( const Type& aType ) throw(RuntimeException)
-{
- Any a= ::cppu::queryInterface( aType, static_cast<XTypeProvider*>(this));
- if( a == Any())
- return OWeakObject::queryInterface( aType);
- else
- return a;
-}
-void SAL_CALL OleServer_Impl::acquire( ) throw()
-{
- OWeakObject::acquire();
-}
-void SAL_CALL OleServer_Impl::release( ) throw ()
+
+OUString OleServer_Impl::getImplementationName()
+ throw (css::uno::RuntimeException, std::exception)
{
- OWeakObject::release();
+ return OUString("com.sun.star.comp.ole.OleServer");
}
-
-// XTypeProvider --------------------------------------------------
-Sequence< Type > SAL_CALL OleServer_Impl::getTypes( ) throw(RuntimeException)
+sal_Bool OleServer_Impl::supportsService(OUString const & ServiceName)
+ throw (css::uno::RuntimeException, std::exception)
{
- static OTypeCollection *pCollection = 0;
- if( ! pCollection )
- {
- MutexGuard guard( Mutex::getGlobalMutex() );
- if( ! pCollection )
- {
- static OTypeCollection collection(
- cppu::UnoType<XWeak>::get(),
- cppu::UnoType<XTypeProvider>::get() );
- pCollection = &collection;
- }
- }
- return (*pCollection).getTypes();
+ return cppu::supportsService(this, ServiceName);
}
-Sequence< sal_Int8 > SAL_CALL OleServer_Impl::getImplementationId() throw(RuntimeException)
+
+css::uno::Sequence<OUString> OleServer_Impl::getSupportedServiceNames()
+ throw (css::uno::RuntimeException, std::exception)
{
- return css::uno::Sequence<sal_Int8>();
+ return css::uno::Sequence<OUString>{
+ "com.sun.star.bridge.OleApplicationRegistration",
+ "com.sun.star.bridge.oleautomation.ApplicationRegistration"};
}
-
sal_Bool OleServer_Impl::provideService(const Reference<XSingleServiceFactory>& xSFact, GUID* guid)
{
IClassFactoryWrapper* pFac = new ProviderOleWrapper_Impl( m_smgr, xSFact, guid);
diff --git a/extensions/source/ole/servprov.hxx b/extensions/source/ole/servprov.hxx
index 24ab22f..9046a5a 100644
--- a/extensions/source/ole/servprov.hxx
+++ b/extensions/source/ole/servprov.hxx
@@ -21,7 +21,8 @@
#define INCLUDED_EXTENSIONS_SOURCE_OLE_SERVPROV_HXX
#include <com/sun/star/lang/XInitialization.hpp>
-#include <cppuhelper/implbase2.hxx>
+#include <com/sun/star/lang/XServiceInfo.hpp>
+#include <cppuhelper/implbase.hxx>
#include "ole2uno.hxx"
#include "unoconversionutilities.hxx"
@@ -164,7 +165,7 @@ protected:
// latter for OleBridgeSupplierVar1.
// The m_nComWrapperClass specifies the class which is used as wrapper for COM interfaces.
// Currently there is only one class available ( IUnknownWrapper_Impl).
-class OleConverter_Impl2 : public WeakImplHelper2<XBridgeSupplier2, XInitialization>,
+class OleConverter_Impl2 : public WeakImplHelper<XBridgeSupplier2, XInitialization, css::lang::XServiceInfo>,
public UnoConversionUtilities<OleConverter_Impl2>
{
public:
@@ -183,6 +184,15 @@ public:
// XInitialization
virtual void SAL_CALL initialize( const Sequence< Any >& aArguments ) throw(Exception, RuntimeException);
+ OUString SAL_CALL getImplementationName()
+ throw (css::uno::RuntimeException, std::exception) SAL_OVERRIDE;
+
+ sal_Bool SAL_CALL supportsService(OUString const & ServiceName)
+ throw (css::uno::RuntimeException, std::exception) SAL_OVERRIDE;
+
+ css::uno::Sequence<OUString> SAL_CALL getSupportedServiceNames()
+ throw (css::uno::RuntimeException, std::exception) SAL_OVERRIDE;
+
// Abstract struct UnoConversionUtilities
virtual Reference< XInterface > createUnoWrapperInstance();
virtual Reference< XInterface > createComWrapperInstance();
@@ -200,7 +210,7 @@ protected:
*****************************************************************************/
-class OleClient_Impl : public WeakImplHelper1<XMultiServiceFactory>,
+class OleClient_Impl : public WeakImplHelper<XMultiServiceFactory, css::lang::XServiceInfo>,
public UnoConversionUtilities<OleClient_Impl>
{
public:
@@ -212,12 +222,19 @@ public:
virtual Reference<XInterface> SAL_CALL createInstanceWithArguments(const OUString& ServiceSpecifier, const Sequence< Any >& Arguments) throw (Exception, RuntimeException);
Sequence< OUString > SAL_CALL getAvailableServiceNames() throw (RuntimeException);
+ OUString SAL_CALL getImplementationName()
+ throw (css::uno::RuntimeException, std::exception) SAL_OVERRIDE;
+
+ sal_Bool SAL_CALL supportsService(OUString const & ServiceName)
+ throw (css::uno::RuntimeException, std::exception) SAL_OVERRIDE;
+
+ css::uno::Sequence<OUString> SAL_CALL getSupportedServiceNames()
+ throw (css::uno::RuntimeException, std::exception) SAL_OVERRIDE;
+
// Abstract struct UnoConversionUtilities
virtual Reference< XInterface > createUnoWrapperInstance();
virtual Reference< XInterface > createComWrapperInstance();
-
- OUString getImplementationName();
protected:
Reference<XBridgeSupplier2> m_bridgeSupplier;
};
@@ -233,20 +250,20 @@ protected:
*****************************************************************************/
-class OleServer_Impl : public OWeakObject, XTypeProvider
+class OleServer_Impl : public cppu::WeakImplHelper<css::lang::XServiceInfo>
{
public:
OleServer_Impl( const Reference<XMultiServiceFactory> &smgr);
~OleServer_Impl();
- // XInterface
- virtual Any SAL_CALL queryInterface( const Type& aType ) throw(RuntimeException);
- virtual void SAL_CALL acquire( ) throw ();
- virtual void SAL_CALL release( ) throw ();
+ OUString SAL_CALL getImplementationName()
+ throw (css::uno::RuntimeException, std::exception) SAL_OVERRIDE;
+
+ sal_Bool SAL_CALL supportsService(OUString const & ServiceName)
+ throw (css::uno::RuntimeException, std::exception) SAL_OVERRIDE;
- // XTypeProvider
- virtual Sequence< Type > SAL_CALL getTypes( ) throw(RuntimeException);
- virtual Sequence< sal_Int8 > SAL_CALL getImplementationId() throw(RuntimeException);
+ css::uno::Sequence<OUString> SAL_CALL getSupportedServiceNames()
+ throw (css::uno::RuntimeException, std::exception) SAL_OVERRIDE;
protected:
diff --git a/shell/source/win32/SysShentry.cxx b/shell/source/win32/SysShentry.cxx
index 6d324b0..a0551ad 100644
--- a/shell/source/win32/SysShentry.cxx
+++ b/shell/source/win32/SysShentry.cxx
@@ -34,7 +34,7 @@ using namespace ::cppu ;
using com::sun::star::system::XSystemShellExecute;
#define SYSSHEXEC_SERVICE_NAME "com.sun.star.system.SystemShellExecute"
-#define SYSSHEXEC_IMPL_NAME "com.sun.star.system.SystemShellExecute"
+#define SYSSHEXEC_IMPL_NAME "com.sun.star.sys.shell.SystemShellExecute"
diff --git a/shell/source/win32/simplemail/smplmail.component b/shell/source/win32/simplemail/smplmail.component
index c37a46e..556c409 100644
--- a/shell/source/win32/simplemail/smplmail.component
+++ b/shell/source/win32/simplemail/smplmail.component
@@ -19,7 +19,7 @@
<component loader="com.sun.star.loader.SharedLibrary" environment="@CPPU_ENV@"
prefix="smplmail" xmlns="http://openoffice.org/2010/uno-components">
- <implementation name="com.sun.star.system.SimpleSystemMail">
+ <implementation name="com.sun.star.sys.shell.SimpleSystemMail">
<service name="com.sun.star.system.SimpleSystemMail"/>
</implementation>
</component>
diff --git a/shell/source/win32/simplemail/smplmailentry.cxx b/shell/source/win32/simplemail/smplmailentry.cxx
index d99d6a7..c192d3c 100644
--- a/shell/source/win32/simplemail/smplmailentry.cxx
+++ b/shell/source/win32/simplemail/smplmailentry.cxx
@@ -34,7 +34,7 @@ using namespace ::cppu ;
using com::sun::star::system::XSimpleMailClientSupplier;
#define COMP_SERVICE_NAME "com.sun.star.system.SimpleSystemMail"
-#define COMP_IMPL_NAME "com.sun.star.system.SimpleSystemMail"
+#define COMP_IMPL_NAME "com.sun.star.sys.shell.SimpleSystemMail"
diff --git a/shell/source/win32/simplemail/smplmailsuppl.cxx b/shell/source/win32/simplemail/smplmailsuppl.cxx
index fea3996..d92de18 100644
--- a/shell/source/win32/simplemail/smplmailsuppl.cxx
+++ b/shell/source/win32/simplemail/smplmailsuppl.cxx
@@ -39,7 +39,7 @@ namespace // private
Sequence< OUString > SAL_CALL Component_getSupportedServiceNames()
{
Sequence< OUString > aRet(1);
- aRet[0] = "com.sun.star.sys.shell.SimpleSystemMail";
+ aRet[0] = "com.sun.star.system.SimpleSystemMail";
return aRet;
}
diff --git a/shell/source/win32/syssh.component b/shell/source/win32/syssh.component
index b488e16..9235d1d 100644
--- a/shell/source/win32/syssh.component
+++ b/shell/source/win32/syssh.component
@@ -19,7 +19,7 @@
<component loader="com.sun.star.loader.SharedLibrary" environment="@CPPU_ENV@"
prefix="syssh" xmlns="http://openoffice.org/2010/uno-components">
- <implementation name="com.sun.star.system.SystemShellExecute">
+ <implementation name="com.sun.star.sys.shell.SystemShellExecute">
<service name="com.sun.star.system.SystemShellExecute"/>
</implementation>
</component>
More information about the Libreoffice-commits
mailing list