TechDraw: Link related changes

* Support link and group objects

* Support view sync by implementing view provider API getMDIView()

* Use handleChangedPropertyType() for object migration instead of
  reimplementing Restore() because of a lots of changes in
  PropertyContainer::Restore().

* Various other small fixes.
This commit is contained in:
Zheng, Lei
2019-07-12 11:28:07 +08:00
committed by wmayer
parent f028ba42ff
commit e90d09dc40
30 changed files with 204 additions and 412 deletions

View File

@@ -1023,7 +1023,8 @@ void CmdTechDrawLinkDimension::activated(int iMsg)
if (!result)
return;
std::vector<Gui::SelectionObject> selection = getSelection().getSelectionEx();
std::vector<Gui::SelectionObject> selection = getSelection().getSelectionEx(0,
App::DocumentObject::getClassTypeId(),0);
App::DocumentObject* obj3D = 0;
std::vector<App::DocumentObject*> parts;
@@ -1031,13 +1032,11 @@ void CmdTechDrawLinkDimension::activated(int iMsg)
std::vector<Gui::SelectionObject>::iterator itSel = selection.begin();
for (; itSel != selection.end(); itSel++) {
if ((*itSel).getObject()->isDerivedFrom(Part::Feature::getClassTypeId())) {
obj3D = ((*itSel).getObject());
std::vector<std::string> subList = (*itSel).getSubNames();
for (auto& s:subList) {
parts.push_back(obj3D);
subs.push_back(s);
}
obj3D = ((*itSel).getObject());
std::vector<std::string> subList = (*itSel).getSubNames();
for (auto& s:subList) {
parts.push_back(obj3D);
subs.push_back(s);
}
}