summaryrefslogtreecommitdiff
path: root/qmsgwatchlet/qmsgwatchletplugin.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'qmsgwatchlet/qmsgwatchletplugin.cpp')
-rw-r--r--qmsgwatchlet/qmsgwatchletplugin.cpp15
1 files changed, 12 insertions, 3 deletions
diff --git a/qmsgwatchlet/qmsgwatchletplugin.cpp b/qmsgwatchlet/qmsgwatchletplugin.cpp
index 64a4157..2471d03 100644
--- a/qmsgwatchlet/qmsgwatchletplugin.cpp
+++ b/qmsgwatchlet/qmsgwatchletplugin.cpp
@@ -19,10 +19,19 @@ QStringList QMsgWatchletPlugin::watchlets()
return l;
}
-Watchlet* QMsgWatchletPlugin::getWatchlet(const QString& driver, QSettings& settings, WatchServer *server)
+WatchletPluginInterface::WatchletInfo QMsgWatchletPlugin::describeWatchlet(const QString &id)
{
- Q_UNUSED(driver);
- Q_UNUSED(settings);
+ WatchletInfo info;
+ if (id != "com.javispedro.sowatch.qmsg") return info;
+ info.name = "Inbox";
+ info.icon = QUrl::fromLocalFile(SOWATCH_QML_DIR "/qmsgwatchlet/icon.png");
+ return info;
+}
+
+Watchlet* QMsgWatchletPlugin::getWatchlet(const QString &id, ConfigKey *config, WatchServer *server)
+{
+ Q_UNUSED(config);
+ if (id != "com.javispedro.sowatch.qmsg") return 0;
return new QMsgWatchlet(server);
}