PartDesign: accomodating to sketch's multisupport
* FeatureSketchBased getSupportFace check for mapping mode * Fixes failure to place sketches on DatumPlanes
This commit is contained in:
parent
2a390660c8
commit
4cc9b32e32
|
@ -191,7 +191,7 @@ std::vector<TopoDS_Wire> SketchBased::getSketchWires() const {
|
||||||
// this method, it becomes null!
|
// this method, it becomes null!
|
||||||
const TopoDS_Face SketchBased::getSupportFace() const {
|
const TopoDS_Face SketchBased::getSupportFace() const {
|
||||||
const Part::Part2DObject* sketch = getVerifiedSketch();
|
const Part::Part2DObject* sketch = getVerifiedSketch();
|
||||||
if (sketch->Support.getValue()) {
|
if (sketch->MapMode.getValue() == Attacher::mmFlatFace && sketch->Support.getValue()) {
|
||||||
const auto &Support = sketch->Support;
|
const auto &Support = sketch->Support;
|
||||||
App::DocumentObject* ref = Support.getValue();
|
App::DocumentObject* ref = Support.getValue();
|
||||||
|
|
||||||
|
|
|
@ -784,7 +784,7 @@ void CmdPartDesignNewSketch::activated(int iMsg)
|
||||||
} else {
|
} else {
|
||||||
obj = static_cast<Part::Feature*>(PlaneFilter.Result[0][0].getObject());
|
obj = static_cast<Part::Feature*>(PlaneFilter.Result[0][0].getObject());
|
||||||
// TODO: Find out whether the user picked front or back of this plane
|
// 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)) {
|
if (!pcActiveBody->hasFeature(obj)) {
|
||||||
|
|
Loading…
Reference in New Issue
Block a user