diff options
author | Arkadiy Illarionov <qarkai@gmail.com> | 2019-09-06 00:50:24 +0300 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2019-09-06 11:55:50 +0200 |
commit | f599c31fe68882f510cf3d101102e71f9bf795c8 (patch) | |
tree | ced0a58620c5aea8420638847192f298d139297b /chart2 | |
parent | 8811516e2e9e71dd45198081d26c748cdf4d831a (diff) |
tdf#39593 use isUnoTunnelId
Adapt getUnoTunnelId methods where required: rename or make public.
Change-Id: I0fd2120bf9f0ff1aa690329a65ff64a154c89315
Reviewed-on: https://gerrit.libreoffice.org/78680
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
Diffstat (limited to 'chart2')
-rw-r--r-- | chart2/source/model/main/ChartModel.cxx | 3 | ||||
-rw-r--r-- | chart2/source/view/main/ChartView.cxx | 3 |
2 files changed, 2 insertions, 4 deletions
diff --git a/chart2/source/model/main/ChartModel.cxx b/chart2/source/model/main/ChartModel.cxx index 3989f8d7e86a..ec0df4b1e789 100644 --- a/chart2/source/model/main/ChartModel.cxx +++ b/chart2/source/model/main/ChartModel.cxx @@ -1201,8 +1201,7 @@ Reference< util::XNumberFormatsSupplier > const & ChartModel::getNumberFormatsSu // ____ XUnoTunnel ___ ::sal_Int64 SAL_CALL ChartModel::getSomething( const Sequence< ::sal_Int8 >& aIdentifier ) { - if( aIdentifier.getLength() == 16 && memcmp( SvNumberFormatsSupplierObj::getUnoTunnelId().getConstArray(), - aIdentifier.getConstArray(), 16 ) == 0 ) + if( isUnoTunnelId<SvNumberFormatsSupplierObj>(aIdentifier) ) { Reference< lang::XUnoTunnel > xTunnel( getNumberFormatsSupplier(), uno::UNO_QUERY ); if( xTunnel.is() ) diff --git a/chart2/source/view/main/ChartView.cxx b/chart2/source/view/main/ChartView.cxx index 876d47570878..ab3b10d7c8cf 100644 --- a/chart2/source/view/main/ChartView.cxx +++ b/chart2/source/view/main/ChartView.cxx @@ -1233,8 +1233,7 @@ sal_Bool SAL_CALL ChartView::isDataFlavorSupported( const datatransfer::DataFlav // ____ XUnoTunnel ___ ::sal_Int64 SAL_CALL ChartView::getSomething( const uno::Sequence< ::sal_Int8 >& aIdentifier ) { - if( aIdentifier.getLength() == 16 && memcmp( ExplicitValueProvider::getUnoTunnelId().getConstArray(), - aIdentifier.getConstArray(), 16 ) == 0 ) + if( isUnoTunnelId<ExplicitValueProvider>(aIdentifier) ) { ExplicitValueProvider* pProvider = this; return reinterpret_cast<sal_Int64>(pProvider); |