/* Copyright (C) 2017 Dan Chapman This file is part of Dekko email client for Ubuntu devices This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License or (at your option) version 3 This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . */ #include "MazDBPlugin.h" #include #include #include #include #include #include #include #include #include #include void MazDBPlugin::registerTypes(const char *uri) { Q_ASSERT(uri == QLatin1String("MazDB")); // @uri MazDB qmlRegisterType("MazDB", 1, 0, "MazDB"); qmlRegisterType("MazDB", 1, 0, "MazDBListModel"); qmlRegisterType("MazDB", 1, 0, "MazDBSettings"); qmlRegisterType("MazDB", 1, 0, "MazDBSortProxy"); qmlRegisterType("MazDB", 1, 0, "MazDBQueryEngine"); qmlRegisterType("MazDB", 1, 0, "MazDBQuery"); qmlRegisterType("MazDB", 1, 0, "WHERE"); qmlRegisterType("MazDB", 1, 0, "AND"); qmlRegisterType("MazDB", 1, 0, "OR"); qmlRegisterUncreatableType("MazDB", 1, 0, "MazOptions", QObject::tr("Cannot create separate instance of Options")); qmlRegisterUncreatableType("MazDB", 1, 0, "MazDBBatch", QObject::tr("Cannot create separate instance of Batch")); qmlRegisterUncreatableType("MazDB", 1, 0, "Query", QObject::tr("Cannot create separate instance of QueryBase")); qmlRegisterUncreatableType("MazDB", 1, 0, "Range", QObject::tr("Cannot create separate instance of Range")); } void MazDBPlugin::initializeEngine(QQmlEngine *engine, const char *uri) { QQmlExtensionPlugin::initializeEngine(engine, uri); }