mirror of
https://github.com/overte-org/overte.git
synced 2025-08-04 04:03:35 +02:00
Disable loading client scripts over ATP
This commit is contained in:
parent
d8f1847fde
commit
4e16998b45
1 changed files with 4 additions and 2 deletions
|
@ -5114,8 +5114,10 @@ void Application::setPreviousScriptLocation(const QString& location) {
|
||||||
}
|
}
|
||||||
|
|
||||||
void Application::loadScriptURLDialog() const {
|
void Application::loadScriptURLDialog() const {
|
||||||
auto newScript = OffscreenUi::getText(nullptr, "Open and Run Script", "Script URL");
|
auto newScript = OffscreenUi::getText(OffscreenUi::ICON_NONE, "Open and Run Script", "Script URL");
|
||||||
if (!newScript.isEmpty()) {
|
if (QUrl(newScript).scheme() == "atp") {
|
||||||
|
OffscreenUi::warning("Error Loading Script", "Cannot load client script over ATP");
|
||||||
|
} else if (!newScript.isEmpty()) {
|
||||||
DependencyManager::get<ScriptEngines>()->loadScript(newScript);
|
DependencyManager::get<ScriptEngines>()->loadScript(newScript);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue