e_policy_wl_display: remove E_CLIENT_HOOK_EVAL_VIAIBILITY callback 49/322349/1
authorSooChan Lim <sc1.lim@samsung.com>
Mon, 7 Apr 2025 08:20:53 +0000 (17:20 +0900)
committerTizen Window System <tizen.windowsystem@gmail.com>
Tue, 8 Apr 2025 01:52:59 +0000 (10:52 +0900)
The callback function for E_CLIENT_HOOK_EVAL_VIAIBILITY moves in
e_policy_zone_visibility_calculate() function.

Change-Id: I5069e6861bc38acecf7c024dea3855d3b633d4ac

src/bin/server/e_policy_wl_display.c
src/bin/windowmgr/e_policy_zone.c

index f8ff5d355b639b3d6f55b36a08ff773317f8988c..15c2449e6dafb8dc90aa5a78644736bb16c2c2f7 100644 (file)
@@ -39,7 +39,6 @@ static Eina_Bool _e_policy_wl_display_client_add_to_list(Eina_List** list, E_Cli
 static Eina_Bool _e_policy_wl_display_client_remove_from_list(Eina_List** list, E_Client *ec);
 
 static void _e_policy_wl_display_hook_client_del(void *d EINA_UNUSED, E_Client *ec);
-static void _e_policy_wl_display_hook_client_visibility(void *d EINA_UNUSED, E_Client *ec);
 
 static Eina_Bool _e_policy_wl_display_cb_client_remove(void *d EINA_UNUSED, int type EINA_UNUSED, void *event);
 
@@ -159,15 +158,6 @@ _e_policy_wl_display_hook_client_del(void *d EINA_UNUSED, E_Client *ec)
    _e_policy_wl_display_client_remove_from_list(&_screen_mode_client_list, ec);
 }
 
-static void
-_e_policy_wl_display_hook_client_visibility(void *d EINA_UNUSED, E_Client *ec)
-{
-   if (ec->visibility.changed)
-     {
-        e_policy_display_screen_mode_apply();
-     }
-}
-
 static Eina_Bool
 _e_policy_wl_display_cb_client_remove(void *d EINA_UNUSED, int type EINA_UNUSED, void *event)
 {
@@ -260,7 +250,6 @@ e_policy_display_init(void)
 
    /* hook functions */
    E_CLIENT_HOOK_APPEND(_display_control_hooks, E_CLIENT_HOOK_DEL, _e_policy_wl_display_hook_client_del, NULL);
-   E_CLIENT_HOOK_APPEND(_display_control_hooks, E_CLIENT_HOOK_EVAL_VISIBILITY, _e_policy_wl_display_hook_client_visibility, NULL);
 
    /* handler functions */
    E_LIST_HANDLER_APPEND(_display_control_handlers, E_EVENT_CLIENT_REMOVE, _e_policy_wl_display_cb_client_remove, NULL);
index 2313239c290076f637fefe23b1b861bf601bbe8c..31c5621a1a9b399e5a0c4ee7116b21a021634cc7 100644 (file)
@@ -19,6 +19,7 @@
 #include "e_comp_input_intern.h"
 #include "e_comp_intern.h"
 #include "e_process_intern.h"
+#include "e_policy_wl_display_intern.h"
 
 #define ZONE_EC_DATA_KEY  "E_Zone_Client"
 
@@ -1603,6 +1604,7 @@ e_policy_zone_visibility_calculate(E_Zone *zone)
              touched_ec = comp_wl->ptr.ec ? comp_wl->ptr.ec : comp_wl->touch.faked_ec;
              EINA_LIST_FOREACH(changed_list, l, ec)
                {
+                  e_policy_display_screen_mode_apply();
                   e_policy_client_visibility_evaluate(ec);
                   if (e_client_visibility_get(ec) == E_VISIBILITY_UNOBSCURED)
                     e_process_thaw(ec->netwm.pid);