summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMiklos Vajna <vmiklos@collabora.co.uk>2017-07-14 09:10:13 +0200
committerMiklos Vajna <vmiklos@collabora.co.uk>2017-07-14 09:12:04 +0200
commitb7b2887d62ea249310f02f03c4ce31cbd8f21307 (patch)
treecb178ffbc9329308214b20ce8e0f990eda8793e1
parentd8e5a0db64fa022b54bddc42b1b1db0c1ddfe2d1 (diff)
Revert "tdf#109067 Fix default value of rotWithShape"
This reverts commit 1b08f129677c1109aae1fadc72ae68ebb7df7cb0. The change was Jenkins-verified, but just rebasing it on top of latest master (without getting conflicts) broke the test added in the commit. So let's revert it for now to have time to find out why does the test fail on top of latest master. Change-Id: I3bce24e54fb07df2dd460fb0f01d44516b3fcd0d
-rw-r--r--oox/source/drawingml/fillproperties.cxx4
-rw-r--r--oox/source/export/drawingml.cxx6
-rw-r--r--sd/qa/unit/data/pptx/tdf109067.pptxbin20183 -> 0 bytes
-rw-r--r--sd/qa/unit/import-tests.cxx13
4 files changed, 5 insertions, 18 deletions
diff --git a/oox/source/drawingml/fillproperties.cxx b/oox/source/drawingml/fillproperties.cxx
index 41ab6ae222bc..314ff5822695 100644
--- a/oox/source/drawingml/fillproperties.cxx
+++ b/oox/source/drawingml/fillproperties.cxx
@@ -362,8 +362,8 @@ void FillProperties::pushToPropMap( ShapePropertyMap& rPropMap,
if ( bFlipV )
nShapeRotation = -nShapeRotation;
- // "rotate with shape" set to false -> do not rotate
- if ( !maGradientProps.moRotateWithShape.get( true ) )
+ // "rotate with shape" not set, or set to false -> do not rotate
+ if ( !maGradientProps.moRotateWithShape.get( false ) )
nShapeRotation = 0;
if( maGradientProps.moGradientPath.has() )
diff --git a/oox/source/export/drawingml.cxx b/oox/source/export/drawingml.cxx
index ee151225f122..ddb91babb7c5 100644
--- a/oox/source/export/drawingml.cxx
+++ b/oox/source/export/drawingml.cxx
@@ -386,14 +386,14 @@ void DrawingML::WriteGradientFill( const Reference< XPropertySet >& rXPropSet )
// If we have no gradient stops that means original gradient were defined by a theme.
if( aGradientStops.hasElements() )
{
- mpFS->startElementNS( XML_a, XML_gradFill, XML_rotWithShape, "0", FSEND );
+ mpFS->startElementNS( XML_a, XML_gradFill, FSEND );
WriteGrabBagGradientFill(aGradientStops, aGradient);
mpFS->endElementNS( XML_a, XML_gradFill );
}
}
else
{
- mpFS->startElementNS( XML_a, XML_gradFill, XML_rotWithShape, "0", FSEND );
+ mpFS->startElementNS( XML_a, XML_gradFill, FSEND );
WriteGradientFill(aGradient);
mpFS->endElementNS( XML_a, XML_gradFill );
}
@@ -1053,7 +1053,7 @@ void DrawingML::WriteBlipFill( const Reference< XPropertySet >& rXPropSet, const
{
SAL_INFO("oox.shape", "URL: " << sBitmapURL);
- mpFS->startElementNS( nXmlNamespace , XML_blipFill, XML_rotWithShape, "0", FSEND );
+ mpFS->startElementNS( nXmlNamespace , XML_blipFill, FSEND );
WriteBlip( rXPropSet, sBitmapURL, bRelPathToMedia );
diff --git a/sd/qa/unit/data/pptx/tdf109067.pptx b/sd/qa/unit/data/pptx/tdf109067.pptx
deleted file mode 100644
index ef213774cbd8..000000000000
--- a/sd/qa/unit/data/pptx/tdf109067.pptx
+++ /dev/null
Binary files differ
diff --git a/sd/qa/unit/import-tests.cxx b/sd/qa/unit/import-tests.cxx
index b71b4aec4e8e..a4d8253399a6 100644
--- a/sd/qa/unit/import-tests.cxx
+++ b/sd/qa/unit/import-tests.cxx
@@ -161,7 +161,6 @@ public:
void testTdf100926();
void testTdf89064();
void testTdf108925();
- void testTdf109067();
bool checkPattern(sd::DrawDocShellRef& rDocRef, int nShapeNumber, std::vector<sal_uInt8>& rExpected);
void testPatternImport();
@@ -231,7 +230,6 @@ public:
CPPUNIT_TEST(testPatternImport);
CPPUNIT_TEST(testTdf89064);
CPPUNIT_TEST(testTdf108925);
- CPPUNIT_TEST(testTdf109067);
CPPUNIT_TEST_SUITE_END();
};
@@ -2208,17 +2206,6 @@ void SdImportTest::testTdf108925()
xDocShRef->DoClose();
}
-void SdImportTest::testTdf109067()
-{
- sd::DrawDocShellRef xDocShRef = loadURL(m_directories.getURLFromSrc("sd/qa/unit/data/pptx/tdf109067.pptx"), PPTX);
- uno::Reference< beans::XPropertySet > xShape(getShapeFromPage(0, 0, xDocShRef), uno::UNO_QUERY_THROW);
- awt::Gradient gradient;
- CPPUNIT_ASSERT(xShape->getPropertyValue("FillGradient") >>= gradient);
- CPPUNIT_ASSERT_EQUAL(sal_Int16(450), gradient.Angle);
-
- xDocShRef->DoClose();
-}
-
CPPUNIT_TEST_SUITE_REGISTRATION(SdImportTest);
CPPUNIT_PLUGIN_IMPLEMENT();