25#ifndef _NOTIFICATION_MANAGER_H__
26#define _NOTIFICATION_MANAGER_H__
30#include "observable_evtvar.h"
40 std::string AddNotification(std::shared_ptr<Notification> _notification);
49 std::string AddNotification(NotificationSeverity _severity,
50 const std::string& _message,
51 int timeout_secs = -1);
64 return active_notifications;
67 size_t GetNotificationCount()
const {
return active_notifications.size(); }
75 void OnTimer(wxTimerEvent& event);
77 std::vector<std::shared_ptr<Notification>> active_notifications;
78 wxTimer m_timeout_timer;
Generic event handling between MVC Model and Controller based on a shared EventVar variable.
The global list of user notifications, a singleton.
const std::vector< std::shared_ptr< Notification > > & GetNotifications() const
Return current active notifications.
bool AcknowledgeNotification(const std::string &guid)
User ack on a notification which eventually will remove it.
EventVar evt_notificationlist_change
Notified without data when a notification is added or removed.
NotificationSeverity GetMaxSeverity()
Return max severity among current active notifications.