diff options
Diffstat (limited to 'sc')
-rw-r--r-- | sc/source/ui/app/drwtrans.cxx | 3 | ||||
-rw-r--r-- | sc/source/ui/app/transobj.cxx | 3 | ||||
-rw-r--r-- | sc/source/ui/unoobj/dapiuno.cxx | 4 | ||||
-rw-r--r-- | sc/source/ui/unoobj/docuno.cxx | 4 | ||||
-rw-r--r-- | sc/source/ui/unoobj/nameuno.cxx | 4 | ||||
-rw-r--r-- | sc/source/ui/unoobj/textuno.cxx | 4 | ||||
-rw-r--r-- | sc/source/ui/vba/vbaworksheet.cxx | 3 |
7 files changed, 7 insertions, 18 deletions
diff --git a/sc/source/ui/app/drwtrans.cxx b/sc/source/ui/app/drwtrans.cxx index 8805c63efe80..d159243adb1a 100644 --- a/sc/source/ui/app/drwtrans.cxx +++ b/sc/source/ui/app/drwtrans.cxx @@ -750,8 +750,7 @@ const css::uno::Sequence< sal_Int8 >& ScDrawTransferObj::getUnoTunnelId() sal_Int64 SAL_CALL ScDrawTransferObj::getSomething( const css::uno::Sequence< sal_Int8 >& rId ) { sal_Int64 nRet; - if( ( rId.getLength() == 16 ) && - ( 0 == memcmp( getUnoTunnelId().getConstArray(), rId.getConstArray(), 16 ) ) ) + if( isUnoTunnelId<ScDrawTransferObj>(rId) ) { nRet = reinterpret_cast< sal_Int64 >( this ); } diff --git a/sc/source/ui/app/transobj.cxx b/sc/source/ui/app/transobj.cxx index 88d5637222e5..0040c12437e1 100644 --- a/sc/source/ui/app/transobj.cxx +++ b/sc/source/ui/app/transobj.cxx @@ -927,8 +927,7 @@ const css::uno::Sequence< sal_Int8 >& ScTransferObj::getUnoTunnelId() sal_Int64 SAL_CALL ScTransferObj::getSomething( const css::uno::Sequence< sal_Int8 >& rId ) { sal_Int64 nRet; - if( ( rId.getLength() == 16 ) && - ( 0 == memcmp( getUnoTunnelId().getConstArray(), rId.getConstArray(), 16 ) ) ) + if( isUnoTunnelId<ScTransferObj>(rId) ) { nRet = reinterpret_cast< sal_Int64 >( this ); } diff --git a/sc/source/ui/unoobj/dapiuno.cxx b/sc/source/ui/unoobj/dapiuno.cxx index 195b2a1b4ac8..3d37f6f9d3d4 100644 --- a/sc/source/ui/unoobj/dapiuno.cxx +++ b/sc/source/ui/unoobj/dapiuno.cxx @@ -1024,9 +1024,7 @@ Reference< XDataPilotField > SAL_CALL ScDataPilotDescriptorBase::getDataLayoutFi sal_Int64 SAL_CALL ScDataPilotDescriptorBase::getSomething( const Sequence<sal_Int8 >& rId ) { - if ( rId.getLength() == 16 && - 0 == memcmp( getUnoTunnelId().getConstArray(), - rId.getConstArray(), 16 ) ) + if ( isUnoTunnelId<ScDataPilotDescriptorBase>(rId) ) { return sal::static_int_cast<sal_Int64>(reinterpret_cast<sal_IntPtr>(this)); } diff --git a/sc/source/ui/unoobj/docuno.cxx b/sc/source/ui/unoobj/docuno.cxx index 30067f6ada2d..bbca0b5b6de0 100644 --- a/sc/source/ui/unoobj/docuno.cxx +++ b/sc/source/ui/unoobj/docuno.cxx @@ -2855,9 +2855,7 @@ uno::Sequence<OUString> SAL_CALL ScModelObj::getSupportedServiceNames() sal_Int64 SAL_CALL ScModelObj::getSomething( const uno::Sequence<sal_Int8 >& rId ) { - if ( rId.getLength() == 16 && - 0 == memcmp( getUnoTunnelId().getConstArray(), - rId.getConstArray(), 16 ) ) + if ( isUnoTunnelId<ScModelObj>(rId) ) { return sal::static_int_cast<sal_Int64>(reinterpret_cast<sal_IntPtr>(this)); } diff --git a/sc/source/ui/unoobj/nameuno.cxx b/sc/source/ui/unoobj/nameuno.cxx index e2fb3da5b154..42e6a836a1b2 100644 --- a/sc/source/ui/unoobj/nameuno.cxx +++ b/sc/source/ui/unoobj/nameuno.cxx @@ -426,9 +426,7 @@ uno::Sequence<OUString> SAL_CALL ScNamedRangeObj::getSupportedServiceNames() sal_Int64 SAL_CALL ScNamedRangeObj::getSomething( const uno::Sequence<sal_Int8 >& rId ) { - if ( rId.getLength() == 16 && - 0 == memcmp( getUnoTunnelId().getConstArray(), - rId.getConstArray(), 16 ) ) + if ( isUnoTunnelId<ScNamedRangeObj>(rId) ) { return sal::static_int_cast<sal_Int64>(reinterpret_cast<sal_IntPtr>(this)); } diff --git a/sc/source/ui/unoobj/textuno.cxx b/sc/source/ui/unoobj/textuno.cxx index c62d834a4475..59f1b724442f 100644 --- a/sc/source/ui/unoobj/textuno.cxx +++ b/sc/source/ui/unoobj/textuno.cxx @@ -137,9 +137,7 @@ uno::Reference<text::XText> SAL_CALL ScHeaderFooterContentObj::getRightText() sal_Int64 SAL_CALL ScHeaderFooterContentObj::getSomething( const uno::Sequence<sal_Int8 >& rId ) { - if ( rId.getLength() == 16 && - 0 == memcmp( getUnoTunnelId().getConstArray(), - rId.getConstArray(), 16 ) ) + if ( isUnoTunnelId<ScHeaderFooterContentObj>(rId) ) { return sal::static_int_cast<sal_Int64>(reinterpret_cast<sal_IntPtr>(this)); } diff --git a/sc/source/ui/vba/vbaworksheet.cxx b/sc/source/ui/vba/vbaworksheet.cxx index 3ff470e89467..f579abf7005f 100644 --- a/sc/source/ui/vba/vbaworksheet.cxx +++ b/sc/source/ui/vba/vbaworksheet.cxx @@ -1042,8 +1042,7 @@ ScVbaWorksheet::PrintOut( const uno::Any& From, const uno::Any& To, const uno::A sal_Int64 SAL_CALL ScVbaWorksheet::getSomething(const uno::Sequence<sal_Int8 > & rId) { - if (rId.getLength() == 16 && - 0 == memcmp( ScVbaWorksheet::getUnoTunnelId().getConstArray(), rId.getConstArray(), 16 )) + if (isUnoTunnelId<ScVbaWorksheet>(rId)) { return sal::static_int_cast<sal_Int64>(reinterpret_cast<sal_IntPtr>(this)); } |