summaryrefslogtreecommitdiff
path: root/vbahelper/source
diff options
context:
space:
mode:
Diffstat (limited to 'vbahelper/source')
-rw-r--r--vbahelper/source/vbahelper/vbahelper.cxx2
-rw-r--r--vbahelper/source/vbahelper/vbashape.cxx4
2 files changed, 3 insertions, 3 deletions
diff --git a/vbahelper/source/vbahelper/vbahelper.cxx b/vbahelper/source/vbahelper/vbahelper.cxx
index 6905cca88978..285d8d64d790 100644
--- a/vbahelper/source/vbahelper/vbahelper.cxx
+++ b/vbahelper/source/vbahelper/vbahelper.cxx
@@ -143,7 +143,7 @@ dispatchRequests (const uno::Reference< frame::XModel>& xModel, const OUString &
uno::Reference<frame::XDispatchProvider> xDispatchProvider (xFrame,uno::UNO_QUERY_THROW);
try
{
- uno::Reference<uno::XComponentContext > xContext(
+ const uno::Reference<uno::XComponentContext >& xContext(
comphelper::getProcessComponentContext() );
uno::Reference<util::XURLTransformer> xParser( util::URLTransformer::create(xContext) );
xParser->parseStrict (url);
diff --git a/vbahelper/source/vbahelper/vbashape.cxx b/vbahelper/source/vbahelper/vbashape.cxx
index 183d3bb9a984..db0942fd29cf 100644
--- a/vbahelper/source/vbahelper/vbashape.cxx
+++ b/vbahelper/source/vbahelper/vbashape.cxx
@@ -393,7 +393,7 @@ ScVbaShape::TextFrame()
uno::Reference< lang::XServiceInfo > xServiceInfo( m_xModel, uno::UNO_QUERY_THROW );
if( xServiceInfo->supportsService( u"com.sun.star.sheet.SpreadsheetDocument"_ustr ) )
{
- uno::Reference< uno::XComponentContext > xContext = comphelper::getProcessComponentContext();
+ const uno::Reference< uno::XComponentContext >& xContext = comphelper::getProcessComponentContext();
uno::Reference< uno::XInterface > xTextFrame = xContext->getServiceManager()->createInstanceWithArgumentsAndContext( u"ooo.vba.excel.TextFrame"_ustr , { uno::Any(getParent()), uno::Any(m_xShape) }, xContext );
return uno::Any( xTextFrame );
}
@@ -727,7 +727,7 @@ ScVbaShape::WrapFormat()
uno::Reference< lang::XServiceInfo > xServiceInfo( m_xModel, uno::UNO_QUERY_THROW );
if( xServiceInfo->supportsService( u"com.sun.star.text.TextDocument"_ustr ))
{
- uno::Reference< uno::XComponentContext > xContext = comphelper::getProcessComponentContext();
+ const uno::Reference< uno::XComponentContext >& xContext = comphelper::getProcessComponentContext();
uno::Reference< uno::XInterface > xWrapFormat = xContext->getServiceManager()->createInstanceWithArgumentsAndContext( u"ooo.vba.word.WrapFormat"_ustr ,{ uno::Any(getParent()), uno::Any(m_xShape) }, xContext );
return uno::Any( xWrapFormat );
}