raster pushed a commit to branch master.

http://git.enlightenment.org/core/enlightenment.git/commit/?id=42100a1ae7305a31a506699bc30a84ccd8fcb385

commit 42100a1ae7305a31a506699bc30a84ccd8fcb385
Author: Carsten Haitzler (Rasterman) <[email protected]>
Date:   Sat Apr 11 23:09:37 2020 +0100

    e - fix fullscreen state revert on focusing of another window if child
    
    check the newly focused window is not part of a parent tree back to a
    fullscreen window e is considering unfullscreening on loss of focus.
    
    fixes T8651
    
    @fix
---
 src/bin/e_client.c | 11 ++++++++++-
 1 file changed, 10 insertions(+), 1 deletion(-)

diff --git a/src/bin/e_client.c b/src/bin/e_client.c
index cb21b9782..4c73a52d3 100644
--- a/src/bin/e_client.c
+++ b/src/bin/e_client.c
@@ -3727,6 +3727,15 @@ e_client_focus_set_with_pointer(E_Client *ec)
      }
 }
 
+static Eina_Bool
+_e_client_is_in_parents(E_Client *ec, E_Client *ec_find)
+{
+   if (ec == ec_find) return EINA_TRUE;
+   if (e_object_is_del(E_OBJECT(ec))) return EINA_FALSE;
+   if (ec->parent) return _e_client_is_in_parents(ec->parent, ec_find);
+   return EINA_FALSE;
+}
+
 EINTERN void
 e_client_focused_set(E_Client *ec)
 {
@@ -3754,7 +3763,7 @@ e_client_focused_set(E_Client *ec)
                        /* but only if it's the same desk or one of the clients 
is sticky */
                        if ((desk == ec->desk) || (ec->sticky || ec2->sticky))
                          {
-                            if (!eina_list_data_find(ec->transients, ec2))
+                            if (!_e_client_is_in_parents(ec, ec2))
                               e_client_unfullscreen(ec2);
                          }
                     }

-- 


Reply via email to