e_client: do not focus to hidden window 19/284319/1 sandbox/junskim/action accepted/tizen/unified/20221118.021714
authorJunseok Kim <juns.kim@samsung.com>
Tue, 15 Nov 2022 12:28:35 +0000 (21:28 +0900)
committerTizen Window System <tizen.windowsystem@gmail.com>
Tue, 15 Nov 2022 12:35:19 +0000 (21:35 +0900)
There was a bug that focus given to topmost not unmapped hidden window.
It caused the window hide pended by e20 module, and the window requests activate.
for fix this issue, check the evas_object of the window is visible when focusable check.

Change-Id: I7a3d8c467ea3c39b1d0d77c5692877bcbf9e4f0d

src/bin/e_client.c

index 37180f559546dede0e6eace076b2cde2bd3d05ba..010fa12096bdd70d4d0614621593c8f68c361941 100644 (file)
@@ -910,6 +910,17 @@ _e_client_focus_can_take(E_Client *ec)
      {
         if (_e_client_check_really_iconified(ec))
           return EINA_FALSE;
+
+        if (!ec->iconic)
+          {
+             if (!evas_object_visible_get(ec->frame) &&
+                 (ec->visibility.obscured == E_VISIBILITY_FULLY_OBSCURED))
+               {
+                  ELOGF("FOCUS", "client is hideen, skip focus", ec);
+                  return EINA_FALSE;
+               }
+          }
+
         if (ec->visibility.obscured == E_VISIBILITY_UNKNOWN)
           {
              if (!evas_object_visible_get(ec->frame))