summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2017-11-21 11:52:40 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2017-11-22 08:33:08 +0100
commitf1a55c4bfc6afcd9fd316e055e626097e0666ea8 (patch)
tree732404505e1ab4f41342322a2be37148dbe453ba
parent02393281b6964b6657985a453c6f1a43ac77411c (diff)
TypedWhichId for SDRATTR* constants (3)
Change-Id: Iea72cb3a4bbf693096de46269f58259b5952eedb Reviewed-on: https://gerrit.libreoffice.org/45024 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
-rw-r--r--chart2/source/controller/dialogs/tp_3D_SceneIllumination.cxx48
-rw-r--r--cui/source/tabpages/transfrm.cxx2
-rw-r--r--filter/source/msfilter/escherex.cxx8
-rw-r--r--filter/source/msfilter/msdffimp.cxx6
-rw-r--r--include/svx/extrud3d.hxx16
-rw-r--r--include/svx/lathe3d.hxx20
-rw-r--r--include/svx/scene3d.hxx6
-rw-r--r--include/svx/sphere3d.hxx4
-rw-r--r--include/svx/svddef.hxx148
-rw-r--r--sc/source/filter/excel/xiescher.cxx2
-rw-r--r--sc/source/filter/xcl97/xcl97esc.cxx4
-rw-r--r--sd/qa/unit/import-tests.cxx2
-rw-r--r--sd/source/ui/table/TableDesignPane.cxx2
-rw-r--r--svx/source/customshapes/EnhancedCustomShape2d.cxx6
-rw-r--r--svx/source/customshapes/EnhancedCustomShape3d.cxx6
-rw-r--r--svx/source/customshapes/EnhancedCustomShapeEngine.cxx4
-rw-r--r--svx/source/customshapes/EnhancedCustomShapeFontWork.cxx2
-rw-r--r--svx/source/dialog/dlgctl3d.cxx48
-rw-r--r--svx/source/engine3d/float3d.cxx82
-rw-r--r--svx/source/engine3d/view3d1.cxx4
-rw-r--r--svx/source/sdr/primitive2d/sdrattributecreator.cxx60
-rw-r--r--svx/source/sdr/primitive3d/sdrattributecreator3d.cxx26
-rw-r--r--svx/source/svdraw/svdoashp.cxx32
-rw-r--r--svx/source/table/tablecontroller.cxx12
-rw-r--r--svx/source/toolbars/extrusionbar.cxx20
-rw-r--r--svx/source/toolbars/fontworkbar.cxx10
-rw-r--r--svx/source/unodraw/unoprov.cxx1
-rw-r--r--svx/source/unodraw/unoshap3.cxx4
-rw-r--r--sw/source/filter/ww8/ww8par.cxx2
-rw-r--r--sw/source/uibase/shells/drawsh.cxx2
30 files changed, 304 insertions, 285 deletions
diff --git a/chart2/source/controller/dialogs/tp_3D_SceneIllumination.cxx b/chart2/source/controller/dialogs/tp_3D_SceneIllumination.cxx
index b76f03807c22..0c63a6f003c2 100644
--- a/chart2/source/controller/dialogs/tp_3D_SceneIllumination.cxx
+++ b/chart2/source/controller/dialogs/tp_3D_SceneIllumination.cxx
@@ -331,44 +331,44 @@ IMPL_LINK_NOARG(ThreeD_SceneIllumination_TabPage, PreviewChangeHdl, SvxLightCtl3
const SfxItemSet a3DLightAttributes(m_pCtl_Preview->GetSvx3DLightControl().Get3DAttributes());
LightSourceInfo* pInfo = &m_pLightSourceInfoList[0];
- pInfo->aLightSource.nDiffuseColor = static_cast<const SvxColorItem&>(a3DLightAttributes.Get(SDRATTR_3DSCENE_LIGHTCOLOR_1)).GetValue().GetColor();
- pInfo->aLightSource.bIsEnabled = static_cast<const SfxBoolItem&>(a3DLightAttributes.Get(SDRATTR_3DSCENE_LIGHTON_1)).GetValue();
- pInfo->aLightSource.aDirection = B3DVectorToDirection3D(static_cast<const SvxB3DVectorItem&>(a3DLightAttributes.Get(SDRATTR_3DSCENE_LIGHTDIRECTION_1)).GetValue());
+ pInfo->aLightSource.nDiffuseColor = a3DLightAttributes.Get(SDRATTR_3DSCENE_LIGHTCOLOR_1).GetValue().GetColor();
+ pInfo->aLightSource.bIsEnabled = a3DLightAttributes.Get(SDRATTR_3DSCENE_LIGHTON_1).GetValue();
+ pInfo->aLightSource.aDirection = B3DVectorToDirection3D(a3DLightAttributes.Get(SDRATTR_3DSCENE_LIGHTDIRECTION_1).GetValue());
pInfo = &m_pLightSourceInfoList[1];
- pInfo->aLightSource.nDiffuseColor = static_cast<const SvxColorItem&>(a3DLightAttributes.Get(SDRATTR_3DSCENE_LIGHTCOLOR_2)).GetValue().GetColor();
- pInfo->aLightSource.bIsEnabled = static_cast<const SfxBoolItem&>(a3DLightAttributes.Get(SDRATTR_3DSCENE_LIGHTON_2)).GetValue();
- pInfo->aLightSource.aDirection = B3DVectorToDirection3D(static_cast<const SvxB3DVectorItem&>(a3DLightAttributes.Get(SDRATTR_3DSCENE_LIGHTDIRECTION_2)).GetValue());
+ pInfo->aLightSource.nDiffuseColor = a3DLightAttributes.Get(SDRATTR_3DSCENE_LIGHTCOLOR_2).GetValue().GetColor();
+ pInfo->aLightSource.bIsEnabled = a3DLightAttributes.Get(SDRATTR_3DSCENE_LIGHTON_2).GetValue();
+ pInfo->aLightSource.aDirection = B3DVectorToDirection3D(a3DLightAttributes.Get(SDRATTR_3DSCENE_LIGHTDIRECTION_2).GetValue());
pInfo = &m_pLightSourceInfoList[2];
- pInfo->aLightSource.nDiffuseColor = static_cast<const SvxColorItem&>(a3DLightAttributes.Get(SDRATTR_3DSCENE_LIGHTCOLOR_3)).GetValue().GetColor();
- pInfo->aLightSource.bIsEnabled = static_cast<const SfxBoolItem&>(a3DLightAttributes.Get(SDRATTR_3DSCENE_LIGHTON_3)).GetValue();
- pInfo->aLightSource.aDirection = B3DVectorToDirection3D(static_cast<const SvxB3DVectorItem&>(a3DLightAttributes.Get(SDRATTR_3DSCENE_LIGHTDIRECTION_3)).GetValue());
+ pInfo->aLightSource.nDiffuseColor = a3DLightAttributes.Get(SDRATTR_3DSCENE_LIGHTCOLOR_3).GetValue().GetColor();
+ pInfo->aLightSource.bIsEnabled = a3DLightAttributes.Get(SDRATTR_3DSCENE_LIGHTON_3).GetValue();
+ pInfo->aLightSource.aDirection = B3DVectorToDirection3D(a3DLightAttributes.Get(SDRATTR_3DSCENE_LIGHTDIRECTION_3).GetValue());
pInfo = &m_pLightSourceInfoList[3];
- pInfo->aLightSource.nDiffuseColor = static_cast<const SvxColorItem&>(a3DLightAttributes.Get(SDRATTR_3DSCENE_LIGHTCOLOR_4)).GetValue().GetColor();
- pInfo->aLightSource.bIsEnabled = static_cast<const SfxBoolItem&>(a3DLightAttributes.Get(SDRATTR_3DSCENE_LIGHTON_4)).GetValue();
- pInfo->aLightSource.aDirection = B3DVectorToDirection3D(static_cast<const SvxB3DVectorItem&>(a3DLightAttributes.Get(SDRATTR_3DSCENE_LIGHTDIRECTION_4)).GetValue());
+ pInfo->aLightSource.nDiffuseColor = a3DLightAttributes.Get(SDRATTR_3DSCENE_LIGHTCOLOR_4).GetValue().GetColor();
+ pInfo->aLightSource.bIsEnabled = a3DLightAttributes.Get(SDRATTR_3DSCENE_LIGHTON_4).GetValue();
+ pInfo->aLightSource.aDirection = B3DVectorToDirection3D(a3DLightAttributes.Get(SDRATTR_3DSCENE_LIGHTDIRECTION_4).GetValue());
pInfo = &m_pLightSourceInfoList[4];
- pInfo->aLightSource.nDiffuseColor = static_cast<const SvxColorItem&>(a3DLightAttributes.Get(SDRATTR_3DSCENE_LIGHTCOLOR_5)).GetValue().GetColor();
- pInfo->aLightSource.bIsEnabled = static_cast<const SfxBoolItem&>(a3DLightAttributes.Get(SDRATTR_3DSCENE_LIGHTON_5)).GetValue();
- pInfo->aLightSource.aDirection = B3DVectorToDirection3D(static_cast<const SvxB3DVectorItem&>(a3DLightAttributes.Get(SDRATTR_3DSCENE_LIGHTDIRECTION_5)).GetValue());
+ pInfo->aLightSource.nDiffuseColor = a3DLightAttributes.Get(SDRATTR_3DSCENE_LIGHTCOLOR_5).GetValue().GetColor();
+ pInfo->aLightSource.bIsEnabled = a3DLightAttributes.Get(SDRATTR_3DSCENE_LIGHTON_5).GetValue();
+ pInfo->aLightSource.aDirection = B3DVectorToDirection3D(a3DLightAttributes.Get(SDRATTR_3DSCENE_LIGHTDIRECTION_5).GetValue());
pInfo = &m_pLightSourceInfoList[5];
- pInfo->aLightSource.nDiffuseColor = static_cast<const SvxColorItem&>(a3DLightAttributes.Get(SDRATTR_3DSCENE_LIGHTCOLOR_6)).GetValue().GetColor();
- pInfo->aLightSource.bIsEnabled = static_cast<const SfxBoolItem&>(a3DLightAttributes.Get(SDRATTR_3DSCENE_LIGHTON_6)).GetValue();
- pInfo->aLightSource.aDirection = B3DVectorToDirection3D(static_cast<const SvxB3DVectorItem&>(a3DLightAttributes.Get(SDRATTR_3DSCENE_LIGHTDIRECTION_6)).GetValue());
+ pInfo->aLightSource.nDiffuseColor = a3DLightAttributes.Get(SDRATTR_3DSCENE_LIGHTCOLOR_6).GetValue().GetColor();
+ pInfo->aLightSource.bIsEnabled = a3DLightAttributes.Get(SDRATTR_3DSCENE_LIGHTON_6).GetValue();
+ pInfo->aLightSource.aDirection = B3DVectorToDirection3D(a3DLightAttributes.Get(SDRATTR_3DSCENE_LIGHTDIRECTION_6).GetValue());
pInfo = &m_pLightSourceInfoList[6];
- pInfo->aLightSource.nDiffuseColor = static_cast<const SvxColorItem&>(a3DLightAttributes.Get(SDRATTR_3DSCENE_LIGHTCOLOR_7)).GetValue().GetColor();
- pInfo->aLightSource.bIsEnabled = static_cast<const SfxBoolItem&>(a3DLightAttributes.Get(SDRATTR_3DSCENE_LIGHTON_7)).GetValue();
- pInfo->aLightSource.aDirection = B3DVectorToDirection3D(static_cast<const SvxB3DVectorItem&>(a3DLightAttributes.Get(SDRATTR_3DSCENE_LIGHTDIRECTION_7)).GetValue());
+ pInfo->aLightSource.nDiffuseColor = a3DLightAttributes.Get(SDRATTR_3DSCENE_LIGHTCOLOR_7).GetValue().GetColor();
+ pInfo->aLightSource.bIsEnabled = a3DLightAttributes.Get(SDRATTR_3DSCENE_LIGHTON_7).GetValue();
+ pInfo->aLightSource.aDirection = B3DVectorToDirection3D(a3DLightAttributes.Get(SDRATTR_3DSCENE_LIGHTDIRECTION_7).GetValue());
pInfo = &m_pLightSourceInfoList[7];
- pInfo->aLightSource.nDiffuseColor = static_cast<const SvxColorItem&>(a3DLightAttributes.Get(SDRATTR_3DSCENE_LIGHTCOLOR_8)).GetValue().GetColor();
- pInfo->aLightSource.bIsEnabled = static_cast<const SfxBoolItem&>(a3DLightAttributes.Get(SDRATTR_3DSCENE_LIGHTON_8)).GetValue();
- pInfo->aLightSource.aDirection = B3DVectorToDirection3D(static_cast<const SvxB3DVectorItem&>(a3DLightAttributes.Get(SDRATTR_3DSCENE_LIGHTDIRECTION_8)).GetValue());
+ pInfo->aLightSource.nDiffuseColor = a3DLightAttributes.Get(SDRATTR_3DSCENE_LIGHTCOLOR_8).GetValue().GetColor();
+ pInfo->aLightSource.bIsEnabled = a3DLightAttributes.Get(SDRATTR_3DSCENE_LIGHTON_8).GetValue();
+ pInfo->aLightSource.aDirection = B3DVectorToDirection3D(a3DLightAttributes.Get(SDRATTR_3DSCENE_LIGHTDIRECTION_8).GetValue());
applyLightSourcesToModel();
}
diff --git a/cui/source/tabpages/transfrm.cxx b/cui/source/tabpages/transfrm.cxx
index 1f87636e7691..d9a3ff38ac85 100644
--- a/cui/source/tabpages/transfrm.cxx
+++ b/cui/source/tabpages/transfrm.cxx
@@ -625,7 +625,7 @@ void SvxSlantTabPage::Reset(const SfxItemSet* rAttrs)
{
//save geometry
SdrCustomShapeGeometryItem aInitialGeometry =
- static_cast<const SdrCustomShapeGeometryItem&>(pObj->GetMergedItem(SDRATTR_CUSTOMSHAPE_GEOMETRY));
+ pObj->GetMergedItem(SDRATTR_CUSTOMSHAPE_GEOMETRY);
EnhancedCustomShape2d aShape(pObj);
diff --git a/filter/source/msfilter/escherex.cxx b/filter/source/msfilter/escherex.cxx
index 5a27ec408d79..b06a325ded6b 100644
--- a/filter/source/msfilter/escherex.cxx
+++ b/filter/source/msfilter/escherex.cxx
@@ -2428,8 +2428,8 @@ void ConvertEnhancedCustomShapeEquation( SdrObjCustomShape* pCustoShape,
if ( pCustoShape )
{
uno::Sequence< OUString > sEquationSource;
- const SdrCustomShapeGeometryItem& rGeometryItem = static_cast<const SdrCustomShapeGeometryItem&>(
- pCustoShape->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ));
+ const SdrCustomShapeGeometryItem& rGeometryItem =
+ pCustoShape->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY );
const uno::Any* pAny = rGeometryItem.GetPropertyValueByName( "Equations" );
if ( pAny )
*pAny >>= sEquationSource;
@@ -4568,8 +4568,8 @@ sal_uInt32 EscherConnectorListEntry::GetConnectorRule( bool bFirst )
SdrObject* pCustoShape( GetSdrObjectFromXShape( aXShape ) );
if ( dynamic_cast<const SdrObjCustomShape* >(pCustoShape) != nullptr )
{
- const SdrCustomShapeGeometryItem& rGeometryItem = static_cast<const SdrCustomShapeGeometryItem&>(
- pCustoShape->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ));
+ const SdrCustomShapeGeometryItem& rGeometryItem =
+ pCustoShape->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY );
const OUString sPath( "Path" );
const OUString sType( "Type" );
diff --git a/filter/source/msfilter/msdffimp.cxx b/filter/source/msfilter/msdffimp.cxx
index 25be4f0f04f6..4b7f8e36b81d 100644
--- a/filter/source/msfilter/msdffimp.cxx
+++ b/filter/source/msfilter/msdffimp.cxx
@@ -2763,7 +2763,7 @@ void DffPropertyReader::CheckAndCorrectExcelTextRotation( SvStream& rIn, SfxItem
if ( !bRotateTextWithShape )
{
const css::uno::Any* pAny;
- SdrCustomShapeGeometryItem aGeometryItem(static_cast<const SdrCustomShapeGeometryItem&>(rSet.Get( SDRATTR_CUSTOMSHAPE_GEOMETRY )));
+ SdrCustomShapeGeometryItem aGeometryItem(rSet.Get( SDRATTR_CUSTOMSHAPE_GEOMETRY ));
const OUString sTextRotateAngle( "TextRotateAngle" );
pAny = aGeometryItem.GetPropertyValueByName( sTextRotateAngle );
double fExtraTextRotateAngle = 0.0;
@@ -4499,7 +4499,7 @@ SdrObject* SvxMSDffManager::ImportShape( const DffRecordHeader& rHd, SvStream& r
const OUString sViewBox( "ViewBox" );
const OUString sPath( "Path" );
const OUString sTextFrames( "TextFrames" );
- SdrCustomShapeGeometryItem aGeometryItem( static_cast<const SdrCustomShapeGeometryItem&>(static_cast<SdrObjCustomShape*>(pRet)->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ) ) );
+ SdrCustomShapeGeometryItem aGeometryItem( static_cast<SdrObjCustomShape*>(pRet)->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ) );
css::uno::Sequence< css::drawing::EnhancedCustomShapeParameterPair> seqCoordinates;
css::uno::Sequence< css::drawing::EnhancedCustomShapeAdjustmentValue > seqAdjustmentValues;
@@ -4673,7 +4673,7 @@ SdrObject* SvxMSDffManager::ImportShape( const DffRecordHeader& rHd, SvStream& r
static_cast<SdrObjCustomShape*>(pRet)->MergeDefaultAttributes();
// now setting a new name, so the above correction is only done once when importing from ms
- SdrCustomShapeGeometryItem aGeoName( static_cast<const SdrCustomShapeGeometryItem&>(static_cast<SdrObjCustomShape*>(pRet)->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ) ) );
+ SdrCustomShapeGeometryItem aGeoName( static_cast<SdrObjCustomShape*>(pRet)->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ) );
const OUString sType( "Type" );
const OUString sName( "mso-spt100" );
PropertyValue aPropVal;
diff --git a/include/svx/extrud3d.hxx b/include/svx/extrud3d.hxx
index 5ce35f7080d0..7001ee86cfd5 100644
--- a/include/svx/extrud3d.hxx
+++ b/include/svx/extrud3d.hxx
@@ -49,35 +49,35 @@ public:
// PercentDiagonal: 0..100, before 0.0..0.5
sal_uInt16 GetPercentDiagonal() const
- { return static_cast<const SfxUInt16Item&>(GetObjectItemSet().Get(SDRATTR_3DOBJ_PERCENT_DIAGONAL)).GetValue(); }
+ { return GetObjectItemSet().Get(SDRATTR_3DOBJ_PERCENT_DIAGONAL).GetValue(); }
// BackScale: 0..100, before 0.0..1.0
sal_uInt16 GetPercentBackScale() const
- { return static_cast<const SfxUInt16Item&>(GetObjectItemSet().Get(SDRATTR_3DOBJ_BACKSCALE)).GetValue(); }
+ { return GetObjectItemSet().Get(SDRATTR_3DOBJ_BACKSCALE).GetValue(); }
// BackScale: 0..100, before 0.0..1.0
sal_uInt32 GetExtrudeDepth() const
- { return static_cast<const SfxUInt32Item&>(GetObjectItemSet().Get(SDRATTR_3DOBJ_DEPTH)).GetValue(); }
+ { return GetObjectItemSet().Get(SDRATTR_3DOBJ_DEPTH).GetValue(); }
// #107245# GetSmoothNormals() for bExtrudeSmoothed
bool GetSmoothNormals() const
- { return static_cast<const Svx3DSmoothNormalsItem&>(GetObjectItemSet().Get(SDRATTR_3DOBJ_SMOOTH_NORMALS)).GetValue(); }
+ { return GetObjectItemSet().Get(SDRATTR_3DOBJ_SMOOTH_NORMALS).GetValue(); }
// #107245# GetSmoothLids() for bExtrudeSmoothFrontBack
bool GetSmoothLids() const
- { return static_cast<const Svx3DSmoothLidsItem&>(GetObjectItemSet().Get(SDRATTR_3DOBJ_SMOOTH_LIDS)).GetValue(); }
+ { return GetObjectItemSet().Get(SDRATTR_3DOBJ_SMOOTH_LIDS).GetValue(); }
// #107245# GetCharacterMode() for bExtrudeCharacterMode
bool GetCharacterMode() const
- { return static_cast<const Svx3DCharacterModeItem&>(GetObjectItemSet().Get(SDRATTR_3DOBJ_CHARACTER_MODE)).GetValue(); }
+ { return GetObjectItemSet().Get(SDRATTR_3DOBJ_CHARACTER_MODE).GetValue(); }
// #107245# GetCloseFront() for bExtrudeCloseFront
bool GetCloseFront() const
- { return static_cast<const Svx3DCloseFrontItem&>(GetObjectItemSet().Get(SDRATTR_3DOBJ_CLOSE_FRONT)).GetValue(); }
+ { return GetObjectItemSet().Get(SDRATTR_3DOBJ_CLOSE_FRONT).GetValue(); }
// #107245# GetCloseBack() for bExtrudeCloseBack
bool GetCloseBack() const
- { return static_cast<const Svx3DCloseBackItem&>(GetObjectItemSet().Get(SDRATTR_3DOBJ_CLOSE_BACK)).GetValue(); }
+ { return GetObjectItemSet().Get(SDRATTR_3DOBJ_CLOSE_BACK).GetValue(); }
virtual sal_uInt16 GetObjIdentifier() const override;
diff --git a/include/svx/lathe3d.hxx b/include/svx/lathe3d.hxx
index 5a7608999181..acc1e4186ce2 100644
--- a/include/svx/lathe3d.hxx
+++ b/include/svx/lathe3d.hxx
@@ -47,43 +47,43 @@ public:
// HorizontalSegments:
sal_uInt32 GetHorizontalSegments() const
- { return static_cast<const SfxUInt32Item&>(GetObjectItemSet().Get(SDRATTR_3DOBJ_HORZ_SEGS)).GetValue(); }
+ { return GetObjectItemSet().Get(SDRATTR_3DOBJ_HORZ_SEGS).GetValue(); }
// VerticalSegments:
sal_uInt32 GetVerticalSegments() const
- { return static_cast<const SfxUInt32Item&>(GetObjectItemSet().Get(SDRATTR_3DOBJ_VERT_SEGS)).GetValue(); }
+ { return GetObjectItemSet().Get(SDRATTR_3DOBJ_VERT_SEGS).GetValue(); }
// PercentDiagonal: 0..100, before 0.0..0.5
sal_uInt16 GetPercentDiagonal() const
- { return static_cast<const SfxUInt16Item&>(GetObjectItemSet().Get(SDRATTR_3DOBJ_PERCENT_DIAGONAL)).GetValue(); }
+ { return GetObjectItemSet().Get(SDRATTR_3DOBJ_PERCENT_DIAGONAL).GetValue(); }
// BackScale: 0..100, before 0.0..1.0
sal_uInt16 GetBackScale() const
- { return static_cast<const SfxUInt16Item&>(GetObjectItemSet().Get(SDRATTR_3DOBJ_BACKSCALE)).GetValue(); }
+ { return GetObjectItemSet().Get(SDRATTR_3DOBJ_BACKSCALE).GetValue(); }
// EndAngle: 0..10000
sal_uInt32 GetEndAngle() const
- { return static_cast<const SfxUInt32Item&>(GetObjectItemSet().Get(SDRATTR_3DOBJ_END_ANGLE)).GetValue(); }
+ { return GetObjectItemSet().Get(SDRATTR_3DOBJ_END_ANGLE).GetValue(); }
// #107245# GetSmoothNormals() for bLatheSmoothed
bool GetSmoothNormals() const
- { return static_cast<const Svx3DSmoothNormalsItem&>(GetObjectItemSet().Get(SDRATTR_3DOBJ_SMOOTH_NORMALS)).GetValue(); }
+ { return GetObjectItemSet().Get(SDRATTR_3DOBJ_SMOOTH_NORMALS).GetValue(); }
// #107245# GetSmoothLids() for bLatheSmoothFrontBack
bool GetSmoothLids() const
- { return static_cast<const Svx3DSmoothLidsItem&>(GetObjectItemSet().Get(SDRATTR_3DOBJ_SMOOTH_LIDS)).GetValue(); }
+ { return GetObjectItemSet().Get(SDRATTR_3DOBJ_SMOOTH_LIDS).GetValue(); }
// #107245# GetCharacterMode() for bLatheCharacterMode
bool GetCharacterMode() const
- { return static_cast<const Svx3DCharacterModeItem&>(GetObjectItemSet().Get(SDRATTR_3DOBJ_CHARACTER_MODE)).GetValue(); }
+ { return GetObjectItemSet().Get(SDRATTR_3DOBJ_CHARACTER_MODE).GetValue(); }
// #107245# GetCloseFront() for bLatheCloseFront
bool GetCloseFront() const
- { return static_cast<const Svx3DCloseFrontItem&>(GetObjectItemSet().Get(SDRATTR_3DOBJ_CLOSE_FRONT)).GetValue(); }
+ { return GetObjectItemSet().Get(SDRATTR_3DOBJ_CLOSE_FRONT).GetValue(); }
// #107245# GetCloseBack() for bLatheCloseBack
bool GetCloseBack() const
- { return static_cast<const Svx3DCloseBackItem&>(GetObjectItemSet().Get(SDRATTR_3DOBJ_CLOSE_BACK)).GetValue(); }
+ { return GetObjectItemSet().Get(SDRATTR_3DOBJ_CLOSE_BACK).GetValue(); }
virtual sal_uInt16 GetObjIdentifier() const override;
diff --git a/include/svx/scene3d.hxx b/include/svx/scene3d.hxx
index 83ecca16b1f5..81703f1d001f 100644
--- a/include/svx/scene3d.hxx
+++ b/include/svx/scene3d.hxx
@@ -102,15 +102,15 @@ public:
// Perspective: enum ProjectionType { ProjectionType::Parallel, ProjectionType::Perspective }
ProjectionType GetPerspective() const
- { return (ProjectionType) static_cast<const Svx3DPerspectiveItem&>(GetObjectItemSet().Get(SDRATTR_3DSCENE_PERSPECTIVE)).GetValue(); }
+ { return (ProjectionType) GetObjectItemSet().Get(SDRATTR_3DSCENE_PERSPECTIVE).GetValue(); }
// Distance:
double GetDistance() const
- { return (double)static_cast<const SfxUInt32Item&>(GetObjectItemSet().Get(SDRATTR_3DSCENE_DISTANCE)).GetValue(); }
+ { return (double)GetObjectItemSet().Get(SDRATTR_3DSCENE_DISTANCE).GetValue(); }
// Focal length: before cm, now 1/10th mm (*100)
double GetFocalLength() const
- { return static_cast<const SfxUInt32Item&>(GetObjectItemSet().Get(SDRATTR_3DSCENE_FOCAL_LENGTH)).GetValue(); }
+ { return GetObjectItemSet().Get(SDRATTR_3DSCENE_FOCAL_LENGTH).GetValue(); }
// set flag to draw only selected
void SetDrawOnlySelected(bool bNew) { bDrawOnlySelected = bNew; }
diff --git a/include/svx/sphere3d.hxx b/include/svx/sphere3d.hxx
index b6742c0e6ecb..9c4bc5d21468 100644
--- a/include/svx/sphere3d.hxx
+++ b/include/svx/sphere3d.hxx
@@ -48,11 +48,11 @@ public:
// horizontal segments:
sal_uInt32 GetHorizontalSegments() const
- { return static_cast<const SfxUInt32Item&>(GetObjectItemSet().Get(SDRATTR_3DOBJ_HORZ_SEGS)).GetValue(); }
+ { return GetObjectItemSet().Get(SDRATTR_3DOBJ_HORZ_SEGS).GetValue(); }
// VerticalSegments:
sal_uInt32 GetVerticalSegments() const
- { return static_cast<const SfxUInt32Item&>(GetObjectItemSet().Get(SDRATTR_3DOBJ_VERT_SEGS)).GetValue(); }
+ { return GetObjectItemSet().Get(SDRATTR_3DOBJ_VERT_SEGS).GetValue(); }
virtual sal_uInt16 GetObjIdentifier() const override;
virtual SdrObject* DoConvertToPolyObj(bool bBezier, bool bAddText) const override;
diff --git a/include/svx/svddef.hxx b/include/svx/svddef.hxx
index e86ce4483d3b..9ed6ba2bff7c 100644
--- a/include/svx/svddef.hxx
+++ b/include/svx/svddef.hxx
@@ -76,6 +76,7 @@ class SdrCaptionFitLineLenItem;
class SdrCaptionLineLenItem;
class SdrCaptionTypeItem;
class SdrCircKindItem;
+class SdrCustomShapeGeometryItem;
class SdrEdgeKindItem;
class SdrEdgeLineDeltaCountItem;
class SdrEdgeNode1GlueDistItem;
@@ -138,8 +139,25 @@ class SdrTransformRef2XItem;
class SdrTransformRef2YItem;
class SdrVertShearAllItem;
class SdrVertShearOneItem;
+class SfxBoolItem;
class SfxStringItem;
class SfxVoidItem;
+class Svx3DCharacterModeItem;
+class Svx3DCloseBackItem;
+class Svx3DCloseFrontItem;
+class Svx3DNormalsKindItem;
+class Svx3DPerspectiveItem;
+class Svx3DReducedLineGeometryItem;
+class Svx3DShadeModeItem;
+class Svx3DSmoothLidsItem;
+class Svx3DSmoothNormalsItem;
+class Svx3DTextureProjectionXItem;
+class Svx3DTextureProjectionYItem;
+class SvxB3DVectorItem;
+class SvxBoxInfoItem;
+class SvxBoxItem;
+class SvxColorItem;
+class SvxLineItem;
class SvxWritingModeItem;
class XColorItem;
@@ -298,86 +316,86 @@ class XColorItem;
#define SDRATTR_3D_FIRST (SDRATTR_GRAF_LAST + 1) /* 1244 V4+++*/
#define SDRATTR_3DOBJ_FIRST (SDRATTR_3D_FIRST) /* 1244 V4+++*/
-#define SDRATTR_3DOBJ_PERCENT_DIAGONAL (SDRATTR_3DOBJ_FIRST + 0) /* 1244 V4+++*/
-#define SDRATTR_3DOBJ_BACKSCALE (SDRATTR_3DOBJ_FIRST + 1) /* 1245 V4+++*/
-#define SDRATTR_3DOBJ_DEPTH (SDRATTR_3DOBJ_FIRST + 2) /* 1246 V4+++*/
-#define SDRATTR_3DOBJ_HORZ_SEGS (SDRATTR_3DOBJ_FIRST + 3) /* 1247 V4+++*/
-#define SDRATTR_3DOBJ_VERT_SEGS (SDRATTR_3DOBJ_FIRST + 4) /* 1248 V4+++*/
-#define SDRATTR_3DOBJ_END_ANGLE (SDRATTR_3DOBJ_FIRST + 5) /* 1249 V4+++*/
-#define SDRATTR_3DOBJ_DOUBLE_SIDED (SDRATTR_3DOBJ_FIRST + 6) /* 1250 V4+++*/
-#define SDRATTR_3DOBJ_NORMALS_KIND (SDRATTR_3DOBJ_FIRST + 7) /* 1251 V4+++*/
-#define SDRATTR_3DOBJ_NORMALS_INVERT (SDRATTR_3DOBJ_FIRST + 8) /* 1252 V4+++*/
-#define SDRATTR_3DOBJ_TEXTURE_PROJ_X (SDRATTR_3DOBJ_FIRST + 9) /* 1253 V4+++*/
-#define SDRATTR_3DOBJ_TEXTURE_PROJ_Y (SDRATTR_3DOBJ_FIRST + 10) /* 1254 V4+++*/
-#define SDRATTR_3DOBJ_SHADOW_3D (SDRATTR_3DOBJ_FIRST + 11) /* 1255 V4+++*/
-#define SDRATTR_3DOBJ_MAT_COLOR (SDRATTR_3DOBJ_FIRST + 12) /* 1256 V4+++*/
-#define SDRATTR_3DOBJ_MAT_EMISSION (SDRATTR_3DOBJ_FIRST + 13) /* 1257 V4+++*/
-#define SDRATTR_3DOBJ_MAT_SPECULAR (SDRATTR_3DOBJ_FIRST + 14) /* 1258 V4+++*/
-#define SDRATTR_3DOBJ_MAT_SPECULAR_INTENSITY (SDRATTR_3DOBJ_FIRST + 15) /* 1259 V4+++*/
-#define SDRATTR_3DOBJ_TEXTURE_KIND (SDRATTR_3DOBJ_FIRST + 16) /* 1260 V4+++*/
-#define SDRATTR_3DOBJ_TEXTURE_MODE (SDRATTR_3DOBJ_FIRST + 17) /* 1261 V4+++*/
-#define SDRATTR_3DOBJ_TEXTURE_FILTER (SDRATTR_3DOBJ_FIRST + 18) /* 1262 V4+++*/
+#define SDRATTR_3DOBJ_PERCENT_DIAGONAL TypedWhichId<SfxUInt16Item>(SDRATTR_3DOBJ_FIRST + 0) /* 1244 V4+++*/
+#define SDRATTR_3DOBJ_BACKSCALE TypedWhichId<SfxUInt16Item>(SDRATTR_3DOBJ_FIRST + 1) /* 1245 V4+++*/
+#define SDRATTR_3DOBJ_DEPTH TypedWhichId<SfxUInt32Item>(SDRATTR_3DOBJ_FIRST + 2) /* 1246 V4+++*/
+#define SDRATTR_3DOBJ_HORZ_SEGS TypedWhichId<SfxUInt32Item>(SDRATTR_3DOBJ_FIRST + 3) /* 1247 V4+++*/
+#define SDRATTR_3DOBJ_VERT_SEGS TypedWhichId<SfxUInt32Item>(SDRATTR_3DOBJ_FIRST + 4) /* 1248 V4+++*/
+#define SDRATTR_3DOBJ_END_ANGLE TypedWhichId<SfxUInt32Item>(SDRATTR_3DOBJ_FIRST + 5) /* 1249 V4+++*/
+#define SDRATTR_3DOBJ_DOUBLE_SIDED TypedWhichId<SfxBoolItem>(SDRATTR_3DOBJ_FIRST + 6) /* 1250 V4+++*/
+#define SDRATTR_3DOBJ_NORMALS_KIND TypedWhichId<Svx3DNormalsKindItem>(SDRATTR_3DOBJ_FIRST + 7) /* 1251 V4+++*/
+#define SDRATTR_3DOBJ_NORMALS_INVERT TypedWhichId<SfxBoolItem>(SDRATTR_3DOBJ_FIRST + 8) /* 1252 V4+++*/
+#define SDRATTR_3DOBJ_TEXTURE_PROJ_X TypedWhichId<Svx3DTextureProjectionXItem>(SDRATTR_3DOBJ_FIRST + 9) /* 1253 V4+++*/
+#define SDRATTR_3DOBJ_TEXTURE_PROJ_Y TypedWhichId<Svx3DTextureProjectionYItem>(SDRATTR_3DOBJ_FIRST + 10) /* 1254 V4+++*/
+#define SDRATTR_3DOBJ_SHADOW_3D TypedWhichId<SfxBoolItem>(SDRATTR_3DOBJ_FIRST + 11) /* 1255 V4+++*/
+#define SDRATTR_3DOBJ_MAT_COLOR TypedWhichId<SvxColorItem>(SDRATTR_3DOBJ_FIRST + 12) /* 1256 V4+++*/
+#define SDRATTR_3DOBJ_MAT_EMISSION TypedWhichId<SvxColorItem>(SDRATTR_3DOBJ_FIRST + 13) /* 1257 V4+++*/
+#define SDRATTR_3DOBJ_MAT_SPECULAR TypedWhichId<SvxColorItem>(SDRATTR_3DOBJ_FIRST + 14) /* 1258 V4+++*/
+#define SDRATTR_3DOBJ_MAT_SPECULAR_INTENSITY TypedWhichId<SfxUInt16Item>(SDRATTR_3DOBJ_FIRST + 15) /* 1259 V4+++*/
+#define SDRATTR_3DOBJ_TEXTURE_KIND TypedWhichId<Svx3DTextureKindItem>(SDRATTR_3DOBJ_FIRST + 16) /* 1260 V4+++*/
+#define SDRATTR_3DOBJ_TEXTURE_MODE TypedWhichId<Svx3DTextureModeItem>(SDRATTR_3DOBJ_FIRST + 17) /* 1261 V4+++*/
+#define SDRATTR_3DOBJ_TEXTURE_FILTER TypedWhichId<SfxBoolItem>(SDRATTR_3DOBJ_FIRST + 18) /* 1262 V4+++*/
// #107245# New items for 3d objects use former range SDRATTR_3DOBJ_RESERVED_01
// up to SDRATTR_3DOBJ_RESERVED_05
-#define SDRATTR_3DOBJ_SMOOTH_NORMALS (SDRATTR_3DOBJ_FIRST + 19) /* 1263 V4+++*/
-#define SDRATTR_3DOBJ_SMOOTH_LIDS (SDRATTR_3DOBJ_FIRST + 20) /* 1264 V4+++*/
-#define SDRATTR_3DOBJ_CHARACTER_MODE (SDRATTR_3DOBJ_FIRST + 21) /* 1265 V4+++*/
-#define SDRATTR_3DOBJ_CLOSE_FRONT (SDRATTR_3DOBJ_FIRST + 22) /* 1266 V4+++*/
-#define SDRATTR_3DOBJ_CLOSE_BACK (SDRATTR_3DOBJ_FIRST + 23) /* 1267 V4+++*/
+#define SDRATTR_3DOBJ_SMOOTH_NORMALS TypedWhichId<Svx3DSmoothNormalsItem>(SDRATTR_3DOBJ_FIRST + 19) /* 1263 V4+++*/
+#define SDRATTR_3DOBJ_SMOOTH_LIDS TypedWhichId<Svx3DSmoothLidsItem>(SDRATTR_3DOBJ_FIRST + 20) /* 1264 V4+++*/
+#define SDRATTR_3DOBJ_CHARACTER_MODE TypedWhichId<Svx3DCharacterModeItem>(SDRATTR_3DOBJ_FIRST + 21) /* 1265 V4+++*/
+#define SDRATTR_3DOBJ_CLOSE_FRONT TypedWhichId<Svx3DCloseFrontItem>(SDRATTR_3DOBJ_FIRST + 22) /* 1266 V4+++*/
+#define SDRATTR_3DOBJ_CLOSE_BACK TypedWhichId<Svx3DCloseBackItem>(SDRATTR_3DOBJ_FIRST + 23) /* 1267 V4+++*/
// #i28528#
// Added extra Item (Bool) for chart2 to be able to show reduced line geometry
-#define SDRATTR_3DOBJ_REDUCED_LINE_GEOMETRY (SDRATTR_3DOBJ_FIRST + 24) /* 1268 V4+++*/
+#define SDRATTR_3DOBJ_REDUCED_LINE_GEOMETRY TypedWhichId<Svx3DReducedLineGeometryItem>(SDRATTR_3DOBJ_FIRST + 24) /* 1268 V4+++*/
#define SDRATTR_3DOBJ_LAST (SDRATTR_3DOBJ_REDUCED_LINE_GEOMETRY) /* 1282 V4+++*/
#define SDRATTR_3DSCENE_FIRST (SDRATTR_3DOBJ_LAST + 1) /* 1283 V4+++*/
-#define SDRATTR_3DSCENE_PERSPECTIVE (SDRATTR_3DSCENE_FIRST + 0) /* 1283 V4+++*/
-#define SDRATTR_3DSCENE_DISTANCE (SDRATTR_3DSCENE_FIRST + 1) /* 1284 V4+++*/
-#define SDRATTR_3DSCENE_FOCAL_LENGTH (SDRATTR_3DSCENE_FIRST + 2) /* 1285 V4+++*/
-#define SDRATTR_3DSCENE_TWO_SIDED_LIGHTING (SDRATTR_3DSCENE_FIRST + 3) /* 1286 V4+++*/
-#define SDRATTR_3DSCENE_LIGHTCOLOR_1 (SDRATTR_3DSCENE_FIRST + 4) /* 1287 V4+++*/
-#define SDRATTR_3DSCENE_LIGHTCOLOR_2 (SDRATTR_3DSCENE_FIRST + 5) /* 1288 V4+++*/
-#define SDRATTR_3DSCENE_LIGHTCOLOR_3 (SDRATTR_3DSCENE_FIRST + 6) /* 1289 V4+++*/
-#define SDRATTR_3DSCENE_LIGHTCOLOR_4 (SDRATTR_3DSCENE_FIRST + 7) /* 1290 V4+++*/
-#define SDRATTR_3DSCENE_LIGHTCOLOR_5 (SDRATTR_3DSCENE_FIRST + 8) /* 1291 V4+++*/
-#define SDRATTR_3DSCENE_LIGHTCOLOR_6 (SDRATTR_3DSCENE_FIRST + 9) /* 1292 V4+++*/
-#define SDRATTR_3DSCENE_LIGHTCOLOR_7 (SDRATTR_3DSCENE_FIRST + 10) /* 1293 V4+++*/
-#define SDRATTR_3DSCENE_LIGHTCOLOR_8 (SDRATTR_3DSCENE_FIRST + 11) /* 1294 V4+++*/
-#define SDRATTR_3DSCENE_AMBIENTCOLOR (SDRATTR_3DSCENE_FIRST + 12) /* 1295 V4+++*/
-#define SDRATTR_3DSCENE_LIGHTON_1 (SDRATTR_3DSCENE_FIRST + 13) /* 1296 V4+++*/
-#define SDRATTR_3DSCENE_LIGHTON_2 (SDRATTR_3DSCENE_FIRST + 14) /* 1297 V4+++*/
-#define SDRATTR_3DSCENE_LIGHTON_3 (SDRATTR_3DSCENE_FIRST + 15) /* 1298 V4+++*/
-#define SDRATTR_3DSCENE_LIGHTON_4 (SDRATTR_3DSCENE_FIRST + 16) /* 1299 V4+++*/
-#define SDRATTR_3DSCENE_LIGHTON_5 (SDRATTR_3DSCENE_FIRST + 17) /* 1300 V4+++*/
-#define SDRATTR_3DSCENE_LIGHTON_6 (SDRATTR_3DSCENE_FIRST + 18) /* 1301 V4+++*/
-#define SDRATTR_3DSCENE_LIGHTON_7 (SDRATTR_3DSCENE_FIRST + 19) /* 1302 V4+++*/
-#define SDRATTR_3DSCENE_LIGHTON_8 (SDRATTR_3DSCENE_FIRST + 20) /* 1303 V4+++*/
-#define SDRATTR_3DSCENE_LIGHTDIRECTION_1 (SDRATTR_3DSCENE_FIRST + 21) /* 1304 V4+++*/
-#define SDRATTR_3DSCENE_LIGHTDIRECTION_2 (SDRATTR_3DSCENE_FIRST + 22) /* 1305 V4+++*/
-#define SDRATTR_3DSCENE_LIGHTDIRECTION_3 (SDRATTR_3DSCENE_FIRST + 23) /* 1306 V4+++*/
-#define SDRATTR_3DSCENE_LIGHTDIRECTION_4 (SDRATTR_3DSCENE_FIRST + 24) /* 1307 V4+++*/
-#define SDRATTR_3DSCENE_LIGHTDIRECTION_5 (SDRATTR_3DSCENE_FIRST + 25) /* 1308 V4+++*/
-#define SDRATTR_3DSCENE_LIGHTDIRECTION_6 (SDRATTR_3DSCENE_FIRST + 26) /* 1309 V4+++*/
-#define SDRATTR_3DSCENE_LIGHTDIRECTION_7 (SDRATTR_3DSCENE_FIRST + 27) /* 1310 V4+++*/
-#define SDRATTR_3DSCENE_LIGHTDIRECTION_8 (SDRATTR_3DSCENE_FIRST + 28) /* 1311 V4+++*/
-#define SDRATTR_3DSCENE_SHADOW_SLANT (SDRATTR_3DSCENE_FIRST + 29) /* 1312 V4+++*/
-#define SDRATTR_3DSCENE_SHADE_MODE (SDRATTR_3DSCENE_FIRST + 30) /* 1313 V4+++*/
+#define SDRATTR_3DSCENE_PERSPECTIVE TypedWhichId<Svx3DPerspectiveItem>(SDRATTR_3DSCENE_FIRST + 0) /* 1283 V4+++*/
+#define SDRATTR_3DSCENE_DISTANCE TypedWhichId<SfxUInt32Item>(SDRATTR_3DSCENE_FIRST + 1) /* 1284 V4+++*/
+#define SDRATTR_3DSCENE_FOCAL_LENGTH TypedWhichId<SfxUInt32Item>(SDRATTR_3DSCENE_FIRST + 2) /* 1285 V4+++*/
+#define SDRATTR_3DSCENE_TWO_SIDED_LIGHTING TypedWhichId<SfxBoolItem>(SDRATTR_3DSCENE_FIRST + 3) /* 1286 V4+++*/
+#define SDRATTR_3DSCENE_LIGHTCOLOR_1 TypedWhichId<SvxColorItem>(SDRATTR_3DSCENE_FIRST + 4) /* 1287 V4+++*/
+#define SDRATTR_3DSCENE_LIGHTCOLOR_2 TypedWhichId<SvxColorItem>(SDRATTR_3DSCENE_FIRST + 5) /* 1288 V4+++*/
+#define SDRATTR_3DSCENE_LIGHTCOLOR_3 TypedWhichId<SvxColorItem>(SDRATTR_3DSCENE_FIRST + 6) /* 1289 V4+++*/
+#define SDRATTR_3DSCENE_LIGHTCOLOR_4 TypedWhichId<SvxColorItem>(SDRATTR_3DSCENE_FIRST + 7) /* 1290 V4+++*/
+#define SDRATTR_3DSCENE_LIGHTCOLOR_5 TypedWhichId<SvxColorItem>(SDRATTR_3DSCENE_FIRST + 8) /* 1291 V4+++*/
+#define SDRATTR_3DSCENE_LIGHTCOLOR_6 TypedWhichId<SvxColorItem>(SDRATTR_3DSCENE_FIRST + 9) /* 1292 V4+++*/
+#define SDRATTR_3DSCENE_LIGHTCOLOR_7 TypedWhichId<SvxColorItem>(SDRATTR_3DSCENE_FIRST + 10) /* 1293 V4+++*/
+#define SDRATTR_3DSCENE_LIGHTCOLOR_8 TypedWhichId<SvxColorItem>(SDRATTR_3DSCENE_FIRST + 11) /* 1294 V4+++*/
+#define SDRATTR_3DSCENE_AMBIENTCOLOR TypedWhichId<SvxColorItem>(SDRATTR_3DSCENE_FIRST + 12) /* 1295 V4+++*/
+#define SDRATTR_3DSCENE_LIGHTON_1 TypedWhichId<SfxBoolItem>(SDRATTR_3DSCENE_FIRST + 13) /* 1296 V4+++*/
+#define SDRATTR_3DSCENE_LIGHTON_2 TypedWhichId<SfxBoolItem>(SDRATTR_3DSCENE_FIRST + 14) /* 1297 V4+++*/
+#define SDRATTR_3DSCENE_LIGHTON_3 TypedWhichId<SfxBoolItem>(SDRATTR_3DSCENE_FIRST + 15) /* 1298 V4+++*/
+#define SDRATTR_3DSCENE_LIGHTON_4 TypedWhichId<SfxBoolItem>(SDRATTR_3DSCENE_FIRST + 16) /* 1299 V4+++*/
+#define SDRATTR_3DSCENE_LIGHTON_5 TypedWhichId<SfxBoolItem>(SDRATTR_3DSCENE_FIRST + 17) /* 1300 V4+++*/
+#define SDRATTR_3DSCENE_LIGHTON_6 TypedWhichId<SfxBoolItem>(SDRATTR_3DSCENE_FIRST + 18) /* 1301 V4+++*/
+#define SDRATTR_3DSCENE_LIGHTON_7 TypedWhichId<SfxBoolItem>(SDRATTR_3DSCENE_FIRST + 19) /* 1302 V4+++*/
+#define SDRATTR_3DSCENE_LIGHTON_8 TypedWhichId<SfxBoolItem>(SDRATTR_3DSCENE_FIRST + 20) /* 1303 V4+++*/
+#define SDRATTR_3DSCENE_LIGHTDIRECTION_1 TypedWhichId<SvxB3DVectorItem>(SDRATTR_3DSCENE_FIRST + 21) /* 1304 V4+++*/
+#define SDRATTR_3DSCENE_LIGHTDIRECTION_2 TypedWhichId<SvxB3DVectorItem>(SDRATTR_3DSCENE_FIRST + 22) /* 1305 V4+++*/
+#define SDRATTR_3DSCENE_LIGHTDIRECTION_3 TypedWhichId<SvxB3DVectorItem>(SDRATTR_3DSCENE_FIRST + 23) /* 1306 V4+++*/
+#define SDRATTR_3DSCENE_LIGHTDIRECTION_4 TypedWhichId<SvxB3DVectorItem>(SDRATTR_3DSCENE_FIRST + 24) /* 1307 V4+++*/
+#define SDRATTR_3DSCENE_LIGHTDIRECTION_5 TypedWhichId<SvxB3DVectorItem>(SDRATTR_3DSCENE_FIRST + 25) /* 1308 V4+++*/
+#define SDRATTR_3DSCENE_LIGHTDIRECTION_6 TypedWhichId<SvxB3DVectorItem>(SDRATTR_3DSCENE_FIRST + 26) /* 1309 V4+++*/
+#define SDRATTR_3DSCENE_LIGHTDIRECTION_7 TypedWhichId<SvxB3DVectorItem>(SDRATTR_3DSCENE_FIRST + 27) /* 1310 V4+++*/
+#define SDRATTR_3DSCENE_LIGHTDIRECTION_8 TypedWhichId<SvxB3DVectorItem>(SDRATTR_3DSCENE_FIRST + 28) /* 1311 V4+++*/
+#define SDRATTR_3DSCENE_SHADOW_SLANT TypedWhichId<SfxUInt16Item>(SDRATTR_3DSCENE_FIRST + 29) /* 1312 V4+++*/
+#define SDRATTR_3DSCENE_SHADE_MODE TypedWhichId<Svx3DShadeModeItem>(SDRATTR_3DSCENE_FIRST + 30) /* 1313 V4+++*/
#define SDRATTR_3DSCENE_LAST (SDRATTR_3DSCENE_SHADE_MODE) /* 1333 V4+++*/
#define SDRATTR_3D_LAST (SDRATTR_3DSCENE_LAST) /* 1333 V4+++*/
-#define SDRATTR_CUSTOMSHAPE_FIRST (SDRATTR_3D_LAST + 1) /* 1334 V4+++*/
-#define SDRATTR_CUSTOMSHAPE_ENGINE (SDRATTR_CUSTOMSHAPE_FIRST + 0) /* 1334 V4+++*/
-#define SDRATTR_CUSTOMSHAPE_DATA (SDRATTR_CUSTOMSHAPE_FIRST + 1) /* 1335 V4+++*/
-#define SDRATTR_CUSTOMSHAPE_GEOMETRY (SDRATTR_CUSTOMSHAPE_FIRST + 2) /* 1336 V4+++*/
-#define SDRATTR_CUSTOMSHAPE_LAST (SDRATTR_CUSTOMSHAPE_GEOMETRY) /* 1357 V4+++*/
+#define SDRATTR_CUSTOMSHAPE_FIRST (SDRATTR_3D_LAST + 1) /* 1334 V4+++*/
+#define SDRATTR_CUSTOMSHAPE_ENGINE TypedWhichId<SfxStringItem>(SDRATTR_CUSTOMSHAPE_FIRST + 0) /* 1334 V4+++*/
+#define SDRATTR_CUSTOMSHAPE_DATA TypedWhichId<SfxStringItem>(SDRATTR_CUSTOMSHAPE_FIRST + 1) /* 1335 V4+++*/
+#define SDRATTR_CUSTOMSHAPE_GEOMETRY TypedWhichId<SdrCustomShapeGeometryItem>(SDRATTR_CUSTOMSHAPE_FIRST + 2) /* 1336 V4+++*/
+#define SDRATTR_CUSTOMSHAPE_LAST (SDRATTR_CUSTOMSHAPE_GEOMETRY) /* 1357 V4+++*/
#define SDRATTR_TABLE_FIRST (SDRATTR_CUSTOMSHAPE_LAST+1)
-#define SDRATTR_TABLE_BORDER (SDRATTR_TABLE_FIRST+0)
-#define SDRATTR_TABLE_BORDER_INNER (SDRATTR_TABLE_FIRST+1)
-#define SDRATTR_TABLE_BORDER_TLBR (SDRATTR_TABLE_FIRST+2)
-#define SDRATTR_TABLE_BORDER_BLTR (SDRATTR_TABLE_FIRST+3)
+#define SDRATTR_TABLE_BORDER TypedWhichId<SvxBoxItem>(SDRATTR_TABLE_FIRST+0)
+#define SDRATTR_TABLE_BORDER_INNER TypedWhichId<SvxBoxInfoItem>(SDRATTR_TABLE_FIRST+1)
+#define SDRATTR_TABLE_BORDER_TLBR TypedWhichId<SvxLineItem>(SDRATTR_TABLE_FIRST+2)
+#define SDRATTR_TABLE_BORDER_BLTR TypedWhichId<SvxLineItem>(SDRATTR_TABLE_FIRST+3)
#define SDRATTR_TABLE_TEXT_ROTATION (SDRATTR_TABLE_FIRST+4)
#define SDRATTR_TABLE_LAST (SDRATTR_TABLE_TEXT_ROTATION)
diff --git a/sc/source/filter/excel/xiescher.cxx b/sc/source/filter/excel/xiescher.cxx
index 94bd7e47039b..c64396b5bb7d 100644
--- a/sc/source/filter/excel/xiescher.cxx
+++ b/sc/source/filter/excel/xiescher.cxx
@@ -1499,7 +1499,7 @@ void XclImpTextObj::DoPreProcessSdrObj( XclImpDffConverter& rDffConv, SdrObject&
css::beans::PropertyValue aTextRotateAngle;
aTextRotateAngle.Name = "TextRotateAngle";
aTextRotateAngle.Value <<= 180.0;
- SdrCustomShapeGeometryItem aGeometryItem(static_cast<const SdrCustomShapeGeometryItem&>(pObjCustomShape->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY )));
+ SdrCustomShapeGeometryItem aGeometryItem(pObjCustomShape->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ));
aGeometryItem.SetPropertyValue( aTextRotateAngle );
pObjCustomShape->SetMergedItem( aGeometryItem );
}
diff --git a/sc/source/filter/xcl97/xcl97esc.cxx b/sc/source/filter/xcl97/xcl97esc.cxx
index 7533190a4b65..198b23ef5c33 100644
--- a/sc/source/filter/xcl97/xcl97esc.cxx
+++ b/sc/source/filter/xcl97/xcl97esc.cxx
@@ -175,8 +175,8 @@ bool lcl_IsFontwork( const SdrObject* pObj )
if( pObj->GetObjIdentifier() == OBJ_CUSTOMSHAPE )
{
const OUString aTextPath = "TextPath";
- const SdrCustomShapeGeometryItem& rGeometryItem = static_cast<const SdrCustomShapeGeometryItem&>(
- pObj->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ) );
+ const SdrCustomShapeGeometryItem& rGeometryItem =
+ pObj->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY );
if( const Any* pAny = rGeometryItem.GetPropertyValueByName( aTextPath, aTextPath ) )
*pAny >>= bIsFontwork;
}
diff --git a/sd/qa/unit/import-tests.cxx b/sd/qa/unit/import-tests.cxx
index cf03f83d02c5..00e72e3b533c 100644
--- a/sd/qa/unit/import-tests.cxx
+++ b/sd/qa/unit/import-tests.cxx
@@ -606,7 +606,7 @@ void SdImportTest::testFdo72998()
{
SdrObjCustomShape *pObj = dynamic_cast<SdrObjCustomShape *>(pPage->GetObj(2));
CPPUNIT_ASSERT( pObj );
- const SdrCustomShapeGeometryItem& rGeometryItem = static_cast<const SdrCustomShapeGeometryItem&>(pObj->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ));
+ const SdrCustomShapeGeometryItem& rGeometryItem = pObj->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY );
const css::uno::Any* pViewBox = const_cast<SdrCustomShapeGeometryItem&>(rGeometryItem).GetPropertyValueByName( OUString( "ViewBox" ) );
CPPUNIT_ASSERT_MESSAGE( "Missing ViewBox", pViewBox );
css::awt::Rectangle aViewBox;
diff --git a/sd/source/ui/table/TableDesignPane.cxx b/sd/source/ui/table/TableDesignPane.cxx
index 9e4920ab2ccf..06a77214f9fe 100644
--- a/sd/source/ui/table/TableDesignPane.cxx
+++ b/sd/source/ui/table/TableDesignPane.cxx
@@ -477,7 +477,7 @@ CellInfo::CellInfo( const Reference< XStyle >& xStyle )
maTextColor.SetColor( COL_TRANSPARENT );
// get border
- const SvxBoxItem* pBoxItem = dynamic_cast<const SvxBoxItem*>(rSet.GetItem( SDRATTR_TABLE_BORDER ) );
+ const SvxBoxItem* pBoxItem = rSet.GetItem( SDRATTR_TABLE_BORDER );
if( pBoxItem )
maBorder = *pBoxItem;
}
diff --git a/svx/source/customshapes/EnhancedCustomShape2d.cxx b/svx/source/customshapes/EnhancedCustomShape2d.cxx
index 51c11848de67..9325e6e88f82 100644
--- a/svx/source/customshapes/EnhancedCustomShape2d.cxx
+++ b/svx/source/customshapes/EnhancedCustomShape2d.cxx
@@ -730,7 +730,7 @@ EnhancedCustomShape2d::EnhancedCustomShape2d( SdrObject* pAObj ) :
aLogicRect = tools::Rectangle( aP, aS );
OUString sShapeType;
- const SdrCustomShapeGeometryItem& rGeometryItem = static_cast<const SdrCustomShapeGeometryItem&>(pCustomShapeObj->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ));
+ const SdrCustomShapeGeometryItem& rGeometryItem = pCustomShapeObj->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY );
const Any* pAny = rGeometryItem.GetPropertyValueByName( "Type" );
if ( pAny ) {
*pAny >>= sShapeType;
@@ -1373,7 +1373,7 @@ bool EnhancedCustomShape2d::SetHandleControllerPosition( const sal_uInt32 nIndex
}
// and writing them back into the GeometryItem
SdrCustomShapeGeometryItem aGeometryItem(
- static_cast<const SdrCustomShapeGeometryItem&>(pCustomShapeObj->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY )));
+ pCustomShapeObj->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ));
css::beans::PropertyValue aPropVal;
aPropVal.Name = "AdjustmentValues";
aPropVal.Value <<= seqAdjustmentValues;
@@ -1607,7 +1607,7 @@ void EnhancedCustomShape2d::CreateSubPath( sal_Int32& rSrcPt, sal_Int32& rSegmen
bIsDefaultPath = true;
OUString sShpType;
- SdrCustomShapeGeometryItem& rGeometryItem = const_cast<SdrCustomShapeGeometryItem&>(static_cast<const SdrCustomShapeGeometryItem&>(pCustomShapeObj->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY )));
+ SdrCustomShapeGeometryItem& rGeometryItem = const_cast<SdrCustomShapeGeometryItem&>(pCustomShapeObj->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ));
Any* pAny = rGeometryItem.GetPropertyValueByName( "Type" );
if ( pAny )
*pAny >>= sShpType;
diff --git a/svx/source/customshapes/EnhancedCustomShape3d.cxx b/svx/source/customshapes/EnhancedCustomShape3d.cxx
index bbc9ad4f7320..d9968a768142 100644
--- a/svx/source/customshapes/EnhancedCustomShape3d.cxx
+++ b/svx/source/customshapes/EnhancedCustomShape3d.cxx
@@ -185,7 +185,7 @@ EnhancedCustomShape3d::Transformation2D::Transformation2D( const SdrObject* pCus
, fOriginY(0.0)
, pMap( pM )
{
- const SdrCustomShapeGeometryItem& rGeometryItem = static_cast<const SdrCustomShapeGeometryItem&>(pCustomShape->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ));
+ const SdrCustomShapeGeometryItem& rGeometryItem = pCustomShape->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY );
const Any* pAny = rGeometryItem.GetPropertyValueByName( "Extrusion", "ProjectionMode" );
if ( pAny )
*pAny >>= eProjectionMode;
@@ -253,7 +253,7 @@ SdrObject* EnhancedCustomShape3d::Create3DObject( const SdrObject* pShape2d, con
{
SdrObject* pRet = nullptr;
SdrModel* pModel = pCustomShape->GetModel();
- const SdrCustomShapeGeometryItem& rGeometryItem = static_cast<const SdrCustomShapeGeometryItem&>(pCustomShape->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ));
+ const SdrCustomShapeGeometryItem& rGeometryItem = pCustomShape->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY );
double fMap, *pMap = nullptr;
if ( pModel )
@@ -734,7 +734,7 @@ SdrObject* EnhancedCustomShape3d::Create3DObject( const SdrObject* pShape2d, con
tools::Rectangle EnhancedCustomShape3d::CalculateNewSnapRect( const SdrObject* pCustomShape, const tools::Rectangle& rSnapRect, const tools::Rectangle& rBoundRect, const double* pMap )
{
- const SdrCustomShapeGeometryItem& rGeometryItem = static_cast<const SdrCustomShapeGeometryItem&>(pCustomShape->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ));
+ const SdrCustomShapeGeometryItem& rGeometryItem = pCustomShape->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY );
const Point aCenter( rSnapRect.Center() );
double fExtrusionBackward, fExtrusionForward;
GetExtrusionDepth( rGeometryItem, pMap, fExtrusionBackward, fExtrusionForward );
diff --git a/svx/source/customshapes/EnhancedCustomShapeEngine.cxx b/svx/source/customshapes/EnhancedCustomShapeEngine.cxx
index 00100d8afad9..4fd5857b315d 100644
--- a/svx/source/customshapes/EnhancedCustomShapeEngine.cxx
+++ b/svx/source/customshapes/EnhancedCustomShapeEngine.cxx
@@ -258,8 +258,8 @@ Reference< drawing::XShape > SAL_CALL EnhancedCustomShapeEngine::render()
if ( pSdrObjCustomShape )
{
// retrieving the TextPath property to check if feature is enabled
- const SdrCustomShapeGeometryItem& rGeometryItem = static_cast<const SdrCustomShapeGeometryItem&>(
- pSdrObjCustomShape->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ));
+ const SdrCustomShapeGeometryItem& rGeometryItem =
+ pSdrObjCustomShape->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY );
bool bTextPathOn = false;
const uno::Any* pAny = rGeometryItem.GetPropertyValueByName( "TextPath", "TextPath" );
if ( pAny )
diff --git a/svx/source/customshapes/EnhancedCustomShapeFontWork.cxx b/svx/source/customshapes/EnhancedCustomShapeFontWork.cxx
index d336ec66e4af..be18edd1b2f8 100644
--- a/svx/source/customshapes/EnhancedCustomShapeFontWork.cxx
+++ b/svx/source/customshapes/EnhancedCustomShapeFontWork.cxx
@@ -428,7 +428,7 @@ bool GetFontWorkOutline(FWData& rFWData, const SdrObject* pCustomShape)
return false;
bool bSameLetterHeights = false;
- const SdrCustomShapeGeometryItem& rGeometryItem = static_cast<const SdrCustomShapeGeometryItem&>(pCustomShape->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ));
+ const SdrCustomShapeGeometryItem& rGeometryItem = pCustomShape->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY );
const css::uno::Any* pAny = rGeometryItem.GetPropertyValueByName( "TextPath", "SameLetterHeights" );
if ( pAny )
*pAny >>= bSameLetterHeights;
diff --git a/svx/source/dialog/dlgctl3d.cxx b/svx/source/dialog/dlgctl3d.cxx
index cab2f5443e98..8deb3bbc8e6c 100644
--- a/svx/source/dialog/dlgctl3d.cxx
+++ b/svx/source/dialog/dlgctl3d.cxx
@@ -876,14 +876,14 @@ bool Svx3DLightControl::GetLightOnOff(sal_uInt32 nNum) const
switch(nNum)
{
- case 0 : return static_cast<const SfxBoolItem&>(aLightItemSet.Get(SDRATTR_3DSCENE_LIGHTON_1)).GetValue();
- case 1 : return static_cast<const SfxBoolItem&>(aLightItemSet.Get(SDRATTR_3DSCENE_LIGHTON_2)).GetValue();
- case 2 : return static_cast<const SfxBoolItem&>(aLightItemSet.Get(SDRATTR_3DSCENE_LIGHTON_3)).GetValue();
- case 3 : return static_cast<const SfxBoolItem&>(aLightItemSet.Get(SDRATTR_3DSCENE_LIGHTON_4)).GetValue();
- case 4 : return static_cast<const SfxBoolItem&>(aLightItemSet.Get(SDRATTR_3DSCENE_LIGHTON_5)).GetValue();
- case 5 : return static_cast<const SfxBoolItem&>(aLightItemSet.Get(SDRATTR_3DSCENE_LIGHTON_6)).GetValue();
- case 6 : return static_cast<const SfxBoolItem&>(aLightItemSet.Get(SDRATTR_3DSCENE_LIGHTON_7)).GetValue();
- case 7 : return static_cast<const SfxBoolItem&>(aLightItemSet.Get(SDRATTR_3DSCENE_LIGHTON_8)).GetValue();
+ case 0 : return aLightItemSet.Get(SDRATTR_3DSCENE_LIGHTON_1).GetValue();
+ case 1 : return aLightItemSet.Get(SDRATTR_3DSCENE_LIGHTON_2).GetValue();
+ case 2 : return aLightItemSet.Get(SDRATTR_3DSCENE_LIGHTON_3).GetValue();
+ case 3 : return aLightItemSet.Get(SDRATTR_3DSCENE_LIGHTON_4).GetValue();
+ case 4 : return aLightItemSet.Get(SDRATTR_3DSCENE_LIGHTON_5).GetValue();
+ case 5 : return aLightItemSet.Get(SDRATTR_3DSCENE_LIGHTON_6).GetValue();
+ case 6 : return aLightItemSet.Get(SDRATTR_3DSCENE_LIGHTON_7).GetValue();
+ case 7 : return aLightItemSet.Get(SDRATTR_3DSCENE_LIGHTON_8).GetValue();
}
}
@@ -898,14 +898,14 @@ Color Svx3DLightControl::GetLightColor(sal_uInt32 nNum) const
switch(nNum)
{
- case 0 : return static_cast<const SvxColorItem&>(aLightItemSet.Get(SDRATTR_3DSCENE_LIGHTCOLOR_1)).GetValue();
- case 1 : return static_cast<const SvxColorItem&>(aLightItemSet.Get(SDRATTR_3DSCENE_LIGHTCOLOR_2)).GetValue();
- case 2 : return static_cast<const SvxColorItem&>(aLightItemSet.Get(SDRATTR_3DSCENE_LIGHTCOLOR_3)).GetValue();
- case 3 : return static_cast<const SvxColorItem&>(aLightItemSet.Get(SDRATTR_3DSCENE_LIGHTCOLOR_4)).GetValue();
- case 4 : return static_cast<const SvxColorItem&>(aLightItemSet.Get(SDRATTR_3DSCENE_LIGHTCOLOR_5)).GetValue();
- case 5 : return static_cast<const SvxColorItem&>(aLightItemSet.Get(SDRATTR_3DSCENE_LIGHTCOLOR_6)).GetValue();
- case 6 : return static_cast<const SvxColorItem&>(aLightItemSet.Get(SDRATTR_3DSCENE_LIGHTCOLOR_7)).GetValue();
- case 7 : return static_cast<const SvxColorItem&>(aLightItemSet.Get(SDRATTR_3DSCENE_LIGHTCOLOR_8)).GetValue();
+ case 0 : return aLightItemSet.Get(SDRATTR_3DSCENE_LIGHTCOLOR_1).GetValue();
+ case 1 : return aLightItemSet.Get(SDRATTR_3DSCENE_LIGHTCOLOR_2).GetValue();
+ case 2 : return aLightItemSet.Get(SDRATTR_3DSCENE_LIGHTCOLOR_3).GetValue();
+ case 3 : return aLightItemSet.Get(SDRATTR_3DSCENE_LIGHTCOLOR_4).GetValue();
+ case 4 : return aLightItemSet.Get(SDRATTR_3DSCENE_LIGHTCOLOR_5).GetValue();
+ case 5 : return aLightItemSet.Get(SDRATTR_3DSCENE_LIGHTCOLOR_6).GetValue();
+ case 6 : return aLightItemSet.Get(SDRATTR_3DSCENE_LIGHTCOLOR_7).GetValue();
+ case 7 : return aLightItemSet.Get(SDRATTR_3DSCENE_LIGHTCOLOR_8).GetValue();
}
}
@@ -920,14 +920,14 @@ basegfx::B3DVector Svx3DLightControl::GetLightDirection(sal_uInt32 nNum) const
switch(nNum)
{
- case 0 : return static_cast<const SvxB3DVectorItem&>(aLightItemSet.Get(SDRATTR_3DSCENE_LIGHTDIRECTION_1)).GetValue();
- case 1 : return static_cast<const SvxB3DVectorItem&>(aLightItemSet.Get(SDRATTR_3DSCENE_LIGHTDIRECTION_2)).GetValue();
- case 2 : return static_cast<const SvxB3DVectorItem&>(aLightItemSet.Get(SDRATTR_3DSCENE_LIGHTDIRECTION_3)).GetValue();
- case 3 : return static_cast<const SvxB3DVectorItem&>(aLightItemSet.Get(SDRATTR_3DSCENE_LIGHTDIRECTION_4)).GetValue();
- case 4 : return static_cast<const SvxB3DVectorItem&>(aLightItemSet.Get(SDRATTR_3DSCENE_LIGHTDIRECTION_5)).GetValue();
- case 5 : return static_cast<const SvxB3DVectorItem&>(aLightItemSet.Get(SDRATTR_3DSCENE_LIGHTDIRECTION_6)).GetValue();
- case 6 : return static_cast<const SvxB3DVectorItem&>(aLightItemSet.Get(SDRATTR_3DSCENE_LIGHTDIRECTION_7)).GetValue();
- case 7 : return static_cast<const SvxB3DVectorItem&>(aLightItemSet.Get(SDRATTR_3DSCENE_LIGHTDIRECTION_8)).GetValue();
+ case 0 : return aLightItemSet.Get(SDRATTR_3DSCENE_LIGHTDIRECTION_1).GetValue();
+ case 1 : return aLightItemSet.Get(SDRATTR_3DSCENE_LIGHTDIRECTION_2).GetValue();
+ case 2 : return aLightItemSet.Get(SDRATTR_3DSCENE_LIGHTDIRECTION_3).GetValue();
+ case 3 : return aLightItemSet.Get(SDRATTR_3DSCENE_LIGHTDIRECTION_4).GetValue();
+ case 4 : return aLightItemSet.Get(SDRATTR_3DSCENE_LIGHTDIRECTION_5).GetValue();
+ case 5 : return aLightItemSet.Get(SDRATTR_3DSCENE_LIGHTDIRECTION_6).GetValue();
+ case 6 : return aLightItemSet.Get(SDRATTR_3DSCENE_LIGHTDIRECTION_7).GetValue();
+ case 7 : return aLightItemSet.Get(SDRATTR_3DSCENE_LIGHTDIRECTION_8).GetValue();
}
}
diff --git a/svx/source/engine3d/float3d.cxx b/svx/source/engine3d/float3d.cxx
index 3a8289d23538..e8e025c7493c 100644
--- a/svx/source/engine3d/float3d.cxx
+++ b/svx/source/engine3d/float3d.cxx
@@ -580,7 +580,7 @@ void Svx3DWin::Update( SfxItemSet const & rAttrs )
eState = rAttrs.GetItemState(SDRATTR_3DOBJ_HORZ_SEGS);
if(eState != SfxItemState::DONTCARE)
{
- sal_uInt32 nValue = static_cast<const SfxUInt32Item&>(rAttrs.Get(SDRATTR_3DOBJ_HORZ_SEGS)).GetValue();
+ sal_uInt32 nValue = rAttrs.Get(SDRATTR_3DOBJ_HORZ_SEGS).GetValue();
if(nValue != (sal_uInt32 )m_pNumHorizontal->GetValue())
{
m_pNumHorizontal->SetValue( nValue );
@@ -605,7 +605,7 @@ void Svx3DWin::Update( SfxItemSet const & rAttrs )
eState = rAttrs.GetItemState(SDRATTR_3DOBJ_VERT_SEGS);
if( eState != SfxItemState::DONTCARE )
{
- sal_uInt32 nValue = static_cast<const SfxUInt32Item&>(rAttrs.Get(SDRATTR_3DOBJ_VERT_SEGS)).GetValue();
+ sal_uInt32 nValue = rAttrs.Get(SDRATTR_3DOBJ_VERT_SEGS).GetValue();
if( nValue != (sal_uInt32) m_pNumVertical->GetValue() )
{
m_pNumVertical->SetValue( nValue );
@@ -630,7 +630,7 @@ void Svx3DWin::Update( SfxItemSet const & rAttrs )
eState = rAttrs.GetItemState(SDRATTR_3DOBJ_DEPTH);
if( eState != SfxItemState::DONTCARE )
{
- sal_uInt32 nValue = static_cast<const SfxUInt32Item&>(rAttrs.Get(SDRATTR_3DOBJ_DEPTH)).GetValue();
+ sal_uInt32 nValue = rAttrs.Get(SDRATTR_3DOBJ_DEPTH).GetValue();
sal_uInt32 nValue2 = GetCoreValue(*m_pMtrDepth, ePoolUnit);
if( nValue != nValue2 )
{
@@ -657,7 +657,7 @@ void Svx3DWin::Update( SfxItemSet const & rAttrs )
eState = rAttrs.GetItemState(SDRATTR_3DOBJ_DOUBLE_SIDED);
if( eState != SfxItemState::DONTCARE )
{
- bool bValue = static_cast<const SfxBoolItem&>(rAttrs.Get(SDRATTR_3DOBJ_DOUBLE_SIDED)).GetValue();
+ bool bValue = rAttrs.Get(SDRATTR_3DOBJ_DOUBLE_SIDED).GetValue();
if( bValue != m_pBtnDoubleSided->IsChecked() )
{
m_pBtnDoubleSided->Check( bValue );
@@ -681,7 +681,7 @@ void Svx3DWin::Update( SfxItemSet const & rAttrs )
eState = rAttrs.GetItemState(SDRATTR_3DOBJ_PERCENT_DIAGONAL);
if( eState != SfxItemState::DONTCARE )
{
- sal_uInt16 nValue = static_cast<const SfxUInt16Item&>(rAttrs.Get(SDRATTR_3DOBJ_PERCENT_DIAGONAL)).GetValue();
+ sal_uInt16 nValue = rAttrs.Get(SDRATTR_3DOBJ_PERCENT_DIAGONAL).GetValue();
if( nValue != m_pMtrPercentDiagonal->GetValue() )
{
m_pMtrPercentDiagonal->SetValue( nValue );
@@ -706,7 +706,7 @@ void Svx3DWin::Update( SfxItemSet const & rAttrs )
eState = rAttrs.GetItemState(SDRATTR_3DOBJ_BACKSCALE);
if( eState != SfxItemState::DONTCARE )
{
- sal_uInt16 nValue = static_cast<const SfxUInt16Item&>(rAttrs.Get(SDRATTR_3DOBJ_BACKSCALE)).GetValue();
+ sal_uInt16 nValue = rAttrs.Get(SDRATTR_3DOBJ_BACKSCALE).GetValue();
if( nValue != m_pMtrBackscale->GetValue() )
{
m_pMtrBackscale->SetValue( nValue );
@@ -731,7 +731,7 @@ void Svx3DWin::Update( SfxItemSet const & rAttrs )
eState = rAttrs.GetItemState(SDRATTR_3DOBJ_END_ANGLE);
if( eState != SfxItemState::DONTCARE )
{
- sal_Int32 nValue = static_cast<const SfxUInt32Item&>(rAttrs.Get(SDRATTR_3DOBJ_END_ANGLE)).GetValue();
+ sal_Int32 nValue = rAttrs.Get(SDRATTR_3DOBJ_END_ANGLE).GetValue();
if( nValue != m_pMtrEndAngle->GetValue() )
{
m_pMtrEndAngle->SetValue( nValue );
@@ -752,7 +752,7 @@ void Svx3DWin::Update( SfxItemSet const & rAttrs )
eState = rAttrs.GetItemState(SDRATTR_3DOBJ_NORMALS_KIND);
if( eState != SfxItemState::DONTCARE )
{
- sal_uInt16 nValue = static_cast<const Svx3DNormalsKindItem&>(rAttrs.Get(SDRATTR_3DOBJ_NORMALS_KIND)).GetValue();
+ sal_uInt16 nValue = rAttrs.Get(SDRATTR_3DOBJ_NORMALS_KIND).GetValue();
if( ( !m_pBtnNormalsObj->IsChecked() && nValue == 0 ) ||
( !m_pBtnNormalsFlat->IsChecked() && nValue == 1 ) ||
@@ -781,7 +781,7 @@ void Svx3DWin::Update( SfxItemSet const & rAttrs )
eState = rAttrs.GetItemState(SDRATTR_3DOBJ_NORMALS_INVERT);
if( eState != SfxItemState::DONTCARE )
{
- bool bValue = static_cast<const SfxBoolItem&>(rAttrs.Get(SDRATTR_3DOBJ_NORMALS_INVERT)).GetValue();
+ bool bValue = rAttrs.Get(SDRATTR_3DOBJ_NORMALS_INVERT).GetValue();
if( bValue != m_pBtnNormalsInvert->IsChecked() )
{
m_pBtnNormalsInvert->Check( bValue );
@@ -803,7 +803,7 @@ void Svx3DWin::Update( SfxItemSet const & rAttrs )
eState = rAttrs.GetItemState(SDRATTR_3DSCENE_TWO_SIDED_LIGHTING);
if( eState != SfxItemState::DONTCARE )
{
- bool bValue = static_cast<const SfxBoolItem&>(rAttrs.Get(SDRATTR_3DSCENE_TWO_SIDED_LIGHTING)).GetValue();
+ bool bValue = rAttrs.Get(SDRATTR_3DSCENE_TWO_SIDED_LIGHTING).GetValue();
if( bValue != m_pBtnTwoSidedLighting->IsChecked() )
{
m_pBtnTwoSidedLighting->Check( bValue );
@@ -826,7 +826,7 @@ void Svx3DWin::Update( SfxItemSet const & rAttrs )
eState = rAttrs.GetItemState(SDRATTR_3DSCENE_SHADE_MODE);
if( eState != SfxItemState::DONTCARE )
{
- sal_uInt16 nValue = static_cast<const Svx3DShadeModeItem&>(rAttrs.Get(SDRATTR_3DSCENE_SHADE_MODE)).GetValue();
+ sal_uInt16 nValue = rAttrs.Get(SDRATTR_3DSCENE_SHADE_MODE).GetValue();
if( nValue != m_pLbShademode->GetSelectedEntryPos() )
{
m_pLbShademode->SelectEntryPos( nValue );
@@ -846,7 +846,7 @@ void Svx3DWin::Update( SfxItemSet const & rAttrs )
eState = rAttrs.GetItemState(SDRATTR_3DOBJ_SHADOW_3D);
if( eState != SfxItemState::DONTCARE )
{
- bool bValue = static_cast<const SfxBoolItem&>(rAttrs.Get(SDRATTR_3DOBJ_SHADOW_3D)).GetValue();
+ bool bValue = rAttrs.Get(SDRATTR_3DOBJ_SHADOW_3D).GetValue();
if( bValue != m_pBtnShadow3d->IsChecked() )
{
m_pBtnShadow3d->Check( bValue );
@@ -870,7 +870,7 @@ void Svx3DWin::Update( SfxItemSet const & rAttrs )
eState = rAttrs.GetItemState(SDRATTR_3DSCENE_SHADOW_SLANT);
if( eState != SfxItemState::DONTCARE )
{
- sal_uInt16 nValue = static_cast<const SfxUInt16Item&>(rAttrs.Get(SDRATTR_3DSCENE_SHADOW_SLANT)).GetValue();
+ sal_uInt16 nValue = rAttrs.Get(SDRATTR_3DSCENE_SHADOW_SLANT).GetValue();
if( nValue != m_pMtrSlant->GetValue() )
{
m_pMtrSlant->SetValue( nValue );
@@ -890,7 +890,7 @@ void Svx3DWin::Update( SfxItemSet const & rAttrs )
eState = rAttrs.GetItemState(SDRATTR_3DSCENE_DISTANCE);
if( eState != SfxItemState::DONTCARE )
{
- sal_uInt32 nValue = static_cast<const SfxUInt32Item&>(rAttrs.Get(SDRATTR_3DSCENE_DISTANCE)).GetValue();
+ sal_uInt32 nValue = rAttrs.Get(SDRATTR_3DSCENE_DISTANCE).GetValue();
sal_uInt32 nValue2 = GetCoreValue(*m_pMtrDistance, ePoolUnit);
if( nValue != nValue2 )
{
@@ -914,7 +914,7 @@ void Svx3DWin::Update( SfxItemSet const & rAttrs )
eState = rAttrs.GetItemState(SDRATTR_3DSCENE_FOCAL_LENGTH);
if( eState != SfxItemState::DONTCARE )
{
- sal_uInt32 nValue = static_cast<const SfxUInt32Item&>(rAttrs.Get(SDRATTR_3DSCENE_FOCAL_LENGTH)).GetValue();
+ sal_uInt32 nValue = rAttrs.Get(SDRATTR_3DSCENE_FOCAL_LENGTH).GetValue();
sal_uInt32 nValue2 = GetCoreValue(*m_pMtrFocalLength, ePoolUnit);
if( nValue != nValue2 )
{
@@ -940,7 +940,7 @@ void Svx3DWin::Update( SfxItemSet const & rAttrs )
eState = rAttrs.GetItemState(SDRATTR_3DSCENE_LIGHTCOLOR_1);
if( eState != SfxItemState::DONTCARE )
{
- aColor = static_cast<const SvxColorItem&>(rAttrs.Get(SDRATTR_3DSCENE_LIGHTCOLOR_1)).GetValue();
+ aColor = rAttrs.Get(SDRATTR_3DSCENE_LIGHTCOLOR_1).GetValue();
SvxColorListBox* pLb = m_pLbLight1;
if( aColor != pLb->GetSelectEntryColor() )
{
@@ -960,7 +960,7 @@ void Svx3DWin::Update( SfxItemSet const & rAttrs )
eState = rAttrs.GetItemState(SDRATTR_3DSCENE_LIGHTON_1);
if( eState != SfxItemState::DONTCARE )
{
- bool bOn = static_cast<const SfxBoolItem&>(rAttrs.Get(SDRATTR_3DSCENE_LIGHTON_1)).GetValue();
+ bool bOn = rAttrs.Get(SDRATTR_3DSCENE_LIGHTON_1).GetValue();
if( ( bOn && !GetUILightState(*m_pBtnLight1)) ||
( !bOn && GetUILightState(*m_pBtnLight1)) )
{
@@ -989,7 +989,7 @@ void Svx3DWin::Update( SfxItemSet const & rAttrs )
eState = rAttrs.GetItemState(SDRATTR_3DSCENE_LIGHTCOLOR_2);
if( eState != SfxItemState::DONTCARE )
{
- aColor = static_cast<const SvxColorItem&>(rAttrs.Get(SDRATTR_3DSCENE_LIGHTCOLOR_2)).GetValue();
+ aColor = rAttrs.Get(SDRATTR_3DSCENE_LIGHTCOLOR_2).GetValue();
SvxColorListBox* pLb = m_pLbLight2;
if( aColor != pLb->GetSelectEntryColor() )
{
@@ -1009,7 +1009,7 @@ void Svx3DWin::Update( SfxItemSet const & rAttrs )
eState = rAttrs.GetItemState(SDRATTR_3DSCENE_LIGHTON_2);
if( eState != SfxItemState::DONTCARE )
{
- bool bOn = static_cast<const SfxBoolItem&>(rAttrs.Get(SDRATTR_3DSCENE_LIGHTON_2)).GetValue();
+ bool bOn = rAttrs.Get(SDRATTR_3DSCENE_LIGHTON_2).GetValue();
if( ( bOn && !GetUILightState(*m_pBtnLight2)) ||
( !bOn && GetUILightState(*m_pBtnLight2)) )
{
@@ -1038,7 +1038,7 @@ void Svx3DWin::Update( SfxItemSet const & rAttrs )
eState = rAttrs.GetItemState(SDRATTR_3DSCENE_LIGHTCOLOR_3);
if( eState != SfxItemState::DONTCARE )
{
- aColor = static_cast<const SvxColorItem&>(rAttrs.Get(SDRATTR_3DSCENE_LIGHTCOLOR_3)).GetValue();
+ aColor = rAttrs.Get(SDRATTR_3DSCENE_LIGHTCOLOR_3).GetValue();
SvxColorListBox* pLb = m_pLbLight3;
if( aColor != pLb->GetSelectEntryColor() )
{
@@ -1058,7 +1058,7 @@ void Svx3DWin::Update( SfxItemSet const & rAttrs )
eState = rAttrs.GetItemState(SDRATTR_3DSCENE_LIGHTON_3);
if( eState != SfxItemState::DONTCARE )
{
- bool bOn = static_cast<const SfxBoolItem&>(rAttrs.Get(SDRATTR_3DSCENE_LIGHTON_3)).GetValue();
+ bool bOn = rAttrs.Get(SDRATTR_3DSCENE_LIGHTON_3).GetValue();
if( ( bOn && !GetUILightState(*m_pBtnLight3)) ||
( !bOn && GetUILightState(*m_pBtnLight3)) )
{
@@ -1087,7 +1087,7 @@ void Svx3DWin::Update( SfxItemSet const & rAttrs )
eState = rAttrs.GetItemState(SDRATTR_3DSCENE_LIGHTCOLOR_4);
if( eState != SfxItemState::DONTCARE )
{
- aColor = static_cast<const SvxColorItem&>(rAttrs.Get(SDRATTR_3DSCENE_LIGHTCOLOR_4)).GetValue();
+ aColor = rAttrs.Get(SDRATTR_3DSCENE_LIGHTCOLOR_4).GetValue();
SvxColorListBox* pLb = m_pLbLight4;
if( aColor != pLb->GetSelectEntryColor() )
{
@@ -1107,7 +1107,7 @@ void Svx3DWin::Update( SfxItemSet const & rAttrs )
eState = rAttrs.GetItemState(SDRATTR_3DSCENE_LIGHTON_4);
if( eState != SfxItemState::DONTCARE )
{
- bool bOn = static_cast<const SfxBoolItem&>(rAttrs.Get(SDRATTR_3DSCENE_LIGHTON_4)).GetValue();
+ bool bOn = rAttrs.Get(SDRATTR_3DSCENE_LIGHTON_4).GetValue();
if( ( bOn && !GetUILightState(*m_pBtnLight4)) ||
( !bOn && GetUILightState(*m_pBtnLight4)) )
{
@@ -1136,7 +1136,7 @@ void Svx3DWin::Update( SfxItemSet const & rAttrs )
eState = rAttrs.GetItemState(SDRATTR_3DSCENE_LIGHTCOLOR_5);
if( eState != SfxItemState::DONTCARE )
{
- aColor = static_cast<const SvxColorItem&>(rAttrs.Get(SDRATTR_3DSCENE_LIGHTCOLOR_5)).GetValue();
+ aColor = rAttrs.Get(SDRATTR_3DSCENE_LIGHTCOLOR_5).GetValue();
SvxColorListBox* pLb = m_pLbLight5;
if( aColor != pLb->GetSelectEntryColor() )
{
@@ -1156,7 +1156,7 @@ void Svx3DWin::Update( SfxItemSet const & rAttrs )
eState = rAttrs.GetItemState(SDRATTR_3DSCENE_LIGHTON_5);
if( eState != SfxItemState::DONTCARE )
{
- bool bOn = static_cast<const SfxBoolItem&>(rAttrs.Get(SDRATTR_3DSCENE_LIGHTON_5)).GetValue();
+ bool bOn = rAttrs.Get(SDRATTR_3DSCENE_LIGHTON_5).GetValue();
if( ( bOn && !GetUILightState(*m_pBtnLight5)) ||
( !bOn && GetUILightState(*m_pBtnLight5)) )
{
@@ -1185,7 +1185,7 @@ void Svx3DWin::Update( SfxItemSet const & rAttrs )
eState = rAttrs.GetItemState(SDRATTR_3DSCENE_LIGHTCOLOR_6);
if( eState != SfxItemState::DONTCARE )
{
- aColor = static_cast<const SvxColorItem&>(rAttrs.Get(SDRATTR_3DSCENE_LIGHTCOLOR_6)).GetValue();
+ aColor = rAttrs.Get(SDRATTR_3DSCENE_LIGHTCOLOR_6).GetValue();
SvxColorListBox* pLb = m_pLbLight6;
if( aColor != pLb->GetSelectEntryColor() )
{
@@ -1205,7 +1205,7 @@ void Svx3DWin::Update( SfxItemSet const & rAttrs )
eState = rAttrs.GetItemState(SDRATTR_3DSCENE_LIGHTON_6);
if( eState != SfxItemState::DONTCARE )
{
- bool bOn = static_cast<const SfxBoolItem&>(rAttrs.Get(SDRATTR_3DSCENE_LIGHTON_6)).GetValue();
+ bool bOn = rAttrs.Get(SDRATTR_3DSCENE_LIGHTON_6).GetValue();
if( ( bOn && !GetUILightState(*m_pBtnLight6)) ||
( !bOn && GetUILightState(*m_pBtnLight6)) )
{
@@ -1234,7 +1234,7 @@ void Svx3DWin::Update( SfxItemSet const & rAttrs )
eState = rAttrs.GetItemState(SDRATTR_3DSCENE_LIGHTCOLOR_7);
if( eState != SfxItemState::DONTCARE )
{
- aColor = static_cast<const SvxColorItem&>(rAttrs.Get(SDRATTR_3DSCENE_LIGHTCOLOR_7)).GetValue();
+ aColor = rAttrs.Get(SDRATTR_3DSCENE_LIGHTCOLOR_7).GetValue();
SvxColorListBox* pLb = m_pLbLight7;
if( aColor != pLb->GetSelectEntryColor() )
{
@@ -1254,7 +1254,7 @@ void Svx3DWin::Update( SfxItemSet const & rAttrs )
eState = rAttrs.GetItemState(SDRATTR_3DSCENE_LIGHTON_7);
if( eState != SfxItemState::DONTCARE )
{
- bool bOn = static_cast<const SfxBoolItem&>(rAttrs.Get(SDRATTR_3DSCENE_LIGHTON_7)).GetValue();
+ bool bOn = rAttrs.Get(SDRATTR_3DSCENE_LIGHTON_7).GetValue();
if( ( bOn && !GetUILightState(*m_pBtnLight7)) ||
( !bOn && GetUILightState(*m_pBtnLight7)) )
{
@@ -1283,7 +1283,7 @@ void Svx3DWin::Update( SfxItemSet const & rAttrs )
eState = rAttrs.GetItemState(SDRATTR_3DSCENE_LIGHTCOLOR_8);
if( eState != SfxItemState::DONTCARE )
{
- aColor = static_cast<const SvxColorItem&>(rAttrs.Get(SDRATTR_3DSCENE_LIGHTCOLOR_8)).GetValue();
+ aColor = rAttrs.Get(SDRATTR_3DSCENE_LIGHTCOLOR_8).GetValue();
SvxColorListBox* pLb = m_pLbLight8;
if( aColor != pLb->GetSelectEntryColor() )
{
@@ -1303,7 +1303,7 @@ void Svx3DWin::Update( SfxItemSet const & rAttrs )
eState = rAttrs.GetItemState(SDRATTR_3DSCENE_LIGHTON_8);
if( eState != SfxItemState::DONTCARE )
{
- bool bOn = static_cast<const SfxBoolItem&>(rAttrs.Get(SDRATTR_3DSCENE_LIGHTON_8)).GetValue();
+ bool bOn = rAttrs.Get(SDRATTR_3DSCENE_LIGHTON_8).GetValue();
if( ( bOn && !GetUILightState(*m_pBtnLight8)) ||
( !bOn && GetUILightState(*m_pBtnLight8)) )
{
@@ -1332,7 +1332,7 @@ void Svx3DWin::Update( SfxItemSet const & rAttrs )
eState = rAttrs.GetItemState(SDRATTR_3DSCENE_AMBIENTCOLOR);
if( eState != SfxItemState::DONTCARE )
{
- aColor = static_cast<const SvxColorItem&>(rAttrs.Get(SDRATTR_3DSCENE_AMBIENTCOLOR)).GetValue();
+ aColor = rAttrs.Get(SDRATTR_3DSCENE_AMBIENTCOLOR).GetValue();
SvxColorListBox* pLb = m_pLbAmbientlight;
if( aColor != pLb->GetSelectEntryColor() )
{
@@ -1357,7 +1357,7 @@ void Svx3DWin::Update( SfxItemSet const & rAttrs )
eState = rAttrs.GetItemState(SDRATTR_3DOBJ_TEXTURE_KIND);
if( eState != SfxItemState::DONTCARE )
{
- sal_uInt16 nValue = static_cast<const Svx3DTextureKindItem&>(rAttrs.Get(SDRATTR_3DOBJ_TEXTURE_KIND)).GetValue();
+ sal_uInt16 nValue = rAttrs.Get(SDRATTR_3DOBJ_TEXTURE_KIND).GetValue();
if( ( !m_pBtnTexLuminance->IsChecked() && nValue == 1 ) ||
( !m_pBtnTexColor->IsChecked() && nValue == 3 ) )
@@ -1382,7 +1382,7 @@ void Svx3DWin::Update( SfxItemSet const & rAttrs )
eState = rAttrs.GetItemState(SDRATTR_3DOBJ_TEXTURE_MODE);
if( eState != SfxItemState::DONTCARE )
{
- sal_uInt16 nValue = static_cast<const Svx3DTextureModeItem&>(rAttrs.Get(SDRATTR_3DOBJ_TEXTURE_MODE)).GetValue();
+ sal_uInt16 nValue = rAttrs.Get(SDRATTR_3DOBJ_TEXTURE_MODE).GetValue();
if( ( !m_pBtnTexReplace->IsChecked() && nValue == 1 ) ||
( !m_pBtnTexModulate->IsChecked() && nValue == 2 ) )
@@ -1407,7 +1407,7 @@ void Svx3DWin::Update( SfxItemSet const & rAttrs )
eState = rAttrs.GetItemState(SDRATTR_3DOBJ_TEXTURE_PROJ_X);
if( eState != SfxItemState::DONTCARE )
{
- sal_uInt16 nValue = static_cast<const Svx3DTextureProjectionXItem&>(rAttrs.Get(SDRATTR_3DOBJ_TEXTURE_PROJ_X)).GetValue();
+ sal_uInt16 nValue = rAttrs.Get(SDRATTR_3DOBJ_TEXTURE_PROJ_X).GetValue();
if( ( !m_pBtnTexObjectX->IsChecked() && nValue == 0 ) ||
( !m_pBtnTexParallelX->IsChecked() && nValue == 1 ) ||
@@ -1436,7 +1436,7 @@ void Svx3DWin::Update( SfxItemSet const & rAttrs )
eState = rAttrs.GetItemState(SDRATTR_3DOBJ_TEXTURE_PROJ_Y);
if( eState != SfxItemState::DONTCARE )
{
- sal_uInt16 nValue = static_cast<const Svx3DTextureProjectionYItem&>(rAttrs.Get(SDRATTR_3DOBJ_TEXTURE_PROJ_Y)).GetValue();
+ sal_uInt16 nValue = rAttrs.Get(SDRATTR_3DOBJ_TEXTURE_PROJ_Y).GetValue();
if( ( !m_pBtnTexObjectY->IsChecked() && nValue == 0 ) ||
( !m_pBtnTexParallelY->IsChecked() && nValue == 1 ) ||
@@ -1465,7 +1465,7 @@ void Svx3DWin::Update( SfxItemSet const & rAttrs )
eState = rAttrs.GetItemState(SDRATTR_3DOBJ_TEXTURE_FILTER);
if( eState != SfxItemState::DONTCARE )
{
- bool bValue = static_cast<const SfxBoolItem&>(rAttrs.Get(SDRATTR_3DOBJ_TEXTURE_FILTER)).GetValue();
+ bool bValue = rAttrs.Get(SDRATTR_3DOBJ_TEXTURE_FILTER).GetValue();
if( bValue != m_pBtnTexFilter->IsChecked() )
{
m_pBtnTexFilter->Check( bValue );
@@ -1513,7 +1513,7 @@ void Svx3DWin::Update( SfxItemSet const & rAttrs )
eState = rAttrs.GetItemState(SDRATTR_3DOBJ_MAT_EMISSION);
if( eState != SfxItemState::DONTCARE )
{
- aColor = static_cast<const SvxColorItem&>(rAttrs.Get(SDRATTR_3DOBJ_MAT_EMISSION)).GetValue();
+ aColor = rAttrs.Get(SDRATTR_3DOBJ_MAT_EMISSION).GetValue();
SvxColorListBox* pLb = m_pLbMatEmission;
if( aColor != pLb->GetSelectEntryColor() )
{
@@ -1534,7 +1534,7 @@ void Svx3DWin::Update( SfxItemSet const & rAttrs )
eState = rAttrs.GetItemState(SDRATTR_3DOBJ_MAT_SPECULAR);
if( eState != SfxItemState::DONTCARE )
{
- aColor = static_cast<const SvxColorItem&>(rAttrs.Get(SDRATTR_3DOBJ_MAT_SPECULAR)).GetValue();
+ aColor = rAttrs.Get(SDRATTR_3DOBJ_MAT_SPECULAR).GetValue();
SvxColorListBox* pLb = m_pLbMatSpecular;
if( aColor != pLb->GetSelectEntryColor() )
{
@@ -1555,7 +1555,7 @@ void Svx3DWin::Update( SfxItemSet const & rAttrs )
eState = rAttrs.GetItemState(SDRATTR_3DOBJ_MAT_SPECULAR_INTENSITY);
if( eState != SfxItemState::DONTCARE )
{
- sal_uInt16 nValue = static_cast<const SfxUInt16Item&>(rAttrs.Get(SDRATTR_3DOBJ_MAT_SPECULAR_INTENSITY)).GetValue();
+ sal_uInt16 nValue = rAttrs.Get(SDRATTR_3DOBJ_MAT_SPECULAR_INTENSITY).GetValue();
if( nValue != m_pMtrMatSpecularIntensity->GetValue() )
{
m_pMtrMatSpecularIntensity->SetValue( nValue );
@@ -1577,7 +1577,7 @@ void Svx3DWin::Update( SfxItemSet const & rAttrs )
eState = rAttrs.GetItemState(SDRATTR_3DSCENE_PERSPECTIVE);
if( eState != SfxItemState::DONTCARE )
{
- ProjectionType ePT = (ProjectionType)static_cast<const Svx3DPerspectiveItem&>(rAttrs.Get(SDRATTR_3DSCENE_PERSPECTIVE)).GetValue();
+ ProjectionType ePT = (ProjectionType)rAttrs.Get(SDRATTR_3DSCENE_PERSPECTIVE).GetValue();
if( ( !m_pBtnPerspective->IsChecked() && ePT == ProjectionType::Perspective ) ||
( m_pBtnPerspective->IsChecked() && ePT == ProjectionType::Parallel ) )
{
diff --git a/svx/source/engine3d/view3d1.cxx b/svx/source/engine3d/view3d1.cxx
index e4e38726ddb4..bfa2db5bc489 100644
--- a/svx/source/engine3d/view3d1.cxx
+++ b/svx/source/engine3d/view3d1.cxx
@@ -175,12 +175,12 @@ void E3dView::Set3DAttributes( const SfxItemSet& rAttr)
double E3dView::GetDefaultCamPosZ()
{
- return (double) static_cast<const SfxUInt32Item&>(mpModel->GetItemPool().GetDefaultItem(SDRATTR_3DSCENE_DISTANCE)).GetValue();
+ return (double) mpModel->GetItemPool().GetDefaultItem(SDRATTR_3DSCENE_DISTANCE).GetValue();
}
double E3dView::GetDefaultCamFocal()
{
- return (double) static_cast<const SfxUInt32Item&>(mpModel->GetItemPool().GetDefaultItem(SDRATTR_3DSCENE_FOCAL_LENGTH)).GetValue();
+ return (double) mpModel->GetItemPool().GetDefaultItem(SDRATTR_3DSCENE_FOCAL_LENGTH).GetValue();
}
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/sdr/primitive2d/sdrattributecreator.cxx b/svx/source/sdr/primitive2d/sdrattributecreator.cxx
index dc62cf66c067..41988f65d70f 100644
--- a/svx/source/sdr/primitive2d/sdrattributecreator.cxx
+++ b/svx/source/sdr/primitive2d/sdrattributecreator.cxx
@@ -886,7 +886,7 @@ namespace drawinglayer
{
// get perspective
css::drawing::ProjectionMode aProjectionMode(css::drawing::ProjectionMode_PARALLEL);
- const sal_uInt16 nProjectionValue(static_cast<const Svx3DPerspectiveItem&>(rSet.Get(SDRATTR_3DSCENE_PERSPECTIVE)).GetValue());
+ const sal_uInt16 nProjectionValue(rSet.Get(SDRATTR_3DSCENE_PERSPECTIVE).GetValue());
if(1 == nProjectionValue)
{
@@ -894,14 +894,14 @@ namespace drawinglayer
}
// get distance
- const double fDistance(static_cast<const SfxUInt32Item&>(rSet.Get(SDRATTR_3DSCENE_DISTANCE)).GetValue());
+ const double fDistance(rSet.Get(SDRATTR_3DSCENE_DISTANCE).GetValue());
// get shadow slant
- const double fShadowSlant(F_PI180 * static_cast<const SfxUInt16Item&>(rSet.Get(SDRATTR_3DSCENE_SHADOW_SLANT)).GetValue());
+ const double fShadowSlant(F_PI180 * rSet.Get(SDRATTR_3DSCENE_SHADOW_SLANT).GetValue());
// get shade mode
css::drawing::ShadeMode aShadeMode(css::drawing::ShadeMode_FLAT);
- const sal_uInt16 nShadeValue(static_cast<const Svx3DShadeModeItem&>(rSet.Get(SDRATTR_3DSCENE_SHADE_MODE)).GetValue());
+ const sal_uInt16 nShadeValue(rSet.Get(SDRATTR_3DSCENE_SHADE_MODE).GetValue());
if(1 == nShadeValue)
{
@@ -917,7 +917,7 @@ namespace drawinglayer
}
// get two sided lighting
- const bool bTwoSidedLighting(static_cast<const SfxBoolItem&>(rSet.Get(SDRATTR_3DSCENE_TWO_SIDED_LIGHTING)).GetValue());
+ const bool bTwoSidedLighting(rSet.Get(SDRATTR_3DSCENE_TWO_SIDED_LIGHTING).GetValue());
return attribute::SdrSceneAttribute(fDistance, fShadowSlant, aProjectionMode, aShadeMode, bTwoSidedLighting);
}
@@ -927,64 +927,64 @@ namespace drawinglayer
// extract lights from given SfxItemSet (from scene)
::std::vector< attribute::Sdr3DLightAttribute > aLightVector;
- if(static_cast<const SfxBoolItem&>(rSet.Get(SDRATTR_3DSCENE_LIGHTON_1)).GetValue())
+ if(rSet.Get(SDRATTR_3DSCENE_LIGHTON_1).GetValue())
{
- const basegfx::BColor aColor(static_cast<const SvxColorItem&>(rSet.Get(SDRATTR_3DSCENE_LIGHTCOLOR_1)).GetValue().getBColor());
- const basegfx::B3DVector aDirection(static_cast<const SvxB3DVectorItem&>(rSet.Get(SDRATTR_3DSCENE_LIGHTDIRECTION_1)).GetValue());
+ const basegfx::BColor aColor(rSet.Get(SDRATTR_3DSCENE_LIGHTCOLOR_1).GetValue().getBColor());
+ const basegfx::B3DVector aDirection(rSet.Get(SDRATTR_3DSCENE_LIGHTDIRECTION_1).GetValue());
aLightVector.emplace_back(aColor, aDirection, true);
}
- if(static_cast<const SfxBoolItem&>(rSet.Get(SDRATTR_3DSCENE_LIGHTON_2)).GetValue())
+ if(rSet.Get(SDRATTR_3DSCENE_LIGHTON_2).GetValue())
{
- const basegfx::BColor aColor(static_cast<const SvxColorItem&>(rSet.Get(SDRATTR_3DSCENE_LIGHTCOLOR_2)).GetValue().getBColor());
- const basegfx::B3DVector aDirection(static_cast<const SvxB3DVectorItem&>(rSet.Get(SDRATTR_3DSCENE_LIGHTDIRECTION_2)).GetValue());
+ const basegfx::BColor aColor(rSet.Get(SDRATTR_3DSCENE_LIGHTCOLOR_2).GetValue().getBColor());
+ const basegfx::B3DVector aDirection(rSet.Get(SDRATTR_3DSCENE_LIGHTDIRECTION_2).GetValue());
aLightVector.emplace_back(aColor, aDirection, false);
}
- if(static_cast<const SfxBoolItem&>(rSet.Get(SDRATTR_3DSCENE_LIGHTON_3)).GetValue())
+ if(rSet.Get(SDRATTR_3DSCENE_LIGHTON_3).GetValue())
{
- const basegfx::BColor aColor(static_cast<const SvxColorItem&>(rSet.Get(SDRATTR_3DSCENE_LIGHTCOLOR_3)).GetValue().getBColor());
- const basegfx::B3DVector aDirection(static_cast<const SvxB3DVectorItem&>(rSet.Get(SDRATTR_3DSCENE_LIGHTDIRECTION_3)).GetValue());
+ const basegfx::BColor aColor(rSet.Get(SDRATTR_3DSCENE_LIGHTCOLOR_3).GetValue().getBColor());
+ const basegfx::B3DVector aDirection(rSet.Get(SDRATTR_3DSCENE_LIGHTDIRECTION_3).GetValue());
aLightVector.emplace_back(aColor, aDirection, false);
}
- if(static_cast<const SfxBoolItem&>(rSet.Get(SDRATTR_3DSCENE_LIGHTON_4)).GetValue())
+ if(rSet.Get(SDRATTR_3DSCENE_LIGHTON_4).GetValue())
{
- const basegfx::BColor aColor(static_cast<const SvxColorItem&>(rSet.Get(SDRATTR_3DSCENE_LIGHTCOLOR_4)).GetValue().getBColor());
- const basegfx::B3DVector aDirection(static_cast<const SvxB3DVectorItem&>(rSet.Get(SDRATTR_3DSCENE_LIGHTDIRECTION_4)).GetValue());
+ const basegfx::BColor aColor(rSet.Get(SDRATTR_3DSCENE_LIGHTCOLOR_4).GetValue().getBColor());
+ const basegfx::B3DVector aDirection(rSet.Get(SDRATTR_3DSCENE_LIGHTDIRECTION_4).GetValue());
aLightVector.emplace_back(aColor, aDirection, false);
}
- if(static_cast<const SfxBoolItem&>(rSet.Get(SDRATTR_3DSCENE_LIGHTON_5)).GetValue())
+ if(rSet.Get(SDRATTR_3DSCENE_LIGHTON_5).GetValue())
{
- const basegfx::BColor aColor(static_cast<const SvxColorItem&>(rSet.Get(SDRATTR_3DSCENE_LIGHTCOLOR_5)).GetValue().getBColor());
- const basegfx::B3DVector aDirection(static_cast<const SvxB3DVectorItem&>(rSet.Get(SDRATTR_3DSCENE_LIGHTDIRECTION_5)).GetValue());
+ const basegfx::BColor aColor(rSet.Get(SDRATTR_3DSCENE_LIGHTCOLOR_5).GetValue().getBColor());
+ const basegfx::B3DVector aDirection(rSet.Get(SDRATTR_3DSCENE_LIGHTDIRECTION_5).GetValue());
aLightVector.emplace_back(aColor, aDirection, false);
}
- if(static_cast<const SfxBoolItem&>(rSet.Get(SDRATTR_3DSCENE_LIGHTON_6)).GetValue())
+ if(rSet.Get(SDRATTR_3DSCENE_LIGHTON_6).GetValue())
{
- const basegfx::BColor aColor(static_cast<const SvxColorItem&>(rSet.Get(SDRATTR_3DSCENE_LIGHTCOLOR_6)).GetValue().getBColor());
- const basegfx::B3DVector aDirection(static_cast<const SvxB3DVectorItem&>(rSet.Get(SDRATTR_3DSCENE_LIGHTDIRECTION_6)).GetValue());
+ const basegfx::BColor aColor(rSet.Get(SDRATTR_3DSCENE_LIGHTCOLOR_6).GetValue().getBColor());
+ const basegfx::B3DVector aDirection(rSet.Get(SDRATTR_3DSCENE_LIGHTDIRECTION_6).GetValue());
aLightVector.emplace_back(aColor, aDirection, false);
}
- if(static_cast<const SfxBoolItem&>(rSet.Get(SDRATTR_3DSCENE_LIGHTON_7)).GetValue())
+ if(rSet.Get(SDRATTR_3DSCENE_LIGHTON_7).GetValue())
{
- const basegfx::BColor aColor(static_cast<const SvxColorItem&>(rSet.Get(SDRATTR_3DSCENE_LIGHTCOLOR_7)).GetValue().getBColor());
- const basegfx::B3DVector aDirection(static_cast<const SvxB3DVectorItem&>(rSet.Get(SDRATTR_3DSCENE_LIGHTDIRECTION_7)).GetValue());
+ const basegfx::BColor aColor(rSet.Get(SDRATTR_3DSCENE_LIGHTCOLOR_7).GetValue().getBColor());
+ const basegfx::B3DVector aDirection(rSet.Get(SDRATTR_3DSCENE_LIGHTDIRECTION_7).GetValue());
aLightVector.emplace_back(aColor, aDirection, false);
}
- if(static_cast<const SfxBoolItem&>(rSet.Get(SDRATTR_3DSCENE_LIGHTON_8)).GetValue())
+ if(rSet.Get(SDRATTR_3DSCENE_LIGHTON_8).GetValue())
{
- const basegfx::BColor aColor(static_cast<const SvxColorItem&>(rSet.Get(SDRATTR_3DSCENE_LIGHTCOLOR_8)).GetValue().getBColor());
- const basegfx::B3DVector aDirection(static_cast<const SvxB3DVectorItem&>(rSet.Get(SDRATTR_3DSCENE_LIGHTDIRECTION_8)).GetValue());
+ const basegfx::BColor aColor(rSet.Get(SDRATTR_3DSCENE_LIGHTCOLOR_8).GetValue().getBColor());
+ const basegfx::B3DVector aDirection(rSet.Get(SDRATTR_3DSCENE_LIGHTDIRECTION_8).GetValue());
aLightVector.emplace_back(aColor, aDirection, false);
}
// get ambient color
- const Color aAmbientValue(static_cast<const SvxColorItem&>(rSet.Get(SDRATTR_3DSCENE_AMBIENTCOLOR)).GetValue());
+ const Color aAmbientValue(rSet.Get(SDRATTR_3DSCENE_AMBIENTCOLOR).GetValue());
const basegfx::BColor aAmbientLight(aAmbientValue.getBColor());
return attribute::SdrLightingAttribute(aAmbientLight, aLightVector);
diff --git a/svx/source/sdr/primitive3d/sdrattributecreator3d.cxx b/svx/source/sdr/primitive3d/sdrattributecreator3d.cxx
index 5a60993b9649..5fe17f59dbad 100644
--- a/svx/source/sdr/primitive3d/sdrattributecreator3d.cxx
+++ b/svx/source/sdr/primitive3d/sdrattributecreator3d.cxx
@@ -37,7 +37,7 @@ namespace drawinglayer
{
// get NormalsKind
css::drawing::NormalsKind aNormalsKind(css::drawing::NormalsKind_SPECIFIC);
- const sal_uInt16 nNormalsValue(static_cast<const Svx3DNormalsKindItem&>(rSet.Get(SDRATTR_3DOBJ_NORMALS_KIND)).GetValue());
+ const sal_uInt16 nNormalsValue(rSet.Get(SDRATTR_3DOBJ_NORMALS_KIND).GetValue());
if(1 == nNormalsValue)
{
@@ -49,11 +49,11 @@ namespace drawinglayer
}
// get NormalsInvert flag
- const bool bInvertNormals(static_cast<const SfxBoolItem&>(rSet.Get(SDRATTR_3DOBJ_NORMALS_INVERT)).GetValue());
+ const bool bInvertNormals(rSet.Get(SDRATTR_3DOBJ_NORMALS_INVERT).GetValue());
// get TextureProjectionX
css::drawing::TextureProjectionMode aTextureProjectionX(css::drawing::TextureProjectionMode_OBJECTSPECIFIC);
- const sal_uInt16 nTextureValueX(static_cast<const Svx3DTextureProjectionXItem&>(rSet.Get(SDRATTR_3DOBJ_TEXTURE_PROJ_X)).GetValue());
+ const sal_uInt16 nTextureValueX(rSet.Get(SDRATTR_3DOBJ_TEXTURE_PROJ_X).GetValue());
if(1 == nTextureValueX)
{
@@ -66,7 +66,7 @@ namespace drawinglayer
// get TextureProjectionY
css::drawing::TextureProjectionMode aTextureProjectionY(css::drawing::TextureProjectionMode_OBJECTSPECIFIC);
- const sal_uInt16 nTextureValueY(static_cast<const Svx3DTextureProjectionYItem&>(rSet.Get(SDRATTR_3DOBJ_TEXTURE_PROJ_Y)).GetValue());
+ const sal_uInt16 nTextureValueY(rSet.Get(SDRATTR_3DOBJ_TEXTURE_PROJ_Y).GetValue());
if(1 == nTextureValueY)
{
@@ -78,18 +78,18 @@ namespace drawinglayer
}
// get DoubleSided flag
- const bool bDoubleSided(static_cast<const SfxBoolItem&>(rSet.Get(SDRATTR_3DOBJ_DOUBLE_SIDED)).GetValue());
+ const bool bDoubleSided(rSet.Get(SDRATTR_3DOBJ_DOUBLE_SIDED).GetValue());
// get Shadow3D flag
- const bool bShadow3D(static_cast<const SfxBoolItem&>(rSet.Get(SDRATTR_3DOBJ_SHADOW_3D)).GetValue());
+ const bool bShadow3D(rSet.Get(SDRATTR_3DOBJ_SHADOW_3D).GetValue());
// get TextureFilter flag
- const bool bTextureFilter(static_cast<const SfxBoolItem&>(rSet.Get(SDRATTR_3DOBJ_TEXTURE_FILTER)).GetValue());
+ const bool bTextureFilter(rSet.Get(SDRATTR_3DOBJ_TEXTURE_FILTER).GetValue());
// get texture kind
// TextureKind: 1 == Base3DTextureLuminance, 2 == Base3DTextureIntensity, 3 == Base3DTextureColor
css::drawing::TextureKind2 aTextureKind(css::drawing::TextureKind2_LUMINANCE);
- const sal_uInt16 nTextureKind(static_cast<const Svx3DTextureKindItem&>(rSet.Get(SDRATTR_3DOBJ_TEXTURE_KIND)).GetValue());
+ const sal_uInt16 nTextureKind(rSet.Get(SDRATTR_3DOBJ_TEXTURE_KIND).GetValue());
if(2 == nTextureKind)
{
@@ -103,7 +103,7 @@ namespace drawinglayer
// get texture mode
// TextureMode: 1 == Base3DTextureReplace, 2 == Base3DTextureModulate, 3 == Base3DTextureBlend
css::drawing::TextureMode aTextureMode(css::drawing::TextureMode_REPLACE);
- const sal_uInt16 nTextureMode(static_cast<const Svx3DTextureModeItem&>(rSet.Get(SDRATTR_3DOBJ_TEXTURE_MODE)).GetValue());
+ const sal_uInt16 nTextureMode(rSet.Get(SDRATTR_3DOBJ_TEXTURE_MODE).GetValue());
if(2 == nTextureMode)
{
@@ -118,13 +118,13 @@ namespace drawinglayer
const ::basegfx::BColor aObjectColor(rSet.Get(XATTR_FILLCOLOR).GetColorValue().getBColor());
// get specular color
- const ::basegfx::BColor aSpecular(static_cast<const SvxColorItem&>(rSet.Get(SDRATTR_3DOBJ_MAT_SPECULAR)).GetValue().getBColor());
+ const ::basegfx::BColor aSpecular(rSet.Get(SDRATTR_3DOBJ_MAT_SPECULAR).GetValue().getBColor());
// get emissive color
- const ::basegfx::BColor aEmission(static_cast<const SvxColorItem&>(rSet.Get(SDRATTR_3DOBJ_MAT_EMISSION)).GetValue().getBColor());
+ const ::basegfx::BColor aEmission(rSet.Get(SDRATTR_3DOBJ_MAT_EMISSION).GetValue().getBColor());
// get specular intensity
- sal_uInt16 nSpecularIntensity(static_cast<const SfxUInt16Item&>(rSet.Get(SDRATTR_3DOBJ_MAT_SPECULAR_INTENSITY)).GetValue());
+ sal_uInt16 nSpecularIntensity(rSet.Get(SDRATTR_3DOBJ_MAT_SPECULAR_INTENSITY).GetValue());
if(nSpecularIntensity > 128)
{
@@ -132,7 +132,7 @@ namespace drawinglayer
}
// get reduced line geometry
- const bool bReducedLineGeometry(static_cast<const Svx3DReducedLineGeometryItem&>(rSet.Get(SDRATTR_3DOBJ_REDUCED_LINE_GEOMETRY)).GetValue());
+ const bool bReducedLineGeometry(rSet.Get(SDRATTR_3DOBJ_REDUCED_LINE_GEOMETRY).GetValue());
// prepare material
attribute::MaterialAttribute3D aMaterial(aObjectColor, aSpecular, aEmission, nSpecularIntensity);
diff --git a/svx/source/svdraw/svdoashp.cxx b/svx/source/svdraw/svdoashp.cxx
index d191331917ab..bfc41acfd63c 100644
--- a/svx/source/svdraw/svdoashp.cxx
+++ b/svx/source/svdraw/svdoashp.cxx
@@ -171,11 +171,11 @@ static MSO_SPT ImpGetCustomShapeType( const SdrObjCustomShape& rCustoShape )
{
MSO_SPT eRetValue = mso_sptNil;
- OUString aEngine( static_cast<const SfxStringItem&>( rCustoShape.GetMergedItem( SDRATTR_CUSTOMSHAPE_ENGINE ) ).GetValue() );
+ OUString aEngine( rCustoShape.GetMergedItem( SDRATTR_CUSTOMSHAPE_ENGINE ).GetValue() );
if ( aEngine.isEmpty() || aEngine == "com.sun.star.drawing.EnhancedCustomShapeEngine" )
{
OUString sShapeType;
- const SdrCustomShapeGeometryItem& rGeometryItem( static_cast<const SdrCustomShapeGeometryItem&>(rCustoShape.GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY )) );
+ const SdrCustomShapeGeometryItem& rGeometryItem( rCustoShape.GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ) );
const Any* pAny = rGeometryItem.GetPropertyValueByName( "Type" );
if ( pAny && ( *pAny >>= sShapeType ) )
eRetValue = EnhancedCustomShapeTypeNames::Get( sShapeType );
@@ -410,7 +410,7 @@ Reference< XCustomShapeEngine > const & SdrObjCustomShape::GetCustomShapeEngine(
if (mxCustomShapeEngine.is())
return mxCustomShapeEngine;
- OUString aEngine(static_cast<const SfxStringItem&>(GetMergedItem( SDRATTR_CUSTOMSHAPE_ENGINE )).GetValue());
+ OUString aEngine(GetMergedItem( SDRATTR_CUSTOMSHAPE_ENGINE ).GetValue());
if ( aEngine.isEmpty() )
aEngine = "com.sun.star.drawing.EnhancedCustomShapeEngine";
@@ -474,7 +474,7 @@ bool SdrObjCustomShape::IsTextPath() const
{
const OUString sTextPath( "TextPath" );
bool bTextPathOn = false;
- const SdrCustomShapeGeometryItem& rGeometryItem = static_cast<const SdrCustomShapeGeometryItem&>(GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ));
+ const SdrCustomShapeGeometryItem& rGeometryItem = GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY );
const Any* pAny = rGeometryItem.GetPropertyValueByName( sTextPath, sTextPath );
if ( pAny )
*pAny >>= bTextPathOn;
@@ -486,7 +486,7 @@ bool SdrObjCustomShape::UseNoFillStyle() const
bool bRet = false;
OUString sShapeType;
const OUString sType( "Type" );
- const SdrCustomShapeGeometryItem& rGeometryItem( static_cast<const SdrCustomShapeGeometryItem&>(GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ) ) );
+ const SdrCustomShapeGeometryItem& rGeometryItem( GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ) );
const Any* pAny = rGeometryItem.GetPropertyValueByName( sType );
if ( pAny )
*pAny >>= sShapeType;
@@ -498,7 +498,7 @@ bool SdrObjCustomShape::UseNoFillStyle() const
bool SdrObjCustomShape::IsMirroredX() const
{
bool bMirroredX = false;
- SdrCustomShapeGeometryItem aGeometryItem( static_cast<const SdrCustomShapeGeometryItem&>(GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ) ) );
+ SdrCustomShapeGeometryItem aGeometryItem( GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ) );
const OUString sMirroredX( "MirroredX" );
css::uno::Any* pAny = aGeometryItem.GetPropertyValueByName( sMirroredX );
if ( pAny )
@@ -508,7 +508,7 @@ bool SdrObjCustomShape::IsMirroredX() const
bool SdrObjCustomShape::IsMirroredY() const
{
bool bMirroredY = false;
- SdrCustomShapeGeometryItem aGeometryItem( static_cast<const SdrCustomShapeGeometryItem&>(GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ) ) );
+ SdrCustomShapeGeometryItem aGeometryItem( GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ) );
const OUString sMirroredY( "MirroredY" );
css::uno::Any* pAny = aGeometryItem.GetPropertyValueByName( sMirroredY );
if ( pAny )
@@ -517,7 +517,7 @@ bool SdrObjCustomShape::IsMirroredY() const
}
void SdrObjCustomShape::SetMirroredX( const bool bMirrorX )
{
- SdrCustomShapeGeometryItem aGeometryItem( static_cast<const SdrCustomShapeGeometryItem&>(GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ) ) );
+ SdrCustomShapeGeometryItem aGeometryItem( GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ) );
const OUString sMirroredX( "MirroredX" );
PropertyValue aPropVal;
aPropVal.Name = sMirroredX;
@@ -527,7 +527,7 @@ void SdrObjCustomShape::SetMirroredX( const bool bMirrorX )
}
void SdrObjCustomShape::SetMirroredY( const bool bMirrorY )
{
- SdrCustomShapeGeometryItem aGeometryItem( static_cast<const SdrCustomShapeGeometryItem&>(GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ) ) );
+ SdrCustomShapeGeometryItem aGeometryItem( GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ) );
const OUString sMirroredY( "MirroredY" );
PropertyValue aPropVal;
aPropVal.Name = sMirroredY;
@@ -539,7 +539,7 @@ void SdrObjCustomShape::SetMirroredY( const bool bMirrorY )
double SdrObjCustomShape::GetExtraTextRotation( const bool bPreRotation ) const
{
const css::uno::Any* pAny;
- const SdrCustomShapeGeometryItem& rGeometryItem = static_cast<const SdrCustomShapeGeometryItem&>(GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ));
+ const SdrCustomShapeGeometryItem& rGeometryItem = GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY );
const OUString sTextRotateAngle( "TextRotateAngle" );
const OUString sTextPreRotateAngle( "TextPreRotateAngle" );
pAny = rGeometryItem.GetPropertyValueByName( bPreRotation ? sTextPreRotateAngle : sTextRotateAngle );
@@ -842,7 +842,7 @@ void SdrObjCustomShape::MergeDefaultAttributes( const OUString* pType )
PropertyValue aPropVal;
OUString sShapeType;
const OUString sType( "Type" );
- SdrCustomShapeGeometryItem aGeometryItem( static_cast<const SdrCustomShapeGeometryItem&>(GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY )) );
+ SdrCustomShapeGeometryItem aGeometryItem( GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ) );
if ( pType && !pType->isEmpty() )
{
sal_Int32 nType = pType->toInt32();
@@ -1086,7 +1086,7 @@ bool SdrObjCustomShape::IsDefaultGeometry( const DefaultType eDefaultType ) cons
PropertyValue aPropVal;
OUString sShapeType;
const OUString sType( "Type" );
- const SdrCustomShapeGeometryItem aGeometryItem( static_cast<const SdrCustomShapeGeometryItem&>(GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY )) );
+ const SdrCustomShapeGeometryItem aGeometryItem( GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ) );
const Any *pAny = aGeometryItem.GetPropertyValueByName( sType );
if ( pAny )
@@ -2885,7 +2885,7 @@ void SdrObjCustomShape::SaveGeoData(SdrObjGeoData& rGeo) const
rAGeo.bMirroredY = IsMirroredY();
const OUString sAdjustmentValues( "AdjustmentValues" );
- const Any* pAny = static_cast<const SdrCustomShapeGeometryItem&>( GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ) ).GetPropertyValueByName( sAdjustmentValues );
+ const Any* pAny = GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ).GetPropertyValueByName( sAdjustmentValues );
if ( pAny )
*pAny >>= rAGeo.aAdjustmentSeq;
}
@@ -2898,7 +2898,7 @@ void SdrObjCustomShape::RestGeoData(const SdrObjGeoData& rGeo)
SetMirroredX( rAGeo.bMirroredX );
SetMirroredY( rAGeo.bMirroredY );
- SdrCustomShapeGeometryItem rGeometryItem = static_cast<const SdrCustomShapeGeometryItem&>(GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ));
+ SdrCustomShapeGeometryItem rGeometryItem = GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY );
const OUString sAdjustmentValues( "AdjustmentValues" );
PropertyValue aPropVal;
aPropVal.Name = sAdjustmentValues;
@@ -3174,13 +3174,13 @@ void SdrObjCustomShape::impl_setUnoShape(const uno::Reference<uno::XInterface>&
OUString SdrObjCustomShape::GetCustomShapeName()
{
OUString sShapeName;
- OUString aEngine( static_cast<const SfxStringItem&>(GetMergedItem( SDRATTR_CUSTOMSHAPE_ENGINE )).GetValue() );
+ OUString aEngine( GetMergedItem( SDRATTR_CUSTOMSHAPE_ENGINE ).GetValue() );
if ( aEngine.isEmpty()
|| aEngine == "com.sun.star.drawing.EnhancedCustomShapeEngine" )
{
OUString sShapeType;
const OUString sType("Type");
- const SdrCustomShapeGeometryItem& rGeometryItem( static_cast<const SdrCustomShapeGeometryItem&>( GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ) ) );
+ const SdrCustomShapeGeometryItem& rGeometryItem( GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ) );
const Any* pAny = rGeometryItem.GetPropertyValueByName( sType );
if ( pAny && ( *pAny >>= sShapeType ) )
sShapeName = EnhancedCustomShapeTypeNames::GetAccName( sShapeType );
diff --git a/svx/source/table/tablecontroller.cxx b/svx/source/table/tablecontroller.cxx
index 7f1dbc070254..bcbfa618ffcc 100644
--- a/svx/source/table/tablecontroller.cxx
+++ b/svx/source/table/tablecontroller.cxx
@@ -882,7 +882,7 @@ namespace
SvxBoxItem mergeDrawinglayerTextDistancesAndSvxBoxItem(const SfxItemSet& rAttrSet)
{
// merge drawing layer text distance items into SvxBoxItem used by the dialog
- SvxBoxItem aBoxItem( static_cast< const SvxBoxItem& >( rAttrSet.Get( SDRATTR_TABLE_BORDER ) ) );
+ SvxBoxItem aBoxItem( rAttrSet.Get( SDRATTR_TABLE_BORDER ) );
aBoxItem.SetDistance( sal::static_int_cast< sal_uInt16 >( rAttrSet.Get(SDRATTR_TEXT_LEFTDIST).GetValue()), SvxBoxItemLine::LEFT );
aBoxItem.SetDistance( sal::static_int_cast< sal_uInt16 >( rAttrSet.Get(SDRATTR_TEXT_RIGHTDIST).GetValue()), SvxBoxItemLine::RIGHT );
aBoxItem.SetDistance( sal::static_int_cast< sal_uInt16 >( rAttrSet.Get(SDRATTR_TEXT_UPPERDIST).GetValue()), SvxBoxItemLine::TOP );
@@ -906,7 +906,7 @@ void SvxTableController::onFormatTable( SfxRequest const & rReq )
// merge drawing layer text distance items into SvxBoxItem used by the dialog
SvxBoxItem aBoxItem(mergeDrawinglayerTextDistancesAndSvxBoxItem(aNewAttr));
- SvxBoxInfoItem aBoxInfoItem( static_cast< const SvxBoxInfoItem& >( aNewAttr.Get( SDRATTR_TABLE_BORDER_INNER ) ) );
+ SvxBoxInfoItem aBoxInfoItem( aNewAttr.Get( SDRATTR_TABLE_BORDER_INNER ) );
MergeAttrFromSelectedCells(aNewAttr, false);
FillCommonBorderAttrFromSelectedCells( aBoxItem, aBoxInfoItem );
@@ -934,7 +934,7 @@ void SvxTableController::onFormatTable( SfxRequest const & rReq )
aNewSet.Put(aBoxInfoItem);
}
- SvxBoxItem aNewBoxItem( static_cast< const SvxBoxItem& >( aNewSet.Get( SDRATTR_TABLE_BORDER ) ) );
+ SvxBoxItem aNewBoxItem( aNewSet.Get( SDRATTR_TABLE_BORDER ) );
if( aNewBoxItem.GetDistance( SvxBoxItemLine::LEFT ) != aBoxItem.GetDistance( SvxBoxItemLine::LEFT ) )
aNewSet.Put(makeSdrTextLeftDistItem( aNewBoxItem.GetDistance( SvxBoxItemLine::LEFT ) ) );
@@ -2415,11 +2415,11 @@ void SvxTableController::ApplyBorderAttr( const SfxItemSet& rAttr )
{
const SvxBoxItem* pBoxItem = nullptr;
if(SfxItemState::SET == rAttr.GetItemState(SDRATTR_TABLE_BORDER, false) )
- pBoxItem = dynamic_cast< const SvxBoxItem* >( &rAttr.Get( SDRATTR_TABLE_BORDER ) );
+ pBoxItem = &rAttr.Get( SDRATTR_TABLE_BORDER );
const SvxBoxInfoItem* pBoxInfoItem = nullptr;
if(SfxItemState::SET == rAttr.GetItemState(SDRATTR_TABLE_BORDER_INNER, false) )
- pBoxInfoItem = dynamic_cast< const SvxBoxInfoItem* >( &rAttr.Get( SDRATTR_TABLE_BORDER_INNER ) );
+ pBoxInfoItem = &rAttr.Get( SDRATTR_TABLE_BORDER_INNER );
const SvxColorItem* pLineColorItem = nullptr;
if(SfxItemState::SET == rAttr.GetItemState(SID_FRAME_LINECOLOR, false) )
@@ -2461,7 +2461,7 @@ void SvxTableController::ApplyBorderAttr( const SfxItemSet& rAttr )
continue;
const SfxItemSet& rSet = xCell->GetItemSet();
- const SvxBoxItem* pOldOuter = static_cast<const SvxBoxItem*>(&rSet.Get( SDRATTR_TABLE_BORDER ));
+ const SvxBoxItem* pOldOuter = &rSet.Get( SDRATTR_TABLE_BORDER );
SvxBoxItem aNewFrame( *pOldOuter );
diff --git a/svx/source/toolbars/extrusionbar.cxx b/svx/source/toolbars/extrusionbar.cxx
index 791f4ee4a729..22321bbb1aab 100644
--- a/svx/source/toolbars/extrusionbar.cxx
+++ b/svx/source/toolbars/extrusionbar.cxx
@@ -545,7 +545,7 @@ void ExtrusionBar::execute( SdrView* pSdrView, SfxRequest const & rReq, SfxBindi
pSdrView->BegUndo( aStr );
pSdrView->AddUndo( pSdrView->GetModel()->GetSdrUndoFactory().CreateUndoAttrObject( *pObj ) );
}
- SdrCustomShapeGeometryItem aGeometryItem( static_cast<const SdrCustomShapeGeometryItem&>(pObj->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY )));
+ SdrCustomShapeGeometryItem aGeometryItem( pObj->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ) );
impl_execute( rReq, aGeometryItem, pObj );
pObj->SetMergedItem( aGeometryItem );
pObj->BroadcastObjectChange();
@@ -625,7 +625,7 @@ void getExtrusionDirectionState( SdrView const * pSdrView, SfxItemSet& rSet )
SdrObject* pObj = rMarkList.GetMark(i)->GetMarkedSdrObj();
if( dynamic_cast<const SdrObjCustomShape*>( pObj) != nullptr )
{
- const SdrCustomShapeGeometryItem aGeometryItem( static_cast<const SdrCustomShapeGeometryItem&>(pObj->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY )) );
+ const SdrCustomShapeGeometryItem aGeometryItem( pObj->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ) );
// see if this is an extruded customshape
if( !bHasCustomShape )
@@ -775,7 +775,7 @@ void getExtrusionProjectionState( SdrView const * pSdrView, SfxItemSet& rSet )
// see if this is an extruded customshape
if( !bHasCustomShape )
{
- const SdrCustomShapeGeometryItem aGeometryItem( static_cast<const SdrCustomShapeGeometryItem&>(pObj->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY )) );
+ const SdrCustomShapeGeometryItem aGeometryItem( pObj->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ) );
const Any* pAny_ = aGeometryItem.GetPropertyValueByName( sExtrusion, sExtrusion );
if( pAny_ )
*pAny_ >>= bHasCustomShape;
@@ -784,7 +784,7 @@ void getExtrusionProjectionState( SdrView const * pSdrView, SfxItemSet& rSet )
continue;
}
- const SdrCustomShapeGeometryItem aGeometryItem( static_cast<const SdrCustomShapeGeometryItem&>(pObj->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY )) );
+ const SdrCustomShapeGeometryItem aGeometryItem( pObj->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ) );
bool bParallel = true;
pAny = aGeometryItem.GetPropertyValueByName( sExtrusion, "ProjectionMode" );
@@ -827,7 +827,7 @@ void getExtrusionSurfaceState( SdrView const * pSdrView, SfxItemSet& rSet )
SdrObject* pObj = rMarkList.GetMark(i)->GetMarkedSdrObj();
if( dynamic_cast<const SdrObjCustomShape*>( pObj) != nullptr )
{
- const SdrCustomShapeGeometryItem aGeometryItem( static_cast<const SdrCustomShapeGeometryItem&>(pObj->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY )) );
+ const SdrCustomShapeGeometryItem aGeometryItem( pObj->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ) );
// see if this is an extruded customshape
if( !bHasCustomShape )
@@ -912,7 +912,7 @@ void getExtrusionDepthState( SdrView const * pSdrView, SfxItemSet& rSet )
SdrObject* pObj = rMarkList.GetMark(i)->GetMarkedSdrObj();
if( dynamic_cast<const SdrObjCustomShape*>( pObj) != nullptr )
{
- const SdrCustomShapeGeometryItem aGeometryItem( static_cast<const SdrCustomShapeGeometryItem&>(pObj->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY )) );
+ const SdrCustomShapeGeometryItem aGeometryItem( pObj->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ) );
// see if this is an extruded customshape
if( !bHasCustomShape )
@@ -996,7 +996,7 @@ void getExtrusionLightingDirectionState( SdrView const * pSdrView, SfxItemSet& r
SdrObject* pObj = rMarkList.GetMark(i)->GetMarkedSdrObj();
if( dynamic_cast<const SdrObjCustomShape*>( pObj) != nullptr )
{
- const SdrCustomShapeGeometryItem aGeometryItem( static_cast<const SdrCustomShapeGeometryItem&>(pObj->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY )) );
+ const SdrCustomShapeGeometryItem aGeometryItem( pObj->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ) );
// see if this is an extruded customshape
if( !bHasCustomShape )
@@ -1070,7 +1070,7 @@ void getExtrusionLightingIntensityState( SdrView const * pSdrView, SfxItemSet& r
SdrObject* pObj = rMarkList.GetMark(i)->GetMarkedSdrObj();
if( dynamic_cast<const SdrObjCustomShape*>( pObj) != nullptr )
{
- const SdrCustomShapeGeometryItem aGeometryItem( static_cast<const SdrCustomShapeGeometryItem&>(pObj->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY )) );
+ const SdrCustomShapeGeometryItem aGeometryItem( pObj->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ) );
// see if this is an extruded customshape
if( !bHasCustomShape )
@@ -1139,7 +1139,7 @@ void getExtrusionColorState( SdrView const * pSdrView, SfxItemSet& rSet )
SdrObject* pObj = rMarkList.GetMark(i)->GetMarkedSdrObj();
if( dynamic_cast<const SdrObjCustomShape*>( pObj) != nullptr )
{
- const SdrCustomShapeGeometryItem aGeometryItem( static_cast<const SdrCustomShapeGeometryItem&>(pObj->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY )) );
+ const SdrCustomShapeGeometryItem aGeometryItem( pObj->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ) );
// see if this is an extruded customshape
if( !bHasCustomShape )
@@ -1207,7 +1207,7 @@ bool checkForSelectedCustomShapes( SdrView const * pSdrView, bool bOnlyExtruded
{
if( bOnlyExtruded )
{
- const SdrCustomShapeGeometryItem aGeometryItem( static_cast<const SdrCustomShapeGeometryItem&>(pObj->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ) ));
+ const SdrCustomShapeGeometryItem aGeometryItem( pObj->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ) );
const Any* pAny = aGeometryItem.GetPropertyValueByName( sExtrusion, sExtrusion );
if( pAny )
*pAny >>= bFound;
diff --git a/svx/source/toolbars/fontworkbar.cxx b/svx/source/toolbars/fontworkbar.cxx
index 161136f3482e..af8117c7f7d2 100644
--- a/svx/source/toolbars/fontworkbar.cxx
+++ b/svx/source/toolbars/fontworkbar.cxx
@@ -151,7 +151,7 @@ void SetFontWorkShapeTypeState( SdrView const * pSdrView, SfxItemSet& rSet )
SdrObject* pObj = rMarkList.GetMark( i )->GetMarkedSdrObj();
if( dynamic_cast<const SdrObjCustomShape*>( pObj) != nullptr )
{
- const SdrCustomShapeGeometryItem aGeometryItem( static_cast<const SdrCustomShapeGeometryItem&>(pObj->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY )));
+ const SdrCustomShapeGeometryItem aGeometryItem( pObj->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ) );
const Any* pAny = aGeometryItem.GetPropertyValueByName( "Type" );
if( pAny )
{
@@ -239,7 +239,7 @@ bool checkForSelectedFontWork( SdrView const * pSdrView, sal_uInt32& nCheckStatu
SdrObject* pObj = rMarkList.GetMark(i)->GetMarkedSdrObj();
if( dynamic_cast<const SdrObjCustomShape*>( pObj) != nullptr )
{
- const SdrCustomShapeGeometryItem aGeometryItem( static_cast<const SdrCustomShapeGeometryItem&>(pObj->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY )));
+ const SdrCustomShapeGeometryItem aGeometryItem( pObj->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ) );
const Any* pAny = aGeometryItem.GetPropertyValueByName( sTextPath, sTextPath );
if( pAny )
*pAny >>= bFound;
@@ -362,7 +362,7 @@ void GetGeometryForCustomShape( SdrCustomShapeGeometryItem& rGeometryItem, const
if( pSourceObj )
{
PropertyValue aPropVal_;
- const SdrCustomShapeGeometryItem& rSourceGeometry = static_cast<const SdrCustomShapeGeometryItem&>(pSourceObj->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ));
+ const SdrCustomShapeGeometryItem& rSourceGeometry = pSourceObj->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY );
const css::uno::Any* pAny = rSourceGeometry.GetPropertyValueByName( sType );
if ( pAny )
{
@@ -461,7 +461,7 @@ void FontworkBar::execute( SdrView* pSdrView, SfxRequest const & rReq, SfxBindin
pSdrView->BegUndo( aStr );
pSdrView->AddUndo( pSdrView->GetModel()->GetSdrUndoFactory().CreateUndoAttrObject( *pObj ) );
}
- SdrCustomShapeGeometryItem aGeometryItem( static_cast<const SdrCustomShapeGeometryItem&>(pObj->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY )));
+ SdrCustomShapeGeometryItem aGeometryItem( pObj->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ) );
GetGeometryForCustomShape( aGeometryItem, aCustomShape );
pObj->SetMergedItem( aGeometryItem );
@@ -539,7 +539,7 @@ void FontworkBar::execute( SdrView* pSdrView, SfxRequest const & rReq, SfxBindin
pSdrView->BegUndo( aStr );
pSdrView->AddUndo( pSdrView->GetModel()->GetSdrUndoFactory().CreateUndoAttrObject( *pObj ) );
}
- SdrCustomShapeGeometryItem aGeometryItem( static_cast<const SdrCustomShapeGeometryItem&>(pObj->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY )));
+ SdrCustomShapeGeometryItem aGeometryItem( pObj->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ) );
impl_execute( rReq, aGeometryItem, pObj );
pObj->SetMergedItem( aGeometryItem );
pObj->BroadcastObjectChange();
diff --git a/svx/source/unodraw/unoprov.cxx b/svx/source/unodraw/unoprov.cxx
index 24358b2f41b0..797870a01a5c 100644
--- a/svx/source/unodraw/unoprov.cxx
+++ b/svx/source/unodraw/unoprov.cxx
@@ -35,6 +35,7 @@
#include <svx/unoapi.hxx>
#include <editeng/unotext.hxx>
#include <svx/unoshprp.hxx>
+#include <svx/svx3ditems.hxx>
#include <editeng/editeng.hxx>
#include <svx/globl3d.hxx>
#include <svx/strings.hrc>
diff --git a/svx/source/unodraw/unoshap3.cxx b/svx/source/unodraw/unoshap3.cxx
index 8b9d1b3debc3..db8fbdd03dd4 100644
--- a/svx/source/unodraw/unoshap3.cxx
+++ b/svx/source/unodraw/unoshap3.cxx
@@ -341,9 +341,9 @@ bool Svx3DSceneObject::setPropertyValueImpl( const OUString& rName, const SfxIte
const SfxItemSet& rSceneSet = pScene->GetMergedItemSet();
double fCamPosZ =
- (double)static_cast<const SfxUInt32Item&>(rSceneSet.Get(SDRATTR_3DSCENE_DISTANCE)).GetValue();
+ (double)rSceneSet.Get(SDRATTR_3DSCENE_DISTANCE).GetValue();
double fCamFocal =
- (double)static_cast<const SfxUInt32Item&>(rSceneSet.Get(SDRATTR_3DSCENE_FOCAL_LENGTH)).GetValue();
+ (double)rSceneSet.Get(SDRATTR_3DSCENE_FOCAL_LENGTH).GetValue();
aCam.SetAutoAdjustProjection(false);
aCam.SetViewWindow(- fW / 2, - fH / 2, fW, fH);
diff --git a/sw/source/filter/ww8/ww8par.cxx b/sw/source/filter/ww8/ww8par.cxx
index 4476ffdf1573..947a1e762ec4 100644
--- a/sw/source/filter/ww8/ww8par.cxx
+++ b/sw/source/filter/ww8/ww8par.cxx
@@ -922,7 +922,7 @@ SdrObject* SwMSDffManager::ProcessObj(SvStream& rSt,
if ( !::basegfx::fTools::equalZero( fExtraTextRotation ) )
{
fExtraTextRotation /= 100.0;
- SdrCustomShapeGeometryItem aGeometryItem( static_cast<const SdrCustomShapeGeometryItem&>(pCustomShape->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY )) );
+ SdrCustomShapeGeometryItem aGeometryItem( pCustomShape->GetMergedItem( SDRATTR_CUSTOMSHAPE_GEOMETRY ) );
const OUString sTextRotateAngle( "TextRotateAngle" );
css::beans::PropertyValue aPropVal;
aPropVal.Name = sTextRotateAngle;
diff --git a/sw/source/uibase/shells/drawsh.cxx b/sw/source/uibase/shells/drawsh.cxx
index eb33d5ebfb0d..5b3ecc18b3d3 100644
--- a/sw/source/uibase/shells/drawsh.cxx
+++ b/sw/source/uibase/shells/drawsh.cxx
@@ -496,7 +496,7 @@ void SwDrawShell::GetState(SfxItemSet& rSet)
{
if (SdrObjCustomShape* pCustomShape = dynamic_cast<SdrObjCustomShape*>( pObj) )
{
- const SdrCustomShapeGeometryItem& rGeometryItem = static_cast<const SdrCustomShapeGeometryItem&>(pCustomShape->GetMergedItem(SDRATTR_CUSTOMSHAPE_GEOMETRY));
+ const SdrCustomShapeGeometryItem& rGeometryItem = pCustomShape->GetMergedItem(SDRATTR_CUSTOMSHAPE_GEOMETRY);
if (const uno::Any* pAny = rGeometryItem.GetPropertyValueByName("Type"))
// But still disallow fontwork shapes.
bDisable = pAny->get<OUString>().startsWith("fontwork-");