mirror of
https://github.com/godotengine/godot.git
synced 2025-12-07 22:00:10 +00:00
Merge pull request #112604 from bruvzg/pop_center_rec
Update rect after `_pre_popup` in `popup_centered_*`.
This commit is contained in:
commit
5afc01c46d
10 changed files with 60 additions and 18 deletions
|
|
@ -95,12 +95,12 @@ bool FileDialog::_can_use_native_popup() {
|
|||
return DisplayServer::get_singleton()->has_feature(DisplayServer::FEATURE_NATIVE_DIALOG_FILE);
|
||||
}
|
||||
|
||||
void FileDialog::popup(const Rect2i &p_rect) {
|
||||
void FileDialog::_popup_base(const Rect2i &p_rect) {
|
||||
_update_option_controls();
|
||||
|
||||
#ifdef TOOLS_ENABLED
|
||||
if (is_part_of_edited_scene()) {
|
||||
ConfirmationDialog::popup(p_rect);
|
||||
ConfirmationDialog::_popup_base(p_rect);
|
||||
return;
|
||||
}
|
||||
#endif
|
||||
|
|
@ -108,7 +108,7 @@ void FileDialog::popup(const Rect2i &p_rect) {
|
|||
if (_can_use_native_popup() && (use_native_dialog || OS::get_singleton()->is_sandboxed())) {
|
||||
_native_popup();
|
||||
} else {
|
||||
ConfirmationDialog::popup(p_rect);
|
||||
ConfirmationDialog::_popup_base(p_rect);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue