Revert "Fix that the focus-out notification got sent deferred"

This reverts commit 8cdab04d7f.

Fixes #78589.
This commit is contained in:
Rémi Verschelde 2023-06-23 18:03:48 +02:00
parent f44b2d7898
commit 68193bee9a
No known key found for this signature in database
GPG Key ID: C3336907360768E1
1 changed files with 1 additions and 9 deletions

View File

@ -1624,15 +1624,7 @@ void Window::popup(const Rect2i &p_screen_rect) {
// Send a focus-out notification when opening a Window Manager Popup.
SceneTree *scene_tree = get_tree();
if (scene_tree) {
List<Node *> list;
scene_tree->get_nodes_in_group("_viewports", &list);
for (Node *n : list) {
Window *w = Object::cast_to<Window>(n);
if (w && !w->get_embedder() && w->has_focus()) {
w->_event_callback(DisplayServer::WINDOW_EVENT_FOCUS_OUT);
break;
}
}
scene_tree->notify_group_flags(SceneTree::GROUP_CALL_DEFERRED, "_viewports", NOTIFICATION_WM_WINDOW_FOCUS_OUT);
}
}