Salome HOME
Updated copyright comment
[modules/geom.git] / src / GEOMToolsGUI / GEOMToolsGUI_ReduceStudyDlg.cxx
index 9ef66592a70801a173b45fe14f556d7c4d937a66..a4d819cc163984ab6f4f922c51d892e4c6fb6c33 100644 (file)
@@ -1,4 +1,4 @@
-// Copyright (C) 2014-2016  CEA/DEN, EDF R&D, OPEN CASCADE
+// Copyright (C) 2014-2024  CEA, EDF, OPEN CASCADE
 //
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
@@ -165,13 +165,13 @@ void GEOMToolsGUI_ReduceStudyDlg::init( const std::set<std::string>& theObjectEn
   GeometryGUI::GetGeomGen()->GetEntriesToReduceStudy( keptObjects, parentsObjects,
                                                              subObjects, otherObjects );
 
-  for ( int i = 0; i < keptObjects->length(); i++ )
+  for ( unsigned long i = 0; i < keptObjects->length(); i++ )
     myKeptObjects.insert( keptObjects[i].in() );
-  for( int i = 0; i< otherObjects->length(); i++ )
+  for( unsigned long i = 0; i< otherObjects->length(); i++ )
     myRemovedObjects.insert( otherObjects[i].in() );
-  for( int i = 0; i< parentsObjects->length(); i++ )
+  for( unsigned long i = 0; i< parentsObjects->length(); i++ )
     myListParents.insert( parentsObjects[i].in() );
-  for( int i = 0; i< subObjects->length(); i++ )
+  for( unsigned long i = 0; i< subObjects->length(); i++ )
     myListSubObjects.insert( subObjects[i].in() );
 
   update();
@@ -219,15 +219,10 @@ void GEOMToolsGUI_ReduceStudyDlg::createTreeWidget( QTreeWidget* theTreeWidget )
   QTreeWidgetItem * headerItem = new QTreeWidgetItem( columnNames );
   theTreeWidget->setHeaderItem ( headerItem );
   theTreeWidget->header()->moveSection( 1, 0 );
-#if QT_VERSION < QT_VERSION_CHECK(5, 0, 0)
-  theTreeWidget->header()->setClickable( true );
-  theTreeWidget->header()->setMovable( false );
-  theTreeWidget->header()->setResizeMode( 1, QHeaderView::ResizeToContents );
-#else
   theTreeWidget->header()->setSectionsClickable( true );
   theTreeWidget->header()->setSectionsMovable( false );
   theTreeWidget->header()->setSectionResizeMode( 1, QHeaderView::ResizeToContents );
-#endif
+
   theTreeWidget->setSelectionMode( QAbstractItemView::ExtendedSelection );
 }
 
@@ -405,7 +400,7 @@ void GEOMToolsGUI_ReduceStudyDlg::unpublishObjects( std::set<std::string>& theOb
       myDisplayer.EraseWithChildren( new SALOME_InteractiveObject( studyEntry.c_str(), "GEOM", "TEMP_IO" ) );
       // hide references if any
       std::vector< _PTR(SObject) > vso = aStudy->FindDependances(obj);
-      for ( int i = 0; i < vso.size(); i++ ) {
+      for ( int i = 0; i < (int)vso.size(); i++ ) {
         _PTR(SObject) refObj = vso[i];
         aDrw = aStudyBuilder->FindOrCreateAttribute( refObj, "AttributeDrawable" );
         aDrw->SetDrawable( false );
@@ -708,16 +703,16 @@ void GEOMToolsGUI_ReduceStudyDlg::clickOnHelp()
 GEOMToolsGUI_TreeWidgetItem::GEOMToolsGUI_TreeWidgetItem( QTreeWidget* view, const QStringList &strings,
                                                           char* studyEntry, int type )
 :QTreeWidgetItem( view, strings, type ),
- myStudyEntry( studyEntry ),
- myVisible( false )
+ myVisible( false ),
+ myStudyEntry( studyEntry )
 {
 }
 
 GEOMToolsGUI_TreeWidgetItem::GEOMToolsGUI_TreeWidgetItem( QTreeWidgetItem* parent, const QStringList &strings,
                                                           char* studyEntry, int type )
 :QTreeWidgetItem( parent, strings, type ),
- myStudyEntry( studyEntry ),
- myVisible( false )
+ myVisible( false ),
+ myStudyEntry( studyEntry )
 {
 }