From a863c385f7fe86c0ff9f10fd93c938e8abb140ca Mon Sep 17 00:00:00 2001 From: Giganzo <158825920+Giganzo@users.noreply.github.com> Date: Sat, 14 Sep 2024 13:28:39 +0200 Subject: [PATCH] Fix FileDialog default size --- doc/classes/FileDialog.xml | 1 + scene/gui/file_dialog.cpp | 1 + 2 files changed, 2 insertions(+) diff --git a/doc/classes/FileDialog.xml b/doc/classes/FileDialog.xml index 38985e99ae3..1ae889adc13 100644 --- a/doc/classes/FileDialog.xml +++ b/doc/classes/FileDialog.xml @@ -151,6 +151,7 @@ If [code]true[/code], the dialog will show hidden files. [b]Note:[/b] This property is ignored by native file dialogs on Linux. + If [code]true[/code], [member access] is set to [constant ACCESS_FILESYSTEM], and it is supported by the current [DisplayServer], OS native dialog will be used instead of custom one. diff --git a/scene/gui/file_dialog.cpp b/scene/gui/file_dialog.cpp index 1fc85864482..6f61295a916 100644 --- a/scene/gui/file_dialog.cpp +++ b/scene/gui/file_dialog.cpp @@ -1526,6 +1526,7 @@ FileDialog::FileDialog() { update_dir(); set_hide_on_ok(false); + set_size(Size2(640, 360)); if (register_func) { register_func(this);