diff options
author | Noel Grandin <noelgrandin@gmail.com> | 2020-12-30 14:13:20 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2021-01-01 08:57:27 +0100 |
commit | f3805d006356651eb2fbac188457d6f89813f8db (patch) | |
tree | 498b942d865b21a6e6d71bee1255ba2fd46cf20d | |
parent | 9980eb71513d4c16ffaceace1a754a387c209d27 (diff) |
use SdrAngleItem for ATTR_COPY_ANGLE
Change-Id: Ieea4d18cec6fd46d2f8d5f58f6246857e07f2129
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108520
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
-rw-r--r-- | sd/source/ui/dlg/copydlg.cxx | 5 | ||||
-rw-r--r-- | sd/source/ui/func/fucopy.cxx | 3 |
2 files changed, 5 insertions, 3 deletions
diff --git a/sd/source/ui/dlg/copydlg.cxx b/sd/source/ui/dlg/copydlg.cxx index 398f9e4ee567..e1e26a542767 100644 --- a/sd/source/ui/dlg/copydlg.cxx +++ b/sd/source/ui/dlg/copydlg.cxx @@ -20,6 +20,7 @@ #include <copydlg.hxx> #include <svx/colorbox.hxx> #include <svx/svdpagv.hxx> +#include <svx/sdangitm.hxx> #include <sfx2/module.hxx> #include <svx/xcolit.hxx> #include <svl/intitem.hxx> @@ -131,7 +132,7 @@ void CopyDlg::Reset() SetMetricValue( *m_xMtrFldMoveY, tools::Long(nMoveY / maUIScale), MapUnit::Map100thMM); if( SfxItemState::SET == mrOutAttrs.GetItemState( ATTR_COPY_ANGLE, true, &pPoolItem ) ) - m_xMtrFldAngle->set_value(static_cast<const SfxInt32Item*>( pPoolItem )->GetValue(), FieldUnit::NONE); + m_xMtrFldAngle->set_value(static_cast<const SdrAngleItem*>( pPoolItem )->GetValue(), FieldUnit::NONE); else m_xMtrFldAngle->set_value(0, FieldUnit::NONE); @@ -187,7 +188,7 @@ void CopyDlg::GetAttr( SfxItemSet& rOutAttrs ) rOutAttrs.Put( SfxUInt16Item( ATTR_COPY_NUMBER, static_cast<sal_uInt16>(m_xNumFldCopies->get_value()) ) ); rOutAttrs.Put( SfxInt32Item( ATTR_COPY_MOVE_X, nMoveX ) ); rOutAttrs.Put( SfxInt32Item( ATTR_COPY_MOVE_Y, nMoveY ) ); - rOutAttrs.Put( SfxInt32Item( ATTR_COPY_ANGLE, static_cast<sal_Int32>(m_xMtrFldAngle->get_value(FieldUnit::DEGREE)) ) ); + rOutAttrs.Put( SdrAngleItem( ATTR_COPY_ANGLE, static_cast<sal_Int32>(m_xMtrFldAngle->get_value(FieldUnit::DEGREE)) ) ); rOutAttrs.Put( SfxInt32Item( ATTR_COPY_WIDTH, nWidth ) ); rOutAttrs.Put( SfxInt32Item( ATTR_COPY_HEIGHT, nHeight ) ); diff --git a/sd/source/ui/func/fucopy.cxx b/sd/source/ui/func/fucopy.cxx index 8a10daaec5d6..ba50612dce3d 100644 --- a/sd/source/ui/func/fucopy.cxx +++ b/sd/source/ui/func/fucopy.cxx @@ -33,6 +33,7 @@ #include <svx/xflclit.hxx> #include <svx/xdef.hxx> #include <svx/xfillit0.hxx> +#include <svx/sdangitm.hxx> #include <sfx2/request.hxx> #include <sdabstdlg.hxx> #include <memory> @@ -135,7 +136,7 @@ void FuCopy::DoExecute( SfxRequest& rReq ) if( pArgs && SfxItemState::SET == pArgs->GetItemState( ATTR_COPY_MOVE_Y, true, &pPoolItem ) ) lSizeY = static_cast<const SfxInt32Item*>( pPoolItem )->GetValue(); if( pArgs && SfxItemState::SET == pArgs->GetItemState( ATTR_COPY_ANGLE, true, &pPoolItem ) ) - lAngle = static_cast<const SfxInt32Item*>( pPoolItem )->GetValue(); + lAngle = static_cast<const SdrAngleItem*>( pPoolItem )->GetValue(); // scale if( pArgs && SfxItemState::SET == pArgs->GetItemState( ATTR_COPY_WIDTH, true, &pPoolItem ) ) |