summaryrefslogtreecommitdiff
path: root/libsowatch/notification.h
blob: 3505c44def1b76efba1f860b2da931dcc7ddf872 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
#ifndef SOWATCH_NOTIFICATION_H
#define SOWATCH_NOTIFICATION_H

#include <QtCore/QString>
#include <QtCore/QDateTime>
#include <QtGui/QImage>
#include "sowatch_global.h"

namespace sowatch
{

class SOWATCH_EXPORT Notification : public QObject
{
	Q_OBJECT
	Q_ENUMS(Type)

public:
	enum Type {
		OtherNotification = 0,
		CallNotification,
		MissedCallNotification,
		SmsNotification,
		MmsNotification,
		ImNotification,
		EmailNotification,
		CalendarNotification,
		TypeCount
	};

	explicit Notification(QObject *parent = 0);
	virtual ~Notification();

	virtual Type type() const = 0;
	virtual uint count() const = 0;
	virtual QDateTime dateTime() const = 0;
	virtual QString displayTime() const;
	virtual QString title() const = 0;
	virtual QString body() const = 0;
	virtual QImage image() const;

public slots:
	virtual void activate() = 0;
	virtual void clear() = 0;

signals:
	void changed();
	void cleared();
};

}

#endif // SOWATCH_NOTIFICATION_H