- if (aSelectedObject != myBase) {
- TColStd_IndexedMapOfInteger aMap;
- aSelMgr->GetIndexes(aSelList.First(), aMap);
- if (aMap.Extent() == 1) {
- int anIndex = aMap(1);
- aName.append(":edge_" + QString::number(anIndex));
-
- //Find SubShape Object in Father
- GEOM::GEOM_Object_var aFindedObject = GEOMBase_Helper::findObjectInFather(aSelectedObject, aName);
-
- if (aFindedObject == GEOM::GEOM_Object::_nil()) { // Object not found in study
- GEOM::GEOM_IShapesOperations_var aShapesOp =
- getGeomEngine()->GetIShapesOperations(getStudyId());
- aSelectedObject = aShapesOp->GetSubShape(aSelectedObject, anIndex);
- myOk = true;
- }
- else { // get Object from study
- aSelectedObject = aFindedObject;
- myOk = true;
- }
- }
- else {
- myOk = true;
- if (S.ShapeType() != TopAbs_EDGE) {
- aSelectedObject = GEOM::GEOM_Object::_nil();
- aName = "";
- myOk = false;
- }
- }
- if (myEditCurrentArgument == GroupPoints->LineEdit2) {
- myPath = aSelectedObject;
- myOkPath = myOk;
- }
- else if (myEditCurrentArgument == GroupPoints->LineEdit3) {
- myVec = aSelectedObject;
- myOkVec = myOk;
- }
- }
- myEditCurrentArgument->setText(aName);
- if (myOkPath) {
- if (!myOkBase)
- GroupPoints->PushButton1->click();
- else if (!myOkVec)
- GroupPoints->PushButton3->click();
- }
- else if (myOkVec) {
- if (!myOkBase)
- GroupPoints->PushButton1->click();
- else if (!myOkPath)
- GroupPoints->PushButton2->click();