X-Git-Url: http://git.salome-platform.org/gitweb/?p=modules%2Fsmesh.git;a=blobdiff_plain;f=src%2FSMESHGUI%2FSMESHGUI_MakeNodeAtPointDlg.cxx;h=bc3fd0723d7b19cbc6834966bbcf5adcd6152315;hp=89034c8a6782b23aa6d4937d66ce61c8dadbc0be;hb=b7a7d49664daa32e1befb558280e13ed0bde37c9;hpb=a0880e7c367025142b27c4669968a7611837c5a9 diff --git a/src/SMESHGUI/SMESHGUI_MakeNodeAtPointDlg.cxx b/src/SMESHGUI/SMESHGUI_MakeNodeAtPointDlg.cxx index 89034c8a6..bc3fd0723 100644 --- a/src/SMESHGUI/SMESHGUI_MakeNodeAtPointDlg.cxx +++ b/src/SMESHGUI/SMESHGUI_MakeNodeAtPointDlg.cxx @@ -1,4 +1,4 @@ -// Copyright (C) 2007-2015 CEA/DEN, EDF R&D, OPEN CASCADE +// Copyright (C) 2007-2016 CEA/DEN, EDF R&D, OPEN CASCADE // // Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS @@ -84,6 +84,11 @@ #define SPACING 6 #define MARGIN 11 +namespace +{ + enum { MANUAL_MODE = 0, SEARCH_MODE }; // how a node to move is specified +} + /*! * \brief Dialog to publish a sub-shape of the mesh main shape * by selecting mesh elements @@ -350,7 +355,7 @@ SMESHGUI_MakeNodeAtPointOp::SMESHGUI_MakeNodeAtPointOp() mySMESHGUI = 0; myDlg = new SMESHGUI_MakeNodeAtPointDlg; myFilter = 0; - myHelpFileName = "mesh_through_point_page.html"; + myHelpFileName = "mesh_through_point.html"; myNoPreview = false; myUpdateDestination = false; @@ -437,7 +442,7 @@ void SMESHGUI_MakeNodeAtPointOp::startOperation() myDlg->myDestDZ->setReadOnly(true); myDlg->myRButNodeToMove->setChecked(true); - myDlg->ConstructorsClicked(GetConstructorId()); + myDlg->ConstructorsClicked( GetConstructorId() ); myDlg->show(); @@ -469,12 +474,13 @@ void SMESHGUI_MakeNodeAtPointOp::stopOperation() mySimulation = 0; } if ( myMeshActor ) { - myMeshActor->SetPointRepresentation(false); - SMESH::RepaintCurrentView(); myMeshActor = 0; } + SMESH::SetPointRepresentation( false ); + SMESH::RepaintCurrentView(); + disconnect(mySMESHGUI, SIGNAL (SignalActivatedViewManager()), this, SLOT(onOpenView())); - disconnect(mySMESHGUI, SIGNAL (SignalCloseView()), this, SLOT(onCloseView())); + disconnect(mySMESHGUI, SIGNAL (SignalCloseView()), this, SLOT(onCloseView())); selectionMgr()->removeFilter( myFilter ); SMESHGUI_SelectionOp::stopOperation(); } @@ -487,7 +493,7 @@ void SMESHGUI_MakeNodeAtPointOp::stopOperation() bool SMESHGUI_MakeNodeAtPointOp::onApply() { - if( isStudyLocked() ) + if( SMESHGUI::isStudyLocked() ) return false; if ( !myMeshActor ) { @@ -685,6 +691,9 @@ void SMESHGUI_MakeNodeAtPointOp::redisplayPreview() return; myNoPreview = true; + if ( !myMeshActor && GetConstructorId() == SEARCH_MODE ) + onSelectionDone(); + SMESH::MeshPreviewStruct_var aMeshPreviewStruct; bool moveShown = false; @@ -776,7 +785,8 @@ void SMESHGUI_MakeNodeAtPointOp::redisplayPreview() } } } - }catch (...) { + } + catch (...) { } } }