Salome HOME
Document's kind dependent features implemented
[modules/shaper.git] / src / XGUI / XGUI_MenuGroupPanel.cpp
index 30c459466e9eaa44c303d1c28ce09bc40501270c..a1883f26baec7d7eb14dce73bb02302f07784e91 100644 (file)
@@ -67,11 +67,25 @@ void XGUI_MenuGroupPanel::resizeEvent(QResizeEvent* theEvent)
   myLayout->setRowStretch(myMaxRow + 1, 1);
 }
 
-XGUI_Command* XGUI_MenuGroupPanel::addFeature(const QString& theId, const QString& theTitle,
-                                              const QString& theTip, const QIcon& theIcon,
-                                              const QKeySequence& theKeys, bool isCheckable)
+XGUI_Command* XGUI_MenuGroupPanel::addFeature(const QString& theId,
+                                              const QString& theTip,
+                                              const QString& theTitle,
+                                              const QIcon& theIcon,
+                                              const QKeySequence& theKeys)
 {
-  XGUI_Command* aCommand = new XGUI_Command(theId, theIcon, theTitle, this, isCheckable);
+  return addFeature(theId, theTip, theTitle, theIcon, QString(), theKeys, false);
+}
+
+XGUI_Command* XGUI_MenuGroupPanel::addFeature(const QString& theId,
+                                              const QString& theTitle,
+                                              const QString& theTip,
+                                              const QIcon& theIcon,
+                                              const QString& theDocumentKind,
+                                              const QKeySequence& theKeys,
+                                              bool isCheckable)
+{
+  XGUI_Command* aCommand = new XGUI_Command(theId, theDocumentKind, theIcon,
+                                            theTitle, this, isCheckable);
   aCommand->setToolTip(theTip);
   if (!theKeys.isEmpty()) {
     aCommand->setShortcut(theKeys);