Attacher: change Part2DObject's MapMode default to mmDeactivated, and set mode to mmFlatFace only when reading files of old format.

PartDesign, Sketcher: set mapping mode when setting support

Mapping mode mmFlatFace is no longer default, so an explicit assignment
is required.
This commit is contained in:
DeepSOIC
2015-07-02 15:26:16 +03:00
committed by Stefan Tröger
parent 9a48d210cf
commit b6152364af
4 changed files with 10 additions and 2 deletions

View File

@@ -233,10 +233,12 @@ void Part2DObject::Restore(Base::XMLReader &reader)
if (strcmp(prop->getTypeId().getName(), TypeName) == 0){
prop->Restore(reader);
} else if (prop->isDerivedFrom(App::PropertyLinkSubList::getClassTypeId())){
//reading legacy Support - when the Support could only be a single flat face.
App::PropertyLinkSub tmp;//getTypeId() is not static =(
if (0 == strcmp(tmp.getTypeId().getName(),TypeName)) {
static_cast<App::PropertyLinkSubList*>(prop)->Restore_FromLinkSub(reader);
}
this->MapMode.setValue(Attacher::mmFlatFace);
}
}
}