diff options
author | Andrzej Hunt <andrzej.hunt@collabora.com> | 2014-08-11 21:22:59 +0200 |
---|---|---|
committer | Andrzej Hunt <andrzej.hunt@collabora.com> | 2014-08-11 21:22:59 +0200 |
commit | 2904c469fc84fe7fb973e499d9d8b34c4919b3b3 (patch) | |
tree | f0bbb22bb579b9031e9014c6b5b4a5cf26aff7bc | |
parent | Return logic units for GetMergeSizePixel too. (diff) | |
download | core-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.cxx | 8 |
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) |