diff options
Diffstat (limited to 'examples/qml/tutorials/extending-qml/chapter6-plugins/main.cpp')
-rw-r--r-- | examples/qml/tutorials/extending-qml/chapter6-plugins/main.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/examples/qml/tutorials/extending-qml/chapter6-plugins/main.cpp b/examples/qml/tutorials/extending-qml/chapter6-plugins/main.cpp index 3475401ebd..7dfb1cf5a7 100644 --- a/examples/qml/tutorials/extending-qml/chapter6-plugins/main.cpp +++ b/examples/qml/tutorials/extending-qml/chapter6-plugins/main.cpp @@ -9,12 +9,12 @@ int main(int argc, char *argv[]) QGuiApplication app(argc, argv); //![0] QQuickView view; -#ifdef Q_OS_OSX +#ifdef Q_OS_MACOS view.engine()->addImportPath(app.applicationDirPath() + "/../PlugIns"); #endif //![0] view.setResizeMode(QQuickView::SizeRootObjectToView); - view.setSource(QUrl("qrc:///app.qml")); + view.loadFromModule("ChartsApp", "App"); view.show(); return app.exec(); } |