Skip to content

Instantly share code, notes, and snippets.

@penk
Created September 17, 2018 04:39
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save penk/b3b54b060f6378b4d000412f8f346fc6 to your computer and use it in GitHub Desktop.
Save penk/b3b54b060f6378b4d000412f8f346fc6 to your computer and use it in GitHub Desktop.
QString QQuickLoader::errorString() const
{
Q_D(const QQuickLoader);
QString ret;
if(d->component->errors().isEmpty())
return ret;
if (d->component && d->component->isError()) {
const QList<QQmlError> errorList = d->component->errors();
for (const QQmlError &e : errorList) {
ret += e.url().toString() + QLatin1Char(':') +
QString::number(e.line()) + QLatin1Char(' ') +
e.description() + QLatin1Char('\n');
}
}
return ret;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment