mirror of
https://github.com/overte-org/overte.git
synced 2025-04-24 03:33:35 +02:00
Switched ScriptEditorWidget to NetworkAccessManager
This commit is contained in:
parent
602015be66
commit
9bcd4e7ac8
1 changed files with 2 additions and 2 deletions
|
@ -148,8 +148,8 @@ void ScriptEditorWidget::loadFile(const QString& scriptPath) {
|
|||
disconnect(_scriptEngine, &ScriptEngine::finished, this, &ScriptEditorWidget::onScriptFinished);
|
||||
}
|
||||
} else {
|
||||
QNetworkAccessManager* networkManager = new QNetworkAccessManager(this);
|
||||
QNetworkReply* reply = networkManager->get(QNetworkRequest(url));
|
||||
NetworkAccessManager& networkAccessManager = NetworkAccessManager::getInstance();
|
||||
QNetworkReply* reply = networkAccessManager.get(QNetworkRequest(url));
|
||||
qDebug() << "Downloading included script at" << scriptPath;
|
||||
QEventLoop loop;
|
||||
QObject::connect(reply, &QNetworkReply::finished, &loop, &QEventLoop::quit);
|
||||
|
|
Loading…
Reference in a new issue