summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJan-Marek Glogowski <glogow@fbihome.de>2014-07-13 20:18:56 +0200
committerJan-Marek Glogowski <glogow@fbihome.de>2014-09-30 09:47:52 +0200
commita935187b2e01293c6d0ba38f46bb5b597ccbb575 (patch)
treebab8a88a02302ed8229ef9d8e8c35e00839bff94
parentSave debug mail merge documents (diff)
downloadcore-a935187b2e01293c6d0ba38f46bb5b597ccbb575.tar.gz
core-a935187b2e01293c6d0ba38f46bb5b597ccbb575.zip
Refactor a tiny bit of SwLayAction::IsShortCut
Change-Id: I13d4fbebec02bddaa27e8929188d497dde715730 Reviewed-on: https://gerrit.libreoffice.org/10980 Reviewed-by: Björn Michaelsen <bjoern.michaelsen@canonical.com> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com> (cherry picked from commit 7fc5207ebe57a2b88e2ba7ab45e4ce3f6c049df3)
-rw-r--r--sw/source/core/layout/layact.cxx6
1 files changed, 2 insertions, 4 deletions
diff --git a/sw/source/core/layout/layact.cxx b/sw/source/core/layout/layact.cxx
index 71659ce4ab95..5ea7b14eafb8 100644
--- a/sw/source/core/layout/layact.cxx
+++ b/sw/source/core/layout/layact.cxx
@@ -1249,15 +1249,13 @@ sal_Bool SwLayAction::IsShortCut( SwPageFrm *&prPage )
}
// #121980# - no shortcut, if at previous page
// an anchored object is registered, whose anchor is <pCntnt>.
- else if ( prPage->GetPrev() &&
- static_cast<SwPageFrm*>(prPage->GetPrev())->GetSortedObjs() )
+ else if ( prPage->GetPrev() )
{
SwSortedObjs* pObjs =
static_cast<SwPageFrm*>(prPage->GetPrev())->GetSortedObjs();
if ( pObjs )
{
- sal_uInt32 i = 0;
- for ( ; i < pObjs->Count(); ++i )
+ for ( sal_uInt32 i = 0; i < pObjs->Count(); ++i )
{
SwAnchoredObject* pObj = (*pObjs)[i];
if ( pObj->GetAnchorFrmContainingAnchPos() == pCntnt )