Kaydet (Commit) 0a8d96b7 authored tarafından Stephan Bergmann's avatar Stephan Bergmann

SdrCustomShapeEngine/DataItem are just SfxStringItem

Change-Id: I94f8c268781f5a5b4da9da78af183adefc0c2925
üst fe51d68f
...@@ -31,18 +31,6 @@ ...@@ -31,18 +31,6 @@
#include <map> #include <map>
#include <unordered_map> #include <unordered_map>
class SdrCustomShapeEngineItem : public SfxStringItem
{
public :
SdrCustomShapeEngineItem();
};
class SdrCustomShapeDataItem : public SfxStringItem
{
public :
SdrCustomShapeDataItem();
};
class SVX_DLLPUBLIC SdrCustomShapeGeometryItem : public SfxPoolItem class SVX_DLLPUBLIC SdrCustomShapeGeometryItem : public SfxPoolItem
{ {
public: public:
......
...@@ -23,14 +23,6 @@ ...@@ -23,14 +23,6 @@
using namespace ::std; using namespace ::std;
using namespace com::sun::star; using namespace com::sun::star;
SdrCustomShapeEngineItem::SdrCustomShapeEngineItem()
: SfxStringItem( SDRATTR_CUSTOMSHAPE_ENGINE, "" )
{}
SdrCustomShapeDataItem::SdrCustomShapeDataItem()
: SfxStringItem( SDRATTR_CUSTOMSHAPE_DATA, "" )
{}
TYPEINIT1_FACTORY( SdrCustomShapeGeometryItem, SfxPoolItem , new SdrCustomShapeGeometryItem); TYPEINIT1_FACTORY( SdrCustomShapeGeometryItem, SfxPoolItem , new SdrCustomShapeGeometryItem);
SdrCustomShapeGeometryItem::SdrCustomShapeGeometryItem() SdrCustomShapeGeometryItem::SdrCustomShapeGeometryItem()
......
...@@ -302,8 +302,8 @@ SdrItemPool::SdrItemPool( ...@@ -302,8 +302,8 @@ SdrItemPool::SdrItemPool(
mppLocalPoolDefaults[ SDRATTR_3DSCENE_LIGHTDIRECTION_8 - SDRATTR_START ] = new SvxB3DVectorItem(SDRATTR_3DSCENE_LIGHTDIRECTION_8, basegfx::B3DVector(0.0,0.0,1.0)); mppLocalPoolDefaults[ SDRATTR_3DSCENE_LIGHTDIRECTION_8 - SDRATTR_START ] = new SvxB3DVectorItem(SDRATTR_3DSCENE_LIGHTDIRECTION_8, basegfx::B3DVector(0.0,0.0,1.0));
mppLocalPoolDefaults[ SDRATTR_3DSCENE_SHADOW_SLANT - SDRATTR_START ] = new SfxUInt16Item(SDRATTR_3DSCENE_SHADOW_SLANT, 0); mppLocalPoolDefaults[ SDRATTR_3DSCENE_SHADOW_SLANT - SDRATTR_START ] = new SfxUInt16Item(SDRATTR_3DSCENE_SHADOW_SLANT, 0);
mppLocalPoolDefaults[ SDRATTR_3DSCENE_SHADE_MODE - SDRATTR_START ] = new Svx3DShadeModeItem; mppLocalPoolDefaults[ SDRATTR_3DSCENE_SHADE_MODE - SDRATTR_START ] = new Svx3DShadeModeItem;
mppLocalPoolDefaults[ SDRATTR_CUSTOMSHAPE_ENGINE - SDRATTR_START ] = new SdrCustomShapeEngineItem; mppLocalPoolDefaults[ SDRATTR_CUSTOMSHAPE_ENGINE - SDRATTR_START ] = new SfxStringItem(SDRATTR_CUSTOMSHAPE_ENGINE, "");
mppLocalPoolDefaults[ SDRATTR_CUSTOMSHAPE_DATA - SDRATTR_START ] = new SdrCustomShapeDataItem; mppLocalPoolDefaults[ SDRATTR_CUSTOMSHAPE_DATA - SDRATTR_START ] = new SfxStringItem(SDRATTR_CUSTOMSHAPE_DATA, "");
mppLocalPoolDefaults[ SDRATTR_CUSTOMSHAPE_GEOMETRY - SDRATTR_START ] = new SdrCustomShapeGeometryItem; mppLocalPoolDefaults[ SDRATTR_CUSTOMSHAPE_GEOMETRY - SDRATTR_START ] = new SdrCustomShapeGeometryItem;
mppLocalPoolDefaults[ SDRATTR_CUSTOMSHAPE_REPLACEMENT_URL - SDRATTR_START ] = new SdrCustomShapeReplacementURLItem; mppLocalPoolDefaults[ SDRATTR_CUSTOMSHAPE_REPLACEMENT_URL - SDRATTR_START ] = new SdrCustomShapeReplacementURLItem;
......
...@@ -171,7 +171,7 @@ static MSO_SPT ImpGetCustomShapeType( const SdrObjCustomShape& rCustoShape ) ...@@ -171,7 +171,7 @@ static MSO_SPT ImpGetCustomShapeType( const SdrObjCustomShape& rCustoShape )
{ {
MSO_SPT eRetValue = mso_sptNil; MSO_SPT eRetValue = mso_sptNil;
OUString aEngine( static_cast<const SdrCustomShapeEngineItem&>( rCustoShape.GetMergedItem( SDRATTR_CUSTOMSHAPE_ENGINE ) ).GetValue() ); OUString aEngine( static_cast<const SfxStringItem&>( rCustoShape.GetMergedItem( SDRATTR_CUSTOMSHAPE_ENGINE ) ).GetValue() );
if ( aEngine.isEmpty() || aEngine == "com.sun.star.drawing.EnhancedCustomShapeEngine" ) if ( aEngine.isEmpty() || aEngine == "com.sun.star.drawing.EnhancedCustomShapeEngine" )
{ {
OUString sShapeType; OUString sShapeType;
...@@ -412,7 +412,7 @@ Reference< XCustomShapeEngine > SdrObjCustomShape::GetCustomShapeEngine() const ...@@ -412,7 +412,7 @@ Reference< XCustomShapeEngine > SdrObjCustomShape::GetCustomShapeEngine() const
if (mxCustomShapeEngine.is()) if (mxCustomShapeEngine.is())
return mxCustomShapeEngine; return mxCustomShapeEngine;
OUString aEngine(static_cast<const SdrCustomShapeEngineItem&>(GetMergedItem( SDRATTR_CUSTOMSHAPE_ENGINE )).GetValue()); OUString aEngine(static_cast<const SfxStringItem&>(GetMergedItem( SDRATTR_CUSTOMSHAPE_ENGINE )).GetValue());
if ( aEngine.isEmpty() ) if ( aEngine.isEmpty() )
aEngine = "com.sun.star.drawing.EnhancedCustomShapeEngine"; aEngine = "com.sun.star.drawing.EnhancedCustomShapeEngine";
...@@ -3255,7 +3255,7 @@ void SdrObjCustomShape::impl_setUnoShape(const uno::Reference<uno::XInterface>& ...@@ -3255,7 +3255,7 @@ void SdrObjCustomShape::impl_setUnoShape(const uno::Reference<uno::XInterface>&
OUString SdrObjCustomShape::GetCustomShapeName() OUString SdrObjCustomShape::GetCustomShapeName()
{ {
OUString sShapeName; OUString sShapeName;
OUString aEngine( static_cast<const SdrCustomShapeEngineItem&>(GetMergedItem( SDRATTR_CUSTOMSHAPE_ENGINE )).GetValue() ); OUString aEngine( static_cast<const SfxStringItem&>(GetMergedItem( SDRATTR_CUSTOMSHAPE_ENGINE )).GetValue() );
if ( aEngine.isEmpty() if ( aEngine.isEmpty()
|| aEngine == "com.sun.star.drawing.EnhancedCustomShapeEngine" ) || aEngine == "com.sun.star.drawing.EnhancedCustomShapeEngine" )
{ {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment