summaryrefslogtreecommitdiff
path: root/vbahelper/source
diff options
context:
space:
mode:
authorMichael Meeks <michael.meeks@suse.com>2012-05-29 17:23:51 +0100
committerMichael Meeks <michael.meeks@suse.com>2012-05-29 18:03:34 +0100
commit6e6d81e9cfc593d865e409ad22b2307f87a37859 (patch)
tree4d578e5be2dfd3a403576d7c638f83f041d56911 /vbahelper/source
parentb7c6716b4bc0742af4206035495d161e7eb49424 (diff)
targetted SAL_N_ELEMENTS reversion.
Change-Id: I30be93ccaeb1f9fd17cbe9e3ed3165e094810b2e
Diffstat (limited to 'vbahelper/source')
-rw-r--r--vbahelper/source/vbahelper/vbaapplicationbase.cxx2
-rw-r--r--vbahelper/source/vbahelper/vbaglobalbase.cxx6
2 files changed, 5 insertions, 3 deletions
diff --git a/vbahelper/source/vbahelper/vbaapplicationbase.cxx b/vbahelper/source/vbahelper/vbaapplicationbase.cxx
index 195ee5e481e9..ecf1e50d2200 100644
--- a/vbahelper/source/vbahelper/vbaapplicationbase.cxx
+++ b/vbahelper/source/vbahelper/vbaapplicationbase.cxx
@@ -339,7 +339,7 @@ uno::Any SAL_CALL VbaApplicationBase::Run( const ::rtl::OUString& MacroName, con
// handle the arguments
const uno::Any* aArgsPtrArray[] = { &varg1, &varg2, &varg3, &varg4, &varg5, &varg6, &varg7, &varg8, &varg9, &varg10, &varg11, &varg12, &varg13, &varg14, &varg15, &varg16, &varg17, &varg18, &varg19, &varg20, &varg21, &varg22, &varg23, &varg24, &varg25, &varg26, &varg27, &varg28, &varg29, &varg30 };
- int nArg = SAL_N_ELEMENTS( aArgsPtrArray );
+ int nArg = sizeof( aArgsPtrArray ) / sizeof( aArgsPtrArray[0] );
uno::Sequence< uno::Any > aArgs( nArg );
const uno::Any** pArg = aArgsPtrArray;
diff --git a/vbahelper/source/vbahelper/vbaglobalbase.cxx b/vbahelper/source/vbahelper/vbaglobalbase.cxx
index 615c6f53d7e8..8e08ecb5b96f 100644
--- a/vbahelper/source/vbahelper/vbaglobalbase.cxx
+++ b/vbahelper/source/vbahelper/vbaglobalbase.cxx
@@ -63,7 +63,9 @@ const uno::Reference< uno::XComponentContext >& xContext, const rtl::OUString& s
};
// don't pass a delegate, this seems to introduce yet another cyclic dependency ( and
// some strange behavior
- mxContext = ::cppu::createComponentContext( aHandlerContextInfo, SAL_N_ELEMENTS( aHandlerContextInfo ), NULL );
+ mxContext = ::cppu::createComponentContext(
+ aHandlerContextInfo,
+ ( sizeof ( aHandlerContextInfo ) / sizeof ( aHandlerContextInfo[0] ) ), NULL );
if ( aSrvMgr.is() )
{
try
@@ -161,7 +163,7 @@ VbaGlobalsBase::getAvailableServiceNames( ) throw (uno::RuntimeException)
// common
::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "ooo.vba.msforms.UserForm" ) ),
};
- static uno::Sequence< rtl::OUString > serviceNames( names, SAL_N_ELEMENTS( names ) );
+ static uno::Sequence< rtl::OUString > serviceNames( names, sizeof( names )/ sizeof( names[0] ) );
return serviceNames;
}