Kaydet (Commit) 274a1bca authored tarafından Bjoern Michaelsen's avatar Bjoern Michaelsen

core/docnode: dont use 'shortcut' that is longer than the original

Change-Id: Idf0bdea2ffb987859e413f2cea4eaa0d97d2ba7b
üst e6fb43ca
......@@ -708,7 +708,7 @@ SwFrmFmt* SwNode::GetFlyFmt() const
{
if( IsCntntNode() )
{
SwCntntFrm* pFrm = SwIterator<SwCntntFrm,SwCntntNode>::FirstElement( *static_cast<const SwCntntNode*>(this) );
SwCntntFrm* pFrm = SwIterator<SwCntntFrm,SwCntntNode>( *static_cast<const SwCntntNode*>(this) ).First();
if( pFrm )
pRet = pFrm->FindFlyFrm()->GetFmt();
}
......@@ -1412,7 +1412,7 @@ bool SwCntntNode::GetInfo( SfxPoolItem& rInfo ) const
case RES_CONTENT_VISIBLE:
{
static_cast<SwPtrMsgPoolItem&>(rInfo).pObject =
SwIterator<SwFrm,SwCntntNode>::FirstElement(*this);
SwIterator<SwFrm,SwCntntNode>(*this).First();
}
return false;
}
......
......@@ -69,9 +69,9 @@ SwNode* GoNextWithFrm(const SwNodes& rNodes, SwNodeIndex *pIdx)
pNd = &aTmp.GetNode();
bool bFound = false;
if ( pNd->IsCntntNode() )
bFound = ( SwIterator<SwFrm,SwCntntNode>::FirstElement(*static_cast<SwCntntNode*>(pNd)) != 0);
bFound = SwIterator<SwFrm,SwCntntNode>(*static_cast<SwCntntNode*>(pNd)).First();
else if ( pNd->IsTableNode() )
bFound = ( SwIterator<SwFrm,SwFmt>::FirstElement(*static_cast<SwTableNode*>(pNd)->GetTable().GetFrmFmt()) != 0 );
bFound = SwIterator<SwFrm,SwFmt>(*static_cast<SwTableNode*>(pNd)->GetTable().GetFrmFmt()).First() ;
else if( pNd->IsEndNode() && !pNd->StartOfSectionNode()->IsSectionNode() )
{
pNd = 0;
......@@ -101,9 +101,9 @@ SwNode* GoPreviousWithFrm(SwNodeIndex *pIdx)
pNd = &aTmp.GetNode();
bool bFound = false;
if ( pNd->IsCntntNode() )
bFound = ( SwIterator<SwFrm,SwCntntNode>::FirstElement(*static_cast<SwCntntNode*>(pNd)) != 0);
bFound = SwIterator<SwFrm,SwCntntNode>(*static_cast<SwCntntNode*>(pNd)).First();
else if ( pNd->IsTableNode() )
bFound = ( SwIterator<SwFrm,SwFmt>::FirstElement(*static_cast<SwTableNode*>(pNd)->GetTable().GetFrmFmt()) != 0 );
bFound = SwIterator<SwFrm,SwFmt>(*static_cast<SwTableNode*>(pNd)->GetTable().GetFrmFmt()).First();
else if( pNd->IsStartNode() && !pNd->IsSectionNode() )
{
pNd = 0;
......
......@@ -679,7 +679,7 @@ SwSectionFmt::~SwSectionFmt()
SwSection * SwSectionFmt::GetSection() const
{
return SwIterator<SwSection,SwSectionFmt>::FirstElement( *this );
return SwIterator<SwSection,SwSectionFmt>( *this ).First();
}
// Do not destroy all Frms in aDepend (Frms are recognized with a PTR_CAST).
......@@ -858,7 +858,7 @@ bool SwSectionFmt::GetInfo( SfxPoolItem& rInfo ) const
case RES_CONTENT_VISIBLE:
{
SwFrm* pFrm = SwIterator<SwFrm,SwFmt>::FirstElement(*this);
SwFrm* pFrm = SwIterator<SwFrm,SwFmt>(*this).First();
// if the current section has no own frame search for the children
if(!pFrm)
{
......@@ -866,7 +866,7 @@ bool SwSectionFmt::GetInfo( SfxPoolItem& rInfo ) const
SwSectionFmt* pChild = aFormatIter.First();
while(pChild && !pFrm)
{
pFrm = SwIterator<SwFrm,SwFmt>::FirstElement(*pChild);
pFrm = SwIterator<SwFrm,SwFmt>(*pChild).First();
pChild = aFormatIter.Next();
}
}
......
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