summaryrefslogtreecommitdiff
path: root/src/lib/efl_wl/efl_wl.c
diff options
context:
space:
mode:
authorMike Blumenkrantz <zmike@osg.samsung.com>2018-01-03 18:22:32 -0500
committerMike Blumenkrantz <zmike@osg.samsung.com>2018-01-03 18:46:54 -0500
commitcca561e94e0fffe4002bee67ab15e3f0179be707 (patch)
treedadb20ad017c605958a98e7d5de8925623110bcd /src/lib/efl_wl/efl_wl.c
parent0f7c5582a4873711e0e086a8c725ffe899e29bcf (diff)
efl-wl: add function to get the parent of an extracted surface
@feature
Diffstat (limited to '')
-rw-r--r--src/lib/efl_wl/efl_wl.c20
1 files changed, 20 insertions, 0 deletions
diff --git a/src/lib/efl_wl/efl_wl.c b/src/lib/efl_wl/efl_wl.c
index 4a71abc26e..0943dbe3f8 100644
--- a/src/lib/efl_wl/efl_wl.c
+++ b/src/lib/efl_wl/efl_wl.c
@@ -5585,3 +5585,23 @@ efl_wl_extracted_surface_object_find(void *surface_resource)
5585 5585
5586 return cs->obj; 5586 return cs->obj;
5587} 5587}
5588
5589Evas_Object *
5590efl_wl_extracted_surface_extracted_parent_get(Evas_Object *surface)
5591{
5592 Comp_Surface *cs;
5593
5594 EINA_SAFETY_ON_NULL_RETURN_VAL(surface, NULL);
5595 if (!eina_streq(evas_object_type_get(surface), "comp_surface")) abort();
5596
5597 cs = evas_object_smart_data_get(surface);
5598 EINA_SAFETY_ON_TRUE_RETURN_VAL(!cs->extracted, NULL);
5599 EINA_SAFETY_ON_TRUE_RETURN_VAL(cs->dead, NULL);
5600
5601 if (cs->parent)
5602 {
5603 EINA_SAFETY_ON_FALSE_RETURN_VAL(!cs->parent->extracted, NULL);
5604 return cs->parent->obj;
5605 }
5606 return NULL;
5607}