diff options
Diffstat (limited to 'editor/editor_run.cpp')
-rw-r--r-- | editor/editor_run.cpp | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/editor/editor_run.cpp b/editor/editor_run.cpp index 99c8481d33..599df12bd3 100644 --- a/editor/editor_run.cpp +++ b/editor/editor_run.cpp @@ -88,7 +88,7 @@ Error EditorRun::run(const String &p_scene, const String &p_write_movie) { } } - int screen = EditorSettings::get_singleton()->get("run/window_placement/screen"); + int screen = EDITOR_GET("run/window_placement/screen"); if (screen == 0) { // Same as editor screen = DisplayServer::get_singleton()->window_get_current_screen(); @@ -114,21 +114,21 @@ Error EditorRun::run(const String &p_scene, const String &p_write_movie) { screen_rect.position = DisplayServer::get_singleton()->screen_get_position(screen); screen_rect.size = DisplayServer::get_singleton()->screen_get_size(screen); - int window_placement = EditorSettings::get_singleton()->get("run/window_placement/rect"); + int window_placement = EDITOR_GET("run/window_placement/rect"); if (screen_rect != Rect2()) { Size2 window_size; - window_size.x = ProjectSettings::get_singleton()->get("display/window/size/viewport_width"); - window_size.y = ProjectSettings::get_singleton()->get("display/window/size/viewport_height"); + window_size.x = GLOBAL_GET("display/window/size/viewport_width"); + window_size.y = GLOBAL_GET("display/window/size/viewport_height"); Size2 desired_size; - desired_size.x = ProjectSettings::get_singleton()->get("display/window/size/window_width_override"); - desired_size.y = ProjectSettings::get_singleton()->get("display/window/size/window_height_override"); + desired_size.x = GLOBAL_GET("display/window/size/window_width_override"); + desired_size.y = GLOBAL_GET("display/window/size/window_height_override"); if (desired_size.x > 0 && desired_size.y > 0) { window_size = desired_size; } if (DisplayServer::get_singleton()->has_feature(DisplayServer::FEATURE_HIDPI)) { - bool hidpi_proj = ProjectSettings::get_singleton()->get("display/window/dpi/allow_hidpi"); + bool hidpi_proj = GLOBAL_GET("display/window/dpi/allow_hidpi"); int display_scale = 1; if (OS::get_singleton()->is_hidpi_allowed()) { @@ -159,7 +159,7 @@ Error EditorRun::run(const String &p_scene, const String &p_write_movie) { args.push_back(itos(pos.x) + "," + itos(pos.y)); } break; case 2: { // custom pos - Vector2 pos = EditorSettings::get_singleton()->get("run/window_placement/rect_custom_position"); + Vector2 pos = EDITOR_GET("run/window_placement/rect_custom_position"); pos += screen_rect.position; args.push_back("--position"); args.push_back(itos(pos.x) + "," + itos(pos.y)); @@ -215,7 +215,7 @@ Error EditorRun::run(const String &p_scene, const String &p_write_movie) { String exec = OS::get_singleton()->get_executable_path(); - const String raw_custom_args = ProjectSettings::get_singleton()->get("editor/run/main_run_args"); + const String raw_custom_args = GLOBAL_GET("editor/run/main_run_args"); if (!raw_custom_args.is_empty()) { // Allow the user to specify a command to run, similar to Steam's launch options. // In this case, Godot will no longer be run directly; it's up to the underlying command |