Support to write vector list and float lists in old format, fix issues in property editor, move back to float for curvature type

This commit is contained in:
wmayer
2013-03-30 12:32:53 +01:00
parent bb63f7a4d5
commit ad49408c58
13 changed files with 64 additions and 167 deletions

View File

@@ -296,8 +296,18 @@ void PropertyVectorList::SaveDocFile (Base::Writer &writer) const
Base::OutputStream str(writer.Stream());
uint32_t uCt = (uint32_t)getSize();
str << uCt;
for (std::vector<Base::Vector3d>::const_iterator it = _lValueList.begin(); it != _lValueList.end(); ++it) {
str << it->x << it->y << it->z;
if (writer.getFileVersion() > 0) {
for (std::vector<Base::Vector3d>::const_iterator it = _lValueList.begin(); it != _lValueList.end(); ++it) {
str << it->x << it->y << it->z;
}
}
else {
for (std::vector<Base::Vector3d>::const_iterator it = _lValueList.begin(); it != _lValueList.end(); ++it) {
float x = (float)it->x;
float y = (float)it->y;
float z = (float)it->z;
str << x << y << z;
}
}
}