### Godot version

v4.1.rc3.official [cdd2313ba]

### System information

Godot v4.1.rc3 - Windows 10.0.19045 - Intel(R) Core(TM) i7-6700 CPU @ 3.40GHz (8 Threads)

### Issue description

Trying to open the filters (file types) menu in a non-exclusive FileDialog makes it automatically close and brings up the following error in the console/debugger:
```
ERROR: Condition "!windows.has(p_window)" is true. Returning: Rect2i()
   at: window_get_popup_safe_rect (platform/windows/display_server_windows.cpp:2426)
```
This seems to have been broken somewhere between 4.1 beta 2 and beta 3.

### Steps to reproduce

- Create a FileDialog
- Untick the "Exclusive" box
- Make it visible / pop it up / etc
- Try opening the `All Files (*)` menu

### Minimal reproduction project

[dialog_test.zip](https://github.com/godotengine/godot/files/11955537/dialog_test.zip)

swap_cancel_ok = p_swap;
}
AcceptDialog::AcceptDialog() {
	set_wrap_controls(true);
	set_visible(false);
	set_transient(true);
	set_exclusive(true);
	set_clamp_to_embedder(true);
	bg_panel = memnew(Panel);
	add_child(bg_panel, false, INTERNAL_MODE_FRONT);
	buttons_hbox = memnew(HBoxContainer);
	message_label = memnew(Label);
	message_label->set_anchor(SIDE_RIGHT, Control::ANCHOR_END);
	message_label->set_anchor(SIDE_BOTTOM, Control::ANCHOR_END);
	add_child(message_label, false, INTERNAL_MODE_FRONT);
	add_child(buttons_hbox, false, INTERNAL_MODE_FRONT);
	buttons_hbox->add_spacer();
	ok_button = memnew(Button);
	ok_button->set_text("OK");
	buttons_hbox->add_child(ok_button);
	buttons_hbox->add_spacer();
	ok_button->connect("pressed", callable_mp(this, &AcceptDialog::_ok_pressed));
	set_title(TTRC("Alert!"));
	connect("window_input", callable_mp(this, &AcceptDialog::_input_from_window));
}
AcceptDialog::~AcceptDialog() {