Showing the changes to interface/src/Application.cpp (1 of 21 files). Show all
Unified · Split
| @@ -5114,8 +5114,10 @@ void Application::setPreviousScriptLocation(const QString& location) { · 5113 unmodified lines | ||
| 5114 | 5114 | } |
| 5115 | 5115 | |
| 5116 | 5116 | void Application::loadScriptURLDialog() const { |
| 5117 | − auto newScript = OffscreenUi::getText(nullptr, "Open and Run Script", "Script URL"); | |
| 5118 | − if (!newScript.isEmpty()) { | |
| 5117 | + auto newScript = OffscreenUi::getText(OffscreenUi::ICON_NONE, "Open and Run Script", "Script URL"); | |
| 5118 | + if (QUrl(newScript).scheme() == "atp") { | |
| 5119 | + OffscreenUi::warning("Error Loading Script", "Cannot load client script over ATP"); | |
| 5120 | + } else if (!newScript.isEmpty()) { | |
| 5119 | 5121 | DependencyManager::get<ScriptEngines>()->loadScript(newScript); |
| 5120 | 5122 | } |
| 5121 | 5123 | } |