mirror of
https://git.salome-platform.org/gitpub/modules/smesh.git
synced 2025-01-06 23:00:34 +05:00
Fix bug 17722: menu for 'Geometry' button of 'Create Sub-mesh' dlg was lost.
This commit is contained in:
parent
d2bb955929
commit
a3511231dc
@ -418,29 +418,27 @@ void SMESHGUI_MeshOp::selectionDone()
|
||||
|
||||
try
|
||||
{
|
||||
myIsOnGeometry = true;
|
||||
|
||||
//Check geometry for mesh
|
||||
QString anObjEntry = myDlg->selectedObject(SMESHGUI_MeshDlg::Obj);
|
||||
_PTR(SObject) pObj = studyDS()->FindObjectID(anObjEntry.latin1());
|
||||
if ( !pObj )
|
||||
return;
|
||||
|
||||
SMESH::SMESH_subMesh_var aSubMeshVar =
|
||||
SMESH::SMESH_subMesh::_narrow( _CAST( SObject,pObj )->GetObject() );
|
||||
if ( !aSubMeshVar->_is_nil() )
|
||||
myIsOnGeometry = true;
|
||||
else {
|
||||
if (pObj)
|
||||
{
|
||||
SMESH::SMESH_Mesh_var aMeshVar =
|
||||
SMESH::SMESH_Mesh::_narrow(_CAST(SObject,pObj)->GetObject());
|
||||
if (!aMeshVar->_is_nil()) {
|
||||
if (!myToCreate && !aMeshVar->HasShapeToMesh())
|
||||
myIsOnGeometry = false;
|
||||
else
|
||||
myIsOnGeometry = true;
|
||||
}
|
||||
}
|
||||
|
||||
if ( myIsOnGeometry ) {
|
||||
if (myIsOnGeometry)
|
||||
{
|
||||
// Enable tabs according to shape dimension
|
||||
|
||||
int shapeDim = 3;
|
||||
|
||||
QStringList aGEOMs;
|
||||
myDlg->selectedObject(SMESHGUI_MeshDlg::Geom, aGEOMs);
|
||||
GEOM::ListOfGO_var aSeq = new GEOM::ListOfGO;
|
||||
@ -500,11 +498,8 @@ void SMESHGUI_MeshOp::selectionDone()
|
||||
|
||||
if (!myToCreate) // edition: read hypotheses
|
||||
{
|
||||
QString anObjEntry = myDlg->selectedObject( SMESHGUI_MeshDlg::Obj );
|
||||
_PTR(SObject) pObj = studyDS()->FindObjectID( anObjEntry.latin1() );
|
||||
if (pObj != 0)
|
||||
{
|
||||
|
||||
SMESH::SMESH_subMesh_var aVar =
|
||||
SMESH::SMESH_subMesh::_narrow( _CAST( SObject,pObj )->GetObject() );
|
||||
myDlg->setObjectShown( SMESHGUI_MeshDlg::Mesh, !aVar->_is_nil() );
|
||||
@ -517,7 +512,6 @@ void SMESHGUI_MeshOp::selectionDone()
|
||||
}
|
||||
else
|
||||
myDlg->reset();
|
||||
|
||||
}
|
||||
else if ( !myIsMesh ) // submesh creation
|
||||
{
|
||||
@ -1299,8 +1293,8 @@ bool SMESHGUI_MeshOp::createMesh( QString& theMess )
|
||||
QStringList aList;
|
||||
myDlg->selectedObject( SMESHGUI_MeshDlg::Geom, aList );
|
||||
QStringList::Iterator it = aList.begin();
|
||||
for(; it!=aList.end(); it++) {
|
||||
|
||||
for (; it!=aList.end(); it++)
|
||||
{
|
||||
QString aGeomEntry = *it;
|
||||
_PTR(SObject) pGeom = studyDS()->FindObjectID( aGeomEntry.latin1() );
|
||||
GEOM::GEOM_Object_var aGeomVar =
|
||||
|
Loading…
Reference in New Issue
Block a user