X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FSMESHGUI%2FSMESHGUI_NodesDlg.cxx;h=3f20596c5afcc88d9693e344c939456d0a73d884;hb=ee2c38087265d128e7d3febc042834b08539b504;hp=47e8f82c2a554187a58180597899e548b2f1fe96;hpb=9a358116f4ee87b52d3d86752c4fb6b3f814a69f;p=modules%2Fsmesh.git diff --git a/src/SMESHGUI/SMESHGUI_NodesDlg.cxx b/src/SMESHGUI/SMESHGUI_NodesDlg.cxx index 47e8f82c2..3f20596c5 100644 --- a/src/SMESHGUI/SMESHGUI_NodesDlg.cxx +++ b/src/SMESHGUI/SMESHGUI_NodesDlg.cxx @@ -230,10 +230,9 @@ SMESHGUI_NodesDlg::SMESHGUI_NodesDlg (SMESHGUI* theModule, WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu | Qt::WDestructiveClose), mySelector(SMESH::GetViewWindow(theModule)->GetSelector()), mySelectionMgr(SMESH::GetSelectionMgr(theModule)), - myViewWindow(SMESH::GetViewWindow(theModule)), mySMESHGUI(theModule) { - mySimulation = new SMESH::TNodeSimulation(myViewWindow); + mySimulation = new SMESH::TNodeSimulation(SMESH::GetViewWindow( mySMESHGUI )); QPixmap image0 (SMESH::GetResourceMgr( mySMESHGUI )->loadPixmap("SMESH", tr("ICON_DLG_NODE"))); if (!name) @@ -382,7 +381,8 @@ void SMESHGUI_NodesDlg::Init () // set selection mode SMESH::SetPointRepresentation(true); - myViewWindow->SetSelectionMode(NodeSelection); + if ( SVTK_ViewWindow* aViewWindow = SMESH::GetViewWindow( mySMESHGUI )) + aViewWindow->SetSelectionMode(NodeSelection); SelectionIntoArgument(); } @@ -468,7 +468,8 @@ bool SMESHGUI_NodesDlg::ClickOnApply() void SMESHGUI_NodesDlg::ClickOnCancel() { disconnect(mySelectionMgr, 0, this, 0); - myViewWindow->SetSelectionMode(ActorSelection); + if ( SVTK_ViewWindow* aViewWindow = SMESH::GetViewWindow( mySMESHGUI )) + aViewWindow->SetSelectionMode(ActorSelection); mySimulation->SetVisibility(false); SMESH::SetPointRepresentation(false); @@ -571,7 +572,8 @@ void SMESHGUI_NodesDlg::ActivateThisDialog() GroupButtons->setEnabled(true); SMESH::SetPointRepresentation(true); - myViewWindow->SetSelectionMode(NodeSelection); + if ( SVTK_ViewWindow* aViewWindow = SMESH::GetViewWindow( mySMESHGUI )) + aViewWindow->SetSelectionMode(NodeSelection); SelectionIntoArgument(); }