diff options
author | Marcel Hollerbach <marcel@osg.samsung.com> | 2022-01-09 15:33:18 +0100 |
---|---|---|
committer | Marcel Hollerbach <marcel@osg.samsung.com> | 2022-01-09 15:51:34 +0100 |
commit | 841c8f477f47bcb21b347d62332f87adc2d6d7d8 (patch) | |
tree | e6f830db5dd7356e2bfa301cb8754ac9e8fcf696 /src/bin/e_comp_object.c | |
parent | aff854b2ea38ff2bbc79b35113a89cf5d69a1827 (diff) | |
download | enlightenment-841c8f477f47bcb21b347d62332f87adc2d6d7d8.tar.gz |
focus: do not revert to another client when client is unfocused
This was a nice idea to fix most focus bugs at once. However, due to the
runtime of e many things can get "randomly" focused, for exmaple: volume
control on the frame, internal dialogs, config value screens when
grabbing for keys, widgets when they get created in a gadget. The list
is quite long. However, fixing all those little bugs is hard and partly
impossible as the behaviour is correct in the context of a toolkit, not
in the context of a compositor.
Long term we should split window-focus and canvas-focus from each other,
then bugs like these would not be a problem anymore.
Diffstat (limited to 'src/bin/e_comp_object.c')
-rw-r--r-- | src/bin/e_comp_object.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/bin/e_comp_object.c b/src/bin/e_comp_object.c index 77720aa19c..d960e4a803 100644 --- a/src/bin/e_comp_object.c +++ b/src/bin/e_comp_object.c @@ -1878,7 +1878,7 @@ _e_comp_intercept_focus(void *data, Evas_Object *obj, Eina_Bool focus) else { if (e_client_focused_get() == ec) { - e_client_revert_focus(ec); + e_client_focused_set(NULL); } } evas_object_focus_set(obj, focus); @@ -2353,8 +2353,9 @@ _e_comp_smart_hide(Evas_Object *obj) edje_object_play_set(cw->frame_object, 0); } /* ensure focus-out */ - if (cw->ec->focused) - evas_object_focus_set(cw->ec->frame, 0); + if (cw->ec->focused) { + e_client_revert_focus(cw->ec); + } e_comp_render_queue(); //force nocomp recheck e_comp_shape_queue(); } |