]> SALOME platform Git repositories - modules/shaper.git/commitdiff
Salome HOME
Add help button to toolbars management dialog boxes
authorvsv <vsv@opencascade.com>
Wed, 7 Nov 2018 12:22:40 +0000 (15:22 +0300)
committervsv <vsv@opencascade.com>
Wed, 7 Nov 2018 12:22:40 +0000 (15:22 +0300)
src/SHAPERGUI/SHAPERGUI_ToolbarsMgr.cpp
src/SHAPERGUI/SHAPERGUI_ToolbarsMgr.h

index 69745537715d9bd76df92a18955c0a8303f87288..e390a4c366bfff536b443b8810513720ccf1c7f2 100644 (file)
@@ -146,10 +146,12 @@ SHAPERGUI_ToolbarsDlg::SHAPERGUI_ToolbarsDlg(SHAPERGUI* theModule)
 
   // Buttons part of the dialog
   QDialogButtonBox* aButtons =
-    new QDialogButtonBox(QDialogButtonBox::Ok | QDialogButtonBox::Cancel, Qt::Horizontal, this);
+    new QDialogButtonBox(QDialogButtonBox::Help | QDialogButtonBox::Ok | QDialogButtonBox::Cancel,
+      Qt::Horizontal, this);
   aMailLayout->addWidget(aButtons);
   connect(aButtons, SIGNAL(accepted()), SLOT(accept()));
   connect(aButtons, SIGNAL(rejected()), SLOT(reject()));
+  connect(aButtons, SIGNAL(helpRequested()), SLOT(onHelp()));
 
   updateToolbarsList();
   updateNumber();
@@ -244,6 +246,11 @@ void SHAPERGUI_ToolbarsDlg::onReset()
   myIsReset = true;
 }
 
+void SHAPERGUI_ToolbarsDlg::onHelp()
+{
+
+}
+
 
 //************************************************************************************
 //************************************************************************************
@@ -351,10 +358,12 @@ SHAPERGUI_ToolbarItemsDlg::SHAPERGUI_ToolbarItemsDlg(QWidget* theParent,
 
   // Buttons part of the dialog
   QDialogButtonBox* aButtons =
-    new QDialogButtonBox(QDialogButtonBox::Ok | QDialogButtonBox::Cancel, Qt::Horizontal, this);
+    new QDialogButtonBox(QDialogButtonBox::Help | QDialogButtonBox::Ok | QDialogButtonBox::Cancel,
+      Qt::Horizontal, this);
   aMailLayout->addWidget(aButtons);
   connect(aButtons, SIGNAL(accepted()), SLOT(accept()));
   connect(aButtons, SIGNAL(rejected()), SLOT(reject()));
+  connect(aButtons, SIGNAL(helpRequested()), SLOT(onHelp()));
 }
 
 void SHAPERGUI_ToolbarItemsDlg::onAddItem()
@@ -457,3 +466,8 @@ QIntList SHAPERGUI_ToolbarItemsDlg::getItems(QListWidget* theWidget, int theStar
   }
   return aList;
 }
+
+void SHAPERGUI_ToolbarItemsDlg::onHelp()
+{
+
+}
index d9fcbde45c124d0052cdc7fb4b41e7f129b92d50..f86f9bd3235a16ec4f2e62e4b26578576cee4e61 100644 (file)
@@ -79,6 +79,9 @@ private slots:
   /// A slot to move a current item down in list of toolbar command
   void onDown();
 
+  /// A slot on help call
+  void onHelp();
+
 private:
   QIntList getItems(QListWidget* theWidget, int theStart) const;
 
@@ -119,9 +122,12 @@ private slots:
   /// A slot to delete a current toolbar
   void onDelete();
 
-  /// A slot to delete a current toolbar
+  /// A slot to reset toolbars
   void onReset();
 
+  /// A slot on help call
+  void onHelp();
+
   /// A slot called on double click on item in list
   void onDoubleClick(const QModelIndex& theIdx);