discomfitor pushed a commit to branch enlightenment-0.20.

http://git.enlightenment.org/core/enlightenment.git/commit/?id=76b76af8ea026ab74b5628dcc6b8bc8209a89995

commit 76b76af8ea026ab74b5628dcc6b8bc8209a89995
Author: Mike Blumenkrantz <zm...@osg.samsung.com>
Date:   Thu Mar 31 11:11:02 2016 -0400

    explicitly manage client focus when setting/unsetting input grabs
    
    clients cannot retain focus during a compositor grab, so ensure that
    they do not think they have focus in such cases
    
    fix T3338
---
 src/bin/e_comp.c | 14 +++++++++++++-
 1 file changed, 13 insertions(+), 1 deletion(-)

diff --git a/src/bin/e_comp.c b/src/bin/e_comp.c
index 0f9fbf1..15a6161 100644
--- a/src/bin/e_comp.c
+++ b/src/bin/e_comp.c
@@ -1648,6 +1648,8 @@ e_comp_grab_input(Eina_Bool mouse, Eina_Bool kbd)
    if ((e_comp->input_mouse_grabs && e_comp->input_key_grabs) ||
        e_grabinput_get(mwin, 0, kwin))
      {
+        if (e_client_focused_get())
+          evas_object_focus_set(e_client_focused_get()->frame, 0);
         ret = EINA_TRUE;
         e_comp->input_mouse_grabs += mouse;
         e_comp->input_key_grabs += kbd;
@@ -1675,7 +1677,17 @@ e_comp_ungrab_input(Eina_Bool mouse, Eina_Bool kbd)
    e_grabinput_release(mwin, kwin);
    evas_event_feed_mouse_out(e_comp->evas, 0, NULL);
    evas_event_feed_mouse_in(e_comp->evas, 0, NULL);
-   if (e_client_focused_get()) return;
+   if (e_client_focused_get())
+     {
+        E_Client *ec = e_client_focused_get();
+
+        if (e_comp->comp_type == E_PIXMAP_TYPE_WL)
+          {
+             evas_object_focus_set(ec->frame, 0);
+             evas_object_focus_set(ec->frame, 1);
+          }
+        return;
+     }
    if (e_config->focus_policy != E_FOCUS_MOUSE)
      e_client_refocus();
 }

-- 


Reply via email to