summaryrefslogtreecommitdiff
path: root/svx/source/table
diff options
context:
space:
mode:
authorNoel Grandin <noelgrandin@gmail.com>2022-05-28 13:36:41 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2022-05-28 17:36:49 +0200
commitbcd27039eec660fce2abd7604cdb8cd36ae4cdba (patch)
tree66aaecdf872ac6ee80142e2141b490b5d1a49880 /svx/source/table
parent9896f330cdb3df67b74b16a2c2177a8505fd2485 (diff)
use the new SfxWhichIter::GetItemState feature
to speed up other places that are iterating over SfxItemSets Change-Id: I646bae12420d15e67effdd279e071cdf8a8afffd Reviewed-on: https://gerrit.libreoffice.org/c/core/+/135075 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'svx/source/table')
-rw-r--r--svx/source/table/tablecontroller.cxx5
1 files changed, 3 insertions, 2 deletions
diff --git a/svx/source/table/tablecontroller.cxx b/svx/source/table/tablecontroller.cxx
index 8ef76acd377e..ef7401489c1d 100644
--- a/svx/source/table/tablecontroller.cxx
+++ b/svx/source/table/tablecontroller.cxx
@@ -2422,14 +2422,15 @@ void SvxTableController::MergeAttrFromSelectedCells(SfxItemSet& rAttr, bool bOnl
sal_uInt16 nWhich(aIter.FirstWhich());
while(nWhich)
{
+ SfxItemState nState = aIter.GetItemState(false);
if(!bOnlyHardAttr)
{
- if(SfxItemState::DONTCARE == rSet.GetItemState(nWhich, false))
+ if(SfxItemState::DONTCARE == nState)
rAttr.InvalidateItem(nWhich);
else
rAttr.MergeValue(rSet.Get(nWhich), true);
}
- else if(SfxItemState::SET == rSet.GetItemState(nWhich, false))
+ else if(SfxItemState::SET == nState)
{
const SfxPoolItem& rItem = rSet.Get(nWhich);
rAttr.MergeValue(rItem, true);