diff options
author | Zolnai Tamás <zolnaitamas2000@gmail.com> | 2013-07-09 12:41:33 +0200 |
---|---|---|
committer | Zolnai Tamás <zolnaitamas2000@gmail.com> | 2013-07-22 20:19:30 +0200 |
commit | ea79b364499d7d9df06fb0cd048f53a38b95077b (patch) | |
tree | 46ac5525c455a71f2d0f4540759c09509be3c6cd /sw | |
parent | 3b7030d99580aa70dad884b1ac74924d9a179b3e (diff) |
Decrease scope of some variable
Change-Id: I23319e09bf6c4c0e33b86edc225cdfaa0433b7c6
Diffstat (limited to 'sw')
-rw-r--r-- | sw/source/core/layout/paintfrm.cxx | 16 |
1 files changed, 7 insertions, 9 deletions
diff --git a/sw/source/core/layout/paintfrm.cxx b/sw/source/core/layout/paintfrm.cxx index b19da71db06c..6d99fd383733 100644 --- a/sw/source/core/layout/paintfrm.cxx +++ b/sw/source/core/layout/paintfrm.cxx @@ -4673,9 +4673,6 @@ static void lcl_PaintLeftRightLine( const bool _bLeft, { pLeftRightBorder = bR2L ? rBox.GetLeft() : rBox.GetRight(); } - // OD 06.05.2003 #107169# - init boolean indicating printer output device. - const bool bPrtOutputDev = - ( OUTDEV_PRINTER == pGlobalShell->GetOut()->GetOutDevType() ); if ( !pLeftRightBorder ) { @@ -4694,9 +4691,7 @@ static void lcl_PaintLeftRightLine( const bool _bLeft, (aRect.*_rRectFn->fnGetWidth)() ); } - const sal_Bool bCnt = _rFrm.IsCntntFrm(); - - if ( bCnt ) + if ( _rFrm.IsCntntFrm() ) { ::lcl_ExtendLeftAndRight( aRect, _rFrm, _rAttrs, _rRectFn ); @@ -4707,6 +4702,10 @@ static void lcl_PaintLeftRightLine( const bool _bLeft, if ( !pLeftRightBorder->GetInWidth() ) { + // OD 06.05.2003 #107169# - init boolean indicating printer output device. + const bool bPrtOutputDev = + ( OUTDEV_PRINTER == pGlobalShell->GetOut()->GetOutDevType() ); + // OD 06.05.2003 #107169# - add 6th parameter ::lcl_SubTopBottom( aRect, rBox, _rAttrs, _rFrm, _rRectFn, bPrtOutputDev ); } @@ -4730,8 +4729,7 @@ static void lcl_PaintTopBottomLine( const bool _bTop, { const SvxBoxItem& rBox = _rAttrs.GetBox(); const SvxBorderLine* pTopBottomBorder = 0; - const SvxBorderLine* pLeftBorder = rBox.GetLeft(); - const SvxBorderLine* pRightBorder = rBox.GetRight(); + if ( _bTop ) { pTopBottomBorder = rBox.GetTop(); @@ -4761,7 +4759,7 @@ static void lcl_PaintTopBottomLine( const bool _bTop, if ( lcl_GetLineWidth( pTopBottomBorder ) > 0 ) { lcl_MakeBorderLine( - aRect, false, _bTop, *pTopBottomBorder, pLeftBorder, pRightBorder); + aRect, false, _bTop, *pTopBottomBorder, rBox.GetLeft(), rBox.GetRight()); } } |