ensure that focus is set and focus stack is managed on winlist hide

if pointer warping is disabled, attempting to pointer warp with mouse-based
focus policies will fail here, preventing focus from being applied as expected

ref T2566
This commit is contained in:
Mike Blumenkrantz 2015-07-15 14:47:35 -04:00
parent 008a0658ec
commit 953b80f8ef
1 changed files with 4 additions and 2 deletions

View File

@ -277,6 +277,8 @@ e_winlist_hide(void)
e_comp_ungrab_input(1, 1); e_comp_ungrab_input(1, 1);
if (ec) if (ec)
{ {
Eina_Bool set = !ec->lock_focus_out;
if (ec->shaded) if (ec->shaded)
{ {
if (!ec->lock_user_shade) if (!ec->lock_user_shade)
@ -304,9 +306,9 @@ e_winlist_hide(void)
(e_config->winlist_warp_at_end) || (e_config->winlist_warp_at_end) ||
(e_config->winlist_warp_while_selecting)) (e_config->winlist_warp_while_selecting))
{ {
e_client_pointer_warp_to_center_now(ec); set |= !e_client_pointer_warp_to_center_now(ec);
} }
else if (!ec->lock_focus_out) if (set)
{ {
evas_object_focus_set(ec->frame, 1); evas_object_focus_set(ec->frame, 1);
e_client_focus_latest_set(ec); e_client_focus_latest_set(ec);