Salome HOME
Fix memory freed
[modules/gui.git] / src / GLViewer / GLViewer_BaseObjects.h
index fdd1f75fc7e1b67c76de14794abd697a5185062f..93d252e9e266b3fc6e5205047fecf3424d02ca16 100644 (file)
@@ -1,28 +1,47 @@
+// Copyright (C) 2007-2024  CEA, EDF, OPEN CASCADE
+//
+// Copyright (C) 2003-2007  OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License, or (at your option) any later version.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+//
+
+//  Author : OPEN CASCADE
 // File:      GLViewer_BaseObjects.h
 // Created:   November, 2004
-// Author:    OCC team
-// Copyright (C) CEA 2004
-
+//
 #ifndef GLVIEWER_BASEOBJECTS_H
 #define GLVIEWER_BASEOBJECTS_H
 
 #include "GLViewer.h"
 #include "GLViewer_Object.h"
 
-#include <qcolor.h>
-#include <qvaluelist.h>
+#include <QColor>
 
 #include <TColStd_SequenceOfInteger.hxx>
 
-#ifdef WNT
+#ifdef WIN32
 #pragma warning( disable:4251 )
 #endif
 
 /*! 
- * Class GLViewer_MarkerSet
- * OpenGL MarkerSet
- */
-
+ \class GLViewer_MarkerSet
+ OpenGL MarkerSet
+*/
 class GLVIEWER_API GLViewer_MarkerSet : public GLViewer_Object
 {
 public:
@@ -74,11 +93,11 @@ public:
   float                    getMarkerSize() const { return myMarkerSize; }
   
   //! Export numbers of heghlighted/selected markers
-  void                     exportNumbers( QValueList<int>& high, QValueList<int>& unhigh,
-                                          QValueList<int>& sel, QValueList<int>& unsel );
+  void                     exportNumbers( QList<int>& high, QList<int>& unhigh,
+                                          QList<int>& sel, QList<int>& unsel );
   
   //! Returns selected numbers
-  QValueList<int>          getSelectedElements() { return mySelNumbers; }
+  QList<int>               getSelectedElements() { return mySelNumbers; }
   //! Adds or remove selected number
   bool                     addOrRemoveSelected( int index );
   //! Adds selected numbers
@@ -91,25 +110,24 @@ protected:
   GLfloat*                myXCoord;
   GLfloat*                myYCoord;    
   GLfloat                 myMarkerSize;
-  QValueList<int>         myHNumbers;
-  QValueList<int>         myUHNumbers;
-  QValueList<int>         mySelNumbers;
-  QValueList<int>         myCurSelNumbers;
-  QValueList<int>         myUSelNumbers;
-  QValueList<int>         myPrevHNumbers;
+  QList<int>              myHNumbers;
+  QList<int>              myUHNumbers;
+  QList<int>              mySelNumbers;
+  QList<int>              myCurSelNumbers;
+  QList<int>              myUSelNumbers;
+  QList<int>              myPrevHNumbers;
   TColStd_SequenceOfInteger mySelectedIndexes;
 };
 
 /*! 
- * Class  GLViewer_Polyline
- * OpenGL Polyline
- */
-
+ \class  GLViewer_Polyline
+ OpenGL Polyline
+*/
 class GLVIEWER_API GLViewer_Polyline: public GLViewer_Object
 {
 public:
   GLViewer_Polyline( int number = 1, float size = 5.0, const QString& toolTip = "GLPolyline" );
- ~GLViewer_Polyline();
virtual ~GLViewer_Polyline();
   
   // redefined  methods
   virtual void            compute();
@@ -159,12 +177,12 @@ public:
   //! Checks highlight as whole object status
   GLboolean               isHighSelAll() const { return myHighSelAll; }
   
-  //! Export numbers of heghlighted/selected lines
-  void                     exportNumbers( QValueList<int>& high, QValueList<int>& unhigh,
-                                          QValueList<int>& sel, QValueList<int>& unsel );
+  //! Export numbers of highlighted/selected lines
+  void                    exportNumbers( QList<int>& high, QList<int>& unhigh,
+                                         QList<int>& sel, QList<int>& unsel );
 
   //! Returns numbers of selected lines
-  QValueList<int>         getSelectedElements() { return mySelNumbers; }
+  QList<int>              getSelectedElements() { return mySelNumbers; }
 
 protected:
   GLfloat*                myXCoord;
@@ -173,20 +191,21 @@ protected:
   GLboolean               myIsClosed;
   GLboolean               myHighSelAll;
   
-  QValueList<int>         myHNumbers;
-  QValueList<int>         myUHNumbers;
-  QValueList<int>         mySelNumbers;
-  QValueList<int>         myUSelNumbers;
-  QValueList<int>         myCurSelNumbers;
-  QValueList<int>         myPrevHNumbers;
+  QList<int>              myHNumbers;
+  QList<int>              myUHNumbers;
+  QList<int>              mySelNumbers;
+  QList<int>              myUSelNumbers;
+  QList<int>              myCurSelNumbers;
+  QList<int>              myPrevHNumbers;
   TColStd_SequenceOfInteger mySelectedIndexes;
   
   GLboolean               myHighFlag;
 };
 
-// Class:   GLViewer_TextObject
-// Descr:   Text as Object for OpenGL
-
+/*!
+  \class GLViewer_TextObject
+  Text as Object for OpenGL
+*/
 class GLVIEWER_API GLViewer_TextObject : public GLViewer_Object
 {
 public:  
@@ -230,7 +249,7 @@ protected:
   int                       myHeight;
 };
 
-#ifdef WNT
+#ifdef WIN32
 #pragma warning ( default:4251 )
 #endif