Salome HOME
Fix regressions
[modules/smesh.git] / src / SMESHGUI / SMESHGUI_FilterDlg.cxx
index b55632f0a753c123c7e4ebbd0724acf7eadd5d72..4e7f6bf5ff91f1fb827ca8e6f3a2088478e904ae 100755 (executable)
@@ -1546,7 +1546,7 @@ void SMESHGUI_FilterTable::onRemoveBtn()
 
 //=======================================================================
 // name    : SMESHGUI_FilterTable::updateAdditionalWidget
-// Purpose : Enable/Disable widget with additonal parameters
+// Purpose : Enable/Disable widget with additional parameters
 //=======================================================================
 void SMESHGUI_FilterTable::updateAdditionalWidget()
 {
@@ -1823,6 +1823,7 @@ void SMESHGUI_FilterTable::onCriterionChanged (const int row, const int col, con
   case SMESH::FT_EqualFaces:
   case SMESH::FT_EqualVolumes: break;
 
+  case SMESH::FT_NodeConnectivityNumber:
   case SMESH::FT_MultiConnection:
   case SMESH::FT_MultiConnection2D: anIsIntCriterion = true; nbCompareSigns = 3; break;
 
@@ -2115,7 +2116,7 @@ QTableWidgetItem* SMESHGUI_FilterTable::getCriterionItem (const int theType) con
 
 //=======================================================================
 // name    : SMESHGUI_FilterTable::getCompareItem
-// Purpose : Get combo table item for operation of comparision
+// Purpose : Get combo table item for operation of comparison
 //=======================================================================
 QTableWidgetItem* SMESHGUI_FilterTable::getCompareItem () const
 {
@@ -2190,6 +2191,7 @@ const QMap<int, QString>& SMESHGUI_FilterTable::getCriteria (const int theType)
       aCriteria[ SMESH::FT_GroupColor         ] = tr("GROUP_COLOR");
       aCriteria[ SMESH::FT_EqualNodes         ] = tr("EQUAL_NODE");
       aCriteria[ SMESH::FT_ConnectedElements  ] = tr("CONNECTED_ELEMS");
+      aCriteria[ SMESH::FT_NodeConnectivityNumber ] = tr("NODE_CONN_NUMBER");
     }
     return aCriteria;
   }
@@ -3487,7 +3489,8 @@ void SMESHGUI_FilterDlg::UnRegisterFilters()
 //=======================================================================
 void SMESHGUI_FilterDlg::insertFilterInViewer()
 {
-  if (SVTK_Selector* aSelector = SMESH::GetSelector()) {
+  if (SVTK_Selector* aSelector = SMESH::GetSelector())
+  {
     SMESH::ElementType anEntType = (SMESH::ElementType)myTable->GetType();
 
     if (myFilter[ myTable->GetType() ]->_is_nil() ||
@@ -3497,7 +3500,8 @@ void SMESHGUI_FilterDlg::insertFilterInViewer()
     {
       SMESH::RemoveFilter(getFilterId(anEntType), aSelector);
     }
-    else {
+    else
+    {
       Handle(SMESHGUI_PredicateFilter) aFilter = new SMESHGUI_PredicateFilter();
       aFilter->SetPredicate(myFilter[ myTable->GetType() ]->GetPredicate());
       SMESH::RemoveFilter(getFilterId(anEntType), aSelector); //skl for IPAL12631
@@ -3657,7 +3661,7 @@ SMESH_Actor* SMESHGUI_FilterDlg::getActor()
 //=======================================================================
 void SMESHGUI_FilterDlg::selectInViewer (const int theType, const QList<int>& theIds)
 {
-  if (mySelectionMgr == 0 || myMesh->_is_nil())
+  if (mySelectionMgr == 0 || myMesh->_is_nil() )
     return;
 
   mySelectionMgr->clearFilters();
@@ -3665,7 +3669,8 @@ void SMESHGUI_FilterDlg::selectInViewer (const int theType, const QList<int>& th
   // Set new selection mode if necessary
   Selection_Mode aSelMode = getSelMode(theType);
   SVTK_ViewWindow* aViewWindow = SMESH::GetViewWindow( mySMESHGUI );
-  if ( aViewWindow && aViewWindow->SelectionMode()!=aSelMode) {
+  if ( aViewWindow && aViewWindow->SelectionMode() != aSelMode )
+  {
     mySelectionMgr->clearSelected();
     mySelectionMgr->clearFilters();
     SMESH::SetPointRepresentation( aSelMode == NodeSelection );
@@ -3678,8 +3683,6 @@ void SMESHGUI_FilterDlg::selectInViewer (const int theType, const QList<int>& th
     return;
 
   Handle(SALOME_InteractiveObject) anIO = anActor->getIO();
-  //mySelectionMgr->clearSelected();
-  //mySelectionMgr->AddIObject(anIO, false);
   SALOME_ListIO aList;
   aList.Append(anIO);
   mySelectionMgr->setSelectedObjects(aList, false);