30 lines
616 B
C++
30 lines
616 B
C++
#ifndef NOTIFICATIONMANAGER_H
|
|
#define NOTIFICATIONMANAGER_H
|
|
|
|
#include <QObject>
|
|
#include <QString>
|
|
|
|
class QWidget;
|
|
class SystemTrayManager;
|
|
|
|
class NotificationManager : public QObject
|
|
{
|
|
Q_OBJECT
|
|
|
|
public:
|
|
explicit NotificationManager(QWidget *parent = nullptr);
|
|
~NotificationManager() override;
|
|
|
|
void setSystemTrayManager(SystemTrayManager *trayManager);
|
|
void setNotificationsEnabled(bool enabled);
|
|
void showNotification(const QString &message) const;
|
|
|
|
private:
|
|
QWidget *m_parent;
|
|
SystemTrayManager *m_trayManager;
|
|
bool m_notificationsEnabled;
|
|
};
|
|
|
|
#endif // NOTIFICATIONMANAGER_H
|
|
|