2
* Copyright (C) 2015 Canonical, Ltd.
4
* This program is free software: you can redistribute it and/or modify it
5
* under the terms of the GNU General Public License version 3, as published
6
* by the Free Software Foundation.
8
* This library is distributed in the hope that it will be useful, but WITHOUT
9
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
10
* FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
13
* You should have received a copy of the GNU General Public License
14
* along with this program. If not, see <http://www.gnu.org/licenses/>.
17
#ifndef DBUSTYPES_HPP_
18
#define DBUSTYPES_HPP_
21
#include <QDBusArgument>
23
#include <QVariantMap>
25
struct NotificationData
32
QList<QString> actions;
36
NotificationData& setAppName(const QString& appName_);
38
NotificationData& setId(quint32 id_);
40
NotificationData& setAppIcon(const QString& appIcon_);
42
NotificationData& setSummary(const QString& summary_);
44
NotificationData& setBody(const QString& body_);
46
NotificationData& setActions(const QList<QString>& actions_);
48
NotificationData& setHints(const QVariantMap& hints_);
50
NotificationData& setExpireTimeout(quint32 expireTimeout_);
52
NotificationData& operator=(const NotificationData& other);
54
bool operator==(const NotificationData& other) const;
57
typedef QList<NotificationData> NotificationDataList;
59
QDBusArgument &operator<<(QDBusArgument &, const NotificationData &);
60
const QDBusArgument &operator>>(const QDBusArgument &, NotificationData &);
63
void registerNotificationMetaTypes();
66
Q_DECLARE_METATYPE(NotificationData)
67
Q_DECLARE_METATYPE(NotificationDataList)