diff options
author | Mike Kaganski <mike.kaganski@collabora.com> | 2019-10-01 00:21:00 +0300 |
---|---|---|
committer | Mike Kaganski <mike.kaganski@collabora.com> | 2019-10-01 06:35:49 +0200 |
commit | 981654f6e0d57c2c6dd1bbf740a6b67941146497 (patch) | |
tree | f7cf40ccf38d4666280b647c77ea7859e97f89e4 /svx/source/svdraw/svdedxv.cxx | |
parent | 1fc63383ccd8af144d681ba405f5ead863ac24e1 (diff) |
Drop SfxItemIter::FirstItem
It is always used right after the iterator is created, where simple
GetCurItem gives the same value without reseting the position.
Change-Id: I871dc7989b79e13f06436ef7928692645b5209f6
Reviewed-on: https://gerrit.libreoffice.org/79903
Tested-by: Jenkins
Reviewed-by: Mike Kaganski <mike.kaganski@collabora.com>
Diffstat (limited to 'svx/source/svdraw/svdedxv.cxx')
-rw-r--r-- | svx/source/svdraw/svdedxv.cxx | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/svx/source/svdraw/svdedxv.cxx b/svx/source/svdraw/svdedxv.cxx index ab186938f46c..52b178b0a82b 100644 --- a/svx/source/svdraw/svdedxv.cxx +++ b/svx/source/svdraw/svdedxv.cxx @@ -2168,8 +2168,8 @@ bool SdrObjEditView::SetAttributes(const SfxItemSet& rSet, bool bReplaceAll) { bool bHasEEFeatureItems = false; SfxItemIter aIter(rSet); - const SfxPoolItem* pItem = aIter.FirstItem(); - while (!bHasEEFeatureItems && pItem != nullptr) + for (const SfxPoolItem* pItem = aIter.GetCurItem(); !bHasEEFeatureItems && pItem; + pItem = aIter.NextItem()) { if (!IsInvalidItem(pItem)) { @@ -2177,8 +2177,6 @@ bool SdrObjEditView::SetAttributes(const SfxItemSet& rSet, bool bReplaceAll) if (nW >= EE_FEATURE_START && nW <= EE_FEATURE_END) bHasEEFeatureItems = true; } - - pItem = aIter.NextItem(); } if (bHasEEFeatureItems) |