Gui: Selection API changes

Mostly about API changes to SelectionSingleton. Also include related
changes to SelectionObject, SelectionChange, and SelectionView.

Please check out the summary of changes [here](https://git.io/fjimC)
This commit is contained in:
Zheng, Lei
2019-07-07 11:46:38 +08:00
committed by wmayer
parent 4bd31c4b91
commit c88e1335d8
7 changed files with 1941 additions and 662 deletions

View File

@@ -110,7 +110,14 @@ Py::Object SelectionObjectPy::getObject(void) const
Py::Tuple SelectionObjectPy::getSubObjects(void) const
{
std::vector<PyObject *> objs = getSelectionObjectPtr()->getObject()->getPySubObjects(getSelectionObjectPtr()->getSubNames());
std::vector<PyObject *> objs;
for(const auto &subname : getSelectionObjectPtr()->getSubNames()) {
PyObject *pyObj=0;
Base::Matrix4D mat;
getSelectionObjectPtr()->getObject()->getSubObject(subname.c_str(),&pyObj,&mat);
if(pyObj) objs.push_back(pyObj);
}
Py::Tuple temp(objs.size());
Py::sequence_index_type index = 0;