diff options
author | Christian Lippka <christian.lippka@sun.com> | 2010-05-05 17:39:48 +0200 |
---|---|---|
committer | Christian Lippka <christian.lippka@sun.com> | 2010-05-05 17:39:48 +0200 |
commit | 58dd850178eb0151f03351b0599fcb88e6b499a8 (patch) | |
tree | 7a005c45abf348b2c29e9748392d52c9383e2236 /sd/source/ui/dlg/dlgsnap.cxx | |
parent | 1875ea687b2c5c45fe3df626c05ca5f483417269 (diff) |
#i89450# removed unused code
Diffstat (limited to 'sd/source/ui/dlg/dlgsnap.cxx')
-rwxr-xr-x[-rw-r--r--] | sd/source/ui/dlg/dlgsnap.cxx | 18 |
1 files changed, 13 insertions, 5 deletions
diff --git a/sd/source/ui/dlg/dlgsnap.cxx b/sd/source/ui/dlg/dlgsnap.cxx index 2b78a649eaef..6cd220d5a5bc 100644..100755 --- a/sd/source/ui/dlg/dlgsnap.cxx +++ b/sd/source/ui/dlg/dlgsnap.cxx @@ -96,27 +96,35 @@ SdSnapLineDlg::SdSnapLineDlg( DBG_ASSERT( pPool, "Wo ist der Pool?" ); SfxMapUnit ePoolUnit = pPool->GetMetric( SID_ATTR_FILL_HATCH ); - // Hier werden die Max- und MinWerte in Ahaengigkeit von der + // #i48497# Consider page origin + SdrPageView* pPV = pView->GetSdrPageView(); + Point aLeftTop(aWorkArea.Left()+1, aWorkArea.Top()+1); + pPV->LogicToPagePos(aLeftTop); + Point aRightBottom(aWorkArea.Right()-2, aWorkArea.Bottom()-2); + pPV->LogicToPagePos(aRightBottom); + + // Hier werden die Max- und MinWerte in Abhaengigkeit von der // WorkArea, PoolUnit und der FieldUnit: - SetMetricValue( aMtrFldX, aWorkArea.Left(), ePoolUnit ); + SetMetricValue( aMtrFldX, aLeftTop.X(), ePoolUnit ); + long nValue = static_cast<long>(aMtrFldX.GetValue()); nValue = Fraction( nValue ) / aUIScale; aMtrFldX.SetMin( nValue ); aMtrFldX.SetFirst( nValue ); - SetMetricValue( aMtrFldX, aWorkArea.Right()+1, ePoolUnit ); + SetMetricValue( aMtrFldX, aRightBottom.X(), ePoolUnit ); nValue = static_cast<long>(aMtrFldX.GetValue()); nValue = Fraction( nValue ) / aUIScale; aMtrFldX.SetMax( nValue ); aMtrFldX.SetLast( nValue ); - SetMetricValue( aMtrFldY, aWorkArea.Top(), ePoolUnit ); + SetMetricValue( aMtrFldY, aLeftTop.Y(), ePoolUnit ); nValue = static_cast<long>(aMtrFldY.GetValue()); nValue = Fraction( nValue ) / aUIScale; aMtrFldY.SetMin( nValue ); aMtrFldY.SetFirst( nValue ); - SetMetricValue( aMtrFldY, aWorkArea.Bottom()+1, ePoolUnit ); + SetMetricValue( aMtrFldY, aRightBottom.Y(), ePoolUnit ); nValue = static_cast<long>(aMtrFldY.GetValue()); nValue = Fraction( nValue ) / aUIScale; aMtrFldY.SetMax( nValue ); |