Fix QRC URL creation for older Qt versions
This commit is contained in:
parent
fac0341e04
commit
8dbd3f8bd5
1 changed files with 2 additions and 2 deletions
|
@ -285,7 +285,7 @@ void LauncherMainWindow::buildSettingsSections()
|
||||||
|
|
||||||
QStringList sections = QStringList() << "general" << "mp" << "downloads" << "view" << "render";
|
QStringList sections = QStringList() << "general" << "mp" << "downloads" << "view" << "render";
|
||||||
Q_FOREACH (QString section, sections) {
|
Q_FOREACH (QString section, sections) {
|
||||||
QQmlComponent* comp = new QQmlComponent(m_qmlEngine, "qrc:/settings/" + section, this);
|
QQmlComponent* comp = new QQmlComponent(m_qmlEngine, QUrl("qrc:///settings/" + section), this);
|
||||||
if (comp->isError()) {
|
if (comp->isError()) {
|
||||||
qWarning() << "Errors parsing settings section:" << section << "\n" << comp->errorString();
|
qWarning() << "Errors parsing settings section:" << section << "\n" << comp->errorString();
|
||||||
} else {
|
} else {
|
||||||
|
@ -319,7 +319,7 @@ void LauncherMainWindow::buildEnvironmentSections()
|
||||||
|
|
||||||
QStringList sections = QStringList() << "time" << "weather";
|
QStringList sections = QStringList() << "time" << "weather";
|
||||||
Q_FOREACH (QString section, sections) {
|
Q_FOREACH (QString section, sections) {
|
||||||
QQmlComponent* comp = new QQmlComponent(m_qmlEngine, "qrc:/environment/" + section, this);
|
QQmlComponent* comp = new QQmlComponent(m_qmlEngine, QUrl("qrc:///environment/" + section), this);
|
||||||
if (comp->isError()) {
|
if (comp->isError()) {
|
||||||
qWarning() << "Errors parsing environment section:" << section << "\n" << comp->errorString();
|
qWarning() << "Errors parsing environment section:" << section << "\n" << comp->errorString();
|
||||||
} else {
|
} else {
|
||||||
|
|
Loading…
Reference in a new issue