nikawhite pushed a commit to branch master.

http://git.enlightenment.org/tools/clouseau.git/commit/?id=0130202924dba6c1205e50d2416f62ff7415028e

commit 0130202924dba6c1205e50d2416f62ff7415028e
Author: Mykyta Biliavskyi <m.biliavs...@samsung.com>
Date:   Fri Dec 8 10:14:23 2017 +0200

    Client: delete extensions on close application.
    
    Summary:
    The Profiling viewer extension require to be notifyed that clouseau_client
    is closing. Another extensions also could require to make some routine
    before extension will be closed. Such as storing session info etc .
    
    Reviewers: i.furs, JackDanielZ, Deepwarrior
    
    Reviewed By: JackDanielZ, Deepwarrior
    
    Differential Revision: https://phab.enlightenment.org/D5608
---
 src/bin/clouseau_client.c | 10 ++++++++++
 1 file changed, 10 insertions(+)

diff --git a/src/bin/clouseau_client.c b/src/bin/clouseau_client.c
index 4b60b99..9b6ccd3 100644
--- a/src/bin/clouseau_client.c
+++ b/src/bin/clouseau_client.c
@@ -935,6 +935,14 @@ save_load_perform(void *data EINA_UNUSED, Evas_Object *obj 
EINA_UNUSED, void *ev
    else _fs_activate(EINA_FALSE);
 }
 
+static void
+_main_window_del(void *data EINA_UNUSED,
+                 Evas_Object *obj EINA_UNUSED,
+                 void *event_info EINA_UNUSED)
+{
+   _all_extensions_delete();
+}
+
 EAPI_MAIN int
 elm_main(int argc EINA_UNUSED, char **argv EINA_UNUSED)
 {
@@ -999,6 +1007,8 @@ elm_main(int argc EINA_UNUSED, char **argv EINA_UNUSED)
 
    elm_policy_set(ELM_POLICY_QUIT, ELM_POLICY_QUIT_LAST_WINDOW_CLOSED);
    _main_widgets = gui_main_win_create(NULL);
+   evas_object_smart_callback_add(_main_widgets->main_win, "delete,request",
+                                  _main_window_del, NULL);
 
    for (i = 0; i < LAST_CONNECTION; i++)
      {

-- 


Reply via email to