From d09238dc26674f20da73bfa8fe1a5331335750fa Mon Sep 17 00:00:00 2001 From: Carsten Haitzler Date: Tue, 31 May 2005 03:26:01 +0000 Subject: [PATCH] bg get ipc SVN revision: 15029 --- src/bin/e_ipc.c | 17 ----------------- src/bin/e_ipc_handlers.h | 22 +++++++++++++++++++++- 2 files changed, 21 insertions(+), 18 deletions(-) diff --git a/src/bin/e_ipc.c b/src/bin/e_ipc.c index a8ec9b2c2..4670be3b0 100644 --- a/src/bin/e_ipc.c +++ b/src/bin/e_ipc.c @@ -78,23 +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_BG_GET: - { - void *data; - int bytes; - - data = e_ipc_codec_str_enc(e_config->desktop_default_background, &bytes); - if (data) - { - ecore_ipc_client_send(e->client, - E_IPC_DOMAIN_REPLY, - E_IPC_OP_BG_GET_REPLY, - 0/*ref*/, 0/*ref_to*/, 0/*response*/, - data, bytes); - free(data); - } - } - break; case E_IPC_OP_FONT_AVAILABLE_LIST: { E_Font_Available *fa; diff --git a/src/bin/e_ipc_handlers.h b/src/bin/e_ipc_handlers.h index d5ee6a383..5850d3046 100644 --- a/src/bin/e_ipc_handlers.h +++ b/src/bin/e_ipc_handlers.h @@ -59,7 +59,6 @@ ecore_ipc_client_send(e->client, E_IPC_DOMAIN_REPLY, __opcode, 0, 0, 0, data, by reply_count++; \ } \ break; - #define SEND_STRING_INT_LIST(__list, __typ1, __v1, __typ2, __v2, HANDLER) \ case HANDLER: { \ Evas_List *dat = NULL, *l; \ @@ -78,6 +77,15 @@ ecore_ipc_client_send(e->client, E_IPC_DOMAIN_REPLY, __opcode, 0, 0, 0, data, by FREE_LIST(dat); \ } \ break; +#define SEND_STRING(__str, __op, HANDLER) \ +case HANDLER: { void *data; int bytes; \ + data = e_ipc_codec_str_enc(__str, &bytes); \ + if (data) { \ + ecore_ipc_client_send(e->client, E_IPC_DOMAIN_REPLY, __op, 0, 0, 0, data, bytes); \ + free(data); \ + } \ +} \ +break; #endif @@ -244,6 +252,18 @@ ecore_ipc_client_send(e->client, E_IPC_DOMAIN_REPLY, __opcode, 0, 0, 0, data, by #endif #undef HANDLER +/****************************************************************************/ +#define HANDLER E_IPC_OP_BG_GET +#if (TYPE == E_REMOTE_OPTIONS) + {"-default-bg-set", 0, "Get the default background edje file path", 1, HANDLER}, +#elif (TYPE == E_REMOTE_OUT) + REQ_NULL(HANDLER); +#elif (TYPE == E_WM_IN) + SEND_STRING(e_config->desktop_default_background, E_IPC_OP_MODULE_LIST_REPLY, HANDLER); +#elif (TYPE == E_REMOTE_IN) +#endif +#undef HANDLER +