[Libreoffice-commits] core.git: svl/source
Julien Nabet (via logerrit)
logerrit at kemper.freedesktop.org
Thu Oct 3 20:23:46 UTC 2019
svl/source/items/aeitem.cxx | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
New commits:
commit 30308a8b4c89ea806dd61a20707bbe28c27286dc
Author: Julien Nabet <serval2412 at yahoo.fr>
AuthorDate: Thu Oct 3 20:45:02 2019 +0200
Commit: Julien Nabet <serval2412 at yahoo.fr>
CommitDate: Thu Oct 3 22:22:20 2019 +0200
Following "Simplify a bit SfxAllEnumItem (svl)"
As Mike suggested in:
https://gerrit.libreoffice.org/#/c/80089/
Change-Id: Ie33cb1464907215ec23bf7be7cf5ce3fafdf6113
Reviewed-on: https://gerrit.libreoffice.org/80161
Tested-by: Jenkins
Reviewed-by: Julien Nabet <serval2412 at yahoo.fr>
diff --git a/svl/source/items/aeitem.cxx b/svl/source/items/aeitem.cxx
index cafa6fe3a3b7..2d2ce6d10ea5 100644
--- a/svl/source/items/aeitem.cxx
+++ b/svl/source/items/aeitem.cxx
@@ -108,10 +108,9 @@ void SfxAllEnumItem::InsertValue( sal_uInt16 nValue, const OUString &rValue )
SfxAllEnumValue_Impl aVal;
aVal.nValue = nValue;
aVal.aText = rValue;
- sal_uInt16 nPos = GetPosByValue(nValue);
if ( !pValues )
pValues.reset( new SfxAllEnumValueArr );
- else if ( nPos != USHRT_MAX )
+ else if ( sal_uInt16 nPos = GetPosByValue(nValue); nPos != USHRT_MAX )
{
// remove when exists
pValues->erase( pValues->begin() + nPos );
More information about the Libreoffice-commits
mailing list