aboutsummaryrefslogtreecommitdiffstats
path: root/src/lib/efl_wl
diff options
context:
space:
mode:
authorMike Blumenkrantz <zmike@osg.samsung.com>2018-01-24 16:13:42 -0500
committerMike Blumenkrantz <zmike@osg.samsung.com>2018-01-24 16:18:51 -0500
commit4a32e2456eaca80cee0b1ce70cea00cb41e11979 (patch)
tree0f81daa76a989513e554f7fc099de1a25bb1147c /src/lib/efl_wl
parentecore-x: add some useful xkb function wrappers (diff)
downloadefl-4a32e2456eaca80cee0b1ce70cea00cb41e11979.tar.gz
efl-wl: fix no-op of setting keyboard enter on already-entered surface
@fix
Diffstat (limited to 'src/lib/efl_wl')
-rw-r--r--src/lib/efl_wl/efl_wl.c11
1 files changed, 7 insertions, 4 deletions
diff --git a/src/lib/efl_wl/efl_wl.c b/src/lib/efl_wl/efl_wl.c
index 6967efc635..c88c4c716f 100644
--- a/src/lib/efl_wl/efl_wl.c
+++ b/src/lib/efl_wl/efl_wl.c
@@ -1107,11 +1107,13 @@ comp_seats_redo_enter(Comp *c, Comp_Surface *cs)
{
Eina_List *l, *ll;
struct wl_resource *res;
- if (c->active_surface && (cs != c->active_surface))
+ Eina_Bool same = s->kbd.enter == cs;
+
+ if (c->active_surface && (!same))
{
l = seat_kbd_active_resources_get(s);
EINA_LIST_FOREACH(l, ll, res)
- wl_keyboard_send_leave(res, serial, c->active_surface->res);
+ wl_keyboard_send_leave(res, serial, s->kbd.enter->res);
}
s->active_client = client;
if (cs)
@@ -1119,12 +1121,13 @@ comp_seats_redo_enter(Comp *c, Comp_Surface *cs)
l = seat_kbd_active_resources_get(s);
EINA_LIST_FOREACH(l, ll, res)
{
- wl_keyboard_send_enter(res, serial, cs->res, &s->kbd.keys);
+ if (!same)
+ wl_keyboard_send_enter(res, serial, cs->res, &s->kbd.keys);
comp_seat_send_modifiers(s, res, serial);
}
}
s->kbd.enter = cs;
- if (s->kbd.enter && s->selection_source)
+ if (s->kbd.enter && s->selection_source && (!same))
comp_seat_kbd_data_device_enter(s);
}
c->active_surface = cs;