summaryrefslogtreecommitdiff
path: root/editor/settings_config_dialog.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'editor/settings_config_dialog.cpp')
-rw-r--r--editor/settings_config_dialog.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/editor/settings_config_dialog.cpp b/editor/settings_config_dialog.cpp
index 537c9ac6b8..a4956bee27 100644
--- a/editor/settings_config_dialog.cpp
+++ b/editor/settings_config_dialog.cpp
@@ -94,8 +94,9 @@ void EditorSettingsDialog::popup_edit_settings() {
set_process_unhandled_input(true);
// Restore valid window bounds or pop up at default size.
- if (EditorSettings::get_singleton()->has_setting("interface/dialogs/editor_settings_bounds")) {
- popup(EditorSettings::get_singleton()->get("interface/dialogs/editor_settings_bounds"));
+ Rect2 saved_size = EditorSettings::get_singleton()->get_project_metadata("dialog_bounds", "editor_settings", Rect2());
+ if (saved_size != Rect2()) {
+ popup(saved_size);
} else {
Size2 popup_size = Size2(900, 700) * editor_get_scale();
@@ -132,7 +133,7 @@ void EditorSettingsDialog::_notification(int p_what) {
_update_icons();
} break;
case NOTIFICATION_POPUP_HIDE: {
- EditorSettings::get_singleton()->set("interface/dialogs/editor_settings_bounds", get_rect());
+ EditorSettings::get_singleton()->set_project_metadata("dialog_bounds", "editor_settings", get_rect());
set_process_unhandled_input(false);
} break;
case EditorSettings::NOTIFICATION_EDITOR_SETTINGS_CHANGED: {