core: Preserve focus across decoration changes
Changes in window decoration result in the window being reparented in and out its frame. This in turn causes unmap/map events, and XI_FocusOut if the window happened to be focused. In order to preserve the focused window across the decoration change, add a flag so that the focus may be restored on MapNotify. Closes: #273
This commit is contained in:

committed by
Carlos Garnacho

parent
2fb3db7659
commit
8dcac664fa
@@ -4653,6 +4653,9 @@ meta_window_focus (MetaWindow *window,
|
||||
|
||||
g_return_if_fail (!window->override_redirect);
|
||||
|
||||
/* This is a oneshot flag */
|
||||
window->restore_focus_on_map = FALSE;
|
||||
|
||||
meta_topic (META_DEBUG_FOCUS,
|
||||
"Setting input focus to window %s, input: %d take_focus: %d\n",
|
||||
window->desc, window->input, window->take_focus);
|
||||
|
Reference in New Issue
Block a user