diff options
author | Daniel Hirt <hirt.danny@gmail.com> | 2017-06-05 01:51:47 +0300 |
---|---|---|
committer | Daniel Hirt <hirt.danny@gmail.com> | 2017-06-05 01:51:47 +0300 |
commit | 4dffc846febfe09ffc029bd37d548e1633c2f3a2 (patch) | |
tree | cb7fc21fcdaff12a0e472dbe812dc295cf5be3d6 | |
parent | e25a304959ef4c27b8e1b012984ac6d45dc1eeee (diff) | |
download | efl-4dffc846febfe09ffc029bd37d548e1633c2f3a2.tar.gz |
Elm layout: use as legacy
-rw-r--r-- | src/lib/elementary/elm_layout.c | 13 | ||||
-rw-r--r-- | src/lib/elementary/elm_layout.eo | 2 | ||||
-rw-r--r-- | src/lib/elementary/elm_layout_legacy.h | 23 |
3 files changed, 38 insertions, 0 deletions
diff --git a/src/lib/elementary/elm_layout.c b/src/lib/elementary/elm_layout.c index 957d8f608d..18e6f5a03a 100644 --- a/src/lib/elementary/elm_layout.c +++ b/src/lib/elementary/elm_layout.c @@ -2315,6 +2315,19 @@ elm_layout_table_clear(Elm_Layout *obj, const char *part, Eina_Bool clear) return efl_pack_unpack_all(efl_part(obj, part)); } +EAPI Eina_Bool +elm_layout_text_set(Elm_Layout *obj, const char *part, const char *text) +{ + efl_text_set(efl_part(obj, part), text); + return EINA_TRUE; +} + +EAPI const char * +elm_layout_text_get(const Elm_Layout *obj, const char *part) +{ + return efl_text_get(efl_part(obj, part)); +} + /* Efl.Part implementation */ static EOLIAN Efl_Object * diff --git a/src/lib/elementary/elm_layout.eo b/src/lib/elementary/elm_layout.eo index 2e83d1da4a..3cf88a13c3 100644 --- a/src/lib/elementary/elm_layout.eo +++ b/src/lib/elementary/elm_layout.eo @@ -199,10 +199,12 @@ class Elm.Layout (Elm.Widget, Efl.Part, Efl.Container, Efl.File, @property text { set { [[Set the text of the given part.]] + legacy: null; return: bool; [[$true on success, $false otherwise]] } get { [[Get the text set in the given part.]] + legacy: null; } keys { part: string @nullable; [[The TEXT part where to set the text.]] diff --git a/src/lib/elementary/elm_layout_legacy.h b/src/lib/elementary/elm_layout_legacy.h index c9654d23fe..0bae5a05e2 100644 --- a/src/lib/elementary/elm_layout_legacy.h +++ b/src/lib/elementary/elm_layout_legacy.h @@ -368,4 +368,27 @@ EAPI int elm_layout_freeze(Evas_Object *obj); */ EAPI int elm_layout_thaw(Evas_Object *obj); +/** + * @brief Set the text of the given part. + * + * @param[in] part The TEXT part where to set the text. + * @param[in] text The text to set. + * + * @return @c true on success, @c false otherwise + * + * @ingroup Elm_Layout + */ +EAPI Eina_Bool elm_layout_text_set(Elm_Layout *obj, const char * part, const char *text); + +/** + * @brief Get the text set in the given part. + * + * @param[in] part The TEXT part where to set the text. + * + * @return The text to set. + * + * @ingroup Elm_Layout + */ +EAPI const char *elm_layout_text_get(const Elm_Layout *obj, const char * part); + #include "elm_layout.eo.legacy.h" |