Salome HOME
Issue #6 Extended processing of nested actions.
[modules/shaper.git] / src / XGUI / XGUI_Command.h
index 34c5f63f6dee6b8c0d55ac06211d1a1fc50804d3..380b64ae4b8ce90eb1761995cc724d67dc5f81ca 100644 (file)
@@ -15,8 +15,8 @@ class XGUI_EXPORT XGUI_Command: public QWidgetAction
 {
 Q_OBJECT
 public:
-  XGUI_Command(const QString& theId, QObject * parent);
-  XGUI_Command(const QString& theId, const QIcon& icon, const QString& text, QObject* parent);
+  XGUI_Command(const QString& theId, QObject * parent, bool isCheckable = false);
+  XGUI_Command(const QString& theId, const QIcon& icon, const QString& text, QObject* parent, bool isCheckable = false);
   ~XGUI_Command();
 
   //! Returns true if the command is enabled
@@ -34,6 +34,9 @@ public:
     return myId;
   }
 
+  const QStringList& unblockableCommands() const;
+  void setUnblockableCommands(const QStringList& myUnblockableCommands);
+
   //! Connect the command to a slot
   virtual void connectTo(const QObject* theResiver, const char* theSlot);
 
@@ -43,6 +46,9 @@ protected:
 
 private:
   QString myId;
+  bool myCheckable;
+  //! List of Ids of commands which WILL NOT be blocked when the command is on.
+  QStringList myUnblockableCommands;
 };
 
 #endif