summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndrzej Hunt <andrzej.hunt@collabora.com>2014-08-11 21:22:59 +0200
committerAndrzej Hunt <andrzej.hunt@collabora.com>2014-08-11 21:22:59 +0200
commit2904c469fc84fe7fb973e499d9d8b34c4919b3b3 (patch)
treef0bbb22bb579b9031e9014c6b5b4a5cf26aff7bc
parentReturn logic units for GetMergeSizePixel too. (diff)
downloadcore-2904c469fc84fe7fb973e499d9d8b34c4919b3b3.tar.gz
core-2904c469fc84fe7fb973e499d9d8b34c4919b3b3.zip
Move variable definition closer to point of use.
Previously it was in a very unlogical location. Change-Id: I6a09244eb1aa3bf413ae98e215c2667adcc96907
-rw-r--r--sc/source/ui/view/hdrcont.cxx8
1 files changed, 4 insertions, 4 deletions
diff --git a/sc/source/ui/view/hdrcont.cxx b/sc/source/ui/view/hdrcont.cxx
index 2c84e5017ed7..16df024f654e 100644
--- a/sc/source/ui/view/hdrcont.cxx
+++ b/sc/source/ui/view/hdrcont.cxx
@@ -319,7 +319,6 @@ void ScHeaderControl::Paint( const Rectangle& rRect )
OUString aString;
sal_uInt16 nBarSize;
Point aScrPos;
- Size aTextSize;
Size aLogicSize = PixelToLogic( GetSizePixel(), maPaintMapMode );
@@ -622,9 +621,10 @@ void ScHeaderControl::Paint( const Rectangle& rRect )
bBoldSet = bMark;
}
aString = GetEntryText( nEntryNo );
- aTextSize.Width() = GetTextWidth( aString );
- aTextSize.Height() = GetTextHeight();
- aTextSize = PixelToLogic( aTextSize, maPaintMapMode );
+ Size aTextSize = PixelToLogic( Size(
+ GetTextWidth( aString ),
+ GetTextHeight() ),
+ maPaintMapMode );
Point aTxtPos(aScrPos);
if (bVertical)