blob: d4c1bcbe8259447099c8bd12342acf6e46d1fa05 (
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
|
#ifndef DBUSCONNECTOR_H
#define DBUSCONNECTOR_H
#include <QObject>
#include <QStringList>
#include <QVariantMap>
#include <Log4Qt/Logger>
class DBusConnector : public QObject
{
Q_OBJECT
LOG4QT_DECLARE_QCLASS_LOGGER
Q_PROPERTY(QVariantMap pebble READ pebble NOTIFY pebbleChanged)
Q_PROPERTY(QStringList services READ services NOTIFY servicesChanged)
QVariantMap pebbleProps;
QStringList dbusServices;
public:
explicit DBusConnector(QObject *parent = 0);
QVariantMap pebble() const { return pebbleProps; }
QStringList services() const { return dbusServices; }
signals:
void pebbleChanged();
void servicesChanged();
public slots:
bool findPebble();
protected slots:
void onServiceRegistered(const QString &);
void onServiceUnregistered(const QString &);
};
#endif // DBUSCONNECTOR_H
|