summaryrefslogtreecommitdiff
path: root/src/bin/e_module.c
diff options
context:
space:
mode:
authorMike Blumenkrantz <michael.blumenkrantz@gmail.com>2013-02-06 13:11:08 +0000
committerMike Blumenkrantz <michael.blumenkrantz@gmail.com>2013-02-06 13:11:08 +0000
commitfea54b3d31a81b371d678e7fd119be08a6d68203 (patch)
tree2ff6277d7bdab3f09b4c5e087e24d49dbc49cede /src/bin/e_module.c
parent637f539c9d5f16551bd68329aa3b55ee4da42e8b (diff)
downloadenlightenment-fea54b3d31a81b371d678e7fd119be08a6d68203.tar.gz
ensure that E_EVENT_MODULE_INIT_END is always sent even if no modules are loaded
SVN revision: 83679
Diffstat (limited to 'src/bin/e_module.c')
-rw-r--r--src/bin/e_module.c11
1 files changed, 9 insertions, 2 deletions
diff --git a/src/bin/e_module.c b/src/bin/e_module.c
index 2c35748e07..ae81af726f 100644
--- a/src/bin/e_module.c
+++ b/src/bin/e_module.c
@@ -23,6 +23,7 @@ static Eina_Hash *_e_modules_hash = NULL;
static Ecore_Idle_Enterer *_e_module_idler = NULL;
static Eina_List *_e_modules_delayed = NULL;
static Eina_Bool _e_modules_initting = EINA_FALSE;
+static Eina_Bool _e_modules_init_end = EINA_FALSE;
static Eina_List *_e_module_path_monitors = NULL;
static Eina_List *_e_module_path_lists = NULL;
@@ -71,6 +72,11 @@ _module_done_cb(void *d EINA_UNUSED, Eio_File *ls)
_e_module_path_lists = eina_list_remove(_e_module_path_lists, ls);
if (_e_module_path_lists) return;
if (_e_modules_initting) e_module_all_load();
+ else if (!_e_modules_init_end)
+ {
+ ecore_event_add(E_EVENT_MODULE_INIT_END, NULL, NULL, NULL);
+ _e_modules_init_end = EINA_TRUE;
+ }
}
static void
@@ -243,6 +249,7 @@ e_module_all_load(void)
if (!_e_modules_delayed)
{
ecore_event_add(E_EVENT_MODULE_INIT_END, NULL, NULL, NULL);
+ _e_modules_init_end = EINA_TRUE;
_e_modules_initting = EINA_FALSE;
_e_module_whitelist_check();
}
@@ -253,7 +260,7 @@ e_module_all_load(void)
EAPI Eina_Bool
e_module_loading_get(void)
{
- return _e_modules_initting;
+ return !_e_modules_init_end;
}
EAPI E_Module *
@@ -768,7 +775,7 @@ _e_module_cb_idler(void *data __UNUSED__)
}
ecore_event_add(E_EVENT_MODULE_INIT_END, NULL, NULL, NULL);
-
+ _e_modules_init_end = EINA_TRUE;
_e_modules_initting = EINA_FALSE;
_e_module_whitelist_check();