forked from enlightenment/efl
elementary textpath: support legacy APIs
Summary: Efl.Ui.Textpath was added when we were developing new interfaces. So, basically, it does not support 'legacy' APIs. ex) elm_textpath_add But, in Tizen, the legacy APIs had been delivered in old version of EFL. To reduce maintainning cost between the platforms, this patch will be helpful. @feature Test Plan: N/A Reviewers: Hermet, woohyun, zmike, cedric, herdsman Reviewed By: Hermet Subscribers: #reviewers, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D7033
This commit is contained in:
parent
0270b20378
commit
32504a8cfa
|
@ -56,6 +56,7 @@ elm_public_eolian_files = \
|
|||
lib/elementary/efl_ui_text_factory_emoticons.eo \
|
||||
lib/elementary/efl_ui_text_factory_fallback.eo \
|
||||
lib/elementary/efl_ui_textpath.eo \
|
||||
lib/elementary/efl_ui_textpath_legacy.eo \
|
||||
lib/elementary/efl_ui_translatable.eo \
|
||||
lib/elementary/efl_ui_clock.eo \
|
||||
lib/elementary/efl_ui_cursor.eo \
|
||||
|
@ -630,6 +631,8 @@ includesub_HEADERS = \
|
|||
lib/elementary/elm_sys_notify.h \
|
||||
lib/elementary/elm_table.h \
|
||||
lib/elementary/elm_table_legacy.h \
|
||||
lib/elementary/elm_textpath.h \
|
||||
lib/elementary/elm_textpath_legacy.h \
|
||||
lib/elementary/elm_theme.h \
|
||||
lib/elementary/elm_thumb.h \
|
||||
lib/elementary/elm_thumb_common.h \
|
||||
|
|
|
@ -160,7 +160,6 @@ typedef Eo Efl_Ui_Focus_Manager;
|
|||
# include <efl_ui_focus_manager_sub.eo.h>
|
||||
# include <efl_ui_focus_manager_root_focus.eo.h>
|
||||
# include <efl_ui_focus_util.eo.h>
|
||||
# include <efl_ui_textpath.eo.h>
|
||||
# include <efl_ui_translatable.eo.h>
|
||||
# include <efl_ui_focus_composition.eo.h>
|
||||
# include <efl_ui_focus_layer.eo.h>
|
||||
|
@ -269,6 +268,7 @@ typedef Eo Efl_Ui_Focus_Manager;
|
|||
#include <elm_spinner.h>
|
||||
#include <elm_store.h>
|
||||
#include <elm_table.h>
|
||||
#include <elm_textpath.h>
|
||||
#include <elm_theme.h>
|
||||
#include <elm_thumb.h>
|
||||
#include <elm_toolbar.h>
|
||||
|
|
|
@ -758,3 +758,32 @@ ELM_PART_OVERRIDE_TEXT_GET(efl_ui_textpath, EFL_UI_TEXTPATH, Efl_Ui_Textpath_Dat
|
|||
EFL_CANVAS_GROUP_ADD_OPS(efl_ui_textpath)
|
||||
|
||||
#include "efl_ui_textpath.eo.c"
|
||||
|
||||
#include "efl_ui_textpath_legacy.eo.h"
|
||||
|
||||
#define MY_CLASS_NAME_LEGACY "elm_textpath"
|
||||
/* Legacy APIs */
|
||||
|
||||
static void
|
||||
_efl_ui_textpath_legacy_class_constructor(Efl_Class *klass)
|
||||
{
|
||||
evas_smart_legacy_type_register(MY_CLASS_NAME_LEGACY, klass);
|
||||
}
|
||||
|
||||
EOLIAN static Eo *
|
||||
_efl_ui_textpath_legacy_efl_object_constructor(Eo *obj, void *_pd EINA_UNUSED)
|
||||
{
|
||||
obj = efl_constructor(efl_super(obj, EFL_UI_TEXTPATH_LEGACY_CLASS));
|
||||
efl_canvas_object_type_set(obj, MY_CLASS_NAME_LEGACY);
|
||||
return obj;
|
||||
}
|
||||
|
||||
EAPI Evas_Object *
|
||||
elm_textpath_add(Evas_Object *parent)
|
||||
{
|
||||
EINA_SAFETY_ON_NULL_RETURN_VAL(parent, NULL);
|
||||
return elm_legacy_add(EFL_UI_TEXTPATH_LEGACY_CLASS, parent);
|
||||
}
|
||||
|
||||
#include "efl_ui_textpath_legacy.eo.c"
|
||||
|
||||
|
|
|
@ -7,6 +7,7 @@ enum Efl.Ui.Textpath_Direction {
|
|||
class Efl.Ui.Textpath (Efl.Ui.Layout.Object, Efl.Text, Efl.Gfx.Path)
|
||||
{
|
||||
[[Efl Ui Textpath class]]
|
||||
legacy_prefix: elm_textpath;
|
||||
methods {
|
||||
circle_set {
|
||||
[[Set a circle with given center, radius, and start angle.]]
|
||||
|
|
|
@ -0,0 +1,9 @@
|
|||
class Efl.Ui.Textpath_Legacy (Efl.Ui.Textpath, Efl.Ui.Legacy)
|
||||
{
|
||||
[[Textpath widget]]
|
||||
data: null;
|
||||
implements {
|
||||
class.constructor;
|
||||
Efl.Object.constructor;
|
||||
}
|
||||
}
|
|
@ -0,0 +1,15 @@
|
|||
/**
|
||||
* @defgroup Elm_Textpath Textpath
|
||||
* @ingroup Elementary
|
||||
*/
|
||||
|
||||
#ifdef EFL_EO_API_SUPPORT
|
||||
#include "efl_ui_textpath.eo.h"
|
||||
#define EFL_UI_RADIO_EVENT_CHANGED EFL_UI_NSTATE_EVENT_CHANGED
|
||||
#endif
|
||||
#ifndef EFL_NOLEGACY_API_SUPPORT
|
||||
#include "elm_textpath_legacy.h"
|
||||
#endif
|
||||
/**
|
||||
* @}
|
||||
*/
|
|
@ -0,0 +1,15 @@
|
|||
typedef Eo Elm_Textpath;
|
||||
|
||||
/**
|
||||
* @brief Add a new textpath to the parent
|
||||
*
|
||||
* @param[in] parent The parent object
|
||||
* @return The new object or NULL if it cannot be created
|
||||
*
|
||||
* @ingroup Elm_Textpath
|
||||
*
|
||||
* @since 1.22
|
||||
*/
|
||||
EAPI Evas_Object *elm_textpath_add(Evas_Object *parent);
|
||||
|
||||
#include "efl_ui_textpath.eo.legacy.h"
|
Loading…
Reference in New Issue