summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2024-05-14 09:10:37 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2024-05-14 15:14:51 +0200
commitfcaf6cee081b8e3282ee85672ba376a9bd0aeeb9 (patch)
treef36ab62781e57ab05a5eff9546cca47ec642575a /include
parent9aa22abcbdfe42e516ecc791605e3a1b7ef80327 (diff)
loplugin:ostr in vbahelper
Change-Id: I7763dd628ba3d4288e52b51e08a5af301f916c1b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167621 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'include')
-rw-r--r--include/vbahelper/vbaaccesshelper.hxx2
-rw-r--r--include/vbahelper/vbacollectionimpl.hxx10
-rw-r--r--include/vbahelper/vbahelperinterface.hxx2
-rw-r--r--include/vbahelper/vbapropvalue.hxx2
-rw-r--r--include/vbahelper/vbareturntypes.hxx2
5 files changed, 9 insertions, 9 deletions
diff --git a/include/vbahelper/vbaaccesshelper.hxx b/include/vbahelper/vbaaccesshelper.hxx
index 36f24d3a4f71..cf163e90ac45 100644
--- a/include/vbahelper/vbaaccesshelper.hxx
+++ b/include/vbahelper/vbaaccesshelper.hxx
@@ -41,7 +41,7 @@ namespace ooo::vba
inline css::uno::Reference< css::lang::XMultiServiceFactory > getVBAServiceFactory( SfxObjectShell const * pShell )
{
css::uno::Any aUnoVar;
- if ( !pShell || ! pShell->GetBasicManager()->GetGlobalUNOConstant( "VBAGlobals", aUnoVar ) )
+ if ( !pShell || ! pShell->GetBasicManager()->GetGlobalUNOConstant( u"VBAGlobals"_ustr, aUnoVar ) )
throw css::lang::IllegalArgumentException();
css::uno::Reference< css::lang::XMultiServiceFactory > xVBAFactory( aUnoVar, css::uno::UNO_QUERY_THROW );
return xVBAFactory;
diff --git a/include/vbahelper/vbacollectionimpl.hxx b/include/vbahelper/vbacollectionimpl.hxx
index 9afcf08a3aa5..d70f531e113f 100644
--- a/include/vbahelper/vbacollectionimpl.hxx
+++ b/include/vbahelper/vbacollectionimpl.hxx
@@ -245,7 +245,7 @@ protected:
virtual css::uno::Any getItemByStringIndex( const OUString& sIndex )
{
if ( !m_xNameAccess.is() )
- throw css::uno::RuntimeException("ScVbaCollectionBase string index access not supported by this object" );
+ throw css::uno::RuntimeException(u"ScVbaCollectionBase string index access not supported by this object"_ustr );
if( mbIgnoreCase )
{
@@ -266,11 +266,11 @@ protected:
virtual css::uno::Any getItemByIntIndex( const sal_Int32 nIndex )
{
if ( !m_xIndexAccess.is() )
- throw css::uno::RuntimeException("ScVbaCollectionBase numeric index access not supported by this object" );
+ throw css::uno::RuntimeException(u"ScVbaCollectionBase numeric index access not supported by this object"_ustr );
if ( nIndex <= 0 )
{
throw css::lang::IndexOutOfBoundsException(
- "index is 0 or negative" );
+ u"index is 0 or negative"_ustr );
}
// need to adjust for vba index ( for which first element is 1 )
return createCollectionObject( m_xIndexAccess->getByIndex( nIndex - 1 ) );
@@ -307,7 +307,7 @@ public:
sal_Int32 nIndex = 0;
if ( !( Index1 >>= nIndex ) )
{
- throw css::lang::IndexOutOfBoundsException( "Couldn't convert index to Int32" );
+ throw css::lang::IndexOutOfBoundsException( u"Couldn't convert index to Int32"_ustr );
}
return getItemByIntIndex( nIndex );
@@ -321,7 +321,7 @@ public:
// XDefaultMethod
OUString SAL_CALL getDefaultMethodName( ) override
{
- return "Item";
+ return u"Item"_ustr;
}
// XEnumerationAccess
virtual css::uno::Reference< css::container::XEnumeration > SAL_CALL createEnumeration() override = 0;
diff --git a/include/vbahelper/vbahelperinterface.hxx b/include/vbahelper/vbahelperinterface.hxx
index c0aa106329c7..6d4b78979a2c 100644
--- a/include/vbahelper/vbahelperinterface.hxx
+++ b/include/vbahelper/vbahelperinterface.hxx
@@ -82,7 +82,7 @@ public:
// The application could certainly be passed around in the context - seems
// to make sense
css::uno::Reference< css::container::XNameAccess > xNameAccess( mxContext, css::uno::UNO_QUERY_THROW );
- return xNameAccess->getByName( "Application" );
+ return xNameAccess->getByName( u"Application"_ustr );
}
// XServiceInfo Methods
diff --git a/include/vbahelper/vbapropvalue.hxx b/include/vbahelper/vbapropvalue.hxx
index ee6443f08a34..fe7cbf1bd12b 100644
--- a/include/vbahelper/vbapropvalue.hxx
+++ b/include/vbahelper/vbapropvalue.hxx
@@ -51,7 +51,7 @@ public:
virtual css::uno::Any SAL_CALL getValue() override;
virtual void SAL_CALL setValue( const css::uno::Any& _value ) override;
- OUString SAL_CALL getDefaultPropertyName() override { return "Value"; }
+ OUString SAL_CALL getDefaultPropertyName() override { return u"Value"_ustr; }
};
#endif //SC_VBA_PROPVALULE_HXX
diff --git a/include/vbahelper/vbareturntypes.hxx b/include/vbahelper/vbareturntypes.hxx
index 96bb168abc01..2d066d797cb4 100644
--- a/include/vbahelper/vbareturntypes.hxx
+++ b/include/vbahelper/vbareturntypes.hxx
@@ -37,7 +37,7 @@ namespace ooo::vba
DefaultReturnHelper( const T1& nValue ) : mnValue( nValue ) {}
virtual void SAL_CALL setValue( T1 nValue ) override { mnValue = nValue; }
virtual T1 SAL_CALL getValue() override { return mnValue; }
- OUString SAL_CALL getDefaultPropertyName( ) override { return "Value"; }
+ OUString SAL_CALL getDefaultPropertyName( ) override { return u"Value"_ustr; }
};
typedef DefaultReturnHelper< sal_Int32, ov::msforms::XReturnInteger > ReturnInteger_BASE;