mirror of
https://github.com/godotengine/godot.git
synced 2025-12-07 22:00:10 +00:00
Fix internal events not being delivered to some Window types
`AcceptDialog`, `Popup` and `PopupMenu` no longer subscribe to "window_input" signal, because that is only sent if it is not an internal signal. Instead they receive events in `_input_from_window`. They ensure that the event is also propagated to their super-function, just like previously the signals would be treated.
This commit is contained in:
parent
c455cb6555
commit
fa02d19fd1
8 changed files with 22 additions and 13 deletions
|
|
@ -39,6 +39,7 @@ void Popup::_input_from_window(const Ref<InputEvent> &p_event) {
|
|||
if (get_flag(FLAG_POPUP) && p_event->is_action_pressed(SNAME("ui_cancel"), false, true)) {
|
||||
_close_pressed();
|
||||
}
|
||||
Window::_input_from_window(p_event);
|
||||
}
|
||||
|
||||
void Popup::_initialize_visible_parents() {
|
||||
|
|
@ -204,8 +205,6 @@ Popup::Popup() {
|
|||
set_flag(FLAG_BORDERLESS, true);
|
||||
set_flag(FLAG_RESIZE_DISABLED, true);
|
||||
set_flag(FLAG_POPUP, true);
|
||||
|
||||
connect("window_input", callable_mp(this, &Popup::_input_from_window));
|
||||
}
|
||||
|
||||
Popup::~Popup() {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue