WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu),
myBusy(false),
mySMESHGUI( theModule ),
- mySelectionMgr( SMESH::GetSelectionMgr( theModule ) ),
- myViewWindow( SMESH::GetViewWindow( theModule ) ),
- mySelector( myViewWindow->GetSelector() )
+ mySelectionMgr( SMESH::GetSelectionMgr( theModule ) )
{
setCaption(tr("CAPTION"));
aDlgLay->setStretchFactor(aMainFrame, 1);
myCreationDlg = 0;
+
+ mySelector = (SMESH::GetViewWindow( mySMESHGUI ))->GetSelector();
+
Init();
}
bool toCreatePolyedrs = myCreatePolyedrsChk->isChecked();
if ( myPattern->MakeMesh( myMesh, toCreatePolygons, toCreatePolyedrs ) ) {
mySelectionMgr->clearSelected();
- SUIT_ResourceMgr* mgr = SMESH::GetResourceMgr( mySMESHGUI );
bool autoUpdate = SMESHGUI::automaticUpdate();
if (!isRefine() && autoUpdate) {
_PTR(SObject) aSO = SMESH::FindSObject(myMesh.in());
}
}
SMESH::UpdateView();
-
+
mySMESHGUI->updateObjBrowser(true);
return true;
} else {
{
mySelectionMgr->clearFilters();
SMESH::SetPickable();
- myViewWindow->SetSelectionMode(ActorSelection);
+ if ( SVTK_ViewWindow* aViewWindow = SMESH::GetViewWindow( mySMESHGUI ))
+ aViewWindow->SetSelectionMode(ActorSelection);
disconnect(mySelectionMgr, 0, this, 0);
disconnect(mySMESHGUI, 0, this, 0);
mySMESHGUI->ResetState();
SMESH::SetPickable(anActor);
if (myType == Type_2d)
- myViewWindow->SetSelectionMode(FaceSelection);
+ {
+ if ( SVTK_ViewWindow* aViewWindow = SMESH::GetViewWindow( mySMESHGUI ))
+ aViewWindow->SetSelectionMode(FaceSelection);
+ }
else
- myViewWindow->SetSelectionMode(CellSelection);
+ {
+ if ( SVTK_ViewWindow* aViewWindow = SMESH::GetViewWindow( mySMESHGUI ))
+ aViewWindow->SetSelectionMode(CellSelection);
+ }
}
else {
SMESH::SetPickable();
//mySelectionMgr->setSelectionModes(ActorSelection);
- myViewWindow->SetSelectionMode(ActorSelection);
+ if ( SVTK_ViewWindow* aViewWindow = SMESH::GetViewWindow( mySMESHGUI ))
+ aViewWindow->SetSelectionMode(ActorSelection);
}
if (mySelInput == Object && !myMeshShape->_is_nil()) {
if (aMesh) {
QStringList aListId = QStringList::split(" ", theNewText, false);
-
+
TColStd_MapOfInteger newIndices;
-
+
for (int i = 0; i < aListId.count(); i++) {
const SMDS_MeshElement * e = aMesh->FindElement(aListId[ i ].toInt());
if (e && e->GetType() == (myType == Type_2d ? SMDSAbs_Face : SMDSAbs_Volume))
newIndices.Add(e->GetID());
}
mySelector->AddOrRemoveIndex( anActor->getIO(), newIndices, false);
- myViewWindow->highlight( anActor->getIO(), true, true );
+ if ( SVTK_ViewWindow* aViewWindow = SMESH::GetViewWindow( mySMESHGUI ))
+ aViewWindow->highlight( anActor->getIO(), true, true );
}
myBusy = false;