diff options
Diffstat (limited to 'src/common/qdbusactiongroup.h')
-rw-r--r-- | src/common/qdbusactiongroup.h | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/src/common/qdbusactiongroup.h b/src/common/qdbusactiongroup.h index 28e4f25..f2b2033 100644 --- a/src/common/qdbusactiongroup.h +++ b/src/common/qdbusactiongroup.h @@ -43,6 +43,8 @@ public: int count() const; + Q_INVOKABLE QStateAction *action(const QString &actionName); + Q_SIGNALS: void busTypeChanged(BusType type); void busNameChanged(const QString &busNameChanged); @@ -50,10 +52,11 @@ Q_SIGNALS: void statusChanged(ConnectionStatus status); void countChanged(int count); + public Q_SLOTS: void start(); void stop(); - QStateAction *action(const QString &actionName); + protected: virtual void serviceAppear(GDBusConnection *connection); @@ -74,10 +77,11 @@ private: void setIntBusType(int busType); void setActionGroup(GDBusActionGroup *ag); - void addAction(const char *actionName); - void removeAction(const char *actionName); + QStateAction *addAction(const char *actionName, bool create); + void removeAction(const char *actionName, bool erase); void updateAction(const char *actionName, GVariant *state); void clear(); + QStateAction *actionImpl(const QString &actionName); // glib slots static void onActionAdded(GDBusActionGroup *ag, gchar *actionName, gpointer data); |