Remove DECLARE_LIST( TargetList, String* )
This commit is contained in:
parent
aae26bf0dc
commit
a99b8aaa33
3 changed files with 14 additions and 19 deletions
|
@ -209,18 +209,18 @@ SwCharURLPage::SwCharURLPage( Window* pParent,
|
|||
TargetList* pList = new TargetList;
|
||||
const SfxFrame& rFrame = pView->GetViewFrame()->GetTopFrame();
|
||||
rFrame.GetTargetList(*pList);
|
||||
USHORT nCount = (USHORT)pList->Count();
|
||||
if( nCount )
|
||||
if ( !pList->empty() )
|
||||
{
|
||||
USHORT i;
|
||||
size_t nCount = pList->size();
|
||||
size_t i;
|
||||
|
||||
for ( i = 0; i < nCount; i++ )
|
||||
{
|
||||
aTargetFrmLB.InsertEntry(*pList->GetObject(i));
|
||||
aTargetFrmLB.InsertEntry( *pList->at( i ) );
|
||||
}
|
||||
for ( i = nCount; i; i-- )
|
||||
for ( i = nCount; i; )
|
||||
{
|
||||
delete pList->GetObject( i - 1 );
|
||||
delete pList->at( --i );
|
||||
}
|
||||
}
|
||||
delete pList;
|
||||
|
|
|
@ -2554,17 +2554,16 @@ void SwFrmURLPage::Reset( const SfxItemSet &rSet )
|
|||
{
|
||||
TargetList* pList = new TargetList;
|
||||
((const SfxFrameItem*)pItem)->GetFrame()->GetTargetList(*pList);
|
||||
USHORT nCount = (USHORT)pList->Count();
|
||||
if( nCount )
|
||||
if( !pList->empty() )
|
||||
{
|
||||
USHORT i;
|
||||
for ( i = 0; i < nCount; i++ )
|
||||
size_t nCount = pList->size();
|
||||
for ( size_t i = 0; i < nCount; i++ )
|
||||
{
|
||||
aFrameCB.InsertEntry(*pList->GetObject(i));
|
||||
aFrameCB.InsertEntry( *pList->at( i ) );
|
||||
}
|
||||
for ( i = nCount; i; i-- )
|
||||
for ( size_t i = nCount; i; )
|
||||
{
|
||||
delete pList->GetObject( i - 1 );
|
||||
delete pList->at( --i );
|
||||
}
|
||||
}
|
||||
delete pList;
|
||||
|
|
|
@ -181,12 +181,8 @@ void lcl_UpdateIMapDlg( SwWrtShell& rSh )
|
|||
SvxIMapDlgChildWindow::UpdateIMapDlg(
|
||||
aGrf, rURL.GetMap(), pList, pEditObj );
|
||||
|
||||
USHORT nCount = (USHORT)pList->Count();
|
||||
if(nCount)
|
||||
for( USHORT i = nCount; i; i-- )
|
||||
{
|
||||
delete pList->GetObject(i-1);
|
||||
}
|
||||
for ( size_t i = 0, n = pList->size(); i < n; ++i )
|
||||
delete pList->at( i );
|
||||
delete pList;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue