diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2021-08-07 18:17:03 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2021-08-08 17:04:03 +0200 |
commit | 9104017e1bf76857d2b9686363013e1e7c49e355 (patch) | |
tree | 949e30187049ed6d177405c8261b206a9b9088e2 /embedserv | |
parent | 5e69c5fbdb44cd782080e7f4d9ad89dc48b2d1b1 (diff) |
create comphelper:OMultiTypeInterfaceContainerHelperVar2 and use it
based on OInterfaceContainerHelper2 which is considerably
faster than the original OInterfaceContainerHelper
Change-Id: Ia8cdbc5ef877a7af3d9193e1bb2faf1595c15470
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/120165
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'embedserv')
-rw-r--r-- | embedserv/source/embed/intercept.cxx | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/embedserv/source/embed/intercept.cxx b/embedserv/source/embed/intercept.cxx index ebe94913744b..2caeec236536 100644 --- a/embedserv/source/embed/intercept.cxx +++ b/embedserv/source/embed/intercept.cxx @@ -17,7 +17,7 @@ * the License at http://www.apache.org/licenses/LICENSE-2.0 . */ #include <cppuhelper/weak.hxx> -#include <cppuhelper/interfacecontainer.hxx> +#include <comphelper/multiinterfacecontainer2.hxx> #include <embeddoc.hxx> #include <docholder.hxx> @@ -32,11 +32,11 @@ using namespace ::com::sun::star; uno::Sequence< OUString > Interceptor::m_aInterceptedURL(IUL); class StatusChangeListenerContainer - : public cppu::OMultiTypeInterfaceContainerHelperVar<OUString> + : public comphelper::OMultiTypeInterfaceContainerHelperVar2<OUString> { public: explicit StatusChangeListenerContainer(osl::Mutex& aMutex) - : cppu::OMultiTypeInterfaceContainerHelperVar<OUString>(aMutex) + : comphelper::OMultiTypeInterfaceContainerHelperVar2<OUString>(aMutex) { } }; @@ -210,12 +210,12 @@ void Interceptor::generateFeatureStateEvent() if( i == 1 || (m_bLink && i != 5) ) continue; - cppu::OInterfaceContainerHelper* pICH = + comphelper::OInterfaceContainerHelper2* pICH = m_pStatCL->getContainer(m_aInterceptedURL[i]); - uno::Sequence<uno::Reference<uno::XInterface> > aSeq; - if(pICH) - aSeq = pICH->getElements(); - if(!aSeq.getLength()) + if(!pICH) + continue; + std::vector<uno::Reference<uno::XInterface> > aSeq = pICH->getElements(); + if(aSeq.empty()) continue; frame::FeatureStateEvent aStateEvent; |