From: eap Date: Mon, 3 Sep 2012 08:30:23 +0000 (+0000) Subject: 0020833: EDF 1361 SMESH : Graphical Selection of the boundary faces in one clic X-Git-Tag: V6_6_0a1~148 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=d45ee63be8255650e03600bc4a7d1d063a8643c4;p=modules%2Fsmesh.git 0020833: EDF 1361 SMESH : Graphical Selection of the boundary faces in one clic 1) Add to Init() a flag controlling the state of "Insert filter in viewer" 2) Fix setting a selection mode --- diff --git a/src/SMESHGUI/SMESHGUI_FilterDlg.cxx b/src/SMESHGUI/SMESHGUI_FilterDlg.cxx index ac756a16c..d29ae2c82 100755 --- a/src/SMESHGUI/SMESHGUI_FilterDlg.cxx +++ b/src/SMESHGUI/SMESHGUI_FilterDlg.cxx @@ -2647,18 +2647,18 @@ SMESHGUI_FilterDlg::~SMESHGUI_FilterDlg() // name : SMESHGUI_FilterDlg::Init // Purpose : Init dialog fields, connect signals and slots, show dialog //======================================================================= -void SMESHGUI_FilterDlg::Init (const int type) +void SMESHGUI_FilterDlg::Init (const int type, const bool setInViewer) { QList aTypes; aTypes.append(type); - Init(aTypes); + Init(aTypes,setInViewer); } //======================================================================= // name : SMESHGUI_FilterDlg::Init // Purpose : Init dialog fields, connect signals and slots, show dialog //======================================================================= -void SMESHGUI_FilterDlg::Init (const QList& theTypes) +void SMESHGUI_FilterDlg::Init (const QList& theTypes, const bool setInViewer) { mySourceWg = 0; myTypes = theTypes; @@ -2713,7 +2713,7 @@ void SMESHGUI_FilterDlg::Init (const QList& theTypes) if (myInsertState.contains(theTypes.first())) mySetInViewer->setChecked(myInsertState[ theTypes.first() ]); else - mySetInViewer->setChecked(true); + mySetInViewer->setChecked(setInViewer); mySourceGrp->button(myApplyToState.contains(theTypes.first()) ? myApplyToState[ theTypes.first() ] : @@ -3008,7 +3008,7 @@ bool SMESHGUI_FilterDlg::isValid() const //======================================================================= // name : SMESHGUI_FilterDlg::SetSourceWg -// Purpose : Set widget of parent dialog containing idsto be filtered if +// Purpose : Set widget of parent dialog containing ids to be filtered if // user select corresponding source radio button //======================================================================= void SMESHGUI_FilterDlg::SetSourceWg (QWidget* theWg, @@ -3501,6 +3501,8 @@ void SMESHGUI_FilterDlg::updateSelection() } else { + mySelector->SetSelectionMode( getSelMode( myTable->GetType() )); + if (myIsSelectionChanged) { // mySelectionMgr->installFilter( new GEOM_TypeFilter( aStudy, -1 ) ); // This filter deactivates selection // Impossible to select any object in the OB on the second opening of FilterDlg