PartDesign: accomodating to sketch's multisupport

* FeatureSketchBased getSupportFace check for mapping mode
* Fixes failure to place sketches on DatumPlanes
This commit is contained in:
DeepSOIC 2015-06-30 21:53:56 +03:00 committed by Stefan Tröger
parent 2a390660c8
commit 4cc9b32e32
2 changed files with 2 additions and 2 deletions

View File

@ -191,7 +191,7 @@ std::vector<TopoDS_Wire> SketchBased::getSketchWires() const {
// this method, it becomes null!
const TopoDS_Face SketchBased::getSupportFace() const {
const Part::Part2DObject* sketch = getVerifiedSketch();
if (sketch->Support.getValue()) {
if (sketch->MapMode.getValue() == Attacher::mmFlatFace && sketch->Support.getValue()) {
const auto &Support = sketch->Support;
App::DocumentObject* ref = Support.getValue();

View File

@ -784,7 +784,7 @@ void CmdPartDesignNewSketch::activated(int iMsg)
} else {
obj = static_cast<Part::Feature*>(PlaneFilter.Result[0][0].getObject());
// TODO: Find out whether the user picked front or back of this plane
supportString = std::string("(App.activeDocument().") + obj->getNameInDocument() + ", ['front'])";
supportString = std::string("(App.activeDocument().") + obj->getNameInDocument() + ", '')";
}
if (!pcActiveBody->hasFeature(obj)) {