blob: d1f7ad06d121a79f5c7523a55ddb6b9c882ee288 (
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
|
#include <QtConnectivity/QBluetoothAddress>
#include "liveview.h"
#include "liveviewscanner.h"
#include "liveviewplugin.h"
using namespace sowatch;
QTM_USE_NAMESPACE
LiveViewPlugin::LiveViewPlugin()
{
}
LiveViewPlugin::~LiveViewPlugin()
{
}
QStringList LiveViewPlugin::drivers()
{
QStringList d;
d << "liveview";
return d;
}
WatchScanner* LiveViewPlugin::getScanner(QObject *parent)
{
return new LiveViewScanner(parent);
}
QUrl LiveViewPlugin::getConfigQmlUrl(const QString &driver)
{
if (driver == "liveview") {
return QUrl::fromLocalFile(SOWATCH_QML_DIR "/liveview-config.qml");
} else {
return QUrl();
}
}
Watch* LiveViewPlugin::getWatch(const QString& driver, ConfigKey* settings, QObject *parent)
{
if (driver == "liveview") {
return new LiveView(settings, parent);
} else {
return 0;
}
}
Q_EXPORT_PLUGIN2(liveview, LiveViewPlugin)
|