]> SALOME platform Git repositories - modules/hydro.git/commitdiff
Salome HOME
- The bug is fixed: iterator on an invalid sequence which is out of scope.
authorrkv <rkv@opencascade.com>
Wed, 30 Oct 2013 10:13:22 +0000 (10:13 +0000)
committerrkv <rkv@opencascade.com>
Wed, 30 Oct 2013 10:13:22 +0000 (10:13 +0000)
- List of objects is sorted on the first page of Calcualtion Case wizard.

src/HYDROGUI/HYDROGUI_CalculationDlg.cxx
src/HYDROGUI/HYDROGUI_DataObject.cxx

index 302efd74631a5126b00fed7cd9b0e699d2695de4..8d43d446fab932257dbc7578d8aa16fb56d8054b 100644 (file)
@@ -104,6 +104,7 @@ QWizardPage* HYDROGUI_CalculationDlg::createObjectsPage() {
   myGeomObjects->setSelectionMode( QListWidget::SingleSelection );
   myGeomObjects->setEditTriggers( QListWidget::NoEditTriggers );
   myGeomObjects->setViewMode( QListWidget::ListMode );
+  myGeomObjects->setSortingEnabled( true );
 
   QFrame* aBtnsFrame = new QFrame( aPage );
   QVBoxLayout* aBtnsLayout = new QVBoxLayout( aBtnsFrame );
index 133a99d36ff72d7e2fa2ba00abadb27e70af2e3f..e060a5ac8692b4ea05527dfb35005ec4900b5c54 100644 (file)
@@ -85,7 +85,8 @@ QString HYDROGUI_DataObject::text( const int theColumnId ) const
       Handle(HYDROData_Zone) aZone = Handle(HYDROData_Zone)::DownCast( myData );
       if ( !aZone.IsNull() )
       {
-        HYDROData_SequenceOfObjects::Iterator anIter( aZone->GetGeometryObjects() );
+        HYDROData_SequenceOfObjects aSeq = aZone->GetGeometryObjects();
+        HYDROData_SequenceOfObjects::Iterator anIter( aSeq );
         for ( ; anIter.More(); anIter.Next() )
         {
           Handle(HYDROData_Object) aRefGeomObj =