diff options
Diffstat (limited to 'src/imports/folderlistmodel/plugin.cpp')
-rw-r--r-- | src/imports/folderlistmodel/plugin.cpp | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/imports/folderlistmodel/plugin.cpp b/src/imports/folderlistmodel/plugin.cpp index 2b58a5677a..5e8b41401f 100644 --- a/src/imports/folderlistmodel/plugin.cpp +++ b/src/imports/folderlistmodel/plugin.cpp @@ -58,7 +58,7 @@ class QmlFolderListModelPlugin : public QQmlExtensionPlugin Q_PLUGIN_METADATA(IID QQmlExtensionInterface_iid) public: - QmlFolderListModelPlugin(QObject *parent = 0) : QQmlExtensionPlugin(parent) { initResources(); } + QmlFolderListModelPlugin(QObject *parent = nullptr) : QQmlExtensionPlugin(parent) { initResources(); } void registerTypes(const char *uri) override { Q_ASSERT(QLatin1String(uri) == QLatin1String("Qt.labs.folderlistmodel")); @@ -66,6 +66,12 @@ public: qmlRegisterType<QQuickFolderListModel>(uri,2,0,"FolderListModel"); qmlRegisterType<QQuickFolderListModel,1>(uri,2,1,"FolderListModel"); qmlRegisterType<QQuickFolderListModel,2>(uri,2,2,"FolderListModel"); + + // Auto-increment the import to stay in sync with ALL future QtQuick minor versions from 5.11 onward + qmlRegisterModule(uri, 2, QT_VERSION_MINOR); + + // revision in Qt 5.11: added status property + qmlRegisterType<QQuickFolderListModel,11>(uri, 2, 11, "FolderListModel"); } }; //![class decl] |