Salome HOME
updated copyright message
[modules/gui.git] / src / SUIT / SUIT_Study.h
old mode 100755 (executable)
new mode 100644 (file)
index 156c6bc..5ea1ad4
@@ -1,34 +1,37 @@
-// Copyright (C) 2005  OPEN CASCADE, CEA/DEN, EDF R&D, PRINCIPIA R&D
-// 
+// Copyright (C) 2007-2023  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.
-// 
-// 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 
+// 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 
+// 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
 //
+
 #ifndef SUIT_STUDY_H
 #define SUIT_STUDY_H
 
 #include "SUIT.h"
 
-#include "SUIT_Operation.h"
-
-#include <qobject.h>
-#include <qptrlist.h>
+#include <QList>
+#include <QObject>
+#include <QListIterator>
 
 class SUIT_DataObject;
 class SUIT_Application;
-class QDialog;
+class SUIT_Operation;
 
 #ifdef WIN32
 #pragma warning( disable:4251 )
@@ -45,15 +48,16 @@ public:
   virtual int       id() const;
 
   SUIT_DataObject*  root() const;
-  QString           studyName() const;
+  virtual QString   studyName() const;
   SUIT_Application* application() const;
 
   virtual bool      isSaved()  const;
   virtual bool      isModified() const;
+  virtual void      Modified();
 
-  virtual void      createDocument();
   virtual void      closeDocument( bool = true );
   virtual bool      openDocument( const QString& );
+  virtual bool      createDocument( const QString& );
 
   bool              saveDocument();
   virtual bool      saveDocumentAs( const QString& );
@@ -65,7 +69,7 @@ public:
   // Operation management
   SUIT_Operation*   activeOperation() const;
   virtual void      abortAllOperations();
-  const QPtrList<SUIT_Operation>& operations() const;
+  const QList<SUIT_Operation*>& operations() const;
   
   virtual SUIT_Operation* blockingOperation( SUIT_Operation* ) const;
 
@@ -75,7 +79,6 @@ public:
   bool              suspend( SUIT_Operation* );
   bool              resume( SUIT_Operation* );
 
-  virtual int       storeState();
   virtual void      restoreState(int savePoint);
 
 signals:
@@ -87,18 +90,18 @@ protected:
   virtual void      setRoot( SUIT_DataObject* );
   virtual void      setStudyName( const QString& );
 
-       virtual void      operationStarted( SUIT_Operation* );
-       virtual void      operationAborted( SUIT_Operation* );
-       virtual void      operationStopped( SUIT_Operation* );
-       virtual void      operationCommited( SUIT_Operation* );
+  virtual void      operationStarted( SUIT_Operation* );
+  virtual void      operationAborted( SUIT_Operation* );
+  virtual void      operationStopped( SUIT_Operation* );
+  virtual void      operationCommited( SUIT_Operation* );
 
   virtual bool      openTransaction();
   virtual bool      abortTransaction();
   virtual bool      hasTransaction() const;
-  virtual bool      commitTransaction( const QString& = QString::null );
+  virtual bool      commitTransaction( const QString& = QString() );
 
 private:
-  typedef QPtrList<SUIT_Operation> Operations;
+  typedef QList<SUIT_Operation*> Operations;
   void              stop( SUIT_Operation* );
 
 private: