diff options
Diffstat (limited to 'libqmenumodel/src/unitymenumodel.h')
-rw-r--r-- | libqmenumodel/src/unitymenumodel.h | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/libqmenumodel/src/unitymenumodel.h b/libqmenumodel/src/unitymenumodel.h index df35f08..a229f09 100644 --- a/libqmenumodel/src/unitymenumodel.h +++ b/libqmenumodel/src/unitymenumodel.h @@ -22,6 +22,7 @@ #include <QAbstractListModel> class ActionStateParser; class QQmlComponent; +class UnityMenuAction; class UnityMenuModel: public QAbstractListModel { @@ -61,18 +62,28 @@ public: Q_INVOKABLE void activate(int index, const QVariant& parameter = QVariant()); Q_INVOKABLE void changeState(int index, const QVariant& parameter); + void registerAction(UnityMenuAction* action); + void unregisterAction(UnityMenuAction* action); + Q_SIGNALS: void busNameChanged(const QByteArray &name); void actionsChanged(const QByteArray &path); void menuObjectPathChanged(const QByteArray &path); void actionStateParserChanged(ActionStateParser* parser); +protected Q_SLOTS: + void onRegisteredActionNameChanged(const QString& name); + void onRegisteredActionActivated(const QVariant& parameter); + void onRegisteredActionStateChanged(const QVariant& parameter); + protected: virtual bool event(QEvent* e); private: class UnityMenuModelPrivate *priv; friend class UnityMenuModelPrivate; + + UnityMenuModel(const UnityMenuModelPrivate& other, QObject *parent); }; #endif |