]> SALOME platform Git repositories - modules/smesh.git/commitdiff
Salome HOME
Fix for bug PAL9590 (SIGSEV when creating a SMESH group on Debian Sarge). T2_2_5b
authormzn <mzn@opencascade.com>
Thu, 8 Sep 2005 08:44:15 +0000 (08:44 +0000)
committermzn <mzn@opencascade.com>
Thu, 8 Sep 2005 08:44:15 +0000 (08:44 +0000)
src/SMESHGUI/SMESHGUI_FilterDlg.cxx
src/SMESHGUI/SMESHGUI_FilterDlg.h

index 62a04bb7424aad3b706bf6de6f0d12296dea87fd..d0b3578b44a6a3390d63aec27773fee4fe0f592a 100755 (executable)
@@ -420,7 +420,8 @@ QString SMESHGUI_FilterTable::Table::text( int row, int col ) const
 //=======================================================================
 SMESHGUI_FilterTable::SMESHGUI_FilterTable( QWidget* parent, 
                                             const int type )
-: QFrame( parent )                                            
+: QFrame( parent ),
+  myIsLocked( false )
 {
   myEntityType = -1;
   Init( type );
@@ -432,7 +433,8 @@ SMESHGUI_FilterTable::SMESHGUI_FilterTable( QWidget* parent,
 //=======================================================================
 SMESHGUI_FilterTable::SMESHGUI_FilterTable( QWidget* parent, 
                                             const QValueList<int>& types )
-: QFrame( parent )                                            
+: QFrame( parent ),
+  myIsLocked( false )
 {
   myEntityType = -1;
   Init( types );
@@ -1029,7 +1031,8 @@ void SMESHGUI_FilterTable::onClearBtn()
 //=======================================================================
 void SMESHGUI_FilterTable::onCurrentChanged( int theRow, int theCol )
 {
-  updateAdditionalWidget();
+  if( !myIsLocked )
+    updateAdditionalWidget();
   emit CurrentChanged( theRow, theCol );
 }
 
@@ -1121,6 +1124,7 @@ void SMESHGUI_FilterTable::addRow( Table* theTable, const int theType, const boo
   int aSelectedRow = getFirstSelectedRow();
   int aCurrCol = theTable->currentColumn();
 
+  myIsLocked = true;
   if ( toTheEnd || aSelectedRow == -1 )
   {
     theTable->insertRows( theTable->numRows() );
@@ -1131,6 +1135,7 @@ void SMESHGUI_FilterTable::addRow( Table* theTable, const int theType, const boo
     theTable->insertRows( aSelectedRow );
     aCurrRow = aSelectedRow;
   }
+  myIsLocked = false;
 
   // Criteria
   theTable->setItem( aCurrRow, 0, getCriterionItem( theTable, theType ) );
index f63d2b2e0a134802a10023875517e0ad9c550238..efd6e2e75b012812bb616e584215483aa50b4f0b 100755 (executable)
@@ -186,6 +186,7 @@ private:
   QButtonGroup*             myEntityTypeGrp;
   int                       myEntityType;
   int                       myIsValid;
+  bool                      myIsLocked;
   
   SMESHGUI_FilterLibraryDlg* myLibDlg;