[Development] QJSEngine debuging

Kevin Krammer kevin.krammer at kdab.com
Tue Nov 20 13:00:04 CET 2012


On Tuesday, 2012-11-20, Michal Dorner wrote:

>     qmlRegisterType<Test>("MyModule", 1, 0, "Test");
> 
>     engine = new QQmlEngine();
> 
> 
>     component = new QQmlComponent(engine,
> QUrl::fromLocalFile("module.qml"));
> 
> 
>     if (!component->isLoading()) {

I think you can just call component->isError() here, unless your module.qml 
refers to some QML that is loaded asynchronously.

But overall it looks similar to what I have in a project that uses QML in a 
similar fashion.

Cheers,
Kevin
-- 
** Qt Developer Conference: http://qtconference.kdab.com/ **

Kevin Krammer | kevin.krammer at kdab.com | Software Engineer
Klarälvdalens Datakonsult AB, a KDAB Group company
Tel. Sweden (HQ) +46-563-540090, USA +1-866-777-KDAB(5322)
KDAB - Qt Experts - Platform-independent software solutions
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 4712 bytes
Desc: not available
URL: <http://lists.qt-project.org/pipermail/development/attachments/20121120/b80b64b2/attachment.bin>


More information about the Development mailing list