summaryrefslogtreecommitdiffstats
path: root/src/gui/kernel/qaction.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/gui/kernel/qaction.h')
-rw-r--r--src/gui/kernel/qaction.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/gui/kernel/qaction.h b/src/gui/kernel/qaction.h
index 6920ec5..133fab4 100644
--- a/src/gui/kernel/qaction.h
+++ b/src/gui/kernel/qaction.h
@@ -67,6 +67,7 @@ class Q_GUI_EXPORT QAction : public QObject
Q_DECLARE_PRIVATE(QAction)
Q_ENUMS(MenuRole)
+ Q_ENUMS(Priority)
Q_PROPERTY(bool checkable READ isCheckable WRITE setCheckable)
Q_PROPERTY(bool checked READ isChecked WRITE setChecked DESIGNABLE isCheckable NOTIFY toggled)
Q_PROPERTY(bool enabled READ isEnabled WRITE setEnabled)
@@ -85,10 +86,14 @@ class Q_GUI_EXPORT QAction : public QObject
Q_PROPERTY(bool visible READ isVisible WRITE setVisible)
Q_PROPERTY(MenuRole menuRole READ menuRole WRITE setMenuRole)
Q_PROPERTY(bool iconVisibleInMenu READ isIconVisibleInMenu WRITE setIconVisibleInMenu)
+ Q_PROPERTY(Priority priority READ priority WRITE setPriority)
public:
enum MenuRole { NoRole, TextHeuristicRole, ApplicationSpecificRole, AboutQtRole,
AboutRole, PreferencesRole, QuitRole };
+ enum Priority { LowPriority = 0,
+ NormalPriority = 128,
+ HighPriority = 256};
explicit QAction(QObject* parent);
QAction(const QString &text, QObject* parent);
QAction(const QIcon &icon, const QString &text, QObject* parent);
@@ -123,6 +128,9 @@ public:
void setWhatsThis(const QString &what);
QString whatsThis() const;
+ void setPriority(Priority priority);
+ Priority priority() const;
+
#ifndef QT_NO_MENU
QMenu *menu() const;
void setMenu(QMenu *menu);