diff options
Diffstat (limited to 'editor/editor_node.cpp')
-rw-r--r-- | editor/editor_node.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/editor/editor_node.cpp b/editor/editor_node.cpp index 4e0ad38320..ff415c83f1 100644 --- a/editor/editor_node.cpp +++ b/editor/editor_node.cpp @@ -4588,7 +4588,8 @@ EditorNode::EditorNode() { { int dpi_mode = EditorSettings::get_singleton()->get("interface/editor/hidpi_mode"); if (dpi_mode == 0) { - editor_set_scale(OS::get_singleton()->get_screen_dpi(0) >= 192 && OS::get_singleton()->get_screen_size(OS::get_singleton()->get_current_screen()).x > 2000 ? 2.0 : 1.0); + const int screen = OS::get_singleton()->get_current_screen(); + editor_set_scale(OS::get_singleton()->get_screen_dpi(screen) >= 192 && OS::get_singleton()->get_screen_size(screen).x > 2000 ? 2.0 : 1.0); } else if (dpi_mode == 1) { editor_set_scale(0.75); } else if (dpi_mode == 2) { |