diff options
Diffstat (limited to 'examples/declarative/cppextensions/referenceexamples/extended/main.cpp')
-rw-r--r-- | examples/declarative/cppextensions/referenceexamples/extended/main.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/examples/declarative/cppextensions/referenceexamples/extended/main.cpp b/examples/declarative/cppextensions/referenceexamples/extended/main.cpp index 65527c3..08c8440 100644 --- a/examples/declarative/cppextensions/referenceexamples/extended/main.cpp +++ b/examples/declarative/cppextensions/referenceexamples/extended/main.cpp @@ -51,14 +51,14 @@ int main(int argc, char ** argv) qmlRegisterExtendedType<QLineEdit, LineEditExtension>("People", 1,0, "QLineEdit"); QDeclarativeEngine engine; - QDeclarativeComponent component(&engine, ":example.qml"); + QDeclarativeComponent component(&engine, QUrl("qrc:example.qml")); QLineEdit *edit = qobject_cast<QLineEdit *>(component.create()); if (edit) { edit->show(); return app.exec(); } else { - qWarning() << "An error occurred"; + qWarning() << component.errors(); return 0; } } |