pollymc/launcher/ui/dialogs/NotificationDialog.h

45 lines
778 B
C
Raw Normal View History

#ifndef NOTIFICATIONDIALOG_H
#define NOTIFICATIONDIALOG_H
#include <QDialog>
2015-02-09 06:21:14 +05:30
#include "notifications/NotificationChecker.h"
namespace Ui {
class NotificationDialog;
}
class NotificationDialog : public QDialog
{
2018-07-15 18:21:05 +05:30
Q_OBJECT
public:
2018-07-15 18:21:05 +05:30
explicit NotificationDialog(const NotificationChecker::NotificationEntry &entry, QWidget *parent = 0);
~NotificationDialog();
2018-07-15 18:21:05 +05:30
enum ExitCode
{
Normal,
DontShowAgain
};
protected:
2018-07-15 18:21:05 +05:30
void timerEvent(QTimerEvent *event);
private:
2018-07-15 18:21:05 +05:30
Ui::NotificationDialog *ui;
2018-07-15 18:21:05 +05:30
int m_dontShowAgainTime = 10;
int m_closeTime = 5;
2018-07-15 18:21:05 +05:30
QString m_dontShowAgainText;
QString m_closeText;
private
slots:
2018-07-15 18:21:05 +05:30
void on_dontShowAgainBtn_clicked();
void on_closeBtn_clicked();
};
#endif // NOTIFICATIONDIALOG_H