[Interest] QQmlApplicationEngine::warnings is not emitted

Alexander Dyagilev alervdvcw at gmail.com
Mon Jan 6 06:13:41 CET 2020


I've created the bug report:
https://bugreports.qt.io/browse/QTBUG-81093

On 1/2/2020 7:48 AM, Alexander Dyagilev wrote:
>
> Hello,
>
> Why this can happen?
>
> I'm getting empty root objects, errors in Application Output tab in Qt 
> Creator and empty qmlWarnings variable.
>
> m_engine.reset(newQQmlApplicationEngine);
>
> QList<QQmlError>qmlWarnings;
> qtconnect(m_engine.data(),&QQmlApplicationEngine::warnings,
> [&qmlWarnings](constQList<QQmlError>&warnings)
> {
> qmlWarnings.append(warnings);
> });
> m_engine->load(qmlUrl);
> if(m_engine->rootObjects().isEmpty())
> {
> m_initFailed.first=true;
> m_errorDesc=QObject::tr("QMLloadfailure.");
> }
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/interest/attachments/20200106/f3fcbcc5/attachment.html>


More information about the Interest mailing list