Kaydet (Commit) 66c81c1a authored tarafından Armin Le Grand's avatar Armin Le Grand

i123616 be more flexible regarding the data type for polygon data

üst b3173c16
...@@ -92,6 +92,7 @@ ...@@ -92,6 +92,7 @@
#include <editeng/outlobj.hxx> #include <editeng/outlobj.hxx>
#include <basegfx/matrix/b2dhommatrix.hxx> #include <basegfx/matrix/b2dhommatrix.hxx>
#include <basegfx/matrix/b2dhommatrixtools.hxx> #include <basegfx/matrix/b2dhommatrixtools.hxx>
#include <basegfx/polygon/b2dpolypolygontools.hxx>
#include <vector> #include <vector>
...@@ -2405,10 +2406,24 @@ bool SvxShape::setPropertyValueImpl( const ::rtl::OUString&, const SfxItemProper ...@@ -2405,10 +2406,24 @@ bool SvxShape::setPropertyValueImpl( const ::rtl::OUString&, const SfxItemProper
} }
case OWN_ATTR_EDGE_POLYPOLYGONBEZIER: case OWN_ATTR_EDGE_POLYPOLYGONBEZIER:
{ {
drawing::PolyPolygonBezierCoords aPolyPoly; basegfx::B2DPolyPolygon aNewPolyPolygon;
if ( rValue >>= aPolyPoly )
// #123616# be a little bit more flexible regardin gthe data type used
if( rValue.getValueType() == ::getCppuType(( const drawing::PointSequenceSequence*)0))
{
// get polygpon data from PointSequenceSequence
aNewPolyPolygon = basegfx::tools::UnoPointSequenceSequenceToB2DPolyPolygon(
*(const drawing::PointSequenceSequence*)rValue.getValue());
}
else if( rValue.getValueType() == ::getCppuType(( const drawing::PolyPolygonBezierCoords*)0))
{
// get polygpon data from PolyPolygonBezierCoords
aNewPolyPolygon = basegfx::tools::UnoPolyPolygonBezierCoordsToB2DPolyPolygon(
*(const drawing::PolyPolygonBezierCoords*)rValue.getValue());
}
if(aNewPolyPolygon.count())
{ {
basegfx::B2DPolyPolygon aNewPolyPolygon( SvxConvertPolyPolygonBezierToB2DPolyPolygon( &aPolyPoly ) );
// --> OD 2010-02-19 #i108851# - reintroduction of fix for issue i59051 // --> OD 2010-02-19 #i108851# - reintroduction of fix for issue i59051
ForceMetricToItemPoolMetric( aNewPolyPolygon ); ForceMetricToItemPoolMetric( aNewPolyPolygon );
// <-- // <--
......
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