aboutsummaryrefslogtreecommitdiffstats
path: root/src/qmlmodels/doc/snippets/delegatemodel/delegatemodel_rootindex/main.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/qmlmodels/doc/snippets/delegatemodel/delegatemodel_rootindex/main.cpp')
-rw-r--r--src/qmlmodels/doc/snippets/delegatemodel/delegatemodel_rootindex/main.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/qmlmodels/doc/snippets/delegatemodel/delegatemodel_rootindex/main.cpp b/src/qmlmodels/doc/snippets/delegatemodel/delegatemodel_rootindex/main.cpp
index a56eb69616..6ec93ce113 100644
--- a/src/qmlmodels/doc/snippets/delegatemodel/delegatemodel_rootindex/main.cpp
+++ b/src/qmlmodels/doc/snippets/delegatemodel/delegatemodel_rootindex/main.cpp
@@ -51,7 +51,7 @@
#include <QQmlContext>
#include <QApplication>
-#include <QDirModel>
+#include <QFileSystemModel>
//![0]
int main(int argc, char ** argv)
@@ -60,8 +60,8 @@ int main(int argc, char ** argv)
QQuickView view;
- QDirModel model;
- view.rootContext()->setContextProperty("dirModel", &model);
+ QFileSystemModel model;
+ view.rootContext()->setContextProperty("fileSystemModel", &model);
view.setSource(QUrl::fromLocalFile("view.qml"));
view.show();