summaryrefslogtreecommitdiff
path: root/src/lib/ecore_evas/ecore_evas_buffer.c
diff options
context:
space:
mode:
authorJiyoun Park <jijibe99@gmail.com>2013-02-15 09:32:40 +0000
committerJiyoun Park <jijibe99@gmail.com>2013-02-15 09:32:40 +0000
commitc5a8a6b5ff3da760fdd5018fdfba05cc2b82588e (patch)
tree021977392dcc128263818e9c118dfd8ae94e25b4 /src/lib/ecore_evas/ecore_evas_buffer.c
parent98854667875ef83fc18a393a5d26b30603984b97 (diff)
Add infrastructure to handle message between ecore and parent ecore in Ecore_Evas
I add new example related with this. (ecore_evas_extn_socket & plug example) ecore extn use this infrasturcture, server app and client app can communicate each other later, this can be used to contorl access message SVN revision: 83942
Diffstat (limited to 'src/lib/ecore_evas/ecore_evas_buffer.c')
-rw-r--r--src/lib/ecore_evas/ecore_evas_buffer.c40
1 files changed, 39 insertions, 1 deletions
diff --git a/src/lib/ecore_evas/ecore_evas_buffer.c b/src/lib/ecore_evas/ecore_evas_buffer.c
index 96e5fb6cfe..c76af25ada 100644
--- a/src/lib/ecore_evas/ecore_evas_buffer.c
+++ b/src/lib/ecore_evas/ecore_evas_buffer.c
@@ -474,6 +474,42 @@ _ecore_evas_buffer_profile_set(Ecore_Evas *ee, const char *profile)
474 } 474 }
475} 475}
476 476
477static void
478_ecore_evas_buffer_msg_parent_send(Ecore_Evas *ee, int msg_domain, int msg_id, void *data, int size)
479{
480 Ecore_Evas *parent_ee = NULL;
481 parent_ee = ecore_evas_data_get(ee, "parent");
482
483 if (parent_ee)
484 {
485 if (parent_ee->func.fn_msg_parent_handle)
486 parent_ee ->func.fn_msg_parent_handle(parent_ee, msg_domain, msg_id, data, size);
487 }
488 else
489 {
490 if (ee->func.fn_msg_parent_handle)
491 ee ->func.fn_msg_parent_handle(ee, msg_domain, msg_id, data, size);
492 }
493}
494
495static void
496_ecore_evas_buffer_msg_send(Ecore_Evas *ee, int msg_domain, int msg_id, void *data, int size)
497{
498 Ecore_Evas *child_ee = NULL;
499 child_ee = ecore_evas_data_get(ee, "child");
500
501 if (!child_ee)
502 {
503 if (child_ee->func.fn_msg_handle)
504 child_ee->func.fn_msg_handle(child_ee, msg_domain, msg_id, data, size);
505 }
506 else
507 {
508 if (ee->func.fn_msg_handle)
509 ee->func.fn_msg_handle(ee, msg_domain, msg_id, data, size);
510 }
511}
512
477static Ecore_Evas_Engine_Func _ecore_buffer_engine_func = 513static Ecore_Evas_Engine_Func _ecore_buffer_engine_func =
478{ 514{
479 _ecore_evas_buffer_free, 515 _ecore_evas_buffer_free,
@@ -534,7 +570,9 @@ static Ecore_Evas_Engine_Func _ecore_buffer_engine_func =
534 570
535 _ecore_evas_buffer_render, 571 _ecore_evas_buffer_render,
536 NULL, // screen_geometry_get 572 NULL, // screen_geometry_get
537 NULL // screen_dpi_get 573 NULL, // screen_dpi_get
574 _ecore_evas_buffer_msg_parent_send,
575 _ecore_evas_buffer_msg_send
538}; 576};
539 577
540static void * 578static void *