diff options
author | Noel Grandin <noelgrandin@gmail.com> | 2021-12-16 16:08:48 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2021-12-17 07:26:25 +0100 |
commit | 7994791e0a3681d46d8b257f09422b04deeae41c (patch) | |
tree | e04944776200e5bad5ac80618aaf3270a23c26d6 /forms | |
parent | 134425eb98147d197833cb4ef7bb4d8c3d7fd2bc (diff) |
use more OInterfaceContainer3::notifyEach
Change-Id: I0dd6e9f1514792e73a31e81896d09c27c1912318
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/126966
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'forms')
-rw-r--r-- | forms/source/component/DatabaseForm.cxx | 10 | ||||
-rw-r--r-- | forms/source/component/errorbroadcaster.cxx | 7 |
2 files changed, 3 insertions, 14 deletions
diff --git a/forms/source/component/DatabaseForm.cxx b/forms/source/component/DatabaseForm.cxx index 3aefbd798ade..45ffd5e595f1 100644 --- a/forms/source/component/DatabaseForm.cxx +++ b/forms/source/component/DatabaseForm.cxx @@ -2930,12 +2930,8 @@ void ODatabaseForm::reload_impl(bool bMoveToFirst, const Reference< XInteraction // the approval is done by the aggregate if (!m_aRowSetApproveListeners.getLength()) { - ::comphelper::OInterfaceIteratorHelper3 aIter(m_aLoadListeners); aGuard.clear(); - - while (aIter.hasMoreElements()) - aIter.next()->reloading(aEvent); - + m_aLoadListeners.notifyEach( &XLoadListener::reloading, aEvent); aGuard.reset(); } } @@ -2953,10 +2949,8 @@ void ODatabaseForm::reload_impl(bool bMoveToFirst, const Reference< XInteraction if (bSuccess) { - ::comphelper::OInterfaceIteratorHelper3 aIter(m_aLoadListeners); aGuard.clear(); - while (aIter.hasMoreElements()) - aIter.next()->reloaded(aEvent); + m_aLoadListeners.notifyEach( &XLoadListener::reloaded, aEvent); // if we are on the insert row, we have to reset all controls // to set the default values diff --git a/forms/source/component/errorbroadcaster.cxx b/forms/source/component/errorbroadcaster.cxx index e22cd2efbb74..7f37e4e0e95a 100644 --- a/forms/source/component/errorbroadcaster.cxx +++ b/forms/source/component/errorbroadcaster.cxx @@ -72,12 +72,7 @@ namespace frm void OErrorBroadcaster::onError( const css::sdb::SQLErrorEvent& _rError ) { - if ( m_aErrorListeners.getLength() ) - { - ::comphelper::OInterfaceIteratorHelper3 aIter( m_aErrorListeners ); - while ( aIter.hasMoreElements() ) - aIter.next()->errorOccured( _rError ); - } + m_aErrorListeners.notifyEach( &XSQLErrorListener::errorOccured, _rError ); } |