Salome HOME
Fix for the issue #2753 : error when dump/load script
[modules/shaper.git] / src / ModuleBase / ModuleBase_PagedContainer.h
index 9e8ec3e1bd91324670241b738f43bd4abd98fc8e..689e0ca9aa7a451ccb7f81a0d2fd8e92acf521fe 100644 (file)
 // 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<mailto:webmaster.salome@opencascade.com>
+// See http://www.salome-platform.org/ or
+// email : webmaster.salome@opencascade.com<mailto:webmaster.salome@opencascade.com>
 //
 
-/*
- * ModuleBase_PagedContainer.h
- *
- *  Created on: Mar 13, 2015
- *      Author: sbh
- */
-
 #ifndef MODULEBASE_PAGEDCONTAINER_H_
 #define MODULEBASE_PAGEDCONTAINER_H_
 
@@ -54,7 +48,8 @@ class MODULEBASE_EXPORT ModuleBase_PagedContainer : public ModuleBase_ModelWidge
   virtual int addPage( ModuleBase_PageBase* theWidget,
                        const QString& theName,
                        const QString& theCaseId,
-                       const QPixmap& theIcon );
+                       const QPixmap& theIcon,
+                       const QString& theTooltip);
 
   /// Redefinition of virtual function
   virtual QList<QWidget*> getControls() const;
@@ -68,6 +63,9 @@ class MODULEBASE_EXPORT ModuleBase_PagedContainer : public ModuleBase_ModelWidge
   /// Redefinition of virtual function
   virtual void enableFocusProcessing();
 
+  /// The slot is called when user press Ok or OkPlus buttons in the parent property panel
+  virtual void onFeatureAccepted();
+
  protected:
    /// Returns index of current page
   virtual int currentPageIndex() const = 0;
@@ -84,6 +82,9 @@ class MODULEBASE_EXPORT ModuleBase_PagedContainer : public ModuleBase_ModelWidge
   /// Redefinition of virtual function
   virtual bool restoreValueCustom();
 
+  // A flag which let to remeber last user choice and restore it on next launch
+  bool myRemeberChoice;
+
  protected slots:
    /// A slot called on page change
   void onPageChanged();
@@ -92,7 +93,8 @@ class MODULEBASE_EXPORT ModuleBase_PagedContainer : public ModuleBase_ModelWidge
   bool myIsFocusOnCurrentPage;
   QStringList myCaseIds;
   QList<ModuleBase_PageBase*> myPages;
-
+  bool myIsFirst;
+  std::string myDefValue;
 };
 
 #endif /* MODULEBASE_PAGEDCONTAINER_H_ */