Make bare plugin build, correct plugin macro
This commit is contained in:
parent
4eb4608608
commit
2ca026e96e
@ -23,24 +23,24 @@
|
||||
|
||||
#include <QtDeclarative/qdeclarative.h>
|
||||
|
||||
#include "qpixmapitem.h"
|
||||
#include "qimageitem.h"
|
||||
#include "qiconitem.h"
|
||||
#include "mouseeventlistener.h"
|
||||
// #include "qpixmapitem.h"
|
||||
// #include "qimageitem.h"
|
||||
// #include "qiconitem.h"
|
||||
//#include "mouseeventlistener.h"
|
||||
#include "columnproxymodel.h"
|
||||
|
||||
void QtExtraComponentsPlugin::registerTypes(const char *uri)
|
||||
{
|
||||
Q_ASSERT(uri == QLatin1String("org.kde.qtextracomponents"));
|
||||
|
||||
qmlRegisterType<QPixmapItem>(uri, 0, 1, "QPixmapItem");
|
||||
qmlRegisterType<QImageItem>(uri, 0, 1, "QImageItem");
|
||||
qmlRegisterType<QIconItem>(uri, 0, 1, "QIconItem");
|
||||
qmlRegisterType<MouseEventListener>(uri, 0, 1, "MouseEventListener");
|
||||
qmlRegisterType<ColumnProxyModel>(uri, 0, 1, "ColumnProxyModel");
|
||||
|
||||
qmlRegisterType<QAbstractItemModel>();
|
||||
qRegisterMetaType<QModelIndex>("QModelIndex");
|
||||
// qmlRegisterType<QPixmapItem>(uri, 0, 1, "QPixmapItem");
|
||||
// qmlRegisterType<QImageItem>(uri, 0, 1, "QImageItem");
|
||||
// qmlRegisterType<QIconItem>(uri, 0, 1, "QIconItem");
|
||||
// qmlRegisterType<MouseEventListener>(uri, 0, 1, "MouseEventListener");
|
||||
// qmlRegisterType<ColumnProxyModel>(uri, 0, 1, "ColumnProxyModel");
|
||||
//
|
||||
// qmlRegisterType<QAbstractItemModel>();
|
||||
// qRegisterMetaType<QModelIndex>("QModelIndex");
|
||||
}
|
||||
|
||||
|
||||
|
@ -22,17 +22,16 @@
|
||||
#ifndef QTEXTRACOMPONENTSPLUGIN_H
|
||||
#define QTEXTRACOMPONENTSPLUGIN_H
|
||||
|
||||
#include <QDeclarativeExtensionPlugin>
|
||||
#include <QQmlExtensionPlugin>
|
||||
|
||||
|
||||
class QtExtraComponentsPlugin : public QDeclarativeExtensionPlugin
|
||||
class QtExtraComponentsPlugin : public QQmlExtensionPlugin
|
||||
{
|
||||
Q_OBJECT
|
||||
Q_PLUGIN_METADATA(IID "org.qt-project.Qt.QQmlExtensionInterface")
|
||||
|
||||
public:
|
||||
void registerTypes(const char *uri);
|
||||
};
|
||||
|
||||
Q_EXPORT_PLUGIN2(qtextracomponentsplugin, QtExtraComponentsPlugin);
|
||||
|
||||
#endif
|
||||
|
Loading…
Reference in New Issue
Block a user