summaryrefslogtreecommitdiff
path: root/vbahelper/source/vbahelper/vbaapplicationbase.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'vbahelper/source/vbahelper/vbaapplicationbase.cxx')
-rw-r--r--vbahelper/source/vbahelper/vbaapplicationbase.cxx27
1 files changed, 4 insertions, 23 deletions
diff --git a/vbahelper/source/vbahelper/vbaapplicationbase.cxx b/vbahelper/source/vbahelper/vbaapplicationbase.cxx
index 54d280094f2c..5ae0a2c23890 100644
--- a/vbahelper/source/vbahelper/vbaapplicationbase.cxx
+++ b/vbahelper/source/vbahelper/vbaapplicationbase.cxx
@@ -387,12 +387,12 @@ uno::Any SAL_CALL VbaApplicationBase::getVBE() throw (uno::RuntimeException)
{
try // return empty object on error
{
- uno::Sequence< uno::Any > aArgs( 2 );
- aArgs[ 0 ] <<= uno::Reference< XHelperInterface >( this );
- aArgs[ 1 ] <<= getCurrentDocument();
+ // "VBE" object does not have a parent, but pass document model to be able to determine application type
+ uno::Sequence< uno::Any > aArgs( 1 );
+ aArgs[ 0 ] <<= getCurrentDocument();
uno::Reference< lang::XMultiComponentFactory > xServiceManager( mxContext->getServiceManager(), uno::UNO_SET_THROW );
uno::Reference< uno::XInterface > xVBE = xServiceManager->createInstanceWithArgumentsAndContext(
- ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "ooo.vba.VBE" ) ), aArgs, mxContext );
+ ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "ooo.vba.vbide.VBE" ) ), aArgs, mxContext );
return uno::Any( xVBE );
}
catch( uno::Exception& )
@@ -401,25 +401,6 @@ uno::Any SAL_CALL VbaApplicationBase::getVBE() throw (uno::RuntimeException)
return uno::Any();
}
-uno::Any SAL_CALL
-VbaApplicationBase::getVBProjects() throw (uno::RuntimeException)
-{
- try // return empty object on error
- {
- uno::Sequence< uno::Any > aArgs( 2 );
- aArgs[ 0 ] <<= uno::Reference< XHelperInterface >( this );
- aArgs[ 1 ] <<= getCurrentDocument();
- uno::Reference< lang::XMultiComponentFactory > xServiceManager( mxContext->getServiceManager(), uno::UNO_SET_THROW );
- uno::Reference< uno::XInterface > xVBProjects = xServiceManager->createInstanceWithArgumentsAndContext(
- ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "ooo.vba.VBProjects" ) ), aArgs, mxContext );
- return uno::Any( xVBProjects );
- }
- catch( uno::Exception& )
- {
- }
- return uno::Any();
-}
-
rtl::OUString&
VbaApplicationBase::getServiceImplName()
{