summaryrefslogtreecommitdiff
path: root/sc/source/ui/miscdlgs/optsolver.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'sc/source/ui/miscdlgs/optsolver.cxx')
-rw-r--r--sc/source/ui/miscdlgs/optsolver.cxx12
1 files changed, 6 insertions, 6 deletions
diff --git a/sc/source/ui/miscdlgs/optsolver.cxx b/sc/source/ui/miscdlgs/optsolver.cxx
index 7c753326be82..89594f57ab5b 100644
--- a/sc/source/ui/miscdlgs/optsolver.cxx
+++ b/sc/source/ui/miscdlgs/optsolver.cxx
@@ -459,10 +459,10 @@ void ScOptSolverDlg::ReadConditions()
aRowEntry.nOperator = mpOperator[nRow]->GetSelectedEntryPos();
long nVecPos = nScrollPos + nRow;
- if ( nVecPos >= (long)maConditions.size() && !aRowEntry.IsDefault() )
+ if ( nVecPos >= static_cast<long>(maConditions.size()) && !aRowEntry.IsDefault() )
maConditions.resize( nVecPos + 1 );
- if ( nVecPos < (long)maConditions.size() )
+ if ( nVecPos < static_cast<long>(maConditions.size()) )
maConditions[nVecPos] = aRowEntry;
// remove default entries at the end
@@ -480,7 +480,7 @@ void ScOptSolverDlg::ShowConditions()
ScOptConditionRow aRowEntry;
long nVecPos = nScrollPos + nRow;
- if ( nVecPos < (long)maConditions.size() )
+ if ( nVecPos < static_cast<long>(maConditions.size()) )
aRowEntry = maConditions[nVecPos];
mpLeftEdit[nRow]->SetRefString( aRowEntry.aLeftStr );
@@ -490,7 +490,7 @@ void ScOptSolverDlg::ShowConditions()
// allow to scroll one page behind the visible or stored rows
long nVisible = nScrollPos + EDIT_ROW_COUNT;
- long nMax = std::max( nVisible, (long) maConditions.size() );
+ long nMax = std::max( nVisible, static_cast<long>(maConditions.size()) );
m_pScrollBar->SetRange( Range( 0, nMax + EDIT_ROW_COUNT ) );
m_pScrollBar->SetThumbPos( nScrollPos );
@@ -502,7 +502,7 @@ void ScOptSolverDlg::EnableButtons()
for ( sal_uInt16 nRow = 0; nRow < EDIT_ROW_COUNT; ++nRow )
{
long nVecPos = nScrollPos + nRow;
- mpDelButton[nRow]->Enable( nVecPos < (long)maConditions.size() );
+ mpDelButton[nRow]->Enable( nVecPos < static_cast<long>(maConditions.size()) );
}
}
@@ -667,7 +667,7 @@ IMPL_LINK( ScOptSolverDlg, DelBtnHdl, Button*, pBtn, void )
ReadConditions();
long nVecPos = nScrollPos + nRow;
- if ( nVecPos < (long)maConditions.size() )
+ if ( nVecPos < static_cast<long>(maConditions.size()) )
{
maConditions.erase( maConditions.begin() + nVecPos );
ShowConditions();