diff options
author | Caolán McNamara <caolanm@redhat.com> | 2011-08-26 22:26:24 +0100 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2011-08-29 09:56:05 +0100 |
commit | 012072ebd70a2180918864818f522944e46adf07 (patch) | |
tree | ba33e6c949b52aa7f61ef410f809c817fea5c328 /sd | |
parent | callcatcher: debug-only and unused code (diff) | |
download | core-012072ebd70a2180918864818f522944e46adf07.tar.gz core-012072ebd70a2180918864818f522944e46adf07.zip |
valgrind: various unused code
Diffstat (limited to 'sd')
-rw-r--r-- | sd/source/ui/dlg/tpoption.cxx | 56 | ||||
-rw-r--r-- | sd/source/ui/inc/tpoption.hxx | 2 |
2 files changed, 0 insertions, 58 deletions
diff --git a/sd/source/ui/dlg/tpoption.cxx b/sd/source/ui/dlg/tpoption.cxx index f0f2fd2b1953..e12cd976ea7c 100644 --- a/sd/source/ui/dlg/tpoption.cxx +++ b/sd/source/ui/dlg/tpoption.cxx @@ -684,62 +684,6 @@ void SdTpOptionsMisc::SetDrawMode() // spacing-between-paragraphs check box normally is in. aCbxUsePrinterMetrics.SetPosPixel (aCbxCompatibility.GetPosPixel()); } -// ----------------------------------------------------------------------- - -IMPL_LINK( SdTpOptionsMisc, ModifyScaleHdl, void *, EMPTYARG ) -{ - // Originalgroesse berechnen - sal_Int32 nX, nY; - if( SetScale( aCbScale.GetText(), nX, nY ) ) - { - sal_Int32 nW = nWidth * nY / nX; - sal_Int32 nH = nHeight * nY / nX; - - SetMetricValue( aMtrFldOriginalWidth, nW, ePoolUnit ); - SetMetricValue( aMtrFldOriginalHeight, nH, ePoolUnit ); - } - - return( 0L ); -} - -// ----------------------------------------------------------------------- - -IMPL_LINK( SdTpOptionsMisc, ModifyOriginalScaleHdl, void *, EMPTYARG ) -{ - // Berechnen des Massstabs - long nOrgW = static_cast<long>(aMtrFldOriginalWidth.GetValue()); - long nOrgH = static_cast<long>(aMtrFldOriginalHeight.GetValue()); - - if( nOrgW == 0 || nOrgH == 0 ) - return( 0L ); - - Fraction aFract1( nOrgW, static_cast<long>(aMtrFldInfo1.GetValue()) ); - Fraction aFract2( nOrgH, static_cast<long>(aMtrFldInfo2.GetValue()) ); - Fraction aFract( aFract1 > aFract2 ? aFract1 : aFract2 ); - - long nValue; - if( aFract < Fraction( 1, 1 ) ) - { - // Fraction umdrehen - aFract1 = aFract; - aFract = Fraction( aFract1.GetDenominator(), aFract1.GetNumerator() ); - nValue = aFract; - - // Swap nominator and denominator - aCbScale.SetText( GetScale( nValue, 1 ) ); - } - else - { - double fValue = aFract; - nValue = aFract; - if( fValue > (double)nValue ) - nValue++; - - // Swap nominator and denominator - aCbScale.SetText( GetScale( 1, nValue ) ); - } - return( 0L ); -} // ----------------------------------------------------------------------- diff --git a/sd/source/ui/inc/tpoption.hxx b/sd/source/ui/inc/tpoption.hxx index c99e9f7af23e..bc080604b069 100644 --- a/sd/source/ui/inc/tpoption.hxx +++ b/sd/source/ui/inc/tpoption.hxx @@ -144,8 +144,6 @@ private: String GetScale( sal_Int32 nX, sal_Int32 nY ); sal_Bool SetScale( const String& aScale, sal_Int32& rX, sal_Int32& rY ); - DECL_LINK( ModifyScaleHdl, void * ); - DECL_LINK( ModifyOriginalScaleHdl, void * ); DECL_LINK( SelectMetricHdl_Impl, ListBox * ); /** Enable or disable the controls in the compatibility section of the |