This is an automated email from the git hooks/post-receive script.

git pushed a commit to branch v-0.25.0
in repository enlightenment.

View the commit online.

commit c22f2faecfef0fa0e75f0c5fe17a2f9c1d7b69c8
Author: Alastair Poole <nets...@gmail.com>
AuthorDate: Mon Apr 25 15:21:19 2022 +0100

    procstats: Handle e_client fullscreen requests.
    
    Add an event handler for E_CLIENT_FULLSCREEN. Remove the client,
    destroying the popup and icon region.
    
    This resolves the issue where a client fullscreen request would
    leave a rogue icon region and popup if switching to full screen
    with some applications.
    
    @fix T8996
---
 src/modules/procstats/e_mod_main.c | 29 +++++++++++++++++++++++++++++
 1 file changed, 29 insertions(+)

diff --git a/src/modules/procstats/e_mod_main.c b/src/modules/procstats/e_mod_main.c
index 0596a61de..2d58d71a7 100644
--- a/src/modules/procstats/e_mod_main.c
+++ b/src/modules/procstats/e_mod_main.c
@@ -8,6 +8,8 @@
 
 #define POLL_INTERVAL 2.0
 
+static Ecore_Event_Handler *_proc_stats_handler_fullscreen = NULL;
+
 static int64_t         _mem_total;
 
 typedef struct
@@ -77,6 +79,28 @@ _memory_total(void)
    return 1;
 }
 
+static Eina_Bool
+_proc_stats_handler_fullscreen_check_cb(void *data EINA_UNUSED, int type EINA_UNUSED, void *event)
+{
+   Proc_Stats_Client *client;
+   E_Event_Client *ev;
+   Eina_List *l;
+   Proc_Stats_Module *module = _this_module;
+
+   ev = event;
+
+   EINA_LIST_FOREACH(module->clients, l, client)
+     {
+        if (client->ec == ev->ec)
+          {
+             _proc_stats_client_remove(client);
+             break;
+          }
+     }
+
+   return ECORE_CALLBACK_PASS_ON;
+}
+
 static Eina_Bool
 _proc_stats_client_exists(E_Client *ec)
 {
@@ -505,6 +529,8 @@ e_modapi_init(E_Module *m)
    //module->sleeper = e_powersave_sleeper_new();
    module->poll_interval = POLL_INTERVAL;
 
+   _proc_stats_handler_fullscreen = ecore_event_handler_add
+      (E_EVENT_CLIENT_FULLSCREEN, _proc_stats_handler_fullscreen_check_cb, NULL);
    _proc_stats_thread_feedback_cb(module, NULL, proc_info_all_children_get());
 
    module->thread = ecore_thread_feedback_run(_proc_stats_thread,
@@ -524,6 +550,9 @@ e_modapi_shutdown(E_Module *m EINA_UNUSED)
 
    //e_powersave_sleeper_free(module->sleeper);
 
+   ecore_event_handler_del(_proc_stats_handler_fullscreen);
+   _proc_stats_handler_fullscreen = NULL;
+
    EINA_LIST_FREE(module->clients, client)
      _proc_stats_client_del(client);
 

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.

Reply via email to