PartDesign changes

* Mostly for supporting in-place editing

* Add new SubShapeBinder that support cross coordinate system,
  external, and sub-object binding
This commit is contained in:
Zheng, Lei
2019-07-13 18:13:21 +08:00
committed by wmayer
parent e911b69769
commit 11a93a0578
55 changed files with 1944 additions and 755 deletions

View File

@@ -279,13 +279,17 @@ void ViewProviderAddSub::setPreviewDisplayMode(bool onoff) {
// displays an object and when restoring the previous state it's
// not sufficient to only revert the mask mode. Also the child
// number of the switch node must be reverted.
if (onoff && displayMode!="Shape preview") {
if (onoff) {
if(pcModeSwitch->getChild(getDefaultMode()) == previewShape)
return;
displayMode = getActiveDisplayMode();
whichChild = pcModeSwitch->whichChild.getValue();
setDisplayMaskMode("Shape preview");
}
if (!onoff) {
if(pcModeSwitch->getChild(getDefaultMode()) != previewShape)
return;
setDisplayMaskMode(displayMode.c_str());
pcModeSwitch->whichChild.setValue(whichChild);
}