Kaydet (Commit) 3e0bf64f authored tarafından Miklos Vajna's avatar Miklos Vajna

oox customshapepresetdata: allow empty handle list

Change-Id: I35d1c6aaf94853df844bd226c57003742d3c48be
üst 79940e2d
......@@ -689,12 +689,15 @@ void CustomShapeProperties::initializePresetDataMap()
else if (aLine == "Handles")
{
aStream.ReadLine(aLine);
OString aExpectedPrefix("([][]com.sun.star.beans.PropertyValue) { ");
assert(aLine.startsWith(aExpectedPrefix));
comphelper::SequenceAsVector< uno::Sequence<beans::PropertyValue> > aHandles;
OString aValue = aLine.copy(aExpectedPrefix.getLength(), aLine.getLength() - aExpectedPrefix.getLength() - strlen(" }"));
lcl_parseHandles(aHandles, aValue);
if (aLine != "([][]com.sun.star.beans.PropertyValue) {}")
{
OString aExpectedPrefix("([][]com.sun.star.beans.PropertyValue) { ");
assert(aLine.startsWith(aExpectedPrefix));
OString aValue = aLine.copy(aExpectedPrefix.getLength(), aLine.getLength() - aExpectedPrefix.getLength() - strlen(" }"));
lcl_parseHandles(aHandles, aValue);
}
aPropertyMap.setProperty(PROP_Handles, aHandles.getAsConstList());
}
else if (aLine == "MirroredX")
......
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