2 * Copyright (C) 2011 Lukáš Karas <lukas.karas@centrum.cz>
4 * This program is free software; you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License as published by
6 * the Free Software Foundation; either version 2 of the License, or
7 * (at your option) any later version.
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
14 * You should have received a copy of the GNU General Public License
15 * along with this program; if not, write to the
16 * Free Software Foundation, Inc.,
17 * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
24 #include "../libnotify-qt/Notification.h"
25 #include "../backend/session.h"
27 #ifndef NOTIFICATIONITEM_H
28 #define NOTIFICATIONITEM_H
30 class NotificationItem
: public QObject
{
33 Q_DISABLE_COPY(NotificationItem
)
34 Q_ENUMS(NotificationType
)
37 enum NotificationType
{
45 NotificationItem(int id
, MaknetoBackend::Session
*session
, NotificationType type
, QString msg
= QString());
46 virtual ~NotificationItem();
49 QVariant
data(int role
);
51 NotificationType
getType();
52 MaknetoBackend::Session
*getSession();
55 void acceptNotification(int id
);
56 void declineNotification(int id
);
57 void notificationExpired(int id
);
61 void onNotificationAction(const QString
&);
62 void onNotificationClosed(quint32
);
64 void onCallEnded(const QString
&);
68 NotificationType type
;
70 MaknetoBackend::Session
*_session
;
71 Notification
*_notification
;
75 #endif /* NOTIFICATIONITEM_H */