list availabel fonts, and handle reply

SVN revision: 15036
This commit is contained in:
Carsten Haitzler 2005-05-31 07:13:27 +00:00
parent 3743c25e1d
commit 55eb16f293
3 changed files with 15 additions and 43 deletions

View File

@ -78,30 +78,6 @@ _e_ipc_cb_client_data(void *data __UNUSED__, int type __UNUSED__, void *event)
#undef TYPE
/* here to steal from to port over to the new e_ipc_handlers.h */
#if 0
case E_IPC_OP_FONT_AVAILABLE_LIST:
{
E_Font_Available *fa;
Evas_List *dat = NULL, *l, *fa_list;
void *data;
int bytes;
fa_list = e_font_available_list();
for (l = fa_list; l; l = l->next)
{
fa = l->data;
dat = evas_list_append(dat, fa->name);
}
data = e_ipc_codec_str_list_enc(dat, &bytes);
ecore_ipc_client_send(e->client,
E_IPC_DOMAIN_REPLY,
E_IPC_OP_FONT_AVAILABLE_LIST_REPLY,
0/*ref*/, 0/*ref_to*/, 0/*response*/,
data, bytes);
free(data);
evas_list_free(dat);
e_font_available_list_free(fa_list);
}
break;
case E_IPC_OP_FONT_APPLY:
{
e_font_apply();

View File

@ -111,6 +111,12 @@ break;
} \
break;
#define LIST() \
Evas_List *dat = NULL, *l;
#define DECODE(__dec) \
if (__dec(e->data, e->size, &dat))
#endif
@ -330,7 +336,15 @@ break;
#elif (TYPE == E_REMOTE_OUT)
#elif (TYPE == E_WM_IN)
#elif (TYPE == E_REMOTE_IN)
//
GENERIC(HANDLER);
LIST();
DECODE(e_ipc_codec_str_list_dec) {
FOR(dat) {
printf("REPLY: \"%s\"\n", (char *)(l->data));
}
FREE_LIST(dat);
}
END_GENERIC();
#endif
#undef HANDLER

View File

@ -951,24 +951,6 @@ _e_ipc_cb_server_data(void *data, int type, void *event)
else
printf("REPLY: FALLBACK NONE\n");
break;
case E_IPC_OP_FONT_AVAILABLE_LIST_REPLY:
if (e->data)
{
Evas_List *available;
E_Font_Available *fa;
available = _e_ipc_font_available_list_dec(e->data, e->size);
while (available)
{
fa = available->data;
printf("REPLY: AVAILABLE NAME=\"%s\"\n", fa->name);
available = evas_list_remove_list(available, available);
E_FREE(fa);
}
}
else
printf("REPLY: AVAILABLE NONE\n");
break;
case E_IPC_OP_FONT_DEFAULT_GET_REPLY:
if (e->data)
{