Lomiri
Loading...
Searching...
No Matches
plugin.cpp
1/*
2 * Copyright (C) 2013 Canonical Ltd.
3 *
4 * This program is free software: you can redistribute it and/or modify it
5 * under the terms of the GNU Lesser General Public License, as
6 * published by the Free Software Foundation; either version 2.1 or 3.0
7 * of the License.
8 *
9 * This program is distributed in the hope that it will be useful, but
10 * WITHOUT ANY WARRANTY; without even the implied warranties of
11 * MERCHANTABILITY, SATISFACTORY QUALITY or FITNESS FOR A PARTICULAR
12 * PURPOSE. See the applicable version of the GNU Lesser General Public
13 * License for more details.
14 *
15 * You should have received a copy of both the GNU Lesser General Public
16 * License along with this program. If not, see <http://www.gnu.org/licenses/>
17 *
18 * Authored by: Diego Sarmentero <diego.sarmentero@canonical.com>
19 */
20
21
22#include "plugin.h"
23#include "DownloadTracker.h"
24
25#include <QtQml/qqml.h>
26#include <QtQml/QQmlContext>
27
28
29void BackendPlugin::registerTypes(const char *uri)
30{
31 Q_ASSERT(uri == QLatin1String("Lomiri.DownloadDaemonListener"));
32
33 qmlRegisterType<DownloadTracker>(uri, 0, 1, "DownloadTracker");
34}
35
36void BackendPlugin::initializeEngine(QQmlEngine *engine, const char *uri)
37{
38 QQmlExtensionPlugin::initializeEngine(engine, uri);
39}