From 7ce7d4cc27ccdee8bc43571ba58bddb8f282d974 Mon Sep 17 00:00:00 2001 From: Jean-Philippe Andre Date: Mon, 29 May 2017 22:27:21 +0900 Subject: [PATCH] edje: Remove part_external_content_get from EO I couldn't find a use of this API. This looks like it returns an object inside a part inside an external (so, inside an edje). Kept as legacy only. --- src/lib/edje/Edje_Legacy.h | 16 ++++++++++++++++ src/lib/edje/edje_external.c | 4 ++-- src/lib/edje/edje_legacy.c | 12 ++++++++++-- src/lib/edje/edje_object.eo | 13 ------------- src/lib/edje/edje_private.h | 1 + 5 files changed, 29 insertions(+), 17 deletions(-) diff --git a/src/lib/edje/Edje_Legacy.h b/src/lib/edje/Edje_Legacy.h index 2451171..70fccb5 100644 --- a/src/lib/edje/Edje_Legacy.h +++ b/src/lib/edje/Edje_Legacy.h @@ -481,6 +481,22 @@ EAPI Eina_Bool edje_object_part_external_param_set(Edje_Object *obj, const char EAPI Eina_Bool edje_object_part_external_param_get(const Edje_Object *obj, const char *part, Edje_External_Param *param); /** + * @brief Gets an object contained in an part of type EXTERNAL + * + * The content string must not be @c null. Its actual value depends on the code + * providing the EXTERNAL. + * + * @param[in] part The name of the part holding the EXTERNAL + * @param[in] content A string identifying which content from the EXTERNAL to + * get + * + * @return Canvas object + * + * @ingroup Edje_Object + */ +EAPI Evas_Object *edje_object_part_external_content_get(const Edje_Object *obj, const char *part, const char *content); + +/** * @} */ diff --git a/src/lib/edje/edje_external.c b/src/lib/edje/edje_external.c index b345200..b067b5c 100644 --- a/src/lib/edje/edje_external.c +++ b/src/lib/edje/edje_external.c @@ -92,8 +92,8 @@ _edje_object_part_external_param_get(Edje *ed, const char *part, Edje_External_P return _edje_external_param_get(ed->obj, rp, param); } -EOLIAN Evas_Object * -_edje_object_part_external_content_get(Eo *obj EINA_UNUSED, Edje *ed, const char *part, const char *content) +Evas_Object * +_edje_object_part_external_content_get(Edje *ed, const char *part, const char *content) { Edje_Real_Part *rp; diff --git a/src/lib/edje/edje_legacy.c b/src/lib/edje/edje_legacy.c index cf27351..5bbb384 100644 --- a/src/lib/edje/edje_legacy.c +++ b/src/lib/edje/edje_legacy.c @@ -68,8 +68,8 @@ edje_object_part_external_param_set(Eo *obj, const char *part, const Edje_Extern if (!ed || !param || !part) return EINA_FALSE; -#if 1 - /* validate EO API - disable for performance */ +#if 0 + /* validate EO API - disabled for performance */ Eina_Value *v; Eina_Bool ok; @@ -118,3 +118,11 @@ edje_object_part_external_param_type_get(const Eo *obj, const char *part, const Edje *ed = _edje_fetch(obj); return _edje_object_part_external_param_type_get(ed, part, param); } + +/* Legacy only. Shall we deprecate this API? */ +EAPI Evas_Object * +edje_object_part_external_content_get(const Edje_Object *obj, const char *part, const char *content) +{ + Edje *ed = _edje_fetch(obj); + return _edje_object_part_external_content_get(ed, part, content); +} diff --git a/src/lib/edje/edje_object.eo b/src/lib/edje/edje_object.eo index ccb101a..84482c5 100644 --- a/src/lib/edje/edje_object.eo +++ b/src/lib/edje/edje_object.eo @@ -1027,19 +1027,6 @@ class Edje.Object (Efl.Canvas.Group.Clipped, Efl.File, Efl.Container, Efl.Part, part: string; [[The part name]] } } - @property part_external_content { - get { - [[Gets an object contained in an part of type EXTERNAL - - The content string must not be $null. Its actual value depends on the - code providing the EXTERNAL.]] - return: Efl.Canvas.Object; [[Canvas object]] - } - keys { - part: string; [[The name of the part holding the EXTERNAL]] - content: string; [[A string identifying which content from the EXTERNAL to get]] - } - } @property text_change_cb { set { [[Sets the object text callback. diff --git a/src/lib/edje/edje_private.h b/src/lib/edje/edje_private.h index e62d59e..531ec16 100644 --- a/src/lib/edje/edje_private.h +++ b/src/lib/edje/edje_private.h @@ -3125,6 +3125,7 @@ Eo *_edje_external_internal_proxy_get(Edje_Object *obj, Edje *ed, Edje_Real_Part Eina_Bool _edje_object_part_external_param_set(Edje *ed, const char *part, const Edje_External_Param *param); Eina_Bool _edje_object_part_external_param_get(Edje *ed, const char *part, Edje_External_Param *param); Edje_External_Param_Type _edje_object_part_external_param_type_get(Edje *ed, const char *part, const char *param); +Evas_Object *_edje_object_part_external_content_get(Edje *ed, const char *part, const char *content); void _edje_internal_proxy_shutdown(void); -- 2.7.4