: QDialog( SMESH::GetDesktop( theModule ), theName, false,\r
WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu),\r
mySMESHGUI( theModule ),\r
- mySelectionMgr( SMESH::GetSelectionMgr( theModule ) ),\r
- myViewWindow( SMESH::GetViewWindow( theModule ) ),\r
- mySelector( myViewWindow->GetSelector() )\r
+ mySelectionMgr( SMESH::GetSelectionMgr( theModule ) )\r
{\r
setCaption(tr("CAPTION"));\r
\r
\r
aDlgLay->setStretchFactor(aMainFrame, 1);\r
\r
+ if ( SVTK_ViewWindow* aViewWindow = SMESH::GetViewWindow( mySMESHGUI ))\r
+ mySelector = aViewWindow->GetSelector();\r
+\r
Init(theType);\r
}\r
\r
tr("ERROR_OF_SAVING"), QMessageBox::Ok);\r
} else {\r
//SUIT_Application::getDesktop()->setSelectionModes(ActorSelection);\r
- myViewWindow->SetSelectionMode(ActorSelection);\r
+ if ( SVTK_ViewWindow* aViewWindow = SMESH::GetViewWindow( mySMESHGUI ))\r
+ aViewWindow->SetSelectionMode(ActorSelection);\r
disconnect(mySelectionMgr, 0, this, 0);\r
disconnect(mySMESHGUI, 0, this, 0);\r
mySMESHGUI->ResetState();\r
return;\r
} else {\r
//SUIT_Application::getDesktop()->setSelectionModes(ActorSelection);\r
- myViewWindow->SetSelectionMode(ActorSelection);\r
+ if ( SVTK_ViewWindow* aViewWindow = SMESH::GetViewWindow( mySMESHGUI ))\r
+ aViewWindow->SetSelectionMode(ActorSelection);\r
disconnect(mySelectionMgr, 0, this, 0);\r
disconnect(mySMESHGUI, 0, this, 0);\r
mySMESHGUI->ResetState();\r
//=======================================================================\r
void SMESHGUI_CreatePatternDlg::onClose()\r
{\r
- myViewWindow->SetSelectionMode(ActorSelection);\r
+ if ( SVTK_ViewWindow* aViewWindow = SMESH::GetViewWindow( mySMESHGUI ))\r
+ aViewWindow->SetSelectionMode(ActorSelection);\r
disconnect(mySelectionMgr, 0, this, 0);\r
disconnect(mySMESHGUI, 0, this, 0);\r
mySMESHGUI->ResetState();\r
{\r
mySelectionMgr->clearFilters();\r
//SUIT_Application::getDesktop()->setSelectionModes(ActorSelection);\r
- myViewWindow->SetSelectionMode(ActorSelection);\r
+ if ( SVTK_ViewWindow* aViewWindow = SMESH::GetViewWindow( mySMESHGUI ))\r
+ aViewWindow->SetSelectionMode(ActorSelection);\r
\r
if (myType == Type_2d) {\r
mySelectionMgr->installFilter(new SMESH_NumberFilter\r