Select highlighted channel on clicking the blinking tray icon in all cases
[quassel.git] / src / qtui / knotificationbackend.h
index 706478e..d846417 100644 (file)
@@ -1,5 +1,5 @@
 /***************************************************************************
-*   Copyright (C) 2005-08 by the Quassel Project                          *
+*   Copyright (C) 2005-09 by the Quassel Project                          *
 *   devel@quassel-irc.org                                                 *
 *                                                                         *
 *   This program is free software; you can redistribute it and/or modify  *
@@ -21,6 +21,8 @@
 #ifndef KNOTIFICATIONBACKEND_H_
 #define KNOTIFICATIONBACKEND_H_
 
+#include <KSystemTrayIcon>
+
 #include "abstractnotificationbackend.h"
 #include "settingspage.h"
 
@@ -37,8 +39,19 @@ public:
   void close(uint notificationId);
   virtual SettingsPage *createConfigWidget() const;
 
+private slots:
+  void notificationActivated();
+  void notificationActivated(QSystemTrayIcon::ActivationReason);
+  void notificationActivated(uint notificationId);
+  void notificationClosed();
+
 private:
   class ConfigWidget;
+
+  void removeNotificationById(uint id);
+
+  QHash<KNotification *, uint> _notificationIds;
+  uint _lastNotificationId;
 };
 
 class KNotificationBackend::ConfigWidget : public SettingsPage {