activate ? "yes" : "no");
if (activate) {
gboolean raise = FALSE;
- gboolean relative_focused = FALSE;
+ gboolean relative_focused;
+ gboolean parent_focused;
+ parent_focused = (focus_client != NULL &&
+ client_search_focus_parent(self));
relative_focused = (focus_client != NULL &&
- client_search_focus_tree_full(self) != NULL &&
- client_search_focus_group_full(self) != NULL);
-
+ (client_search_focus_tree_full(self) != NULL ||
+ client_search_focus_group_full(self) != NULL));
-
/* This is focus stealing prevention */
ob_debug_type(OB_DEBUG_FOCUS,
"Want to focus new window 0x%x at time %u "
- "launched at %u (last user interaction time %u)\n",
+ "launched at %u (last user interaction time %u)",
self->window, map_time, launch_time,
event_last_user_time);
++ ob_debug_type(OB_DEBUG_FOCUS,
++ "Current focus_client: %s",
++ (focus_client ? focus_client->title : "(none)"));
++ ob_debug_type(OB_DEBUG_FOCUS,
++ "parent focuesed: %d relative focused: %d",
++ parent_focused, relative_focused);
if (menu_frame_visible || moveresize_in_progress) {
activate = FALSE;
activate = FALSE;
ob_debug_type(OB_DEBUG_FOCUS,
"Not focusing the window because the user is "
- "working in another window");
+ "working in another window that is not "
- "its parent\n");
++ "its parent");
}
/* If the new window is a transient (and its relatives aren't
focused) */