e_manager_comp_set now sends an event instead of using e_msg, though I don't even think this is necessary anymore since it will only be called on startup and shutdown...

SVN revision: 82696
This commit is contained in:
Mike Blumenkrantz 2013-01-12 12:57:53 +00:00
parent 16062072e4
commit 91748cdc92
3 changed files with 5 additions and 12 deletions

View File

@ -43,6 +43,7 @@ struct _Frame_Extents
};
EAPI int E_EVENT_MANAGER_KEYS_GRAB = -1;
EAPI int E_EVENT_MANAGER_COMP_SET = -1;
static Eina_List *managers = NULL;
static Eina_Hash *frame_extents = NULL;
@ -55,6 +56,7 @@ e_manager_init(void)
ecore_x_screensaver_event_listen_set(1);
frame_extents = eina_hash_string_superfast_new(NULL);
E_EVENT_MANAGER_KEYS_GRAB = ecore_event_type_new();
E_EVENT_MANAGER_COMP_SET = ecore_event_type_new();
return 1;
}
@ -529,11 +531,7 @@ e_manager_comp_set(E_Manager *man, E_Manager_Comp *comp)
E_OBJECT_CHECK(man);
E_OBJECT_TYPE_CHECK(man, E_MANAGER_TYPE);
man->comp = comp;
e_msg_send("comp.manager", "change.comp", // name + info
0, // val
E_OBJECT(man), // obj
NULL, // msgdata
NULL, NULL); // afterfunc + afterdata
ecore_event_add(E_EVENT_MANAGER_COMP_SET, NULL, NULL, NULL);
}
EAPI Evas *

View File

@ -11,6 +11,7 @@ typedef struct _E_Manager_Comp_Source E_Manager_Comp_Source;
#define E_MANAGER_TYPE (int) 0xE0b01008
extern EAPI int E_EVENT_MANAGER_KEYS_GRAB;
extern EAPI int E_EVENT_MANAGER_COMP_SET;
struct _E_Manager
{

View File

@ -947,13 +947,7 @@ handler(void *data, const char *name, const char *info, int val,
if (strcmp(name, "comp.manager")) return;
e = e_manager_comp_evas_get(man);
if (!strcmp(info, "change.comp"))
{
if (!e) printf("TTT: No comp manager\n");
else printf("TTT: comp canvas = %p\n", e);
if (e) setup(man);
}
else if (!strcmp(info, "resize.comp"))
if (!strcmp(info, "resize.comp"))
{
printf("%s: %p | %p\n", info, man, src);
}