summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'Swift/QtUI/WindowsNotifier.h')
-rw-r--r--Swift/QtUI/WindowsNotifier.h36
1 files changed, 36 insertions, 0 deletions
diff --git a/Swift/QtUI/WindowsNotifier.h b/Swift/QtUI/WindowsNotifier.h
new file mode 100644
index 0000000..dbf86a2
--- /dev/null
+++ b/Swift/QtUI/WindowsNotifier.h
@@ -0,0 +1,36 @@
+/*
+ * Copyright (c) 2010 Remko Tronçon
+ * Licensed under the GNU General Public License v3.
+ * See Documentation/Licenses/GPLv3.txt for more information.
+ */
+
+#pragma once
+
+#include <map>
+
+#include <QObject>
+#include <SwifTools/Notifier/Notifier.h>
+#include <SwifTools/Notifier/SnarlNotifier.h>
+
+class QSystemTrayIcon;
+
+namespace Swift {
+ class WindowsNotifier : public QObject, public Notifier {
+ Q_OBJECT
+
+ public:
+ WindowsNotifier(const String& name, const boost::filesystem::path& icon, QSystemTrayIcon* tray);
+ ~WindowsNotifier();
+
+ virtual void showMessage(Type type, const String& subject, const String& description, const boost::filesystem::path& picture, boost::function<void()> callback);
+
+ private slots:
+ void handleMessageClicked();
+
+ private:
+ QSystemTrayIcon* tray;
+ Win32NotifierWindow* notifierWindow;
+ SnarlNotifier* snarlNotifier;
+ boost::function<void()> lastCallback;
+ };
+}