Salome HOME
Refactoring
[modules/smesh.git] / src / SMESHGUI / SMESHGUI_Hypotheses.h
index cccf69fd6df83b6e4da518933c7c77e885c6643d..ac6fa8d720ee30837256f8db43b8c143a24742e2 100644 (file)
@@ -29,6 +29,7 @@
 // SMESH includes
 #include "SMESH_SMESHGUI.hxx"
 #include "SMESHGUI_HypothesesUtils.h"
+#include "SMESHGUI_Helper.h"
 
 // Qt includes
 #include <QtxDialog.h>
@@ -43,7 +44,7 @@ class QEventLoop;
 /*!
  * \brief Auxiliary class for creation of hypotheses
 */
-class SMESHGUI_EXPORT SMESHGUI_GenericHypothesisCreator : public QObject
+class SMESHGUI_EXPORT SMESHGUI_GenericHypothesisCreator : public QObject, public SMESHGUI_Helper
 {
   Q_OBJECT
 
@@ -52,12 +53,12 @@ public:
   virtual ~SMESHGUI_GenericHypothesisCreator();
 
   void                         create( SMESH::SMESH_Hypothesis_ptr,
-                                      const QString&, QWidget*, QObject*, const QString& );
+                                       const QString&, QWidget*, QObject*, const QString& );
   void                         create( bool, const QString&, QWidget*, QObject*, const QString& );
   void                         edit( SMESH::SMESH_Hypothesis_ptr, const QString&, QWidget*, QObject*, const QString& );
   void                         setInitParamsHypothesis(SMESH::SMESH_Hypothesis_ptr);
 
-  virtual bool                 checkParams( QString& ) const;
+  virtual bool                 checkParams( QString&, QStringList& ) const;
   virtual void                 onReject();
   virtual QString              helpPage() const;
 
@@ -68,6 +69,9 @@ public:
   QString                      getShapeEntry() const { return myShapeEntry; }
   void                         setShapeEntry( const QString& theEntry );
 
+  QString                      getMainShapeEntry() const { return myMainShapeEntry; }
+  void                         setMainShapeEntry( const QString& theEntry ) { myMainShapeEntry = theEntry; }
+
 signals:
   void                         finished( int );
 
@@ -102,7 +106,7 @@ protected:
   static  QString              stdParamValues( const ListOfStdParams& );
   virtual void                 attuneStdWidget( QWidget*, const int ) const;
   virtual QWidget*             getCustomWidget( const StdParam&, 
-                                               QWidget*, const int ) const;
+                                                QWidget*, const int ) const;
   virtual bool                 getParamFromCustomWidget( StdParam&, QWidget* ) const;
   virtual void                 valueChanged( QWidget* );
   virtual QString              caption() const;
@@ -126,6 +130,7 @@ private:
   bool                         myIsCreate;
   QtxDialog*                   myDlg;
   QString                      myShapeEntry;
+  QString                      myMainShapeEntry;
 };
 
 class SMESHGUI_HypothesisDlg : public QtxDialog
@@ -162,7 +167,7 @@ public:
                   const QList<int>&, const bool,
                   const QStringList&, const QStringList&,
                   const QStringList&, const QStringList&,
-                 const bool=true, const bool supportSub=false );
+                  const bool=true, const bool supportSub=false );
 
   QString TypeName;        //!< hypothesis type name
   QString PluginName;      //!< plugin name