diff options
author | Elton Chung <elton@layerjet.com> | 2012-02-19 16:59:40 +0400 |
---|---|---|
committer | Ivan Timofeev <timofeev.i.s@gmail.com> | 2012-02-19 17:07:46 +0400 |
commit | d30b4e9fb66f377295d8eeea8c1b1cf879aecdf6 (patch) | |
tree | a99079bda02a9d8dd5bd0d54666164f362314c52 /sw | |
parent | 704c9477039e37b4910db6aa8dd644751dd5e6a5 (diff) |
Get rid of size() == 0
Diffstat (limited to 'sw')
-rw-r--r-- | sw/source/core/SwNumberTree/SwNumberTree.cxx | 2 | ||||
-rw-r--r-- | sw/source/core/table/swnewtable.cxx | 2 | ||||
-rw-r--r-- | sw/source/ui/wrtsh/navmgr.cxx | 2 |
3 files changed, 3 insertions, 3 deletions
diff --git a/sw/source/core/SwNumberTree/SwNumberTree.cxx b/sw/source/core/SwNumberTree/SwNumberTree.cxx index bc34218110ce..b2359f923d78 100644 --- a/sw/source/core/SwNumberTree/SwNumberTree.cxx +++ b/sw/source/core/SwNumberTree/SwNumberTree.cxx @@ -358,7 +358,7 @@ SwNumberTreeNode * SwNumberTreeNode::GetFirstNonPhantomChild() void SwNumberTreeNode::MoveGreaterChildren( SwNumberTreeNode& _rCompareNode, SwNumberTreeNode& _rDestNode ) { - if ( mChildren.size() == 0 ) + if ( mChildren.empty() ) return; // determine first child, which has to move to <_rDestNode> diff --git a/sw/source/core/table/swnewtable.cxx b/sw/source/core/table/swnewtable.cxx index d2ba75e87b2c..3f68127408c8 100644 --- a/sw/source/core/table/swnewtable.cxx +++ b/sw/source/core/table/swnewtable.cxx @@ -2068,7 +2068,7 @@ SwSaveRowSpan* SwTable::CleanUpTopRowSpan( sal_uInt16 nSplitLine ) if( !IsNewModel() ) return pRet; pRet = new SwSaveRowSpan( GetTabLines()[0]->GetTabBoxes(), nSplitLine ); - if( pRet->mnRowSpans.size() == 0 ) + if( pRet->mnRowSpans.empty() ) { delete pRet; pRet = 0; diff --git a/sw/source/ui/wrtsh/navmgr.cxx b/sw/source/ui/wrtsh/navmgr.cxx index 6ee622241e8c..66a53f14b5cf 100644 --- a/sw/source/ui/wrtsh/navmgr.cxx +++ b/sw/source/ui/wrtsh/navmgr.cxx @@ -201,7 +201,7 @@ bool SwNavigationMgr::addEntry(const SwPosition& rPos) { bRet = true; } else { - if ( (m_entries.size() > 0 && *m_entries.back()->GetPoint() != rPos) || (m_entries.size() == 0) ) { + if ( (!m_entries.empty() && *m_entries.back()->GetPoint() != rPos) || m_entries.empty() ) { SwUnoCrsr *const pCursor = m_rMyShell.GetDoc()->CreateUnoCrsr(rPos); m_entries.push_back(::boost::shared_ptr<SwUnoCrsr>(pCursor)); bRet = true; |