Kaydet (Commit) f2504a0a authored tarafından Julien Nabet's avatar Julien Nabet

Fix some "Variables reassigned a value before the old one has been used"

Change-Id: I64eadd8f34e9d60e9d696fa572dc0001532eab02
üst a579ad2c
......@@ -250,10 +250,9 @@ namespace accessibility
ensureAlive();
sal_Int32 i, nCount = 0;
SvtIconChoiceCtrl* pCtrl = getCtrl();
nCount = pCtrl->GetEntryCount();
for ( i = 0; i < nCount; ++i )
sal_Int32 nCount = pCtrl->GetEntryCount();
for ( sal_Int32 i = 0; i < nCount; ++i )
{
SvxIconChoiceCtrlEntry* pEntry = pCtrl->GetEntry( i );
if ( pCtrl->GetCursor() != pEntry )
......@@ -267,10 +266,10 @@ namespace accessibility
ensureAlive();
sal_Int32 i, nSelCount = 0, nCount = 0;
sal_Int32 nSelCount = 0;
SvtIconChoiceCtrl* pCtrl = getCtrl();
nCount = pCtrl->GetEntryCount();
for ( i = 0; i < nCount; ++i )
sal_Int32 nCount = pCtrl->GetEntryCount();
for ( sal_Int32 i = 0; i < nCount; ++i )
{
SvxIconChoiceCtrlEntry* pEntry = pCtrl->GetEntry( i );
if ( pCtrl->GetCursor() == pEntry )
......@@ -290,10 +289,10 @@ namespace accessibility
throw IndexOutOfBoundsException();
Reference< XAccessible > xChild;
sal_Int32 i, nSelCount = 0, nCount = 0;
sal_Int32 nSelCount = 0;
SvtIconChoiceCtrl* pCtrl = getCtrl();
nCount = pCtrl->GetEntryCount();
for ( i = 0; i < nCount; ++i )
sal_Int32 nCount = pCtrl->GetEntryCount();
for ( sal_Int32 i = 0; i < nCount; ++i )
{
SvxIconChoiceCtrlEntry* pEntry = pCtrl->GetEntry( i );
if ( pCtrl->GetCursor() == pEntry )
......@@ -319,11 +318,11 @@ namespace accessibility
throw IndexOutOfBoundsException();
Reference< XAccessible > xChild;
sal_Int32 i, nSelCount = 0, nCount = 0;
sal_Int32 nSelCount = 0;
SvtIconChoiceCtrl* pCtrl = getCtrl();
nCount = pCtrl->GetEntryCount();
sal_Int32 nCount = pCtrl->GetEntryCount();
bool bFound = false;
for ( i = 0; i < nCount; ++i )
for ( sal_Int32 i = 0; i < nCount; ++i )
{
SvxIconChoiceCtrlEntry* pEntry = pCtrl->GetEntry( i );
if ( pEntry->IsSelected() )
......
......@@ -307,9 +307,8 @@ namespace accessibility
ensureAlive();
sal_Int32 i, nCount = 0;
nCount = getListBox()->GetLevelChildCount( NULL );
for ( i = 0; i < nCount; ++i )
sal_Int32 nCount = getListBox()->GetLevelChildCount( NULL );
for ( sal_Int32 i = 0; i < nCount; ++i )
{
SvLBoxEntry* pEntry = getListBox()->GetEntry( i );
if ( getListBox()->IsSelected( pEntry ) )
......@@ -323,9 +322,8 @@ namespace accessibility
ensureAlive();
sal_Int32 i, nCount = 0;
nCount = getListBox()->GetLevelChildCount( NULL );
for ( i = 0; i < nCount; ++i )
sal_Int32 nCount = getListBox()->GetLevelChildCount( NULL );
for ( sal_Int32 i = 0; i < nCount; ++i )
{
SvLBoxEntry* pEntry = getListBox()->GetEntry( i );
if ( !getListBox()->IsSelected( pEntry ) )
......@@ -339,9 +337,9 @@ namespace accessibility
ensureAlive();
sal_Int32 i, nSelCount = 0, nCount = 0;
nCount = getListBox()->GetLevelChildCount( NULL );
for ( i = 0; i < nCount; ++i )
sal_Int32 nSelCount = 0;
sal_Int32 nCount = getListBox()->GetLevelChildCount( NULL );
for ( sal_Int32 i = 0; i < nCount; ++i )
{
SvLBoxEntry* pEntry = getListBox()->GetEntry( i );
if ( getListBox()->IsSelected( pEntry ) )
......@@ -361,9 +359,9 @@ namespace accessibility
throw IndexOutOfBoundsException();
Reference< XAccessible > xChild;
sal_Int32 i, nSelCount = 0, nCount = 0;
nCount = getListBox()->GetLevelChildCount( NULL );
for ( i = 0; i < nCount; ++i )
sal_Int32 nSelCount= 0;
sal_Int32 nCount = getListBox()->GetLevelChildCount( NULL );
for ( sal_Int32 i = 0; i < nCount; ++i )
{
SvLBoxEntry* pEntry = getListBox()->GetEntry( i );
if ( getListBox()->IsSelected( pEntry ) )
......
......@@ -730,9 +730,8 @@ namespace accessibility
SvLBoxEntry* pParent = getListBox()->GetEntryFromPath( m_aEntryPath );
if ( !pParent )
throw RuntimeException();
sal_Int32 i, nCount = 0;
nCount = getListBox()->GetLevelChildCount( pParent );
for ( i = 0; i < nCount; ++i )
sal_Int32 nCount = getListBox()->GetLevelChildCount( pParent );
for ( sal_Int32 i = 0; i < nCount; ++i )
{
SvLBoxEntry* pEntry = getListBox()->GetEntry( pParent, i );
if ( getListBox()->IsSelected( pEntry ) )
......@@ -750,9 +749,8 @@ namespace accessibility
SvLBoxEntry* pParent = getListBox()->GetEntryFromPath( m_aEntryPath );
if ( !pParent )
throw RuntimeException();
sal_Int32 i, nCount = 0;
nCount = getListBox()->GetLevelChildCount( pParent );
for ( i = 0; i < nCount; ++i )
sal_Int32 nCount = getListBox()->GetLevelChildCount( pParent );
for ( sal_Int32 i = 0; i < nCount; ++i )
{
SvLBoxEntry* pEntry = getListBox()->GetEntry( pParent, i );
if ( !getListBox()->IsSelected( pEntry ) )
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment