diff options
author | Luboš Luňák <l.lunak@suse.cz> | 2012-03-18 08:02:08 +0100 |
---|---|---|
committer | Luboš Luňák <l.lunak@suse.cz> | 2012-03-18 08:04:07 +0100 |
commit | 89d3de59abdd218750d78bbf80a6f07f7a13f31c (patch) | |
tree | 3cce10cefde0c45dfca64919a40c22494d7f8002 /sc | |
parent | 66ff55f8c6a4a315023b26f60056c3e52e3fc15c (diff) |
match if-else properly (warnings are actually sometimes useful, huh)
Diffstat (limited to 'sc')
-rw-r--r-- | sc/source/filter/excel/xiescher.cxx | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/sc/source/filter/excel/xiescher.cxx b/sc/source/filter/excel/xiescher.cxx index f049f251529c..6c8eb507d626 100644 --- a/sc/source/filter/excel/xiescher.cxx +++ b/sc/source/filter/excel/xiescher.cxx @@ -2634,9 +2634,11 @@ void XclImpListBoxObj::DoProcessControl( ScfPropertySet& rPropSet ) const // multi selection: API expects sequence of list entry indexes if( bMultiSel ) + { for( ScfUInt8Vec::const_iterator aBeg = maSelection.begin(), aIt = aBeg, aEnd = maSelection.end(); aIt != aEnd; ++aIt ) if( *aIt != 0 ) aSelVec.push_back( static_cast< sal_Int16 >( aIt - aBeg ) ); + } // single selection: mnSelEntry is one-based, API expects zero-based else if( mnSelEntry > 0 ) aSelVec.push_back( static_cast< sal_Int16 >( mnSelEntry - 1 ) ); |