diff options
Diffstat (limited to 'notificationmonitor.h')
-rw-r--r-- | notificationmonitor.h | 34 |
1 files changed, 34 insertions, 0 deletions
diff --git a/notificationmonitor.h b/notificationmonitor.h new file mode 100644 index 0000000..8563053 --- /dev/null +++ b/notificationmonitor.h @@ -0,0 +1,34 @@ +#ifndef NOTIFICATIONMONITOR_H +#define NOTIFICATIONMONITOR_H + +#include <QtCore/QObject> +#include <QtCore/QMap> + +namespace watchfish +{ + +class Notification; + +class NotificationMonitor : public QObject +{ + Q_OBJECT + +public: + ~NotificationMonitor(); + + static NotificationMonitor *instance(); + + void processIncomingNotification(quint32 id, const QVariantHash &content); + void processCloseNotification(quint32 id, quint32 reason); + +signals: + void notification(Notification *n); + +private: + explicit NotificationMonitor(QObject *parent = 0); + QMap<quint32, Notification*> _notifs; +}; + +} + +#endif // NOTIFICATIONMONITOR_H |