summaryrefslogtreecommitdiff
path: root/src/lib
diff options
context:
space:
mode:
authorSungtaek Hong <sth253.hong@samsung.com>2018-01-24 15:50:58 +0900
committerJean-Philippe Andre <jp.andre@samsung.com>2018-01-24 18:14:26 +0900
commitcb25699dacde420a0e0c3434065ab8dac242ee6e (patch)
treeaadf195322243f48771eb3235e9079c5a25891b5 /src/lib
parentf6ba674cd8ada4e018fd205dab2e877e9a19a820 (diff)
downloadefl-cb25699dacde420a0e0c3434065ab8dac242ee6e.tar.gz
efl_ui_legacy: add new interface to indicate legacy widget
Summary: For now, how to check whether a widget is legacy or not is to check flags in private data or static flag, which is set during elm_legacy_add. If Efl.Ui.Legacy interface is added, it can be easilly checked by efl_isa(obj, EFL_UI_LEGACY_INTERFACE) Reviewers: woohyun, jpeg, cedric, Jaehyun_Cho Subscribers: conr2d, cedric, jpeg Differential Revision: https://phab.enlightenment.org/D5748
Diffstat (limited to 'src/lib')
-rw-r--r--src/lib/elementary/efl_ui_bg_widget.c44
-rw-r--r--src/lib/elementary/efl_ui_bg_widget.eo1
-rw-r--r--src/lib/elementary/efl_ui_bg_widget_legacy.eo14
-rw-r--r--src/lib/elementary/efl_ui_button.c42
-rw-r--r--src/lib/elementary/efl_ui_button.eo1
-rw-r--r--src/lib/elementary/efl_ui_button_legacy.eo13
-rw-r--r--src/lib/elementary/efl_ui_check.c42
-rw-r--r--src/lib/elementary/efl_ui_check.eo1
-rw-r--r--src/lib/elementary/efl_ui_check_legacy.eo15
-rw-r--r--src/lib/elementary/efl_ui_clock.c8
-rw-r--r--src/lib/elementary/efl_ui_clock.eo1
-rw-r--r--src/lib/elementary/efl_ui_clock_legacy.eo9
-rw-r--r--src/lib/elementary/efl_ui_flip.c42
-rw-r--r--src/lib/elementary/efl_ui_flip.eo1
-rw-r--r--src/lib/elementary/efl_ui_flip_legacy.eo9
-rw-r--r--src/lib/elementary/efl_ui_frame.c42
-rw-r--r--src/lib/elementary/efl_ui_frame.eo1
-rw-r--r--src/lib/elementary/efl_ui_frame_legacy.eo14
-rw-r--r--src/lib/elementary/efl_ui_image.c52
-rw-r--r--src/lib/elementary/efl_ui_image.eo1
-rw-r--r--src/lib/elementary/efl_ui_image_legacy.eo9
-rw-r--r--src/lib/elementary/efl_ui_image_zoomable.c47
-rw-r--r--src/lib/elementary/efl_ui_image_zoomable_legacy.eo9
-rw-r--r--src/lib/elementary/efl_ui_layout.c514
-rw-r--r--src/lib/elementary/efl_ui_layout.eo1
-rw-r--r--src/lib/elementary/efl_ui_layout_legacy.eo9
-rw-r--r--src/lib/elementary/efl_ui_legacy.c8
-rw-r--r--src/lib/elementary/efl_ui_legacy.eo9
-rw-r--r--src/lib/elementary/efl_ui_multibuttonentry.c39
-rw-r--r--src/lib/elementary/efl_ui_multibuttonentry_legacy.eo9
-rw-r--r--src/lib/elementary/efl_ui_panes.c33
-rw-r--r--src/lib/elementary/efl_ui_panes.eo1
-rw-r--r--src/lib/elementary/efl_ui_panes_legacy.eo9
-rw-r--r--src/lib/elementary/efl_ui_progressbar.c30
-rw-r--r--src/lib/elementary/efl_ui_progressbar.eo1
-rw-r--r--src/lib/elementary/efl_ui_progressbar_legacy.eo9
-rw-r--r--src/lib/elementary/efl_ui_radio.c29
-rw-r--r--src/lib/elementary/efl_ui_radio.eo1
-rw-r--r--src/lib/elementary/efl_ui_radio_legacy.eo9
-rw-r--r--src/lib/elementary/efl_ui_slider.c54
-rw-r--r--src/lib/elementary/efl_ui_slider.eo1
-rw-r--r--src/lib/elementary/efl_ui_slider_legacy.eo9
-rw-r--r--src/lib/elementary/efl_ui_video.c63
-rw-r--r--src/lib/elementary/efl_ui_video.eo1
-rw-r--r--src/lib/elementary/efl_ui_video_legacy.eo9
-rw-r--r--src/lib/elementary/efl_ui_widget.c16
-rw-r--r--src/lib/elementary/efl_ui_win.c136
-rw-r--r--src/lib/elementary/efl_ui_win_legacy.eo9
-rw-r--r--src/lib/elementary/elm_actionslider.eo2
-rw-r--r--src/lib/elementary/elm_box.eo2
-rw-r--r--src/lib/elementary/elm_bubble.eo2
-rw-r--r--src/lib/elementary/elm_calendar.eo3
-rw-r--r--src/lib/elementary/elm_clock.eo2
-rw-r--r--src/lib/elementary/elm_code.h1
-rw-r--r--src/lib/elementary/elm_code_diff_widget.c4
-rw-r--r--src/lib/elementary/elm_code_widget.c9
-rw-r--r--src/lib/elementary/elm_code_widget_legacy.eo5
-rw-r--r--src/lib/elementary/elm_colorselector.eo2
-rw-r--r--src/lib/elementary/elm_combobox.eo2
-rw-r--r--src/lib/elementary/elm_conformant.eo2
-rw-r--r--src/lib/elementary/elm_ctxpopup.eo2
-rw-r--r--src/lib/elementary/elm_ctxpopup_item.eo3
-rw-r--r--src/lib/elementary/elm_datetime.c22
-rw-r--r--src/lib/elementary/elm_dayselector.eo2
-rw-r--r--src/lib/elementary/elm_diskselector.eo2
-rw-r--r--src/lib/elementary/elm_diskselector_item.eo2
-rw-r--r--src/lib/elementary/elm_entry.eo3
-rw-r--r--src/lib/elementary/elm_fileselector.eo2
-rw-r--r--src/lib/elementary/elm_fileselector_button.eo3
-rw-r--r--src/lib/elementary/elm_fileselector_entry.eo2
-rw-r--r--src/lib/elementary/elm_flipselector.eo2
-rw-r--r--src/lib/elementary/elm_gengrid.eo2
-rw-r--r--src/lib/elementary/elm_gengrid_item.eo2
-rw-r--r--src/lib/elementary/elm_genlist.eo2
-rw-r--r--src/lib/elementary/elm_genlist_item.eo2
-rw-r--r--src/lib/elementary/elm_gesture_layer.eo2
-rw-r--r--src/lib/elementary/elm_glview.eo2
-rw-r--r--src/lib/elementary/elm_grid.eo2
-rw-r--r--src/lib/elementary/elm_hover.eo3
-rw-r--r--src/lib/elementary/elm_hoversel.eo3
-rw-r--r--src/lib/elementary/elm_hoversel_item.eo2
-rw-r--r--src/lib/elementary/elm_icon.eo2
-rw-r--r--src/lib/elementary/elm_index.eo2
-rw-r--r--src/lib/elementary/elm_index_item.eo2
-rw-r--r--src/lib/elementary/elm_interface_scrollable.c2
-rw-r--r--src/lib/elementary/elm_interfaces.h2
-rw-r--r--src/lib/elementary/elm_inwin.eo2
-rw-r--r--src/lib/elementary/elm_label.eo2
-rw-r--r--src/lib/elementary/elm_list.eo2
-rw-r--r--src/lib/elementary/elm_list_item.eo2
-rw-r--r--src/lib/elementary/elm_map.eo2
-rw-r--r--src/lib/elementary/elm_mapbuf.eo2
-rw-r--r--src/lib/elementary/elm_menu.eo2
-rw-r--r--src/lib/elementary/elm_menu_item.eo2
-rw-r--r--src/lib/elementary/elm_multibuttonentry_item.eo3
-rw-r--r--src/lib/elementary/elm_naviframe.eo2
-rw-r--r--src/lib/elementary/elm_naviframe_item.eo2
-rw-r--r--src/lib/elementary/elm_notify.eo2
-rw-r--r--src/lib/elementary/elm_panel.eo2
-rw-r--r--src/lib/elementary/elm_photo.eo3
-rw-r--r--src/lib/elementary/elm_player.eo2
-rw-r--r--src/lib/elementary/elm_plug.eo2
-rw-r--r--src/lib/elementary/elm_popup.eo2
-rw-r--r--src/lib/elementary/elm_popup_item.eo2
-rw-r--r--src/lib/elementary/elm_prefs.eo2
-rw-r--r--src/lib/elementary/elm_route.eo2
-rw-r--r--src/lib/elementary/elm_scroller.eo2
-rw-r--r--src/lib/elementary/elm_segment_control.eo2
-rw-r--r--src/lib/elementary/elm_segment_control_item.eo2
-rw-r--r--src/lib/elementary/elm_separator.eo2
-rw-r--r--src/lib/elementary/elm_slideshow.eo2
-rw-r--r--src/lib/elementary/elm_spinner.eo2
-rw-r--r--src/lib/elementary/elm_table.eo2
-rw-r--r--src/lib/elementary/elm_theme.c1
-rw-r--r--src/lib/elementary/elm_thumb.eo2
-rw-r--r--src/lib/elementary/elm_toolbar.eo2
-rw-r--r--src/lib/elementary/elm_toolbar_item.eo2
-rw-r--r--src/lib/elementary/elm_web.eo2
-rw-r--r--src/lib/elementary/elm_widget.h12
119 files changed, 985 insertions, 632 deletions
diff --git a/src/lib/elementary/efl_ui_bg_widget.c b/src/lib/elementary/efl_ui_bg_widget.c
index def31d006f..dba5dd7a34 100644
--- a/src/lib/elementary/efl_ui_bg_widget.c
+++ b/src/lib/elementary/efl_ui_bg_widget.c
@@ -13,7 +13,6 @@
#define MY_CLASS_PFX efl_ui_bg_widget
#define MY_CLASS_NAME "Efl.Ui.Bg_Widget"
-#define MY_CLASS_NAME_LEGACY "elm_bg"
static const Elm_Layout_Part_Alias_Description _content_aliases[] =
{
@@ -21,13 +20,6 @@ static const Elm_Layout_Part_Alias_Description _content_aliases[] =
{NULL, NULL}
};
-EAPI Evas_Object *
-elm_bg_add(Evas_Object *parent)
-{
- EINA_SAFETY_ON_NULL_RETURN_VAL(parent, NULL);
- return elm_legacy_add(MY_CLASS, parent);
-}
-
EOLIAN static Eo *
_efl_ui_bg_widget_efl_object_constructor(Eo *obj, Efl_Ui_Bg_Widget_Data *pd)
{
@@ -54,7 +46,6 @@ _efl_ui_bg_widget_efl_object_constructor(Eo *obj, Efl_Ui_Bg_Widget_Data *pd)
efl_image_scale_type_set(efl_added, EFL_IMAGE_SCALE_TYPE_FIT_OUTSIDE),
efl_content_set(efl_part(obj, "elm.swallow.background"), efl_added));
- efl_canvas_object_type_set(obj, MY_CLASS_NAME_LEGACY);
efl_access_type_set(obj, EFL_ACCESS_TYPE_DISABLED);
efl_ui_widget_focus_allow_set(obj, EINA_FALSE);
@@ -191,12 +182,6 @@ _efl_ui_bg_widget_efl_image_load_load_size_get(Eo *obj EINA_UNUSED, Efl_Ui_Bg_Wi
return efl_image_load_size_get(sd->img);
}
-static void
-_efl_ui_bg_widget_class_constructor(Efl_Class *klass)
-{
- evas_smart_legacy_type_register(MY_CLASS_NAME_LEGACY, klass);
-}
-
EAPI Eina_Bool
elm_bg_file_set(Eo *obj, const char *file, const char *group)
{
@@ -242,3 +227,32 @@ ELM_LAYOUT_CONTENT_ALIASES_IMPLEMENT(MY_CLASS_PFX)
ELM_LAYOUT_CONTENT_ALIASES_OPS(MY_CLASS_PFX)
#include "efl_ui_bg_widget.eo.c"
+
+
+#include "efl_ui_bg_widget_legacy.eo.h"
+
+#define MY_CLASS_NAME_LEGACY "elm_bg"
+
+static void
+_efl_ui_bg_widget_legacy_class_constructor(Efl_Class *klass)
+{
+ evas_smart_legacy_type_register(MY_CLASS_NAME_LEGACY, klass);
+}
+
+EOLIAN static Eo *
+_efl_ui_bg_widget_legacy_efl_object_constructor(Eo *obj, void *_pd EINA_UNUSED)
+{
+ obj = efl_constructor(efl_super(obj, EFL_UI_BG_WIDGET_LEGACY_CLASS));
+ efl_canvas_object_type_set(obj, MY_CLASS_NAME_LEGACY);
+
+ return obj;
+}
+
+EAPI Evas_Object *
+elm_bg_add(Evas_Object *parent)
+{
+ EINA_SAFETY_ON_NULL_RETURN_VAL(parent, NULL);
+ return elm_legacy_add(EFL_UI_BG_WIDGET_LEGACY_CLASS, parent);
+}
+
+#include "efl_ui_bg_widget_legacy.eo.c"
diff --git a/src/lib/elementary/efl_ui_bg_widget.eo b/src/lib/elementary/efl_ui_bg_widget.eo
index 96a94245ca..ef8882d7ac 100644
--- a/src/lib/elementary/efl_ui_bg_widget.eo
+++ b/src/lib/elementary/efl_ui_bg_widget.eo
@@ -8,7 +8,6 @@ class Efl.Ui.Bg_Widget (Efl.Ui.Layout, Efl.Ui.Bg, Efl.Image.Load)
]]
legacy_prefix: elm_bg;
implements {
- class.constructor;
Efl.Object.constructor;
Efl.File.file { get; set; }
Efl.File.mmap { get; set; }
diff --git a/src/lib/elementary/efl_ui_bg_widget_legacy.eo b/src/lib/elementary/efl_ui_bg_widget_legacy.eo
new file mode 100644
index 0000000000..66d38b27b1
--- /dev/null
+++ b/src/lib/elementary/efl_ui_bg_widget_legacy.eo
@@ -0,0 +1,14 @@
+class Efl.Ui.Bg_Widget_Legacy (Efl.Ui.Bg_Widget, Efl.Ui.Legacy)
+{
+ [[The bg (background) widget is used for setting (solid) background decorations
+
+ for a window (unless it has transparency enabled) or for any container object. It
+ works just like an image, but has some properties useful for backgrounds, such as
+ setting it to tiled, centered, scaled or stretched.
+ ]]
+ data: null;
+ implements {
+ class.constructor;
+ Efl.Object.constructor;
+ }
+}
diff --git a/src/lib/elementary/efl_ui_button.c b/src/lib/elementary/efl_ui_button.c
index 8cdfa7d161..c14d4be44a 100644
--- a/src/lib/elementary/efl_ui_button.c
+++ b/src/lib/elementary/efl_ui_button.c
@@ -17,7 +17,6 @@
#define MY_CLASS_PFX efl_ui_button
#define MY_CLASS_NAME "Efl.Ui.Button"
-#define MY_CLASS_NAME_LEGACY "elm_button"
static const char SIG_CLICKED[] = "clicked";
static const char SIG_REPEATED[] = "repeated";
@@ -303,18 +302,10 @@ _efl_ui_button_efl_canvas_group_group_add(Eo *obj, Efl_Ui_Button_Data *_pd EINA_
CRI("Failed to set layout!");
}
-EAPI Evas_Object *
-elm_button_add(Evas_Object *parent)
-{
- EINA_SAFETY_ON_NULL_RETURN_VAL(parent, NULL);
- return elm_legacy_add(MY_CLASS, parent);
-}
-
EOLIAN static Eo *
_efl_ui_button_efl_object_constructor(Eo *obj, Efl_Ui_Button_Data *_pd EINA_UNUSED)
{
obj = efl_constructor(efl_super(obj, MY_CLASS));
- efl_canvas_object_type_set(obj, MY_CLASS_NAME_LEGACY);
evas_object_smart_callbacks_descriptions_set(obj, _smart_callbacks);
efl_access_role_set(obj, EFL_ACCESS_ROLE_PUSH_BUTTON);
@@ -406,12 +397,6 @@ _efl_ui_button_efl_access_widget_action_elm_actions_get(Eo *obj EINA_UNUSED, Efl
return &atspi_actions[0];
}
-static void
-_efl_ui_button_class_constructor(Efl_Class *klass)
-{
- evas_smart_legacy_type_register(MY_CLASS_NAME_LEGACY, klass);
-}
-
/* Standard widget overrides */
ELM_WIDGET_KEY_DOWN_DEFAULT_IMPLEMENT(efl_ui_button, Efl_Ui_Button_Data)
@@ -481,3 +466,30 @@ ELM_LAYOUT_TEXT_ALIASES_IMPLEMENT(MY_CLASS_PFX)
EFL_CANVAS_GROUP_ADD_OPS(efl_ui_button)
#include "efl_ui_button.eo.c"
+
+#include "efl_ui_button_legacy.eo.h"
+
+#define MY_CLASS_NAME_LEGACY "elm_button"
+
+static void
+_efl_ui_button_legacy_class_constructor(Efl_Class *klass)
+{
+ evas_smart_legacy_type_register(MY_CLASS_NAME_LEGACY, klass);
+}
+
+EOLIAN static Eo *
+_efl_ui_button_legacy_efl_object_constructor(Eo *obj, void *_pd EINA_UNUSED)
+{
+ obj = efl_constructor(efl_super(obj, EFL_UI_BUTTON_LEGACY_CLASS));
+ efl_canvas_object_type_set(obj, MY_CLASS_NAME_LEGACY);
+ return obj;
+}
+
+EAPI Evas_Object *
+elm_button_add(Evas_Object *parent)
+{
+ EINA_SAFETY_ON_NULL_RETURN_VAL(parent, NULL);
+ return elm_legacy_add(EFL_UI_BUTTON_LEGACY_CLASS, parent);
+}
+
+#include "efl_ui_button_legacy.eo.c"
diff --git a/src/lib/elementary/efl_ui_button.eo b/src/lib/elementary/efl_ui_button.eo
index cb165ed84a..883bd34a96 100644
--- a/src/lib/elementary/efl_ui_button.eo
+++ b/src/lib/elementary/efl_ui_button.eo
@@ -9,7 +9,6 @@ class Efl.Ui.Button (Efl.Ui.Layout, Efl.Ui.Clickable, Efl.Ui.Autorepeat,
]]
legacy_prefix: elm_button;
implements {
- class.constructor;
Efl.Object.constructor;
Efl.Ui.Autorepeat.autorepeat_initial_timeout { set; get; }
Efl.Ui.Autorepeat.autorepeat_gap_timeout { set; get; }
diff --git a/src/lib/elementary/efl_ui_button_legacy.eo b/src/lib/elementary/efl_ui_button_legacy.eo
new file mode 100644
index 0000000000..91f104b89d
--- /dev/null
+++ b/src/lib/elementary/efl_ui_button_legacy.eo
@@ -0,0 +1,13 @@
+class Efl.Ui.Button_Legacy (Efl.Ui.Button, Efl.Ui.Legacy)
+{
+ [[Push-button widget
+
+ Press it and run some function. It can contain a simple label and icon
+ object and it also has an autorepeat feature.
+ ]]
+ data: null;
+ implements {
+ class.constructor;
+ Efl.Object.constructor;
+ }
+}
diff --git a/src/lib/elementary/efl_ui_check.c b/src/lib/elementary/efl_ui_check.c
index 2bb3e07a4c..d119a8e6b9 100644
--- a/src/lib/elementary/efl_ui_check.c
+++ b/src/lib/elementary/efl_ui_check.c
@@ -16,7 +16,6 @@
#define MY_CLASS_PFX efl_ui_check
#define MY_CLASS_NAME "Efl.Ui.Check"
-#define MY_CLASS_NAME_LEGACY "elm_check"
static const Elm_Layout_Part_Alias_Description _text_aliases[] =
{
@@ -311,20 +310,12 @@ _efl_ui_check_efl_ui_nstate_value_set(Eo *obj, Efl_Ui_Check_Data *pd EINA_UNUSED
efl_ui_nstate_value_set(efl_super(obj, MY_CLASS), _state);
}
-EAPI Evas_Object *
-elm_check_add(Evas_Object *parent)
-{
- EINA_SAFETY_ON_NULL_RETURN_VAL(parent, NULL);
- return elm_legacy_add(MY_CLASS, parent);
-}
-
EOLIAN static Eo *
_efl_ui_check_efl_object_constructor(Eo *obj, Efl_Ui_Check_Data *pd EINA_UNUSED)
{
if (!elm_widget_theme_klass_get(obj))
elm_widget_theme_klass_set(obj, "check");
obj = efl_constructor(efl_super(obj, MY_CLASS));
- efl_canvas_object_type_set(obj, MY_CLASS_NAME_LEGACY);
evas_object_smart_callbacks_descriptions_set(obj, _smart_callbacks);
ELM_WIDGET_DATA_GET_OR_RETURN(obj, wd, NULL);
@@ -392,12 +383,6 @@ _efl_ui_check_efl_access_widget_action_elm_actions_get(Eo *obj EINA_UNUSED, Efl_
return &atspi_action[0];
}
-static void
-_efl_ui_check_class_constructor(Efl_Class *klass)
-{
- evas_smart_legacy_type_register(MY_CLASS_NAME_LEGACY, klass);
-}
-
/* Standard widget overrides */
ELM_WIDGET_KEY_DOWN_DEFAULT_IMPLEMENT(efl_ui_check, Efl_Ui_Check_Data)
@@ -410,3 +395,30 @@ ELM_LAYOUT_TEXT_ALIASES_IMPLEMENT(MY_CLASS_PFX)
ELM_LAYOUT_TEXT_ALIASES_OPS(MY_CLASS_PFX)
#include "efl_ui_check.eo.c"
+
+#include "efl_ui_check_legacy.eo.h"
+
+#define MY_CLASS_NAME_LEGACY "elm_check"
+
+static void
+_efl_ui_check_legacy_class_constructor(Efl_Class *klass)
+{
+ evas_smart_legacy_type_register(MY_CLASS_NAME_LEGACY, klass);
+}
+
+EOLIAN static Eo *
+_efl_ui_check_legacy_efl_object_constructor(Eo *obj, void *pd EINA_UNUSED)
+{
+ obj = efl_constructor(efl_super(obj, EFL_UI_CHECK_LEGACY_CLASS));
+ efl_canvas_object_type_set(obj, MY_CLASS_NAME_LEGACY);
+ return obj;
+}
+
+EAPI Evas_Object *
+elm_check_add(Evas_Object *parent)
+{
+ EINA_SAFETY_ON_NULL_RETURN_VAL(parent, NULL);
+ return elm_legacy_add(EFL_UI_CHECK_LEGACY_CLASS, parent);
+}
+
+#include "efl_ui_check_legacy.eo.c"
diff --git a/src/lib/elementary/efl_ui_check.eo b/src/lib/elementary/efl_ui_check.eo
index 6544f39d8b..508d3fa7a7 100644
--- a/src/lib/elementary/efl_ui_check.eo
+++ b/src/lib/elementary/efl_ui_check.eo
@@ -21,7 +21,6 @@ class Efl.Ui.Check (Efl.Ui.Nstate, Efl.Access.Widget.Action)
}
}
implements {
- class.constructor;
Efl.Object.constructor;
Efl.Ui.Widget.on_access_activate;
Efl.Ui.Widget.theme_apply;
diff --git a/src/lib/elementary/efl_ui_check_legacy.eo b/src/lib/elementary/efl_ui_check_legacy.eo
new file mode 100644
index 0000000000..b140077a5a
--- /dev/null
+++ b/src/lib/elementary/efl_ui_check_legacy.eo
@@ -0,0 +1,15 @@
+class Efl.Ui.Check_Legacy (Efl.Ui.Check, Efl.Ui.Legacy)
+{
+ [[Check widget
+
+ The check widget allows for toggling a value between true and false.
+ Check objects are a lot like radio objects in layout and functionality,
+ except they do not work as a group, but independently, and only toggle
+ the value of a boolean between false and true.
+ ]]
+ data: null;
+ implements {
+ class.constructor;
+ Efl.Object.constructor;
+ }
+}
diff --git a/src/lib/elementary/efl_ui_clock.c b/src/lib/elementary/efl_ui_clock.c
index e133ee96e5..274346ded4 100644
--- a/src/lib/elementary/efl_ui_clock.c
+++ b/src/lib/elementary/efl_ui_clock.c
@@ -13,7 +13,6 @@
#define MY_CLASS EFL_UI_CLOCK_CLASS
#define MY_CLASS_NAME "Efl.Ui.Clock"
-#define MY_CLASS_NAME_LEGACY "efl_ui_clock"
#ifdef HAVE_LOCALE_H
# include <locale.h>
@@ -918,7 +917,6 @@ EOLIAN static Eo *
_efl_ui_clock_efl_object_constructor(Eo *obj, Efl_Ui_Clock_Data *_pd EINA_UNUSED)
{
obj = efl_constructor(efl_super(obj, MY_CLASS));
- efl_canvas_object_type_set(obj, MY_CLASS_NAME_LEGACY);
evas_object_smart_callbacks_descriptions_set(obj, _smart_callbacks);
efl_access_role_set(obj, EFL_ACCESS_ROLE_DATE_EDITOR);
@@ -1125,12 +1123,6 @@ _efl_ui_clock_time_max_set(Eo *obj, Efl_Ui_Clock_Data *sd, Efl_Time maxtime)
efl_event_callback_legacy_call(obj, EFL_UI_CLOCK_EVENT_CHANGED, NULL);
}
-EOLIAN static void
-_efl_ui_clock_class_constructor(Efl_Class *klass)
-{
- evas_smart_legacy_type_register(MY_CLASS_NAME_LEGACY, klass);
-}
-
/* Internal EO APIs and hidden overrides */
#define EFL_UI_CLOCK_EXTRA_OPS \
diff --git a/src/lib/elementary/efl_ui_clock.eo b/src/lib/elementary/efl_ui_clock.eo
index 795afd44dd..f1ec354fe4 100644
--- a/src/lib/elementary/efl_ui_clock.eo
+++ b/src/lib/elementary/efl_ui_clock.eo
@@ -222,7 +222,6 @@ class Efl.Ui.Clock (Efl.Ui.Layout)
}
}
implements {
- class.constructor;
Efl.Object.constructor;
Efl.Ui.Widget.theme_apply;
Efl.Ui.Widget.on_disabled_update;
diff --git a/src/lib/elementary/efl_ui_clock_legacy.eo b/src/lib/elementary/efl_ui_clock_legacy.eo
new file mode 100644
index 0000000000..b15225742c
--- /dev/null
+++ b/src/lib/elementary/efl_ui_clock_legacy.eo
@@ -0,0 +1,9 @@
+class Efl.Ui.Clock_Legacy (Efl.Ui.Clock, Efl.Ui.Legacy)
+{
+ [[Efl UI clock class]]
+ data: null;
+ implements {
+ class.constructor;
+ Efl.Object.constructor;
+ }
+}
diff --git a/src/lib/elementary/efl_ui_flip.c b/src/lib/elementary/efl_ui_flip.c
index 3967a3a382..e9c5412c21 100644
--- a/src/lib/elementary/efl_ui_flip.c
+++ b/src/lib/elementary/efl_ui_flip.c
@@ -14,7 +14,6 @@
#define MY_CLASS EFL_UI_FLIP_CLASS
#define MY_CLASS_NAME "Efl.Ui.Flip"
-#define MY_CLASS_NAME_LEGACY "elm_flip"
static const char SIG_ANIMATE_BEGIN[] = "animate,begin";
static const char SIG_ANIMATE_DONE[] = "animate,done";
@@ -1862,20 +1861,12 @@ _efl_ui_flip_efl_canvas_group_group_del(Eo *obj, Efl_Ui_Flip_Data *sd)
efl_canvas_group_del(efl_super(obj, MY_CLASS));
}
-EAPI Evas_Object *
-elm_flip_add(Evas_Object *parent)
-{
- EINA_SAFETY_ON_NULL_RETURN_VAL(parent, NULL);
- return elm_legacy_add(MY_CLASS, parent);
-}
-
EOLIAN static Eo *
_efl_ui_flip_efl_object_constructor(Eo *obj, Efl_Ui_Flip_Data *sd)
{
obj = efl_constructor(efl_super(obj, MY_CLASS));
sd->obj = obj;
- efl_canvas_object_type_set(obj, MY_CLASS_NAME_LEGACY);
evas_object_smart_callbacks_descriptions_set(obj, _smart_callbacks);
efl_access_role_set(obj, EFL_ACCESS_ROLE_PAGE_TAB_LIST);
@@ -2313,12 +2304,6 @@ _efl_ui_flip_efl_pack_linear_pack_index_get(Eo *obj EINA_UNUSED, Efl_Ui_Flip_Dat
return eina_list_data_idx(pd->content_list, (void *)subobj);
}
-static void
-_efl_ui_flip_class_constructor(Efl_Class *klass)
-{
- evas_smart_legacy_type_register(MY_CLASS_NAME_LEGACY, klass);
-}
-
EAPI void
elm_flip_interaction_direction_hitsize_set(Efl_Ui_Flip *obj, Elm_Flip_Direction dir, double hitsize)
{
@@ -2371,3 +2356,30 @@ ELM_PART_CONTENT_DEFAULT_GET(efl_ui_flip, "front")
EFL_CANVAS_GROUP_ADD_DEL_OPS(efl_ui_flip)
#include "efl_ui_flip.eo.c"
+
+#include "efl_ui_flip_legacy.eo.h"
+
+#define MY_CLASS_NAME_LEGACY "elm_flip"
+
+static void
+_efl_ui_flip_legacy_class_constructor(Efl_Class *klass)
+{
+ evas_smart_legacy_type_register(MY_CLASS_NAME_LEGACY, klass);
+}
+
+EOLIAN static Eo *
+_efl_ui_flip_legacy_efl_object_constructor(Eo *obj, void *pd EINA_UNUSED)
+{
+ obj = efl_constructor(efl_super(obj, EFL_UI_FLIP_LEGACY_CLASS));
+ efl_canvas_object_type_set(obj, MY_CLASS_NAME_LEGACY);
+ return obj;
+}
+
+EAPI Evas_Object *
+elm_flip_add(Evas_Object *parent)
+{
+ EINA_SAFETY_ON_NULL_RETURN_VAL(parent, NULL);
+ return elm_legacy_add(EFL_UI_FLIP_LEGACY_CLASS, parent);
+}
+
+#include "efl_ui_flip_legacy.eo.c"
diff --git a/src/lib/elementary/efl_ui_flip.eo b/src/lib/elementary/efl_ui_flip.eo
index 892ebf9246..9e55aa1e34 100644
--- a/src/lib/elementary/efl_ui_flip.eo
+++ b/src/lib/elementary/efl_ui_flip.eo
@@ -227,7 +227,6 @@ class Efl.Ui.Flip (Efl.Ui.Widget, Efl.Pack.Linear, Efl.Part)
}
}
implements {
- class.constructor;
Efl.Object.constructor;
Efl.Ui.Widget.widget_sub_object_add;
Efl.Ui.Widget.theme_apply;
diff --git a/src/lib/elementary/efl_ui_flip_legacy.eo b/src/lib/elementary/efl_ui_flip_legacy.eo
new file mode 100644
index 0000000000..697c2d1399
--- /dev/null
+++ b/src/lib/elementary/efl_ui_flip_legacy.eo
@@ -0,0 +1,9 @@
+class Efl.Ui.Flip_Legacy (Efl.Ui.Flip, Efl.Ui.Legacy)
+{
+ [[Efl UI flip class]]
+ data: null;
+ implements {
+ class.constructor;
+ Efl.Object.constructor;
+ }
+}
diff --git a/src/lib/elementary/efl_ui_frame.c b/src/lib/elementary/efl_ui_frame.c
index 234812d928..d4f60eb9c9 100644
--- a/src/lib/elementary/efl_ui_frame.c
+++ b/src/lib/elementary/efl_ui_frame.c
@@ -14,7 +14,6 @@
#define MY_CLASS EFL_UI_FRAME_CLASS
#define MY_CLASS_PFX efl_ui_frame
#define MY_CLASS_NAME "Efl.Ui.Frame"
-#define MY_CLASS_NAME_LEGACY "elm_frame"
static const char SIG_CLICKED[] = "clicked";
@@ -140,18 +139,10 @@ _efl_ui_frame_efl_canvas_group_group_add(Eo *obj, Efl_Ui_Frame_Data *_pd EINA_UN
elm_layout_sizing_eval(obj);
}
-EAPI Evas_Object *
-elm_frame_add(Evas_Object *parent)
-{
- EINA_SAFETY_ON_NULL_RETURN_VAL(parent, NULL);
- return elm_legacy_add(MY_CLASS, parent);
-}
-
EOLIAN static Eo *
_efl_ui_frame_efl_object_constructor(Eo *obj, Efl_Ui_Frame_Data *_pd EINA_UNUSED)
{
obj = efl_constructor(efl_super(obj, MY_CLASS));
- efl_canvas_object_type_set(obj, MY_CLASS_NAME_LEGACY);
evas_object_smart_callbacks_descriptions_set(obj, _smart_callbacks);
efl_access_role_set(obj, EFL_ACCESS_ROLE_FRAME);
@@ -210,12 +201,6 @@ _efl_ui_frame_collapse_get(Eo *obj EINA_UNUSED, Efl_Ui_Frame_Data *sd)
return sd->collapsed;
}
-EOLIAN static void
-_efl_ui_frame_class_constructor(Efl_Class *klass)
-{
- evas_smart_legacy_type_register(MY_CLASS_NAME_LEGACY, klass);
-}
-
/* Default text (title) and content */
ELM_PART_TEXT_DEFAULT_IMPLEMENT(efl_ui_frame, Efl_Ui_Frame_Data)
@@ -235,3 +220,30 @@ ELM_LAYOUT_TEXT_ALIASES_IMPLEMENT(efl_ui_frame)
ELM_LAYOUT_TEXT_ALIASES_OPS(efl_ui_frame)
#include "efl_ui_frame.eo.c"
+
+#include "efl_ui_frame_legacy.eo.h"
+
+#define MY_CLASS_NAME_LEGACY "elm_frame"
+
+static void
+_efl_ui_frame_legacy_class_constructor(Efl_Class *klass)
+{
+ evas_smart_legacy_type_register(MY_CLASS_NAME_LEGACY, klass);
+}
+
+EOLIAN static Eo *
+_efl_ui_frame_legacy_efl_object_constructor(Eo *obj, void *_pd EINA_UNUSED)
+{
+ obj = efl_constructor(efl_super(obj, EFL_UI_FRAME_LEGACY_CLASS));
+ efl_canvas_object_type_set(obj, MY_CLASS_NAME_LEGACY);
+ return obj;
+}
+
+EAPI Evas_Object *
+elm_frame_add(Evas_Object *parent)
+{
+ EINA_SAFETY_ON_NULL_RETURN_VAL(parent, NULL);
+ return elm_legacy_add(EFL_UI_FRAME_LEGACY_CLASS, parent);
+}
+
+#include "efl_ui_frame_legacy.eo.c"
diff --git a/src/lib/elementary/efl_ui_frame.eo b/src/lib/elementary/efl_ui_frame.eo
index 557e475e52..f05017f709 100644
--- a/src/lib/elementary/efl_ui_frame.eo
+++ b/src/lib/elementary/efl_ui_frame.eo
@@ -55,7 +55,6 @@ class Efl.Ui.Frame (Efl.Ui.Layout, Efl.Ui.Clickable, Efl.Text, Efl.Text.Markup,
}
implements {
Efl.Object.constructor;
- class.constructor;
Efl.Canvas.Group.group_calculate;
Efl.Text.text { get; set; }
Efl.Text.Markup.markup { get; set; }
diff --git a/src/lib/elementary/efl_ui_frame_legacy.eo b/src/lib/elementary/efl_ui_frame_legacy.eo
new file mode 100644
index 0000000000..02393c5fc8
--- /dev/null
+++ b/src/lib/elementary/efl_ui_frame_legacy.eo
@@ -0,0 +1,14 @@
+class Efl.Ui.Frame_Legacy (Efl.Ui.Frame, Efl.Ui.Legacy)
+{
+ [[Frame widget
+
+ The Frame widget allows for collapsing and expanding the content widget
+ by clicking on the frame label.
+ the label and content can be set using text_set and content_set api.
+ ]]
+ data: null;
+ implements {
+ Efl.Object.constructor;
+ class.constructor;
+ }
+}
diff --git a/src/lib/elementary/efl_ui_image.c b/src/lib/elementary/efl_ui_image.c
index 35ab7b4b8e..4b0faf8552 100644
--- a/src/lib/elementary/efl_ui_image.c
+++ b/src/lib/elementary/efl_ui_image.c
@@ -16,7 +16,6 @@
#define MY_CLASS EFL_UI_IMAGE_CLASS
#define MY_CLASS_NAME "Efl.Ui.Image"
-#define MY_CLASS_NAME_LEGACY "elm_image"
#define NON_EXISTING (void *)-1
static const char *icon_theme = NULL;
@@ -850,23 +849,10 @@ _on_size_hints_changed(void *data, const Efl_Event *ev)
_efl_ui_image_internal_sizing_eval(ev->object, data);
}
-EAPI Evas_Object *
-elm_image_add(Evas_Object *parent)
-{
- EINA_SAFETY_ON_NULL_RETURN_VAL(parent, NULL);
- Evas_Object *obj = elm_legacy_add(MY_CLASS, parent);
- EFL_UI_IMAGE_DATA_GET(obj, priv);
-
- efl_event_callback_add(obj, EFL_GFX_EVENT_CHANGE_SIZE_HINTS, _on_size_hints_changed, priv);
-
- return obj;
-}
-
EOLIAN static Eo *
_efl_ui_image_efl_object_constructor(Eo *obj, Efl_Ui_Image_Data *pd)
{
obj = efl_constructor(efl_super(obj, MY_CLASS));
- efl_canvas_object_type_set(obj, MY_CLASS_NAME_LEGACY);
evas_object_smart_callbacks_descriptions_set(obj, _smart_callbacks);
efl_access_role_set(obj, EFL_ACCESS_ROLE_IMAGE);
@@ -1518,12 +1504,6 @@ _efl_ui_image_efl_player_play_get(Eo *obj, Efl_Ui_Image_Data *sd)
return _efl_ui_image_animated_play_get_internal(obj, sd);
}
-static void
-_efl_ui_image_class_constructor(Efl_Class *klass)
-{
- evas_smart_legacy_type_register(MY_CLASS_NAME_LEGACY, klass);
-}
-
EOLIAN static void
_efl_ui_image_efl_image_scale_type_set(Eo *obj EINA_UNUSED, Efl_Ui_Image_Data *sd EINA_UNUSED, Efl_Image_Scale_Type scale_type)
{
@@ -2278,3 +2258,35 @@ ELM_WIDGET_KEY_DOWN_DEFAULT_IMPLEMENT(efl_ui_image, Efl_Ui_Image_Data)
EFL_CANVAS_GROUP_ADD_DEL_OPS(efl_ui_image)
#include "efl_ui_image.eo.c"
+
+#include "efl_ui_image_legacy.eo.h"
+
+#define MY_CLASS_NAME_LEGACY "elm_image"
+
+static void
+_efl_ui_image_legacy_class_constructor(Efl_Class *klass)
+{
+ evas_smart_legacy_type_register(MY_CLASS_NAME_LEGACY, klass);
+}
+
+EOLIAN static Eo *
+_efl_ui_image_legacy_efl_object_constructor(Eo *obj, void *pd EINA_UNUSED)
+{
+ obj = efl_constructor(efl_super(obj, EFL_UI_IMAGE_LEGACY_CLASS));
+ efl_canvas_object_type_set(obj, MY_CLASS_NAME_LEGACY);
+ return obj;
+}
+
+EAPI Evas_Object *
+elm_image_add(Evas_Object *parent)
+{
+ EINA_SAFETY_ON_NULL_RETURN_VAL(parent, NULL);
+ Evas_Object *obj = elm_legacy_add(EFL_UI_IMAGE_LEGACY_CLASS, parent);
+ EFL_UI_IMAGE_DATA_GET(obj, priv);
+
+ efl_event_callback_add(obj, EFL_GFX_EVENT_CHANGE_SIZE_HINTS, _on_size_hints_changed, priv);
+
+ return obj;
+}
+
+#include "efl_ui_image_legacy.eo.c"
diff --git a/src/lib/elementary/efl_ui_image.eo b/src/lib/elementary/efl_ui_image.eo
index db48d04d75..11a8f2ab5e 100644
--- a/src/lib/elementary/efl_ui_image.eo
+++ b/src/lib/elementary/efl_ui_image.eo
@@ -88,7 +88,6 @@ class Efl.Ui.Image (Efl.Ui.Widget, Efl.Ui.Clickable, Efl.Ui.Draggable,
}
}
implements {
- class.constructor;
Efl.Object.constructor;
Efl.File.file { get; set; }
Efl.File.mmap { set; }
diff --git a/src/lib/elementary/efl_ui_image_legacy.eo b/src/lib/elementary/efl_ui_image_legacy.eo
new file mode 100644
index 0000000000..0ee7309adf
--- /dev/null
+++ b/src/lib/elementary/efl_ui_image_legacy.eo
@@ -0,0 +1,9 @@
+class Efl.Ui.Image_Legacy (Efl.Ui.Image, Efl.Ui.Legacy)
+{
+ [[ Efl UI image class]]
+ data: null;
+ implements {
+ class.constructor;
+ Efl.Object.constructor;
+ }
+}
diff --git a/src/lib/elementary/efl_ui_image_zoomable.c b/src/lib/elementary/efl_ui_image_zoomable.c
index c3d0f5e2d5..bd9dc5cafe 100644
--- a/src/lib/elementary/efl_ui_image_zoomable.c
+++ b/src/lib/elementary/efl_ui_image_zoomable.c
@@ -21,7 +21,6 @@
#define MY_CLASS EFL_UI_IMAGE_ZOOMABLE_CLASS
#define MY_CLASS_NAME "Efl.Ui.Image_Zoomable"
-#define MY_CLASS_NAME_LEGACY "elm_photocam"
/*
* TODO (maybe - optional future stuff):
@@ -1789,7 +1788,6 @@ EOLIAN static Eo *
_efl_ui_image_zoomable_efl_object_constructor(Eo *obj, Efl_Ui_Image_Zoomable_Data *_pd EINA_UNUSED)
{
obj = efl_constructor(efl_super(obj, MY_CLASS));
- efl_canvas_object_type_set(obj, MY_CLASS_NAME_LEGACY);
evas_object_smart_callbacks_descriptions_set(obj, _smart_callbacks);
efl_access_role_set(obj, EFL_ACCESS_ROLE_IMAGE);
@@ -2954,10 +2952,8 @@ _efl_ui_image_zoomable_efl_player_play_get(Eo *obj, Efl_Ui_Image_Zoomable_Data *
}
EOLIAN static void
-_efl_ui_image_zoomable_class_constructor(Efl_Class *klass)
+_efl_ui_image_zoomable_class_constructor(Efl_Class *klass EINA_UNUSED)
{
- evas_smart_legacy_type_register(MY_CLASS_NAME_LEGACY, klass);
-
PHOTO_FILE_LOAD_ERROR_GENERIC = eina_error_msg_static_register("Generic load error");
PHOTO_FILE_LOAD_ERROR_DOES_NOT_EXIST = eina_error_msg_static_register("File does not exist");
PHOTO_FILE_LOAD_ERROR_PERMISSION_DENIED = eina_error_msg_static_register("Permission denied to an existing file");
@@ -2983,13 +2979,39 @@ _efl_ui_image_zoomable_efl_access_widget_action_elm_actions_get(Eo *obj EINA_UNU
return &atspi_actions[0];
}
-/* Legacy APIs */
+/* Standard widget overrides */
+
+ELM_WIDGET_KEY_DOWN_DEFAULT_IMPLEMENT(efl_ui_image_zoomable, Efl_Ui_Image_Zoomable_Data)
+
+/* Internal EO APIs and hidden overrides */
+
+#define EFL_UI_IMAGE_ZOOMABLE_EXTRA_OPS \
+ EFL_CANVAS_GROUP_ADD_DEL_OPS(efl_ui_image_zoomable)
+
+#include "efl_ui_image_zoomable.eo.c"
+
+#include "efl_ui_image_zoomable_legacy.eo.h"
+#define MY_CLASS_NAME_LEGACY "elm_photocam"
+
+static void
+_efl_ui_image_zoomable_legacy_class_constructor(Efl_Class *klass)
+{
+ evas_smart_legacy_type_register(MY_CLASS_NAME_LEGACY, klass);
+}
+
+EOLIAN static Eo *
+_efl_ui_image_zoomable_legacy_efl_object_constructor(Eo *obj, void *_pd EINA_UNUSED)
+{
+ obj = efl_constructor(efl_super(obj, EFL_UI_IMAGE_ZOOMABLE_LEGACY_CLASS));
+ efl_canvas_object_type_set(obj, MY_CLASS_NAME_LEGACY);
+ return obj;
+}
EAPI Evas_Object *
elm_photocam_add(Evas_Object *parent)
{
EINA_SAFETY_ON_NULL_RETURN_VAL(parent, NULL);
- return elm_legacy_add(MY_CLASS, parent);
+ return elm_legacy_add(EFL_UI_IMAGE_ZOOMABLE_LEGACY_CLASS, parent);
}
static inline void
@@ -3223,13 +3245,4 @@ elm_photocam_image_region_get(const Efl_Ui_Image_Zoomable *obj, int *x, int *y,
if (h) *h = r.h;
}
-/* Standard widget overrides */
-
-ELM_WIDGET_KEY_DOWN_DEFAULT_IMPLEMENT(efl_ui_image_zoomable, Efl_Ui_Image_Zoomable_Data)
-
-/* Internal EO APIs and hidden overrides */
-
-#define EFL_UI_IMAGE_ZOOMABLE_EXTRA_OPS \
- EFL_CANVAS_GROUP_ADD_DEL_OPS(efl_ui_image_zoomable)
-
-#include "efl_ui_image_zoomable.eo.c"
+#include "efl_ui_image_zoomable_legacy.eo.c"
diff --git a/src/lib/elementary/efl_ui_image_zoomable_legacy.eo b/src/lib/elementary/efl_ui_image_zoomable_legacy.eo
new file mode 100644
index 0000000000..3816422bc9
--- /dev/null
+++ b/src/lib/elementary/efl_ui_image_zoomable_legacy.eo
@@ -0,0 +1,9 @@
+class Efl.Ui.Image_Zoomable_Legacy (Efl.Ui.Image_Zoomable, Efl.Ui.Legacy)
+{
+ [[Elementary Image Zoomable class]]
+ data: null;
+ implements {
+ class.constructor;
+ Efl.Object.constructor;
+ }
+}
diff --git a/src/lib/elementary/efl_ui_layout.c b/src/lib/elementary/efl_ui_layout.c
index f2cf37a890..919e02f63f 100644
--- a/src/lib/elementary/efl_ui_layout.c
+++ b/src/lib/elementary/efl_ui_layout.c
@@ -17,7 +17,6 @@
#define MY_CLASS_PFX efl_ui_layout
#define MY_CLASS_NAME "Efl.Ui.Layout"
-#define MY_CLASS_NAME_LEGACY "elm_layout"
Eo *_efl_ui_layout_pack_proxy_get(Efl_Ui_Layout *obj, Edje_Part_Type type, const char *part);
static void _efl_model_properties_changed_cb(void *, const Efl_Event *);
@@ -802,9 +801,8 @@ EOLIAN static Efl_Ui_Theme_Apply
_efl_ui_layout_theme_set(Eo *obj, Efl_Ui_Layout_Data *sd, const char *klass, const char *group, const char *style)
{
Eina_Bool changed = EINA_FALSE;
- ELM_WIDGET_DATA_GET_OR_RETURN(obj, wd, EINA_FALSE);
- if (!wd->legacy && efl_finalized_get(obj))
+ if (!elm_widget_is_legacy(obj) && efl_finalized_get(obj))
{
ERR("Efl.Ui.Layout.theme can only be set before finalize!");
return EFL_UI_THEME_APPLY_FAILED;
@@ -1153,7 +1151,7 @@ _efl_ui_layout_text_generic_set(Eo *obj, Efl_Ui_Layout_Data *sd, const char *par
if (!text) return EINA_TRUE;
- if (wd->legacy)
+ if (elm_widget_is_legacy(obj))
{
if (!edje_object_part_text_escaped_set
(wd->resize_obj, part, text))
@@ -2088,30 +2086,17 @@ _efl_ui_layout_efl_ui_model_factory_connect_connect(Eo *obj EINA_UNUSED, Efl_Ui_
elm_layout_content_set(obj, name, new_ev);
}
-EAPI Evas_Object *
-elm_layout_add(Evas_Object *parent)
-{
- EINA_SAFETY_ON_NULL_RETURN_VAL(parent, NULL);
- return elm_legacy_add(MY_CLASS, parent);
-}
-
EOLIAN static Eo *
_efl_ui_layout_efl_object_constructor(Eo *obj, Efl_Ui_Layout_Data *sd)
{
sd->obj = obj;
obj = efl_constructor(efl_super(obj, MY_CLASS));
- efl_canvas_object_type_set(obj, MY_CLASS_NAME_LEGACY);
evas_object_smart_callbacks_descriptions_set(obj, _smart_callbacks);
efl_access_role_set(obj, EFL_ACCESS_ROLE_FILLER);
return obj;
}
-EOLIAN static void _efl_ui_layout_class_constructor(Efl_Class *klass)
-{
- evas_smart_legacy_type_register(MY_CLASS_NAME_LEGACY, klass);
-}
-
EOLIAN static Efl_Object*
_efl_ui_layout_efl_object_finalize(Eo *obj, Efl_Ui_Layout_Data *pd EINA_UNUSED)
{
@@ -2137,8 +2122,264 @@ _efl_ui_layout_efl_layout_signal_signal_process(Eo *obj, Efl_Ui_Layout_Data *pd
efl_layout_signal_process(wd->resize_obj, recurse);
}
+/* Efl.Part implementation */
+
+EOLIAN static Eo *
+_efl_ui_layout_efl_part_part(const Eo *obj, Efl_Ui_Layout_Data *sd EINA_UNUSED, const char *part)
+{
+ Efl_Canvas_Layout_Part_Type type = EFL_CANVAS_LAYOUT_PART_TYPE_NONE;
+
+ EINA_SAFETY_ON_NULL_RETURN_VAL(part, NULL);
+ ELM_WIDGET_DATA_GET_OR_RETURN((Eo *) obj, wd, NULL);
+
+ // Check part type without using edje_object_part_object_get(), as this
+ // can cause recalc, which has side effects... and could be slow.
+
+ if (eina_streq(part, "background"))
+ {
+ if (efl_layout_group_part_exist_get(wd->resize_obj, part))
+ type = efl_canvas_layout_part_type_get(efl_part(wd->resize_obj, part));
+ if (type != EFL_CANVAS_LAYOUT_PART_TYPE_SWALLOW)
+ {
+ if (type < EFL_CANVAS_LAYOUT_PART_TYPE_LAST &&
+ type > EFL_CANVAS_LAYOUT_PART_TYPE_NONE)
+ {
+ const char *file = NULL, *key = NULL;
+ efl_file_get(wd->resize_obj, &file, &key);
+ WRN("Layout has a background but it's not a swallow: '%s'",
+ elm_widget_theme_element_get(obj));
+ }
+ return efl_part(efl_super(obj, MY_CLASS), part);
+ }
+
+ return ELM_PART_IMPLEMENT(EFL_UI_LAYOUT_PART_BG_CLASS, obj, part);
+ }
+ else if (eina_streq(part, "shadow"))
+ return efl_part(efl_super(obj, MY_CLASS), part);
+
+ if (!efl_layout_group_part_exist_get(wd->resize_obj, part))
+ {
+ // edje part will handle the error message
+ return efl_part(wd->resize_obj, part);
+ }
+
+ type = efl_canvas_layout_part_type_get(efl_part(wd->resize_obj, part));
+ if (type >= EFL_CANVAS_LAYOUT_PART_TYPE_LAST)
+ {
+ ERR("Invalid type found for part '%s' in group '%s'",
+ part, elm_widget_theme_element_get(obj));
+ return NULL;
+ }
+
+ switch (type)
+ {
+ case EFL_CANVAS_LAYOUT_PART_TYPE_BOX:
+ case EFL_CANVAS_LAYOUT_PART_TYPE_TABLE:
+ return _efl_ui_layout_pack_proxy_get((Eo *) obj, type, part);
+ case EFL_CANVAS_LAYOUT_PART_TYPE_TEXT:
+ case EFL_CANVAS_LAYOUT_PART_TYPE_TEXTBLOCK:
+ return ELM_PART_IMPLEMENT(EFL_UI_LAYOUT_PART_TEXT_CLASS, obj, part);
+ case EFL_CANVAS_LAYOUT_PART_TYPE_SWALLOW:
+ return ELM_PART_IMPLEMENT(EFL_UI_LAYOUT_PART_CONTENT_CLASS, obj, part);
+ default:
+ return ELM_PART_IMPLEMENT(EFL_UI_LAYOUT_PART_CLASS, obj, part);
+ }
+}
+
+static const char *
+_efl_ui_layout_default_content_part_get(const Eo *obj, Efl_Ui_Layout_Data *sd EINA_UNUSED)
+{
+ const char *part = NULL;
+ if (!_elm_layout_part_aliasing_eval(obj, &part, EINA_FALSE))
+ return NULL;
+ return part;
+}
+
+static const char *
+_efl_ui_layout_default_text_part_get(const Eo *obj, Efl_Ui_Layout_Data *sd EINA_UNUSED)
+{
+ const char *part = NULL;
+ if (!_elm_layout_part_aliasing_eval(obj, &part, EINA_TRUE))
+ return NULL;
+ return part;
+}
+
+/* Efl.Ui.Layout.Part (common) */
+
+EOLIAN static Eina_Bool
+_efl_ui_layout_part_efl_ui_cursor_cursor_set(Eo *obj, void *_pd EINA_UNUSED, const char *cursor)
+{
+ Elm_Part_Data *pd = efl_data_scope_get(obj, EFL_UI_WIDGET_PART_CLASS);
+ Efl_Ui_Layout_Data *sd = efl_data_scope_get(pd->obj, MY_CLASS);
+ return _efl_ui_layout_part_cursor_set(sd, pd->part, cursor);
+}
+
+EOLIAN static const char *
+_efl_ui_layout_part_efl_ui_cursor_cursor_get(Eo *obj, void *_pd EINA_UNUSED)
+{
+ Elm_Part_Data *pd = efl_data_scope_get(obj, EFL_UI_WIDGET_PART_CLASS);
+ Efl_Ui_Layout_Data *sd = efl_data_scope_get(pd->obj, MY_CLASS);
+ return _efl_ui_layout_part_cursor_get(sd, pd->part);
+}
+
+EOLIAN static Eina_Bool
+_efl_ui_layout_part_efl_ui_cursor_cursor_style_set(Eo *obj, void *_pd EINA_UNUSED, const char *style)
+{
+ Elm_Part_Data *pd = efl_data_scope_get(obj, EFL_UI_WIDGET_PART_CLASS);
+ Efl_Ui_Layout_Data *sd = efl_data_scope_get(pd->obj, MY_CLASS);
+ return _efl_ui_layout_part_cursor_style_set(sd, pd->part, style);
+}
+
+EOLIAN static const char *
+_efl_ui_layout_part_efl_ui_cursor_cursor_style_get(Eo *obj, void *_pd EINA_UNUSED)
+{
+ Elm_Part_Data *pd = efl_data_scope_get(obj, EFL_UI_WIDGET_PART_CLASS);
+ Efl_Ui_Layout_Data *sd = efl_data_scope_get(pd->obj, MY_CLASS);
+ return _efl_ui_layout_part_cursor_style_get(sd, pd->part);
+}
+
+EOLIAN static Eina_Bool
+_efl_ui_layout_part_efl_ui_cursor_cursor_theme_search_enabled_set(Eo *obj, void *_pd EINA_UNUSED, Eina_Bool allow)
+{
+ Elm_Part_Data *pd = efl_data_scope_get(obj, EFL_UI_WIDGET_PART_CLASS);
+ Efl_Ui_Layout_Data *sd = efl_data_scope_get(pd->obj, MY_CLASS);
+ return _efl_ui_layout_part_cursor_engine_only_set(sd, pd->part, !allow);
+}
+
+EOLIAN static Eina_Bool
+_efl_ui_layout_part_efl_ui_cursor_cursor_theme_search_enabled_get(Eo *obj, void *_pd EINA_UNUSED)
+{
+ Elm_Part_Data *pd = efl_data_scope_get(obj, EFL_UI_WIDGET_PART_CLASS);
+ Efl_Ui_Layout_Data *sd = efl_data_scope_get(pd->obj, MY_CLASS);
+ return !_efl_ui_layout_part_cursor_engine_only_get(sd, pd->part);
+}
+
+/* Efl.Ui.Layout.Part_Content */
+ELM_PART_OVERRIDE_CONTENT_GET_FULL(efl_ui_layout_part_content, efl_ui_layout, EFL_UI_LAYOUT, Efl_Ui_Layout_Data)
+ELM_PART_OVERRIDE_CONTENT_SET_FULL(efl_ui_layout_part_content, efl_ui_layout, EFL_UI_LAYOUT, Efl_Ui_Layout_Data)
+ELM_PART_OVERRIDE_CONTENT_UNSET_FULL(efl_ui_layout_part_content, efl_ui_layout, EFL_UI_LAYOUT, Efl_Ui_Layout_Data)
+
+/* Efl.Ui.Layout.Part_Text */
+ELM_PART_OVERRIDE_TEXT_GET_FULL(efl_ui_layout_part_text, efl_ui_layout, EFL_UI_LAYOUT, Efl_Ui_Layout_Data)
+ELM_PART_OVERRIDE_TEXT_SET_FULL(efl_ui_layout_part_text, efl_ui_layout, EFL_UI_LAYOUT, Efl_Ui_Layout_Data)
+ELM_PART_OVERRIDE_TEXT_MARKUP_GET_FULL(efl_ui_layout_part_text, efl_ui_layout, EFL_UI_LAYOUT, Efl_Ui_Layout_Data)
+ELM_PART_OVERRIDE_TEXT_MARKUP_SET_FULL(efl_ui_layout_part_text, efl_ui_layout, EFL_UI_LAYOUT, Efl_Ui_Layout_Data)
+
+EOLIAN static const char *
+_efl_ui_layout_part_text_efl_ui_translatable_translatable_text_get(Eo *obj, void *_pd EINA_UNUSED, const char **domain)
+{
+ Elm_Part_Data *pd = efl_data_scope_get(obj, EFL_UI_WIDGET_PART_CLASS);
+ return elm_widget_part_translatable_text_get(pd->obj, pd->part, domain);
+}
+
+EOLIAN static void
+_efl_ui_layout_part_text_efl_ui_translatable_translatable_text_set(Eo *obj, void *_pd EINA_UNUSED, const char *label, const char *domain)
+{
+ Elm_Part_Data *pd = efl_data_scope_get(obj, EFL_UI_WIDGET_PART_CLASS);
+ elm_widget_part_translatable_text_set(pd->obj, pd->part, label, domain);
+}
+
+/* Efl.Ui.Layout.Part_Legacy */
+ELM_PART_OVERRIDE_CONTENT_GET_FULL(efl_ui_layout_part_legacy, efl_ui_layout, EFL_UI_LAYOUT, Efl_Ui_Layout_Data)
+ELM_PART_OVERRIDE_CONTENT_SET_FULL(efl_ui_layout_part_legacy, efl_ui_layout, EFL_UI_LAYOUT, Efl_Ui_Layout_Data)
+ELM_PART_OVERRIDE_CONTENT_UNSET_FULL(efl_ui_layout_part_legacy, efl_ui_layout, EFL_UI_LAYOUT, Efl_Ui_Layout_Data)
+ELM_PART_OVERRIDE_TEXT_GET_FULL(efl_ui_layout_part_legacy, efl_ui_layout, EFL_UI_LAYOUT, Efl_Ui_Layout_Data)
+ELM_PART_OVERRIDE_TEXT_SET_FULL(efl_ui_layout_part_legacy, efl_ui_layout, EFL_UI_LAYOUT, Efl_Ui_Layout_Data)
+ELM_PART_OVERRIDE_TEXT_MARKUP_GET_FULL(efl_ui_layout_part_legacy, efl_ui_layout, EFL_UI_LAYOUT, Efl_Ui_Layout_Data)
+ELM_PART_OVERRIDE_TEXT_MARKUP_SET_FULL(efl_ui_layout_part_legacy, efl_ui_layout, EFL_UI_LAYOUT, Efl_Ui_Layout_Data)
+
+EOLIAN static const char *
+_efl_ui_layout_part_legacy_efl_ui_translatable_translatable_text_get(Eo *obj, void *_pd EINA_UNUSED, const char **domain)
+{
+ Elm_Part_Data *pd = efl_data_scope_get(obj, EFL_UI_WIDGET_PART_CLASS);
+ return elm_widget_part_translatable_text_get(pd->obj, pd->part, domain);
+}
+
+EOLIAN static void
+_efl_ui_layout_part_legacy_efl_ui_translatable_translatable_text_set(Eo *obj, void *_pd EINA_UNUSED, const char *label, const char *domain)
+{
+ Elm_Part_Data *pd = efl_data_scope_get(obj, EFL_UI_WIDGET_PART_CLASS);
+ elm_widget_part_translatable_text_set(pd->obj, pd->part, label, domain);
+}
+
+/* Efl.Ui.Layout.Part_Bg (common) */
+
+EOLIAN static Efl_Object *
+_efl_ui_layout_part_bg_efl_object_finalize(Eo *obj, void *_pd EINA_UNUSED)
+{
+ Efl_Ui_Layout_Data *sd;
+ Elm_Part_Data *pd;
+ Eo *bg;
+
+ obj = efl_finalize(efl_super(obj, EFL_UI_LAYOUT_PART_BG_CLASS));
+ if (!obj) return NULL;
+
+ pd = efl_data_scope_get(obj, EFL_UI_WIDGET_PART_CLASS);
+ sd = efl_data_scope_get(pd->obj, MY_CLASS);
+ bg = _efl_ui_widget_bg_get(pd->obj);
+ if (!_efl_ui_layout_content_set(pd->obj, sd, "background", bg))
+ {
+ ERR("Failed to swallow new background object!");
+ // Shouldn't happen. What now? del bg? call super? return null?
+ }
+
+ return obj;
+}
+
+/* Efl.Ui.Layout.Part_Xxx includes */
+#include "efl_ui_layout_part.eo.c"
+#include "efl_ui_layout_part_content.eo.c"
+#include "efl_ui_layout_part_bg.eo.c"
+#include "efl_ui_layout_part_text.eo.c"
+#include "efl_ui_layout_part_legacy.eo.c"
+
+/* Efl.Part end */
+
+
+/* Internal EO APIs and hidden overrides */
+
+EAPI EFL_VOID_FUNC_BODY(elm_layout_sizing_eval)
+EFL_FUNC_BODY_CONST(elm_layout_text_aliases_get, const Elm_Layout_Part_Alias_Description *, NULL)
+EFL_FUNC_BODY_CONST(elm_layout_content_aliases_get, const Elm_Layout_Part_Alias_Description *, NULL)
+
+ELM_LAYOUT_CONTENT_ALIASES_IMPLEMENT(MY_CLASS_PFX)
+ELM_LAYOUT_TEXT_ALIASES_IMPLEMENT(MY_CLASS_PFX)
+
+#define EFL_UI_LAYOUT_EXTRA_OPS \
+ EFL_CANVAS_GROUP_ADD_DEL_OPS(efl_ui_layout), \
+ ELM_PART_CONTENT_DEFAULT_OPS(efl_ui_layout), \
+ ELM_PART_TEXT_DEFAULT_OPS(efl_ui_layout), \
+ ELM_LAYOUT_CONTENT_ALIASES_OPS(MY_CLASS_PFX), \
+ ELM_LAYOUT_TEXT_ALIASES_OPS(MY_CLASS_PFX), \
+ EFL_OBJECT_OP_FUNC(elm_layout_sizing_eval, _elm_layout_sizing_eval), \
+ EFL_OBJECT_OP_FUNC(efl_dbg_info_get, _efl_ui_layout_efl_object_dbg_info_get)
+
+#include "efl_ui_layout.eo.c"
+
+#include "efl_ui_layout_legacy.eo.h"
+
+#define MY_CLASS_NAME_LEGACY "elm_layout"
+
+static void
+_efl_ui_layout_legacy_class_constructor(Efl_Class *klass)
+{
+ evas_smart_legacy_type_register(MY_CLASS_NAME_LEGACY, klass);
+}
+
+EOLIAN static Eo *
+_efl_ui_layout_legacy_efl_object_constructor(Eo *obj, void *pd EINA_UNUSED)
+{
+ obj = efl_constructor(efl_super(obj, EFL_UI_LAYOUT_LEGACY_CLASS));
+ efl_canvas_object_type_set(obj, MY_CLASS_NAME_LEGACY);
+ return obj;
+}
-/* Legacy APIs */
+EAPI Evas_Object *
+elm_layout_add(Evas_Object *parent)
+{
+ EINA_SAFETY_ON_NULL_RETURN_VAL(parent, NULL);
+ return elm_legacy_add(EFL_UI_LAYOUT_LEGACY_CLASS, parent);
+}
EAPI Eina_Bool
elm_layout_file_set(Eo *obj, const char *file, const char *group)
@@ -2425,239 +2666,4 @@ elm_layout_theme_set(Evas_Object *obj, const char *klass, const char *group, con
return (ta != EFL_UI_THEME_APPLY_FAILED);
}
-/* End of legacy only */
-
-
-/* Efl.Part implementation */
-
-EOLIAN static Eo *
-_efl_ui_layout_efl_part_part(const Eo *obj, Efl_Ui_Layout_Data *sd EINA_UNUSED, const char *part)
-{
- Efl_Canvas_Layout_Part_Type type = EFL_CANVAS_LAYOUT_PART_TYPE_NONE;
-
- EINA_SAFETY_ON_NULL_RETURN_VAL(part, NULL);
- ELM_WIDGET_DATA_GET_OR_RETURN((Eo *) obj, wd, NULL);
-
- // Check part type without using edje_object_part_object_get(), as this
- // can cause recalc, which has side effects... and could be slow.
-
- if (eina_streq(part, "background"))
- {
- if (efl_layout_group_part_exist_get(wd->resize_obj, part))
- type = efl_canvas_layout_part_type_get(efl_part(wd->resize_obj, part));
- if (type != EFL_CANVAS_LAYOUT_PART_TYPE_SWALLOW)
- {
- if (type < EFL_CANVAS_LAYOUT_PART_TYPE_LAST &&
- type > EFL_CANVAS_LAYOUT_PART_TYPE_NONE)
- {
- const char *file = NULL, *key = NULL;
- efl_file_get(wd->resize_obj, &file, &key);
- WRN("Layout has a background but it's not a swallow: '%s'",
- elm_widget_theme_element_get(obj));
- }
- return efl_part(efl_super(obj, MY_CLASS), part);
- }
-
- return ELM_PART_IMPLEMENT(EFL_UI_LAYOUT_PART_BG_CLASS, obj, part);
- }
- else if (eina_streq(part, "shadow"))
- return efl_part(efl_super(obj, MY_CLASS), part);
-
- if (!efl_layout_group_part_exist_get(wd->resize_obj, part))
- {
- // edje part will handle the error message
- return efl_part(wd->resize_obj, part);
- }
-
- type = efl_canvas_layout_part_type_get(efl_part(wd->resize_obj, part));
- if (type >= EFL_CANVAS_LAYOUT_PART_TYPE_LAST)
- {
- ERR("Invalid type found for part '%s' in group '%s'",
- part, elm_widget_theme_element_get(obj));
- return NULL;
- }
-
- switch (type)
- {
- case EFL_CANVAS_LAYOUT_PART_TYPE_BOX:
- case EFL_CANVAS_LAYOUT_PART_TYPE_TABLE:
- return _efl_ui_layout_pack_proxy_get((Eo *) obj, type, part);
- case EFL_CANVAS_LAYOUT_PART_TYPE_TEXT:
- case EFL_CANVAS_LAYOUT_PART_TYPE_TEXTBLOCK:
- return ELM_PART_IMPLEMENT(EFL_UI_LAYOUT_PART_TEXT_CLASS, obj, part);
- case EFL_CANVAS_LAYOUT_PART_TYPE_SWALLOW:
- return ELM_PART_IMPLEMENT(EFL_UI_LAYOUT_PART_CONTENT_CLASS, obj, part);
- default:
- return ELM_PART_IMPLEMENT(EFL_UI_LAYOUT_PART_CLASS, obj, part);
- }
-}
-
-static const char *
-_efl_ui_layout_default_content_part_get(const Eo *obj, Efl_Ui_Layout_Data *sd EINA_UNUSED)
-{
- const char *part = NULL;
- if (!_elm_layout_part_aliasing_eval(obj, &part, EINA_FALSE))
- return NULL;
- return part;
-}
-
-static const char *
-_efl_ui_layout_default_text_part_get(const Eo *obj, Efl_Ui_Layout_Data *sd EINA_UNUSED)
-{
- const char *part = NULL;
- if (!_elm_layout_part_aliasing_eval(obj, &part, EINA_TRUE))
- return NULL;
- return part;
-}
-
-/* Efl.Ui.Layout.Part (common) */
-
-EOLIAN static Eina_Bool
-_efl_ui_layout_part_efl_ui_cursor_cursor_set(Eo *obj, void *_pd EINA_UNUSED, const char *cursor)
-{
- Elm_Part_Data *pd = efl_data_scope_get(obj, EFL_UI_WIDGET_PART_CLASS);
- Efl_Ui_Layout_Data *sd = efl_data_scope_get(pd->obj, MY_CLASS);
- return _efl_ui_layout_part_cursor_set(sd, pd->part, cursor);
-}
-
-EOLIAN static const char *
-_efl_ui_layout_part_efl_ui_cursor_cursor_get(Eo *obj, void *_pd EINA_UNUSED)
-{
- Elm_Part_Data *pd = efl_data_scope_get(obj, EFL_UI_WIDGET_PART_CLASS);
- Efl_Ui_Layout_Data *sd = efl_data_scope_get(pd->obj, MY_CLASS);
- return _efl_ui_layout_part_cursor_get(sd, pd->part);
-}
-
-EOLIAN static Eina_Bool
-_efl_ui_layout_part_efl_ui_cursor_cursor_style_set(Eo *obj, void *_pd EINA_UNUSED, const char *style)
-{
- Elm_Part_Data *pd = efl_data_scope_get(obj, EFL_UI_WIDGET_PART_CLASS);
- Efl_Ui_Layout_Data *sd = efl_data_scope_get(pd->obj, MY_CLASS);
- return _efl_ui_layout_part_cursor_style_set(sd, pd->part, style);
-}
-
-EOLIAN static const char *
-_efl_ui_layout_part_efl_ui_cursor_cursor_style_get(Eo *obj, void *_pd EINA_UNUSED)
-{
- Elm_Part_Data *pd = efl_data_scope_get(obj, EFL_UI_WIDGET_PART_CLASS);
- Efl_Ui_Layout_Data *sd = efl_data_scope_get(pd->obj, MY_CLASS);
- return _efl_ui_layout_part_cursor_style_get(sd, pd->part);
-}
-
-EOLIAN static Eina_Bool
-_efl_ui_layout_part_efl_ui_cursor_cursor_theme_search_enabled_set(Eo *obj, void *_pd EINA_UNUSED, Eina_Bool allow)
-{
- Elm_Part_Data *pd = efl_data_scope_get(obj, EFL_UI_WIDGET_PART_CLASS);
- Efl_Ui_Layout_Data *sd = efl_data_scope_get(pd->obj, MY_CLASS);
- return _efl_ui_layout_part_cursor_engine_only_set(sd, pd->part, !allow);
-}
-
-EOLIAN static Eina_Bool
-_efl_ui_layout_part_efl_ui_cursor_cursor_theme_search_enabled_get(Eo *obj, void *_pd EINA_UNUSED)
-{
- Elm_Part_Data *pd = efl_data_scope_get(obj, EFL_UI_WIDGET_PART_CLASS);
- Efl_Ui_Layout_Data *sd = efl_data_scope_get(pd->obj, MY_CLASS);
- return !_efl_ui_layout_part_cursor_engine_only_get(sd, pd->part);
-}
-
-/* Efl.Ui.Layout.Part_Content */
-ELM_PART_OVERRIDE_CONTENT_GET_FULL(efl_ui_layout_part_content, efl_ui_layout, EFL_UI_LAYOUT, Efl_Ui_Layout_Data)
-ELM_PART_OVERRIDE_CONTENT_SET_FULL(efl_ui_layout_part_content, efl_ui_layout, EFL_UI_LAYOUT, Efl_Ui_Layout_Data)
-ELM_PART_OVERRIDE_CONTENT_UNSET_FULL(efl_ui_layout_part_content, efl_ui_layout, EFL_UI_LAYOUT, Efl_Ui_Layout_Data)
-
-/* Efl.Ui.Layout.Part_Text */
-ELM_PART_OVERRIDE_TEXT_GET_FULL(efl_ui_layout_part_text, efl_ui_layout, EFL_UI_LAYOUT, Efl_Ui_Layout_Data)
-ELM_PART_OVERRIDE_TEXT_SET_FULL(efl_ui_layout_part_text, efl_ui_layout, EFL_UI_LAYOUT, Efl_Ui_Layout_Data)
-ELM_PART_OVERRIDE_TEXT_MARKUP_GET_FULL(efl_ui_layout_part_text, efl_ui_layout, EFL_UI_LAYOUT, Efl_Ui_Layout_Data)
-ELM_PART_OVERRIDE_TEXT_MARKUP_SET_FULL(efl_ui_layout_part_text, efl_ui_layout, EFL_UI_LAYOUT, Efl_Ui_Layout_Data)
-
-EOLIAN static const char *
-_efl_ui_layout_part_text_efl_ui_translatable_translatable_text_get(Eo *obj, void *_pd EINA_UNUSED, const char **domain)
-{
- Elm_Part_Data *pd = efl_data_scope_get(obj, EFL_UI_WIDGET_PART_CLASS);
- return elm_widget_part_translatable_text_get(pd->obj, pd->part, domain);
-}
-
-EOLIAN static void
-_efl_ui_layout_part_text_efl_ui_translatable_translatable_text_set(Eo *obj, void *_pd EINA_UNUSED, const char *label, const char *domain)
-{
- Elm_Part_Data *pd = efl_data_scope_get(obj, EFL_UI_WIDGET_PART_CLASS);
- elm_widget_part_translatable_text_set(pd->obj, pd->part, label, domain);
-}
-
-/* Efl.Ui.Layout.Part_Legacy */
-ELM_PART_OVERRIDE_CONTENT_GET_FULL(efl_ui_layout_part_legacy, efl_ui_layout, EFL_UI_LAYOUT, Efl_Ui_Layout_Data)
-ELM_PART_OVERRIDE_CONTENT_SET_FULL(efl_ui_layout_part_legacy, efl_ui_layout, EFL_UI_LAYOUT, Efl_Ui_Layout_Data)
-ELM_PART_OVERRIDE_CONTENT_UNSET_FULL(efl_ui_layout_part_legacy, efl_ui_layout, EFL_UI_LAYOUT, Efl_Ui_Layout_Data)
-ELM_PART_OVERRIDE_TEXT_GET_FULL(efl_ui_layout_part_legacy, efl_ui_layout, EFL_UI_LAYOUT, Efl_Ui_Layout_Data)
-ELM_PART_OVERRIDE_TEXT_SET_FULL(efl_ui_layout_part_legacy, efl_ui_layout, EFL_UI_LAYOUT, Efl_Ui_Layout_Data)
-ELM_PART_OVERRIDE_TEXT_MARKUP_GET_FULL(efl_ui_layout_part_legacy, efl_ui_layout, EFL_UI_LAYOUT, Efl_Ui_Layout_Data)
-ELM_PART_OVERRIDE_TEXT_MARKUP_SET_FULL(efl_ui_layout_part_legacy, efl_ui_layout, EFL_UI_LAYOUT, Efl_Ui_Layout_Data)
-
-EOLIAN static const char *
-_efl_ui_layout_part_legacy_efl_ui_translatable_translatable_text_get(Eo *obj, void *_pd EINA_UNUSED, const char **domain)
-{
- Elm_Part_Data *pd = efl_data_scope_get(obj, EFL_UI_WIDGET_PART_CLASS);
- return elm_widget_part_translatable_text_get(pd->obj, pd->part, domain);
-}
-
-EOLIAN static void
-_efl_ui_layout_part_legacy_efl_ui_translatable_translatable_text_set(Eo *obj, void *_pd EINA_UNUSED, const char *label, const char *domain)
-{
- Elm_Part_Data *pd = efl_data_scope_get(obj, EFL_UI_WIDGET_PART_CLASS);
- elm_widget_part_translatable_text_set(pd->obj, pd->part, label, domain);
-}
-
-/* Efl.Ui.Layout.Part_Bg (common) */
-
-EOLIAN static Efl_Object *
-_efl_ui_layout_part_bg_efl_object_finalize(Eo *obj, void *_pd EINA_UNUSED)
-{
- Efl_Ui_Layout_Data *sd;
- Elm_Part_Data *pd;
- Eo *bg;
-
- obj = efl_finalize(efl_super(obj, EFL_UI_LAYOUT_PART_BG_CLASS));
- if (!obj) return NULL;
-
- pd = efl_data_scope_get(obj, EFL_UI_WIDGET_PART_CLASS);
- sd = efl_data_scope_get(pd->obj, MY_CLASS);
- bg = _efl_ui_widget_bg_get(pd->obj);
- if (!_efl_ui_layout_content_set(pd->obj, sd, "background", bg))
- {
- ERR("Failed to swallow new background object!");
- // Shouldn't happen. What now? del bg? call super? return null?
- }
-
- return obj;
-}
-
-/* Efl.Ui.Layout.Part_Xxx includes */
-#include "efl_ui_layout_part.eo.c"
-#include "efl_ui_layout_part_content.eo.c"
-#include "efl_ui_layout_part_bg.eo.c"
-#include "efl_ui_layout_part_text.eo.c"
-#include "efl_ui_layout_part_legacy.eo.c"
-
-/* Efl.Part end */
-
-
-/* Internal EO APIs and hidden overrides */
-
-EAPI EFL_VOID_FUNC_BODY(elm_layout_sizing_eval)
-EFL_FUNC_BODY_CONST(elm_layout_text_aliases_get, const Elm_Layout_Part_Alias_Description *, NULL)
-EFL_FUNC_BODY_CONST(elm_layout_content_aliases_get, const Elm_Layout_Part_Alias_Description *, NULL)
-
-ELM_LAYOUT_CONTENT_ALIASES_IMPLEMENT(MY_CLASS_PFX)
-ELM_LAYOUT_TEXT_ALIASES_IMPLEMENT(MY_CLASS_PFX)
-
-#define EFL_UI_LAYOUT_EXTRA_OPS \
- EFL_CANVAS_GROUP_ADD_DEL_OPS(efl_ui_layout), \
- ELM_PART_CONTENT_DEFAULT_OPS(efl_ui_layout), \
- ELM_PART_TEXT_DEFAULT_OPS(efl_ui_layout), \
- ELM_LAYOUT_CONTENT_ALIASES_OPS(MY_CLASS_PFX), \
- ELM_LAYOUT_TEXT_ALIASES_OPS(MY_CLASS_PFX), \
- EFL_OBJECT_OP_FUNC(elm_layout_sizing_eval, _elm_layout_sizing_eval), \
- EFL_OBJECT_OP_FUNC(efl_dbg_info_get, _efl_ui_layout_efl_object_dbg_info_get)
-
-#include "efl_ui_layout.eo.c"
+#include "efl_ui_layout_legacy.eo.c"
diff --git a/src/lib/elementary/efl_ui_layout.eo b/src/lib/elementary/efl_ui_layout.eo
index 1667b0dbd2..573768c89f 100644
--- a/src/lib/elementary/efl_ui_layout.eo
+++ b/src/lib/elementary/efl_ui_layout.eo
@@ -43,7 +43,6 @@ class Efl.Ui.Layout (Efl.Ui.Widget, Efl.Part, Efl.Container, Efl.File,
}
}
implements {
- class.constructor;
Efl.Object.constructor;
Efl.Object.finalize;
Efl.File.file { get; set; }
diff --git a/src/lib/elementary/efl_ui_layout_legacy.eo b/src/lib/elementary/efl_ui_layout_legacy.eo
new file mode 100644
index 0000000000..453d78e85f
--- /dev/null
+++ b/src/lib/elementary/efl_ui_layout_legacy.eo
@@ -0,0 +1,9 @@
+class Efl.Ui.Layout_Legacy (Efl.Ui.Layout, Efl.Ui.Legacy)
+{
+ [[Elementary layout class]]
+ data: null;
+ implements {
+ class.constructor;
+ Efl.Object.constructor;
+ }
+}
diff --git a/src/lib/elementary/efl_ui_legacy.c b/src/lib/elementary/efl_ui_legacy.c
new file mode 100644
index 0000000000..85a0c23042
--- /dev/null
+++ b/src/lib/elementary/efl_ui_legacy.c
@@ -0,0 +1,8 @@
+#ifdef HAVE_CONFIG_H
+# include "elementary_config.h"
+#endif
+
+#include <Elementary.h>
+#include "elm_priv.h"
+
+#include "efl_ui_legacy.eo.c"
diff --git a/src/lib/elementary/efl_ui_legacy.eo b/src/lib/elementary/efl_ui_legacy.eo
new file mode 100644
index 0000000000..e077691310
--- /dev/null
+++ b/src/lib/elementary/efl_ui_legacy.eo
@@ -0,0 +1,9 @@
+interface EFl.Ui.Legacy (Efl.Interface)
+{
+ [[The bg (background) widget is used for setting (solid) background decorations
+
+ in a window (unless it has transparency enabled) or on any container object. It
+ works just like an image but has some properties useful for backgrounds, such as
+ setting it to tiled, centered, scaled or stretched.
+ ]]
+}
diff --git a/src/lib/elementary/efl_ui_multibuttonentry.c b/src/lib/elementary/efl_ui_multibuttonentry.c
index 638c79199c..47a8e1683e 100644
--- a/src/lib/elementary/efl_ui_multibuttonentry.c
+++ b/src/lib/elementary/efl_ui_multibuttonentry.c
@@ -18,7 +18,6 @@
#define MY_CLASS_PFX efl_ui_multibuttonentry
#define MY_CLASS_NAME "Efl.Ui.Multibuttonentry"
-#define MY_CLASS_NAME_LEGACY "elm_multibuttonentry"
#define MAX_STR 256
#define MIN_W_ENTRY 10
@@ -1636,13 +1635,6 @@ _efl_ui_multibuttonentry_efl_ui_widget_on_access_update(Eo *obj, Efl_Ui_Multibut
_access_obj_process(obj, _efl_ui_multibuttonentry_smart_focus_next_enable);
}
-EAPI Evas_Object *
-elm_multibuttonentry_add(Evas_Object *parent)
-{
- EINA_SAFETY_ON_NULL_RETURN_VAL(parent, NULL);
- return elm_legacy_add(MY_CLASS, parent);
-}
-
static void
_legacy_focused(void *data, const Efl_Event *ev)
{
@@ -1684,7 +1676,6 @@ EOLIAN static Eo *
_efl_ui_multibuttonentry_efl_object_constructor(Eo *obj, Efl_Ui_Multibuttonentry_Data *sd EINA_UNUSED)
{
obj = efl_constructor(efl_super(obj, MY_CLASS));
- efl_canvas_object_type_set(obj, MY_CLASS_NAME_LEGACY);
evas_object_smart_callbacks_descriptions_set(obj, _smart_callbacks);
efl_access_role_set(obj, EFL_ACCESS_ROLE_PANEL);
@@ -1977,10 +1968,8 @@ _efl_ui_multibuttonentry_efl_ui_format_format_cb_set(Eo *obj EINA_UNUSED, Efl_Ui
}
static void
-_efl_ui_multibuttonentry_class_constructor(Efl_Class *klass)
+_efl_ui_multibuttonentry_class_constructor(Efl_Class *klass EINA_UNUSED)
{
- evas_smart_legacy_type_register(MY_CLASS_NAME_LEGACY, klass);
-
if (_elm_config->access_mode != ELM_ACCESS_MODE_OFF)
_efl_ui_multibuttonentry_smart_focus_next_enable = EINA_TRUE;
}
@@ -2082,6 +2071,30 @@ ELM_PART_OVERRIDE_TEXT_GET(efl_ui_multibuttonentry, EFL_UI_MULTIBUTTONENTRY, Efl
#include "elm_multibuttonentry_item.eo.c"
#include "efl_ui_multibuttonentry.eo.c"
+#include "efl_ui_multibuttonentry_legacy.eo.h"
+#define MY_CLASS_NAME_LEGACY "elm_multibuttonentry"
+
+static void
+_efl_ui_multibuttonentry_legacy_class_constructor(Efl_Class *klass)
+{
+ evas_smart_legacy_type_register(MY_CLASS_NAME_LEGACY, klass);
+}
+
+EOLIAN static Eo *
+_efl_ui_multibuttonentry_legacy_efl_object_constructor(Eo *obj, void *pd EINA_UNUSED)
+{
+ obj = efl_constructor(efl_super(obj, EFL_UI_MULTIBUTTONENTRY_LEGACY_CLASS));
+ efl_canvas_object_type_set(obj, MY_CLASS_NAME_LEGACY);
+ return obj;
+}
+
+EAPI Evas_Object *
+elm_multibuttonentry_add(Evas_Object *parent)
+{
+ EINA_SAFETY_ON_NULL_RETURN_VAL(parent, NULL);
+ return elm_legacy_add(EFL_UI_MULTIBUTTONENTRY_LEGACY_CLASS, parent);
+}
+
/* Legacy APIs */
typedef struct
@@ -2128,3 +2141,5 @@ elm_multibuttonentry_format_function_set(Eo *obj, Efl_Ui_Multibuttonentry_Format
efl_ui_format_cb_set(obj, mfwd, _format_legacy_to_format_eo_cb, _format_legacy_to_format_eo_free_cb);
}
+
+#include "efl_ui_multibuttonentry_legacy.eo.c"
diff --git a/src/lib/elementary/efl_ui_multibuttonentry_legacy.eo b/src/lib/elementary/efl_ui_multibuttonentry_legacy.eo
new file mode 100644
index 0000000000..e649ed6c70
--- /dev/null
+++ b/src/lib/elementary/efl_ui_multibuttonentry_legacy.eo
@@ -0,0 +1,9 @@
+class Efl.Ui.Multibuttonentry_Legacy (Efl.Ui.Multibuttonentry, Efl.Ui.Legacy)
+{
+ [[Elementary multibuttonentry class]]
+ data: null;
+ implements {
+ class.constructor;
+ Efl.Object.constructor;
+ }
+}
diff --git a/src/lib/elementary/efl_ui_panes.c b/src/lib/elementary/efl_ui_panes.c
index de2b2257e9..6f77dd7f61 100644
--- a/src/lib/elementary/efl_ui_panes.c
+++ b/src/lib/elementary/efl_ui_panes.c
@@ -19,7 +19,6 @@
#define MY_CLASS_PFX efl_ui_panes
#define MY_CLASS_NAME "Efl.Ui.Panes"
-#define MY_CLASS_NAME_LEGACY "elm_panes"
/**
* TODO
* Update the minimun height of the bar in the theme.
@@ -465,7 +464,6 @@ EOLIAN static Eo *
_efl_ui_panes_efl_object_constructor(Eo *obj, Efl_Ui_Panes_Data *_pd EINA_UNUSED)
{
obj = efl_constructor(efl_super(obj, MY_CLASS));
- efl_canvas_object_type_set(obj, MY_CLASS_NAME_LEGACY);
evas_object_smart_callbacks_descriptions_set(obj, _smart_callbacks);
efl_access_role_set(obj, EFL_ACCESS_ROLE_SPLIT_PANE);
@@ -550,12 +548,6 @@ _efl_ui_panes_fixed_get(Eo *obj EINA_UNUSED, Efl_Ui_Panes_Data *sd)
return sd->fixed;
}
-static void
-_efl_ui_panes_class_constructor(Efl_Class *klass)
-{
- evas_smart_legacy_type_register(MY_CLASS_NAME_LEGACY, klass);
-}
-
/* Efl.Part begin */
static Eina_Bool
@@ -660,13 +652,30 @@ ELM_LAYOUT_CONTENT_ALIASES_IMPLEMENT(efl_ui_panes)
ELM_LAYOUT_CONTENT_ALIASES_OPS(efl_ui_panes), \
ELM_LAYOUT_SIZING_EVAL_OPS(efl_ui_panes)
-/* Legacy APIs */
+#include "efl_ui_panes.eo.c"
+
+#include "efl_ui_panes_legacy.eo.h"
+#define MY_CLASS_NAME_LEGACY "elm_panes"
+
+static void
+_efl_ui_panes_legacy_class_constructor(Efl_Class *klass)
+{
+ evas_smart_legacy_type_register(MY_CLASS_NAME_LEGACY, klass);
+}
+
+EOLIAN static Eo *
+_efl_ui_panes_legacy_efl_object_constructor(Eo *obj, void *_pd EINA_UNUSED)
+{
+ obj = efl_constructor(efl_super(obj, EFL_UI_PANES_LEGACY_CLASS));
+ efl_canvas_object_type_set(obj, MY_CLASS_NAME_LEGACY);
+ return obj;
+}
EAPI Evas_Object *
elm_panes_add(Evas_Object *parent)
{
EINA_SAFETY_ON_NULL_RETURN_VAL(parent, NULL);
- return elm_legacy_add(MY_CLASS, parent);
+ return elm_legacy_add(EFL_UI_PANES_LEGACY_CLASS, parent);
}
EAPI void
@@ -826,6 +835,4 @@ elm_panes_content_right_unset(Evas_Object *obj)
return elm_layout_content_unset(obj, "right");
}
-/* Legacy APIs end */
-
-#include "efl_ui_panes.eo.c"
+#include "efl_ui_panes_legacy.eo.c"
diff --git a/src/lib/elementary/efl_ui_panes.eo b/src/lib/elementary/efl_ui_panes.eo
index bfd8381ec1..41e8021cbd 100644
--- a/src/lib/elementary/efl_ui_panes.eo
+++ b/src/lib/elementary/efl_ui_panes.eo
@@ -49,7 +49,6 @@ class Efl.Ui.Panes (Efl.Ui.Layout, Efl.Ui.Direction,
second: Efl.Ui.Panes.Part; [[The second half of the panes widget (right or bottom)]]
}
implements {
- class.constructor;
Efl.Object.constructor;
Efl.Ui.Widget.theme_apply;
Efl.Ui.Direction.direction { get; set; [[Only supports $vertical and $horizontal. Default is $vertical.]] }
diff --git a/src/lib/elementary/efl_ui_panes_legacy.eo b/src/lib/elementary/efl_ui_panes_legacy.eo
new file mode 100644
index 0000000000..704f70952c
--- /dev/null
+++ b/src/lib/elementary/efl_ui_panes_legacy.eo
@@ -0,0 +1,9 @@
+class Efl.Ui.Panes_Legacy(Efl.Ui.Panes, Efl.Ui.Legacy)
+{
+ [[Elementary panes class]]
+ data: null;
+ implements {
+ class.constructor;
+ Efl.Object.constructor;
+ }
+}
diff --git a/src/lib/elementary/efl_ui_progressbar.c b/src/lib/elementary/efl_ui_progressbar.c
index 0ecaed2a0b..dc03e3dcf7 100644
--- a/src/lib/elementary/efl_ui_progressbar.c
+++ b/src/lib/elementary/efl_ui_progressbar.c
@@ -19,7 +19,6 @@
#define MY_CLASS_PFX efl_ui_progressbar
#define MY_CLASS_NAME "Efl.Ui.Progressbar"
-#define MY_CLASS_NAME_LEGACY "elm_progressbar"
static const char SIG_CHANGED[] = "changed";
@@ -421,7 +420,6 @@ EOLIAN static Eo *
_efl_ui_progressbar_efl_object_constructor(Eo *obj, Efl_Ui_Progressbar_Data *_pd EINA_UNUSED)
{
obj = efl_constructor(efl_super(obj, MY_CLASS));
- efl_canvas_object_type_set(obj, MY_CLASS_NAME_LEGACY);
evas_object_smart_callbacks_descriptions_set(obj, _smart_callbacks);
efl_access_role_set(obj, EFL_ACCESS_ROLE_PROGRESS_BAR);
@@ -585,12 +583,6 @@ _efl_ui_progressbar_pulse_get(Eo *obj EINA_UNUSED, Efl_Ui_Progressbar_Data *sd)
return (sd->pulse_state && sd->pulse);
}
-EOLIAN static void
-_efl_ui_progressbar_class_constructor(Efl_Class *klass)
-{
- evas_smart_legacy_type_register(MY_CLASS_NAME_LEGACY, klass);
-}
-
/* Efl.Part begin */
EOLIAN static Eo *
@@ -651,13 +643,29 @@ ELM_LAYOUT_TEXT_ALIASES_IMPLEMENT(efl_ui_progressbar)
#include "efl_ui_progressbar.eo.c"
-/* Legacy APIs */
+#include "efl_ui_progressbar_legacy.eo.h"
+
+#define MY_CLASS_NAME_LEGACY "elm_progressbar"
+
+static void
+_efl_ui_progressbar_legacy_class_constructor(Efl_Class *klass)
+{
+ evas_smart_legacy_type_register(MY_CLASS_NAME_LEGACY, klass);
+}
+
+EOLIAN static Eo *
+_efl_ui_progressbar_legacy_efl_object_constructor(Eo *obj, void *pd EINA_UNUSED)
+{
+ obj = efl_constructor(efl_super(obj, EFL_UI_PROGRESSBAR_LEGACY_CLASS));
+ efl_canvas_object_type_set(obj, MY_CLASS_NAME_LEGACY);
+ return obj;
+}
EAPI Evas_Object *
elm_progressbar_add(Evas_Object *parent)
{
EINA_SAFETY_ON_NULL_RETURN_VAL(parent, NULL);
- Eo *obj = elm_legacy_add(MY_CLASS, parent);
+ Eo *obj = elm_legacy_add(EFL_UI_PROGRESSBAR_LEGACY_CLASS, parent);
elm_progressbar_unit_format_set(obj, "%.0f %%");
return obj;
@@ -825,3 +833,5 @@ elm_progressbar_value_get(const Evas_Object *obj)
{
return efl_ui_range_value_get(obj);
}
+
+#include "efl_ui_progressbar_legacy.eo.c"
diff --git a/src/lib/elementary/efl_ui_progressbar.eo b/src/lib/elementary/efl_ui_progressbar.eo
index 3100b90ec0..fd1e890af4 100644
--- a/src/lib/elementary/efl_ui_progressbar.eo
+++ b/src/lib/elementary/efl_ui_progressbar.eo
@@ -49,7 +49,6 @@ class Efl.Ui.Progressbar (Efl.Ui.Layout, Efl.Ui.Range, Efl.Ui.Format,
}
}
implements {
- class.constructor;
Efl.Object.constructor;
Efl.Ui.Widget.theme_apply;
Efl.Ui.Widget.widget_sub_object_add;
diff --git a/src/lib/elementary/efl_ui_progressbar_legacy.eo b/src/lib/elementary/efl_ui_progressbar_legacy.eo
new file mode 100644
index 0000000000..b6bf882c24
--- /dev/null
+++ b/src/lib/elementary/efl_ui_progressbar_legacy.eo
@@ -0,0 +1,9 @@
+class Efl.Ui.Progressbar_Legacy (Efl.Ui.Progressbar, Efl.Ui.Legacy)
+{
+ [[Elementary progressbar class]]
+ data: null;
+ implements {
+ class.constructor;
+ Efl.Object.constructor;
+ }
+}
diff --git a/src/lib/elementary/efl_ui_radio.c b/src/lib/elementary/efl_ui_radio.c
index 1486cf8b31..8a3c537bda 100644
--- a/src/lib/elementary/efl_ui_radio.c
+++ b/src/lib/elementary/efl_ui_radio.c
@@ -17,7 +17,6 @@
#define MY_CLASS_PFX efl_ui_radio
#define MY_CLASS_NAME "Efl.Ui.Radio"
-#define MY_CLASS_NAME_LEGACY "elm_radio"
static const Elm_Layout_Part_Alias_Description _text_aliases[] =
{
@@ -209,7 +208,6 @@ _efl_ui_radio_efl_object_constructor(Eo *obj, Efl_Ui_Radio_Data *pd)
if (!elm_widget_theme_klass_get(obj))
elm_widget_theme_klass_set(obj, "radio");
obj = efl_constructor(efl_super(obj, MY_CLASS));
- efl_canvas_object_type_set(obj, MY_CLASS_NAME_LEGACY);
evas_object_smart_callbacks_descriptions_set(obj, _smart_callbacks);
ELM_WIDGET_DATA_GET_OR_RETURN(obj, wd, NULL);
@@ -337,12 +335,6 @@ _efl_ui_radio_efl_ui_widget_on_access_activate(Eo *obj, Efl_Ui_Radio_Data *_pd E
return EINA_TRUE;
}
-EOLIAN static void
-_efl_ui_radio_class_constructor(Efl_Class *klass)
-{
- evas_smart_legacy_type_register(MY_CLASS_NAME_LEGACY, klass);
-}
-
EOLIAN const Efl_Access_Action_Data *
_efl_ui_radio_efl_access_widget_action_elm_actions_get(Eo *obj EINA_UNUSED, Efl_Ui_Radio_Data *pd EINA_UNUSED)
{
@@ -380,13 +372,30 @@ ELM_LAYOUT_TEXT_ALIASES_IMPLEMENT(MY_CLASS_PFX)
#include "efl_ui_radio.eo.c"
+#include "efl_ui_radio_legacy.eo.h"
+
+#define MY_CLASS_NAME_LEGACY "elm_radio"
/* Legacy APIs */
+static void
+_efl_ui_radio_legacy_class_constructor(Efl_Class *klass)
+{
+ evas_smart_legacy_type_register(MY_CLASS_NAME_LEGACY, klass);
+}
+
+EOLIAN static Eo *
+_efl_ui_radio_legacy_efl_object_constructor(Eo *obj, void *_pd EINA_UNUSED)
+{
+ obj = efl_constructor(efl_super(obj, EFL_UI_RADIO_LEGACY_CLASS));
+ efl_canvas_object_type_set(obj, MY_CLASS_NAME_LEGACY);
+ return obj;
+}
+
EAPI Evas_Object *
elm_radio_add(Evas_Object *parent)
{
EINA_SAFETY_ON_NULL_RETURN_VAL(parent, NULL);
- return elm_legacy_add(MY_CLASS, parent);
+ return elm_legacy_add(EFL_UI_RADIO_LEGACY_CLASS, parent);
}
EAPI void
@@ -400,3 +409,5 @@ elm_radio_value_get(const Evas_Object *obj)
{
return efl_ui_nstate_value_get(obj);
}
+
+#include "efl_ui_radio_legacy.eo.c" \ No newline at end of file
diff --git a/src/lib/elementary/efl_ui_radio.eo b/src/lib/elementary/efl_ui_radio.eo
index 35602e806b..f3ec5d60ee 100644
--- a/src/lib/elementary/efl_ui_radio.eo
+++ b/src/lib/elementary/efl_ui_radio.eo
@@ -59,7 +59,6 @@ class Efl.Ui.Radio (Efl.Ui.Check, Efl.Access.Widget.Action, Efl.Content)
}
}
implements {
- class.constructor;
Efl.Object.constructor;
Efl.Object.destructor;
Efl.Ui.Widget.theme_apply;
diff --git a/src/lib/elementary/efl_ui_radio_legacy.eo b/src/lib/elementary/efl_ui_radio_legacy.eo
new file mode 100644
index 0000000000..da18c8a654
--- /dev/null
+++ b/src/lib/elementary/efl_ui_radio_legacy.eo
@@ -0,0 +1,9 @@
+class Efl.Ui.Radio_Legacy (Efl.Ui.Radio, Efl.Ui.Legacy)
+{
+ [[Elementary radio class]]
+ data: null;
+ implements {
+ class.constructor;
+ Efl.Object.constructor;
+ }
+}
diff --git a/src/lib/elementary/efl_ui_slider.c b/src/lib/elementary/efl_ui_slider.c
index be7232bcab..ca38c46f31 100644
--- a/src/lib/elementary/efl_ui_slider.c
+++ b/src/lib/elementary/efl_ui_slider.c
@@ -18,7 +18,6 @@
#define MY_CLASS_PFX efl_ui_slider
#define MY_CLASS_NAME "Efl.Ui.Slider"
-#define MY_CLASS_NAME_LEGACY "elm_slider"
#define SLIDER_DELAY_CHANGED_INTERVAL 0.2
#define SLIDER_STEP 0.05
@@ -1222,7 +1221,6 @@ EOLIAN static Eo *
_efl_ui_slider_efl_object_constructor(Eo *obj, Efl_Ui_Slider_Data *_pd EINA_UNUSED)
{
obj = efl_constructor(efl_super(obj, MY_CLASS));
- efl_canvas_object_type_set(obj, MY_CLASS_NAME_LEGACY);
evas_object_smart_callbacks_descriptions_set(obj, _smart_callbacks);
efl_access_role_set(obj, EFL_ACCESS_ROLE_SLIDER);
@@ -1313,12 +1311,6 @@ _efl_ui_slider_efl_ui_focus_object_on_focus_update(Eo *obj, Efl_Ui_Slider_Data *
return int_ret;
}
-EOLIAN static void
-_efl_ui_slider_class_constructor(Efl_Class *klass)
-{
- evas_smart_legacy_type_register(MY_CLASS_NAME_LEGACY, klass);
-}
-
// A11Y Accessibility
EOLIAN static void
@@ -1540,13 +1532,42 @@ _efl_ui_slider_part_indicator_visible_mode_get(Eo *obj, void *_pd EINA_UNUSED)
/* Efl.Part end */
-/* Legacy APIs */
+/* Internal EO APIs and hidden overrides */
+
+ELM_LAYOUT_CONTENT_ALIASES_IMPLEMENT(efl_ui_slider)
+ELM_LAYOUT_TEXT_ALIASES_IMPLEMENT(efl_ui_slider)
+
+#define EFL_UI_SLIDER_EXTRA_OPS \
+ ELM_LAYOUT_CONTENT_ALIASES_OPS(efl_ui_slider), \
+ ELM_LAYOUT_TEXT_ALIASES_OPS(efl_ui_slider), \
+ ELM_LAYOUT_SIZING_EVAL_OPS(efl_ui_slider), \
+ EFL_CANVAS_GROUP_ADD_DEL_OPS(efl_ui_slider)
+
+#include "efl_ui_slider.eo.c"
+
+#include "efl_ui_slider_legacy.eo.h"
+
+#define MY_CLASS_NAME_LEGACY "elm_slider"
+
+static void
+_efl_ui_slider_legacy_class_constructor(Efl_Class *klass)
+{
+ evas_smart_legacy_type_register(MY_CLASS_NAME_LEGACY, klass);
+}
+
+EOLIAN static Eo *
+_efl_ui_slider_legacy_efl_object_constructor(Eo *obj, void *_pd EINA_UNUSED)
+{
+ obj = efl_constructor(efl_super(obj, EFL_UI_SLIDER_LEGACY_CLASS));
+ efl_canvas_object_type_set(obj, MY_CLASS_NAME_LEGACY);
+ return obj;
+}
EAPI Evas_Object *
elm_slider_add(Evas_Object *parent)
{
EINA_SAFETY_ON_NULL_RETURN_VAL(parent, NULL);
- return elm_legacy_add(MY_CLASS, parent);
+ return elm_legacy_add(EFL_UI_SLIDER_LEGACY_CLASS, parent);
}
EAPI void
@@ -1819,15 +1840,4 @@ elm_slider_indicator_visible_mode_get(const Evas_Object *obj)
return efl_ui_slider_part_indicator_visible_mode_get(efl_part(obj, "indicator"));
}
-/* Internal EO APIs and hidden overrides */
-
-ELM_LAYOUT_CONTENT_ALIASES_IMPLEMENT(efl_ui_slider)
-ELM_LAYOUT_TEXT_ALIASES_IMPLEMENT(efl_ui_slider)
-
-#define EFL_UI_SLIDER_EXTRA_OPS \
- ELM_LAYOUT_CONTENT_ALIASES_OPS(efl_ui_slider), \
- ELM_LAYOUT_TEXT_ALIASES_OPS(efl_ui_slider), \
- ELM_LAYOUT_SIZING_EVAL_OPS(efl_ui_slider), \
- EFL_CANVAS_GROUP_ADD_DEL_OPS(efl_ui_slider)
-
-#include "efl_ui_slider.eo.c"
+#include "efl_ui_slider_legacy.eo.c"
diff --git a/src/lib/elementary/efl_ui_slider.eo b/src/lib/elementary/efl_ui_slider.eo
index 50092849f0..002204db8e 100644
--- a/src/lib/elementary/efl_ui_slider.eo
+++ b/src/lib/elementary/efl_ui_slider.eo
@@ -34,7 +34,6 @@ class Efl.Ui.Slider (Efl.Ui.Layout, Efl.Ui.Range, Efl.Ui.Direction,
[[A floating indicator above the slider.]]
}
implements {
- class.constructor;
Efl.Object.constructor;
Efl.Canvas.Group.group_calculate;
Efl.Ui.Widget.theme_apply;
diff --git a/src/lib/elementary/efl_ui_slider_legacy.eo b/src/lib/elementary/efl_ui_slider_legacy.eo
new file mode 100644
index 0000000000..c6653c0e3f
--- /dev/null
+++ b/src/lib/elementary/efl_ui_slider_legacy.eo
@@ -0,0 +1,9 @@
+class Efl.Ui.Slider_Legacy (Efl.Ui.Slider, Efl.Ui.Legacy)
+{
+ [[Elementary slider class]]
+ data: null;
+ implements {
+ class.constructor;
+ Efl.Object.constructor;
+ }
+}
diff --git a/src/lib/elementary/efl_ui_video.c b/src/lib/elementary/efl_ui_video.c
index 9d19b8ad4d..96a68d7218 100644
--- a/src/lib/elementary/efl_ui_video.c
+++ b/src/lib/elementary/efl_ui_video.c
@@ -18,7 +18,6 @@
#define MY_CLASS EFL_UI_VIDEO_CLASS
#define MY_CLASS_NAME "Efl.Ui.Video"
-#define MY_CLASS_NAME_LEGACY "elm_video"
static const Evas_Smart_Cb_Description _smart_callbacks[] = {
{SIG_LAYOUT_FOCUSED, ""}, /**< handled by elm_layout */
@@ -258,18 +257,10 @@ _efl_ui_video_efl_canvas_group_group_del(Eo *obj, Efl_Ui_Video_Data *sd)
efl_canvas_group_del(efl_super(obj, MY_CLASS));
}
-EAPI Evas_Object *
-elm_video_add(Evas_Object *parent)
-{
- EINA_SAFETY_ON_NULL_RETURN_VAL(parent, NULL);
- return elm_legacy_add(MY_CLASS, parent);
-}
-
EOLIAN static Eo *
_efl_ui_video_efl_object_constructor(Eo *obj, Efl_Ui_Video_Data *_pd EINA_UNUSED)
{
obj = efl_constructor(efl_super(obj, MY_CLASS));
- efl_canvas_object_type_set(obj, MY_CLASS_NAME_LEGACY);
evas_object_smart_callbacks_descriptions_set(obj, _smart_callbacks);
efl_access_role_set(obj, EFL_ACCESS_ROLE_ANIMATION);
@@ -373,12 +364,6 @@ _efl_ui_video_remember_position_get(Eo *obj EINA_UNUSED, Efl_Ui_Video_Data *sd)
return sd->remember;
}
-EOLIAN static void
-_efl_ui_video_class_constructor(Efl_Class *klass)
-{
- evas_smart_legacy_type_register(MY_CLASS_NAME_LEGACY, klass);
-}
-
EOLIAN const Efl_Access_Action_Data *
_efl_ui_video_efl_access_widget_action_elm_actions_get(Eo *obj EINA_UNUSED, Efl_Ui_Video_Data *pd EINA_UNUSED)
{
@@ -390,6 +375,42 @@ _efl_ui_video_efl_access_widget_action_elm_actions_get(Eo *obj EINA_UNUSED, Efl_
};
return &atspi_actions[0];
}
+/* Internal EO APIs and hidden overrides */
+
+ELM_WIDGET_KEY_DOWN_DEFAULT_IMPLEMENT(efl_ui_video, Efl_Ui_Video_Data)
+
+/* Internal EO APIs and hidden overrides */
+
+#define EFL_UI_VIDEO_EXTRA_OPS \
+ ELM_LAYOUT_SIZING_EVAL_OPS(efl_ui_video), \
+ EFL_CANVAS_GROUP_ADD_DEL_OPS(efl_ui_video)
+
+#include "efl_ui_video.eo.c"
+
+#include "efl_ui_video_legacy.eo.h"
+
+#define MY_CLASS_NAME_LEGACY "elm_video"
+
+static void
+_efl_ui_video_legacy_class_constructor(Efl_Class *klass)
+{
+ evas_smart_legacy_type_register(MY_CLASS_NAME_LEGACY, klass);
+}
+
+EOLIAN static Eo *
+_efl_ui_video_legacy_efl_object_constructor(Eo *obj, void *_pd EINA_UNUSED)
+{
+ obj = efl_constructor(efl_super(obj, EFL_UI_VIDEO_LEGACY_CLASS));
+ efl_canvas_object_type_set(obj, MY_CLASS_NAME_LEGACY);
+ return obj;
+}
+
+EAPI Evas_Object *
+elm_video_add(Evas_Object *parent)
+{
+ EINA_SAFETY_ON_NULL_RETURN_VAL(parent, NULL);
+ return elm_legacy_add(EFL_UI_VIDEO_LEGACY_CLASS, parent);
+}
EAPI Eina_Bool
elm_video_file_set(Eo *obj, const char *filename)
@@ -475,14 +496,4 @@ elm_video_pause(Evas_Object *obj)
efl_player_play_set(obj, EINA_FALSE);
}
-/* Internal EO APIs and hidden overrides */
-
-ELM_WIDGET_KEY_DOWN_DEFAULT_IMPLEMENT(efl_ui_video, Efl_Ui_Video_Data)
-
-/* Internal EO APIs and hidden overrides */
-
-#define EFL_UI_VIDEO_EXTRA_OPS \
- ELM_LAYOUT_SIZING_EVAL_OPS(efl_ui_video), \
- EFL_CANVAS_GROUP_ADD_DEL_OPS(efl_ui_video)
-
-#include "efl_ui_video.eo.c"
+#include "efl_ui_video_legacy.eo.c"
diff --git a/src/lib/elementary/efl_ui_video.eo b/src/lib/elementary/efl_ui_video.eo
index 5971f26df4..32aa8efdd8 100644
--- a/src/lib/elementary/efl_ui_video.eo
+++ b/src/lib/elementary/efl_ui_video.eo
@@ -42,7 +42,6 @@ class Efl.Ui.Video (Efl.Ui.Layout, Efl.File,
}
}
implements {
- class.constructor;
Efl.Object.constructor;
Efl.File.file { get; set; }
Efl.Ui.Widget.widget_event;
diff --git a/src/lib/elementary/efl_ui_video_legacy.eo b/src/lib/elementary/efl_ui_video_legacy.eo
new file mode 100644
index 0000000000..9edfc48867
--- /dev/null
+++ b/src/lib/elementary/efl_ui_video_legacy.eo
@@ -0,0 +1,9 @@
+class Efl.Ui.Video_Legacy (Efl.Ui.Video, Efl.Ui.Legacy)
+{
+ [[Efl UI video class]]
+ data: null;
+ implements {
+ class.constructor;
+ Efl.Object.constructor;
+ }
+}
diff --git a/src/lib/elementary/efl_ui_widget.c b/src/lib/elementary/efl_ui_widget.c
index 2816397da4..c34608708f 100644
--- a/src/lib/elementary/efl_ui_widget.c
+++ b/src/lib/elementary/efl_ui_widget.c
@@ -55,9 +55,6 @@ typedef struct _Elm_Event_Cb_Data Elm_Event_Cb_Data;
typedef struct _Elm_Label_Data Elm_Label_Data;
typedef struct _Elm_Translate_String_Data Elm_Translate_String_Data;
-/* FIXME: EAPI because of elm_code_widget test case */
-EAPI Eina_Bool _elm_legacy_add = EINA_FALSE;
-
struct _Elm_Event_Cb_Data
{
Elm_Event_Cb func;
@@ -5162,11 +5159,6 @@ _efl_ui_widget_efl_object_constructor(Eo *obj, Elm_Widget_Smart_Data *sd EINA_UN
Eo *parent = NULL;
sd->on_create = EINA_TRUE;
- if (_elm_legacy_add)
- {
- sd->legacy = _elm_legacy_add;
- _elm_legacy_add = EINA_FALSE;
- }
efl_canvas_group_clipped_set(obj, EINA_FALSE);
obj = efl_constructor(efl_super(obj, MY_CLASS));
efl_canvas_object_type_set(obj, MY_CLASS_NAME_LEGACY);
@@ -5217,13 +5209,6 @@ _efl_ui_widget_efl_object_destructor(Eo *obj, Elm_Widget_Smart_Data *sd)
}
/* internal eo */
-static void
-_efl_ui_widget_legacy_ctor(Eo *obj, Elm_Widget_Smart_Data *sd)
-{
- efl_canvas_object_legacy_ctor(efl_super(obj, MY_CLASS));
- sd->legacy = EINA_TRUE;
- _elm_legacy_add = EINA_FALSE;
-}
EOLIAN static void
_efl_ui_widget_efl_object_debug_name_override(Eo *obj, Elm_Widget_Smart_Data *sd EINA_UNUSED, Eina_Strbuf *sb)
@@ -6009,7 +5994,6 @@ ELM_PART_TEXT_DEFAULT_GET(efl_ui_widget, NULL)
EFL_CANVAS_GROUP_ADD_DEL_OPS(efl_ui_widget), \
ELM_PART_CONTENT_DEFAULT_OPS(efl_ui_widget), \
ELM_PART_TEXT_DEFAULT_OPS(efl_ui_widget), \
- EFL_OBJECT_OP_FUNC(efl_canvas_object_legacy_ctor, _efl_ui_widget_legacy_ctor), \
EFL_OBJECT_OP_FUNC(efl_dbg_info_get, _efl_ui_widget_efl_object_dbg_info_get)
#include "elm_widget_item.eo.c"
diff --git a/src/lib/elementary/efl_ui_win.c b/src/lib/elementary/efl_ui_win.c
index 38be004df3..081ce2d846 100644
--- a/src/lib/elementary/efl_ui_win.c
+++ b/src/lib/elementary/efl_ui_win.c
@@ -5103,7 +5103,6 @@ _elm_win_finalize_internal(Eo *obj, Efl_Ui_Win_Data *sd, const char *name, Efl_U
/* FIXME: Major hack: calling the constructor in the middle of finalize. */
efl_constructor(efl_super(obj, MY_CLASS));
- efl_canvas_object_type_set(obj, MY_CLASS_NAME_LEGACY);
evas_object_smart_callbacks_descriptions_set(obj, _smart_callbacks);
evas_object_focus_set(obj, EINA_TRUE);
@@ -6958,10 +6957,8 @@ _on_atspi_bus_connected(void *data EINA_UNUSED, const Efl_Event *event EINA_UNUS
}
EOLIAN static void
-_efl_ui_win_class_constructor(Efl_Class *klass)
+_efl_ui_win_class_constructor(Efl_Class *klass EINA_UNUSED)
{
- evas_smart_legacy_type_register(MY_CLASS_NAME_LEGACY, klass);
-
if (_elm_config->atspi_mode)
{
Eo *bridge = _elm_atspi_bridge_get();
@@ -8326,62 +8323,6 @@ _fake_canvas_set(Evas_Object *obj, Ecore_Evas *oee)
_elm_win_need_frame_adjust(sd, ecore_evas_engine_name_get(oee));
}
-EAPI Evas_Object *
-elm_win_add(Evas_Object *parent, const char *name, Efl_Ui_Win_Type type)
-{
- const Efl_Class *klass = MY_CLASS;
-
- switch ((int) type)
- {
- case ELM_WIN_INLINED_IMAGE: klass = EFL_UI_WIN_INLINED_CLASS; break;
- case ELM_WIN_SOCKET_IMAGE: klass = EFL_UI_WIN_SOCKET_CLASS; break;
- default: break;
- }
-
- return elm_legacy_add(klass, parent,
- efl_ui_win_name_set(efl_added, name),
- efl_ui_win_type_set(efl_added, type));
-}
-
-EAPI Evas_Object *
-elm_win_fake_add(Ecore_Evas *ee)
-{
- return elm_legacy_add(MY_CLASS, NULL,
- _fake_canvas_set(efl_added, ee),
- efl_ui_win_name_set(efl_added, NULL),
- efl_ui_win_type_set(efl_added, ELM_WIN_FAKE));
-}
-
-EAPI Evas_Object *
-elm_win_util_standard_add(const char *name, const char *title)
-{
- Evas_Object *win;
-
- win = elm_legacy_add(EFL_UI_WIN_CLASS, NULL,
- efl_text_set(efl_added, title),
- efl_ui_win_name_set(efl_added, name),
- efl_ui_win_type_set(efl_added, EFL_UI_WIN_BASIC));
- if (!win) return NULL;
-
- _elm_win_standard_init(win);
- return win;
-}
-
-EAPI Evas_Object *
-elm_win_util_dialog_add(Evas_Object *parent, const char *name, const char *title)
-{
- Evas_Object *win;
-
- win = elm_legacy_add(EFL_UI_WIN_CLASS, parent,
- efl_text_set(efl_added, title),
- efl_ui_win_name_set(efl_added, name),
- efl_ui_win_type_set(efl_added, EFL_UI_WIN_DIALOG_BASIC));
- if (!win) return NULL;
-
- _elm_win_standard_init(win);
- return win;
-}
-
/**
* @internal
*
@@ -8676,3 +8617,78 @@ ELM_WIDGET_KEY_DOWN_DEFAULT_IMPLEMENT(efl_ui_win, Efl_Ui_Win_Data)
EFL_OBJECT_OP_FUNC(efl_canvas_object_legacy_ctor, _efl_ui_win_efl_canvas_object_legacy_ctor)
#include "efl_ui_win.eo.c"
+
+#include "efl_ui_win_legacy.eo.h"
+
+static void
+_efl_ui_win_legacy_class_constructor(Efl_Class *klass)
+{
+ evas_smart_legacy_type_register(MY_CLASS_NAME_LEGACY, klass);
+}
+
+EOLIAN static Eo *
+_efl_ui_win_legacy_efl_object_constructor(Eo *obj, void *pd EINA_UNUSED)
+{
+ obj = efl_constructor(efl_super(obj, EFL_UI_WIN_LEGACY_CLASS));
+ efl_canvas_object_type_set(obj, MY_CLASS_NAME_LEGACY);
+ return obj;
+}
+
+EAPI Evas_Object *
+elm_win_add(Evas_Object *parent, const char *name, Efl_Ui_Win_Type type)
+{
+ const Efl_Class *klass = EFL_UI_WIN_LEGACY_CLASS;
+
+ switch ((int) type)
+ {
+ case ELM_WIN_INLINED_IMAGE: klass = EFL_UI_WIN_INLINED_CLASS; break;
+ case ELM_WIN_SOCKET_IMAGE: klass = EFL_UI_WIN_SOCKET_CLASS; break;
+ default: break;
+ }
+
+ return elm_legacy_add(klass, parent,
+ efl_ui_win_name_set(efl_added, name),
+ efl_ui_win_type_set(efl_added, type));
+}
+
+
+EAPI Evas_Object *
+elm_win_fake_add(Ecore_Evas *ee)
+{
+ return elm_legacy_add(EFL_UI_WIN_LEGACY_CLASS, NULL,
+ _fake_canvas_set(efl_added, ee),
+ efl_ui_win_name_set(efl_added, NULL),
+ efl_ui_win_type_set(efl_added, ELM_WIN_FAKE));
+}
+
+EAPI Evas_Object *
+elm_win_util_standard_add(const char *name, const char *title)
+{
+ Evas_Object *win;
+
+ win = elm_legacy_add(EFL_UI_WIN_LEGACY_CLASS, NULL,
+ efl_text_set(efl_added, title),
+ efl_ui_win_name_set(efl_added, name),
+ efl_ui_win_type_set(efl_added, EFL_UI_WIN_BASIC));
+ if (!win) return NULL;
+
+ _elm_win_standard_init(win);
+ return win;
+}
+
+EAPI Evas_Object *
+elm_win_util_dialog_add(Evas_Object *parent, const char *name, const char *title)
+{
+ Evas_Object *win;
+
+ win = elm_legacy_add(EFL_UI_WIN_LEGACY_CLASS, parent,
+ efl_text_set(efl_added, title),
+ efl_ui_win_name_set(efl_added, name),
+ efl_ui_win_type_set(efl_added, EFL_UI_WIN_DIALOG_BASIC));
+ if (!win) return NULL;
+
+ _elm_win_standard_init(win);
+ return win;
+}
+
+#include "efl_ui_win_legacy.eo.c"
diff --git a/src/lib/elementary/efl_ui_win_legacy.eo b/src/lib/elementary/efl_ui_win_legacy.eo
new file mode 100644
index 0000000000..fe13a0480a
--- /dev/null
+++ b/src/lib/elementary/efl_ui_win_legacy.eo
@@ -0,0 +1,9 @@
+class Efl.Ui.Win_Legacy (Efl.Ui.Win, Efl.Ui.Legacy)
+{
+ [[Efl UI window class]]
+ data: null;
+ implements {
+ class.constructor;
+ Efl.Object.constructor;
+ }
+}
diff --git a/src/lib/elementary/elm_actionslider.eo b/src/lib/elementary/elm_actionslider.eo
index 30f78db6a3..351cb282aa 100644
--- a/src/lib/elementary/elm_actionslider.eo
+++ b/src/lib/elementary/elm_actionslider.eo
@@ -10,7 +10,7 @@ enum Elm.Actionslider.Pos
all = (1 << 3) - 1 [[All positions for left/center/right.]]
}
-class Elm.Actionslider (Efl.Ui.Layout, Efl.Ui.Selectable)
+class Elm.Actionslider (Efl.Ui.Layout, Efl.Ui.Selectable, Efl.Ui.Legacy)
{
[[An actionslider is a switcher for 2 or 3 labels
diff --git a/src/lib/elementary/elm_box.eo b/src/lib/elementary/elm_box.eo
index 924959907c..c7280482f9 100644
--- a/src/lib/elementary/elm_box.eo
+++ b/src/lib/elementary/elm_box.eo
@@ -1,6 +1,6 @@
import evas_box;
-class Elm.Box (Efl.Ui.Widget, Efl.Ui.Focus.Composition)
+class Elm.Box (Efl.Ui.Widget, Efl.Ui.Focus.Composition, Efl.Ui.Legacy)
{
[[Elementary box class]]
legacy_prefix: elm_box;
diff --git a/src/lib/elementary/elm_bubble.eo b/src/lib/elementary/elm_bubble.eo
index f696846831..2b326abc84 100644
--- a/src/lib/elementary/elm_bubble.eo
+++ b/src/lib/elementary/elm_bubble.eo
@@ -12,7 +12,7 @@ enum Elm.Bubble.Pos
bottom_right [[The arrow of the bubble points to the bottom right corner.]]
}
-class Elm.Bubble (Efl.Ui.Layout, Efl.Ui.Clickable)
+class Elm.Bubble (Efl.Ui.Layout, Efl.Ui.Clickable, Efl.Ui.Legacy)
{
[[Speech bubble widget used in messaging applications]]
diff --git a/src/lib/elementary/elm_calendar.eo b/src/lib/elementary/elm_calendar.eo
index 80c77480f1..47cc9470fb 100644
--- a/src/lib/elementary/elm_calendar.eo
+++ b/src/lib/elementary/elm_calendar.eo
@@ -72,7 +72,8 @@ struct Elm.Calendar.Mark; [[Item handle for a calendar mark.
with @Elm.Calendar.mark_del.
]]
-class Elm.Calendar (Efl.Ui.Layout, Efl.Ui.Focus.Composition, Efl.Access.Widget.Action)
+class Elm.Calendar (Efl.Ui.Layout, Efl.Ui.Focus.Composition, Efl.Access.Widget.Action,
+ Efl.Ui.Legacy)
{
[[Calendar widget
diff --git a/src/lib/elementary/elm_clock.eo b/src/lib/elementary/elm_clock.eo
index 16e4868b17..3bd3f0f0f0 100644
--- a/src/lib/elementary/elm_clock.eo
+++ b/src/lib/elementary/elm_clock.eo
@@ -18,7 +18,7 @@ enum Elm.Clock.Edit_Mode
all = (1 << 6) - 1 [[All digits should be editable.]]
}
-class Elm.Clock (Efl.Ui.Layout, Efl.Ui.Focus.Composition)
+class Elm.Clock (Efl.Ui.Layout, Efl.Ui.Focus.Composition, Efl.Ui.Legacy)
{
[[Digital clock widget
diff --git a/src/lib/elementary/elm_code.h b/src/lib/elementary/elm_code.h
index 9ffd0e9ad1..3a0887b9cd 100644
--- a/src/lib/elementary/elm_code.h
+++ b/src/lib/elementary/elm_code.h
@@ -11,6 +11,7 @@
#include "elm_code_parse.h"
#include "elm_code_syntax.h"
#include "elm_code_widget.eo.h"
+#include "elm_code_widget_legacy.eo.h"
#include "elm_code_widget_legacy.h"
#include "elm_code_widget_selection.h"
#include "elm_code_diff_widget.h"
diff --git a/src/lib/elementary/elm_code_diff_widget.c b/src/lib/elementary/elm_code_diff_widget.c
index eec32ee48d..d8ec1495de 100644
--- a/src/lib/elementary/elm_code_diff_widget.c
+++ b/src/lib/elementary/elm_code_diff_widget.c
@@ -95,7 +95,7 @@ elm_code_diff_widget_add(Evas_Object *parent, Elm_Code *code)
// left side of diff
wcode1 = elm_code_create();
elm_code_parser_standard_add(wcode1, ELM_CODE_PARSER_STANDARD_DIFF);
- widget_left = efl_add(ELM_CODE_WIDGET_CLASS, parent, elm_obj_code_widget_code_set(efl_added, wcode1));
+ widget_left = elm_legacy_add(ELM_CODE_WIDGET_LEGACY_CLASS, parent, elm_obj_code_widget_code_set(efl_added, wcode1));
evas_object_size_hint_weight_set(widget_left, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
evas_object_size_hint_align_set(widget_left, EVAS_HINT_FILL, EVAS_HINT_FILL);
@@ -106,7 +106,7 @@ elm_code_diff_widget_add(Evas_Object *parent, Elm_Code *code)
// right side of diff
wcode2 = elm_code_create();
elm_code_parser_standard_add(wcode2, ELM_CODE_PARSER_STANDARD_DIFF);
- widget_right = efl_add(ELM_CODE_WIDGET_CLASS, parent, elm_obj_code_widget_code_set(efl_added, wcode2));
+ widget_right = elm_legacy_add(ELM_CODE_WIDGET_LEGACY_CLASS, parent, elm_obj_code_widget_code_set(efl_added, wcode2));
evas_object_size_hint_weight_set(widget_right, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
evas_object_size_hint_align_set(widget_right, EVAS_HINT_FILL, EVAS_HINT_FILL);
diff --git a/src/lib/elementary/elm_code_widget.c b/src/lib/elementary/elm_code_widget.c
index 5d1fc785ef..21abee7f78 100644
--- a/src/lib/elementary/elm_code_widget.c
+++ b/src/lib/elementary/elm_code_widget.c
@@ -59,12 +59,19 @@ static Eina_Unicode status_icons[] = {
static void _elm_code_widget_resize(Elm_Code_Widget *widget, Elm_Code_Line *newline);
#ifndef ELM_CODE_TEST
+
+#include "elm_code_widget_legacy.eo.h"
+
EAPI Evas_Object *
elm_code_widget_add(Evas_Object *parent, Elm_Code *code)
{
EINA_SAFETY_ON_NULL_RETURN_VAL(parent, NULL);
- return elm_legacy_add(MY_CLASS, parent, elm_obj_code_widget_code_set(efl_added, code));
+ return elm_legacy_add(ELM_CODE_WIDGET_LEGACY_CLASS, parent,
+ elm_obj_code_widget_code_set(efl_added, code));
}
+
+#include "elm_code_widget_legacy.eo.c"
+
#endif // ELM_CODE_TEST
EOLIAN static Eo *
diff --git a/src/lib/elementary/elm_code_widget_legacy.eo b/src/lib/elementary/elm_code_widget_legacy.eo
new file mode 100644
index 0000000000..1c228b3e76
--- /dev/null
+++ b/src/lib/elementary/elm_code_widget_legacy.eo
@@ -0,0 +1,5 @@
+class Elm.Code_Widget_Legacy (Elm.Code_Widget, Efl.Ui.Legacy)
+{
+ [[Elementary code widget]]
+ data: null;
+}
diff --git a/src/lib/elementary/elm_colorselector.eo b/src/lib/elementary/elm_colorselector.eo
index 2449b8b83d..6a18f28fc1 100644
--- a/src/lib/elementary/elm_colorselector.eo
+++ b/src/lib/elementary/elm_colorselector.eo
@@ -13,7 +13,7 @@ enum Elm.Colorselector.Mode
}
class Elm.Colorselector (Efl.Ui.Layout, Efl.Ui.Focus.Composition,
- Efl.Access.Widget.Action, Efl.Ui.Clickable)
+ Efl.Access.Widget.Action, Efl.Ui.Clickable, Efl.Ui.Legacy)
{
[[Elementary colorselector class]]
legacy_prefix: elm_colorselector;
diff --git a/src/lib/elementary/elm_combobox.eo b/src/lib/elementary/elm_combobox.eo
index d0c914b37d..d8fa736bab 100644
--- a/src/lib/elementary/elm_combobox.eo
+++ b/src/lib/elementary/elm_combobox.eo
@@ -1,6 +1,6 @@
class Elm.Combobox (Efl.Ui.Button, Efl.Ui.Selectable,
Efl.Access.Widget.Action,
- Elm.Entry, Elm.Genlist, Elm.Hover)
+ Elm.Entry, Elm.Genlist, Elm.Hover, Efl.Ui.Legacy)
{
[[Elementary combobox class]]
legacy_prefix: elm_combobox;
diff --git a/src/lib/elementary/elm_conformant.eo b/src/lib/elementary/elm_conformant.eo
index 66a3632dbf..f63dbbdefe 100644
--- a/src/lib/elementary/elm_conformant.eo
+++ b/src/lib/elementary/elm_conformant.eo
@@ -1,4 +1,4 @@
-class Elm.Conformant (Efl.Ui.Layout)
+class Elm.Conformant (Efl.Ui.Layout, Efl.Ui.Legacy)
{
[[Elementary conformant class]]
legacy_prefix: elm_conformant;
diff --git a/src/lib/elementary/elm_ctxpopup.eo b/src/lib/elementary/elm_ctxpopup.eo
index f759dcb7d2..1421d036a9 100644
--- a/src/lib/elementary/elm_ctxpopup.eo
+++ b/src/lib/elementary/elm_ctxpopup.eo
@@ -9,7 +9,7 @@ enum Elm.Ctxpopup.Direction
}
class Elm.Ctxpopup (Efl.Ui.Layout, Efl.Ui.Focus.Layer, Efl.Access.Widget.Action,
- Efl.Ui.Menu)
+ Efl.Ui.Menu, Efl.Ui.Legacy)
{
[[Elementary context popup class]]
legacy_prefix: elm_ctxpopup;
diff --git a/src/lib/elementary/elm_ctxpopup_item.eo b/src/lib/elementary/elm_ctxpopup_item.eo
index 8c87b23a4c..db6bc1f7a5 100644
--- a/src/lib/elementary/elm_ctxpopup_item.eo
+++ b/src/lib/elementary/elm_ctxpopup_item.eo
@@ -1,4 +1,5 @@
-class Elm.Ctxpopup.Item(Elm.Widget.Item, Efl.Ui.Item, Efl.Access.Widget.Action)
+class Elm.Ctxpopup.Item(Elm.Widget.Item, Efl.Ui.Item, Efl.Access.Widget.Action,
+ Efl.Ui.Legacy)
{
[[Elementary context popup item class]]
legacy_prefix: elm_ctxpopup_item;
diff --git a/src/lib/elementary/elm_datetime.c b/src/lib/elementary/elm_datetime.c
index fc68f87525..b857971e0d 100644
--- a/src/lib/elementary/elm_datetime.c
+++ b/src/lib/elementary/elm_datetime.c
@@ -17,11 +17,29 @@
#include "elm_datetime.h"
+#include "efl_ui_clock_legacy.eo.h"
+
+#define MY_CLASS_NAME_LEGACY "elm_datetime"
+
+static void
+_efl_ui_clock_legacy_class_constructor(Efl_Class *klass)
+{
+ evas_smart_legacy_type_register(MY_CLASS_NAME_LEGACY, klass);
+}
+
+EOLIAN static Eo *
+_efl_ui_clock_legacy_efl_object_constructor(Eo *obj, void *pd EINA_UNUSED)
+{
+ obj = efl_constructor(efl_super(obj, EFL_UI_CLOCK_LEGACY_CLASS));
+ efl_canvas_object_type_set(obj, MY_CLASS_NAME_LEGACY);
+ return obj;
+}
+
EAPI Evas_Object *
elm_datetime_add(Evas_Object *parent)
{
EINA_SAFETY_ON_NULL_RETURN_VAL(parent, NULL);
- return elm_legacy_add(EFL_UI_CLOCK_CLASS, parent);
+ return elm_legacy_add(EFL_UI_CLOCK_LEGACY_CLASS, parent);
}
EAPI void
@@ -131,3 +149,5 @@ elm_datetime_value_max_get(const Evas_Object *obj, Efl_Time *maxtime)
if (maxtime) *maxtime = efl_ui_clock_time_max_get(obj);
return EINA_TRUE;
}
+
+#include "efl_ui_clock_legacy.eo.c"
diff --git a/src/lib/elementary/elm_dayselector.eo b/src/lib/elementary/elm_dayselector.eo
index 39427aa820..d95ca9fd54 100644
--- a/src/lib/elementary/elm_dayselector.eo
+++ b/src/lib/elementary/elm_dayselector.eo
@@ -17,7 +17,7 @@ enum Elm.Dayselector.Day
max [[Sentinel value to indicate last enum field during iteration]]
}
-class Elm.Dayselector (Efl.Ui.Layout)
+class Elm.Dayselector (Efl.Ui.Layout, Efl.Ui.Legacy)
{
[[Elementary dayselector class]]
legacy_prefix: elm_dayselector;
diff --git a/src/lib/elementary/elm_diskselector.eo b/src/lib/elementary/elm_diskselector.eo
index 29c5787a30..77282aaafd 100644
--- a/src/lib/elementary/elm_diskselector.eo
+++ b/src/lib/elementary/elm_diskselector.eo
@@ -1,7 +1,7 @@
class Elm.Diskselector (Efl.Ui.Widget, Elm.Interface_Scrollable,
Efl.Access.Widget.Action,
Efl.Ui.Clickable, Efl.Ui.Scrollable,
- Efl.Ui.Selectable)
+ Efl.Ui.Selectable, Efl.Ui.Legacy)
{
[[Elementary diskselector class]]
legacy_prefix: elm_diskselector;
diff --git a/src/lib/elementary/elm_diskselector_item.eo b/src/lib/elementary/elm_diskselector_item.eo
index 9a281cc611..740364faa7 100644
--- a/src/lib/elementary/elm_diskselector_item.eo
+++ b/src/lib/elementary/elm_diskselector_item.eo
@@ -1,4 +1,4 @@
-class Elm.Diskselector.Item(Elm.Widget.Item)
+class Elm.Diskselector.Item(Elm.Widget.Item, Efl.Ui.Legacy)
{
[[Elementary diskselector item class]]
legacy_prefix: elm_diskselector_item;
diff --git a/src/lib/elementary/elm_entry.eo b/src/lib/elementary/elm_entry.eo
index b90a961387..88f71bfada 100644
--- a/src/lib/elementary/elm_entry.eo
+++ b/src/lib/elementary/elm_entry.eo
@@ -5,7 +5,8 @@ type Elm_Entry_Filter_Cb: __undefined_type; [[Elementary entry filter callback t
class Elm.Entry (Efl.Ui.Layout, Elm.Interface_Scrollable, Efl.Ui.Clickable,
Efl.Access.Text, Efl.Access.Editable.Text, Efl.File,
- Efl.Ui.Selectable, Efl.Ui.Scrollable, Efl.Access.Widget.Action)
+ Efl.Ui.Selectable, Efl.Ui.Scrollable, Efl.Access.Widget.Action,
+ Efl.Ui.Legacy)
{
[[Elementary entry class]]
legacy_prefix: elm_entry;
diff --git a/src/lib/elementary/elm_fileselector.eo b/src/lib/elementary/elm_fileselector.eo
index c1a4e43bbc..e7ff91fcfb 100644
--- a/src/lib/elementary/elm_fileselector.eo
+++ b/src/lib/elementary/elm_fileselector.eo
@@ -1,6 +1,6 @@
class Elm.Fileselector (Efl.Ui.Layout, Elm.Interface.Fileselector,
Efl.Access.Widget.Action,
- Efl.Ui.Clickable, Efl.Ui.Selectable)
+ Efl.Ui.Clickable, Efl.Ui.Selectable, Efl.Ui.Legacy)
{
[[Elementary fileselector class]]
legacy_prefix: elm_fileselector;
diff --git a/src/lib/elementary/elm_fileselector_button.eo b/src/lib/elementary/elm_fileselector_button.eo
index 728a086c21..9ed6c55fe5 100644
--- a/src/lib/elementary/elm_fileselector_button.eo
+++ b/src/lib/elementary/elm_fileselector_button.eo
@@ -1,4 +1,5 @@
-class Elm.Fileselector_Button (Efl.Ui.Button, Elm.Interface.Fileselector)
+class Elm.Fileselector_Button (Efl.Ui.Button, Elm.Interface.Fileselector,
+ Efl.Ui.Legacy)
{
[[Elementary fileselector button class]]
event_prefix: elm_fileselector_button;
diff --git a/src/lib/elementary/elm_fileselector_entry.eo b/src/lib/elementary/elm_fileselector_entry.eo
index 1b267b890b..2959619d0e 100644
--- a/src/lib/elementary/elm_fileselector_entry.eo
+++ b/src/lib/elementary/elm_fileselector_entry.eo
@@ -1,5 +1,5 @@
class Elm.Fileselector_Entry (Efl.Ui.Layout, Elm.Interface.Fileselector,
- Efl.Ui.Clickable, Efl.Ui.Selectable)
+ Efl.Ui.Clickable, Efl.Ui.Selectable, Efl.Ui.Legacy)
{
[[Elementary fileselector entry class]]
event_prefix: elm_fileselector_entry;
diff --git a/src/lib/elementary/elm_flipselector.eo b/src/lib/elementary/elm_flipselector.eo
index 0ed8c610f3..f46b749762 100644
--- a/src/lib/elementary/elm_flipselector.eo
+++ b/src/lib/elementary/elm_flipselector.eo
@@ -1,6 +1,6 @@
class Elm.Flipselector (Efl.Ui.Layout, Efl.Ui.Range,
Efl.Access.Widget.Action,
- Efl.Ui.Selectable)
+ Efl.Ui.Selectable, Efl.Ui.Legacy)
{
[[Elementary flipselector class]]
legacy_prefix: elm_flipselector;
diff --git a/src/lib/elementary/elm_gengrid.eo b/src/lib/elementary/elm_gengrid.eo
index 7a06679f4f..508bb9a449 100644
--- a/src/lib/elementary/elm_gengrid.eo
+++ b/src/lib/elementary/elm_gengrid.eo
@@ -12,7 +12,7 @@ enum Elm.Gengrid.Reorder_Type
class Elm.Gengrid (Efl.Ui.Layout, Efl.Ui.Focus.Composition, Elm.Interface_Scrollable,
Efl.Ui.Clickable, Efl.Access.Widget.Action,
- Efl.Access.Selection)
+ Efl.Access.Selection, Efl.Ui.Legacy)
{
[[Elementary gengrid class]]
legacy_prefix: elm_gengrid;
diff --git a/src/lib/elementary/elm_gengrid_item.eo b/src/lib/elementary/elm_gengrid_item.eo
index 8a0cb65220..32975723f4 100644
--- a/src/lib/elementary/elm_gengrid_item.eo
+++ b/src/lib/elementary/elm_gengrid_item.eo
@@ -25,7 +25,7 @@ enum Elm.Gengrid.Item.Field_Type
}
-class Elm.Gengrid.Item(Elm.Widget.Item.Static_Focus, Efl.Ui.Focus.Object)
+class Elm.Gengrid.Item(Elm.Widget.Item.Static_Focus, Efl.Ui.Focus.Object, Efl.Ui.Legacy)
{
[[Elementary gengrid item class]]
legacy_prefix: elm_gengrid_item;
diff --git a/src/lib/elementary/elm_genlist.eo b/src/lib/elementary/elm_genlist.eo
index 318655f291..2d9a4e2536 100644
--- a/src/lib/elementary/elm_genlist.eo
+++ b/src/lib/elementary/elm_genlist.eo
@@ -4,7 +4,7 @@ import elm_genlist_item;
class Elm.Genlist (Efl.Ui.Layout, Efl.Ui.Focus.Composition, Elm.Interface_Scrollable, Efl.Ui.Clickable,
Efl.Access.Widget_Action, Efl.Access.Selection,
- Efl.Ui.Selectable)
+ Efl.Ui.Selectable, Efl.Ui.Legacy)
{
[[Elementary genlist class]]
legacy_prefix: elm_genlist;
diff --git a/src/lib/elementary/elm_genlist_item.eo b/src/lib/elementary/elm_genlist_item.eo
index 64fb0982a6..840d7f7291 100644
--- a/src/lib/elementary/elm_genlist_item.eo
+++ b/src/lib/elementary/elm_genlist_item.eo
@@ -38,7 +38,7 @@ enum Elm.Genlist.Item.Scrollto_Type
bottom = (1 << 3) [[To the bottom of viewport.]]
}
-class Elm.Genlist.Item(Elm.Widget.Item.Static_Focus)
+class Elm.Genlist.Item(Elm.Widget.Item.Static_Focus, Efl.Ui.Legacy)
{
[[Elementary genlist item class]]
legacy_prefix: elm_genlist_item;
diff --git a/src/lib/elementary/elm_gesture_layer.eo b/src/lib/elementary/elm_gesture_layer.eo
index 2e590946cb..6f384ed8d9 100644
--- a/src/lib/elementary/elm_gesture_layer.eo
+++ b/src/lib/elementary/elm_gesture_layer.eo
@@ -31,7 +31,7 @@ enum Elm.Gesture.State
abort [[Ongoing gesture was aborted]]
}
-class Elm.Gesture_Layer (Efl.Ui.Widget)
+class Elm.Gesture_Layer (Efl.Ui.Widget, Efl.Ui.Legacy)
{
[[Elementary gesture layer class]]
legacy_prefix: elm_gesture_layer;
diff --git a/src/lib/elementary/elm_glview.eo b/src/lib/elementary/elm_glview.eo
index aafb81bbc6..e6ec64c1e4 100644
--- a/src/lib/elementary/elm_glview.eo
+++ b/src/lib/elementary/elm_glview.eo
@@ -80,7 +80,7 @@ enum Elm.GLView.Render.Policy
always = 2 [[Render always even when it is not visible]]
}
-class Elm.Glview (Efl.Ui.Widget, Efl.Gfx.View)
+class Elm.Glview (Efl.Ui.Widget, Efl.Gfx.View, Efl.Ui.Legacy)
{
[[Elementary GL view class]]
legacy_prefix: elm_glview;
diff --git a/src/lib/elementary/elm_grid.eo b/src/lib/elementary/elm_grid.eo
index b8e685fb0a..61996cd5a4 100644
--- a/src/lib/elementary/elm_grid.eo
+++ b/src/lib/elementary/elm_grid.eo
@@ -1,4 +1,4 @@
-class Elm.Grid (Efl.Ui.Widget, Efl.Ui.Focus.Composition)
+class Elm.Grid (Efl.Ui.Widget, Efl.Ui.Focus.Composition, Efl.Ui.Legacy)
{
[[Elementary grid class]]
legacy_prefix: elm_grid;
diff --git a/src/lib/elementary/elm_hover.eo b/src/lib/elementary/elm_hover.eo
index 874bae2dc8..cc67a7dde3 100644
--- a/src/lib/elementary/elm_hover.eo
+++ b/src/lib/elementary/elm_hover.eo
@@ -7,7 +7,8 @@ enum Elm.Hover.Axis
both [[ELM_HOVER_AXIS_BOTH -- both.]]
}
-class Elm.Hover (Efl.Ui.Layout, Efl.Ui.Focus.Layer, Efl.Ui.Clickable, Efl.Access.Widget.Action)
+class Elm.Hover (Efl.Ui.Layout, Efl.Ui.Focus.Layer, Efl.Ui.Clickable,
+ Efl.Access.Widget.Action, Efl.Ui.Legacy)
{
[[Elementary hover class]]
legacy_prefix: elm_hover;
diff --git a/src/lib/elementary/elm_hoversel.eo b/src/lib/elementary/elm_hoversel.eo
index 8e7a580716..a3454b228f 100644
--- a/src/lib/elementary/elm_hoversel.eo
+++ b/src/lib/elementary/elm_hoversel.eo
@@ -2,7 +2,8 @@ import elm_general;
class Elm.Hoversel (Efl.Ui.Button, Efl.Ui.Selectable,
Efl.Ui.Clickable,
- Efl.Access.Widget.Action)
+ Efl.Access.Widget.Action,
+ Efl.Ui.Legacy)
{
[[Elementary hoversel class]]
legacy_prefix: elm_hoversel;
diff --git a/src/lib/elementary/elm_hoversel_item.eo b/src/lib/elementary/elm_hoversel_item.eo
index 1f9a77b3a9..6f5c7f7f55 100644
--- a/src/lib/elementary/elm_hoversel_item.eo
+++ b/src/lib/elementary/elm_hoversel_item.eo
@@ -1,6 +1,6 @@
import elm_general;
-class Elm.Hoversel.Item(Elm.Widget.Item)
+class Elm.Hoversel.Item(Elm.Widget.Item, Efl.Ui.Legacy)
{
[[Elementary hoversel item class]]
legacy_prefix: elm_hoversel_item;
diff --git a/src/lib/elementary/elm_icon.eo b/src/lib/elementary/elm_icon.eo
index a49143691c..774b609a06 100644
--- a/src/lib/elementary/elm_icon.eo
+++ b/src/lib/elementary/elm_icon.eo
@@ -1,4 +1,4 @@
-class Elm.Icon (Efl.Ui.Image)
+class Elm.Icon (Efl.Ui.Image, Efl.Ui.Legacy)
{
[[Elementary Icon Class]]
legacy_prefix: elm_icon;
diff --git a/src/lib/elementary/elm_index.eo b/src/lib/elementary/elm_index.eo
index bdde52b480..ee79dd34d1 100644
--- a/src/lib/elementary/elm_index.eo
+++ b/src/lib/elementary/elm_index.eo
@@ -1,5 +1,5 @@
class Elm.Index (Efl.Ui.Layout, Efl.Ui.Direction,
- Efl.Ui.Clickable, Efl.Ui.Selectable)
+ Efl.Ui.Clickable, Efl.Ui.Selectable, Efl.Ui.Legacy)
{
[[elementary index class]]
legacy_prefix: elm_index;
diff --git a/src/lib/elementary/elm_index_item.eo b/src/lib/elementary/elm_index_item.eo
index b1c3d8bdeb..4c2706652e 100644
--- a/src/lib/elementary/elm_index_item.eo
+++ b/src/lib/elementary/elm_index_item.eo
@@ -1,4 +1,4 @@
-class Elm.Index.Item(Elm.Widget.Item, Efl.Access.Widget.Action)
+class Elm.Index.Item(Elm.Widget.Item, Efl.Access.Widget.Action, Efl.Ui.Legacy)
{
[[Elementary index item class]]
legacy_prefix: elm_index_item;
diff --git a/src/lib/elementary/elm_interface_scrollable.c b/src/lib/elementary/elm_interface_scrollable.c
index ce73fcf8e5..d431401f60 100644
--- a/src/lib/elementary/elm_interface_scrollable.c
+++ b/src/lib/elementary/elm_interface_scrollable.c
@@ -193,7 +193,7 @@ _elm_pan_content_size_get(Eo *obj EINA_UNUSED, Elm_Pan_Smart_Data *psd, Evas_Coo
static Evas_Object *
_elm_pan_add(Evas *evas)
{
- return efl_add(MY_PAN_CLASS, evas, efl_canvas_object_legacy_ctor(efl_added));
+ return elm_legacy_add(MY_PAN_CLASS, evas);
}
EOLIAN static Eo *
diff --git a/src/lib/elementary/elm_interfaces.h b/src/lib/elementary/elm_interfaces.h
index c15669ebea..6f27a34ad0 100644
--- a/src/lib/elementary/elm_interfaces.h
+++ b/src/lib/elementary/elm_interfaces.h
@@ -16,6 +16,7 @@
#include "efl_access_image.eo.h"
#include "efl_access_selection.eo.h"
#include "efl_access_value.eo.h"
+#include "efl_ui_legacy.eo.h"
#endif
#ifndef EFL_NOLEGACY_API_SUPPORT
#include "efl_access_action.eo.legacy.h"
@@ -24,5 +25,6 @@
#include "efl_access_image.eo.legacy.h"
#include "efl_access_selection.eo.legacy.h"
#include "efl_access_value.eo.legacy.h"
+#include "efl_ui_legacy.eo.legacy.h"
#endif
#endif
diff --git a/src/lib/elementary/elm_inwin.eo b/src/lib/elementary/elm_inwin.eo
index 9edf1d65b1..0b6acf9bc1 100644
--- a/src/lib/elementary/elm_inwin.eo
+++ b/src/lib/elementary/elm_inwin.eo
@@ -1,4 +1,4 @@
-class Elm.Inwin (Efl.Ui.Layout, Efl.Ui.Focus.Layer, Efl.Content)
+class Elm.Inwin (Efl.Ui.Layout, Efl.Ui.Focus.Layer, Efl.Content, Efl.Ui.Legacy)
{
[[Elementary inwin class]]
legacy_prefix: elm_inwin;
diff --git a/src/lib/elementary/elm_label.eo b/src/lib/elementary/elm_label.eo
index 8211153e21..73b1298b71 100644
--- a/src/lib/elementary/elm_label.eo
+++ b/src/lib/elementary/elm_label.eo
@@ -8,7 +8,7 @@ enum Elm.Label.Slide_Mode
always [[Slide always.]]
}
-class Elm.Label (Efl.Ui.Layout)
+class Elm.Label (Efl.Ui.Layout, Efl.Ui.Legacy)
{
[[Elementary label class]]
legacy_prefix: elm_label;
diff --git a/src/lib/elementary/elm_list.eo b/src/lib/elementary/elm_list.eo
index 5987cca579..4e5cc2b6c9 100644
--- a/src/lib/elementary/elm_list.eo
+++ b/src/lib/elementary/elm_list.eo
@@ -38,7 +38,7 @@ enum Elm.List.Mode
class Elm.List (Efl.Ui.Layout, Elm.Interface_Scrollable,
Efl.Access.Widget.Action, Efl.Access.Selection,
- Efl.Ui.Clickable, Efl.Ui.Selectable)
+ Efl.Ui.Clickable, Efl.Ui.Selectable, Efl.Ui.Legacy)
{
[[Elementary list class]]
legacy_prefix: elm_list;
diff --git a/src/lib/elementary/elm_list_item.eo b/src/lib/elementary/elm_list_item.eo
index 23729d3837..c1005780d6 100644
--- a/src/lib/elementary/elm_list_item.eo
+++ b/src/lib/elementary/elm_list_item.eo
@@ -1,4 +1,4 @@
-class Elm.List.Item(Elm.Widget.Item)
+class Elm.List.Item(Elm.Widget.Item, Efl.Ui.Legacy)
{
[[Elementary list item class]]
legacy_prefix: elm_list_item;
diff --git a/src/lib/elementary/elm_map.eo b/src/lib/elementary/elm_map.eo
index a20ccff9dc..9c4d68d162 100644
--- a/src/lib/elementary/elm_map.eo
+++ b/src/lib/elementary/elm_map.eo
@@ -71,7 +71,7 @@ enum Elm.Map.Route_Method
class Elm.Map (Efl.Ui.Widget, Elm.Interface_Scrollable,
Efl.Access.Widget.Action,
- Efl.Ui.Clickable)
+ Efl.Ui.Clickable, Efl.Ui.Legacy)
{
[[Elementary map class]]
legacy_prefix: elm_map;
diff --git a/src/lib/elementary/elm_mapbuf.eo b/src/lib/elementary/elm_mapbuf.eo
index a8f1eadea6..b116ed7ce6 100644
--- a/src/lib/elementary/elm_mapbuf.eo
+++ b/src/lib/elementary/elm_mapbuf.eo
@@ -1,4 +1,4 @@
-class Elm.Mapbuf (Efl.Ui.Widget, Efl.Content, Efl.Part)
+class Elm.Mapbuf (Efl.Ui.Widget, Efl.Content, Efl.Part, Efl.Ui.Legacy)
{
[[Elementary mapbuf class]]
legacy_prefix: elm_mapbuf;
diff --git a/src/lib/elementary/elm_menu.eo b/src/lib/elementary/elm_menu.eo
index ccbaa21500..a808f29af1 100644
--- a/src/lib/elementary/elm_menu.eo
+++ b/src/lib/elementary/elm_menu.eo
@@ -1,5 +1,5 @@
class Elm.Menu (Efl.Ui.Widget, Efl.Ui.Clickable, Efl.Ui.Menu,
- Efl.Access.Selection, Efl.Ui.Focus.Manager)
+ Efl.Access.Selection, Efl.Ui.Focus.Manager, Efl.Ui.Legacy)
{
[[Elementary menu class]]
legacy_prefix: elm_menu;
diff --git a/src/lib/elementary/elm_menu_item.eo b/src/lib/elementary/elm_menu_item.eo
index 249b0f04c1..464f8313f8 100644
--- a/src/lib/elementary/elm_menu_item.eo
+++ b/src/lib/elementary/elm_menu_item.eo
@@ -1,5 +1,5 @@
class Elm.Menu.Item(Elm.Widget.Item, Efl.Access.Selection,
- Efl.Ui.Item)
+ Efl.Ui.Item, Efl.Ui.Legacy)
{
[[Elementary menu item class]]
legacy_prefix: elm_menu_item;
diff --git a/src/lib/elementary/elm_multibuttonentry_item.eo b/src/lib/elementary/elm_multibuttonentry_item.eo
index 1c7292db71..32a6185190 100644
--- a/src/lib/elementary/elm_multibuttonentry_item.eo
+++ b/src/lib/elementary/elm_multibuttonentry_item.eo
@@ -1,5 +1,6 @@
class Elm.Multibuttonentry.Item(Elm.Widget.Item,
- Efl.Access.Widget.Action)
+ Efl.Access.Widget.Action,
+ Efl.Ui.Legacy)
{
[[Elementary multibuttonentry class]]
legacy_prefix: elm_multibuttonentry_item;
diff --git a/src/lib/elementary/elm_naviframe.eo b/src/lib/elementary/elm_naviframe.eo
index 4f6c7bf457..349f3973ce 100644
--- a/src/lib/elementary/elm_naviframe.eo
+++ b/src/lib/elementary/elm_naviframe.eo
@@ -1,4 +1,4 @@
-class Elm.Naviframe (Efl.Ui.Layout, Efl.Access.Widget.Action)
+class Elm.Naviframe (Efl.Ui.Layout, Efl.Access.Widget.Action, Efl.Ui.Legacy)
{
[[Elementary naviframe class]]
legacy_prefix: elm_naviframe;
diff --git a/src/lib/elementary/elm_naviframe_item.eo b/src/lib/elementary/elm_naviframe_item.eo
index 6e372e7dce..761a6692e6 100644
--- a/src/lib/elementary/elm_naviframe_item.eo
+++ b/src/lib/elementary/elm_naviframe_item.eo
@@ -1,6 +1,6 @@
type Elm_Naviframe_Item_Pop_Cb: __undefined_type; [[Elementary naviframe item pop callback type]]
-class Elm.Naviframe.Item(Elm.Widget.Item)
+class Elm.Naviframe.Item(Elm.Widget.Item, Efl.Ui.Legacy)
{
[[Elementary naviframe item class]]
legacy_prefix: elm_naviframe_item;
diff --git a/src/lib/elementary/elm_notify.eo b/src/lib/elementary/elm_notify.eo
index a3a0afcf7f..4b4236efe6 100644
--- a/src/lib/elementary/elm_notify.eo
+++ b/src/lib/elementary/elm_notify.eo
@@ -1,4 +1,4 @@
-class Elm.Notify (Efl.Ui.Widget, Efl.Ui.Focus.Layer, Efl.Content, Efl.Part)
+class Elm.Notify (Efl.Ui.Widget, Efl.Ui.Focus.Layer, Efl.Content, Efl.Part, Efl.Ui.Legacy)
{
[[Elementary notification class]]
legacy_prefix: elm_notify;
diff --git a/src/lib/elementary/elm_panel.eo b/src/lib/elementary/elm_panel.eo
index 6a8f6f9e3f..fd4aa87ad5 100644
--- a/src/lib/elementary/elm_panel.eo
+++ b/src/lib/elementary/elm_panel.eo
@@ -9,7 +9,7 @@ enum Elm.Panel.Orient
}
class Elm.Panel (Efl.Ui.Layout, Efl.Ui.Focus.Layer, Elm.Interface_Scrollable,
- Efl.Access.Widget.Action)
+ Efl.Access.Widget.Action, Efl.Ui.Legacy)
{
[[Elementary panel class]]
legacy_prefix: elm_panel;
diff --git a/src/lib/elementary/elm_photo.eo b/src/lib/elementary/elm_photo.eo
index a7811ab123..bd9e986142 100644
--- a/src/lib/elementary/elm_photo.eo
+++ b/src/lib/elementary/elm_photo.eo
@@ -1,4 +1,5 @@
-class Elm.Photo (Efl.Ui.Widget, Efl.File, Efl.Ui.Clickable, Efl.Ui.Draggable)
+class Elm.Photo (Efl.Ui.Widget, Efl.File, Efl.Ui.Clickable, Efl.Ui.Draggable,
+ Efl.Ui.Legacy)
{
[[Elementary photo class]]
legacy_prefix: elm_photo;
diff --git a/src/lib/elementary/elm_player.eo b/src/lib/elementary/elm_player.eo
index 3771e08db9..49263c1348 100644
--- a/src/lib/elementary/elm_player.eo
+++ b/src/lib/elementary/elm_player.eo
@@ -1,4 +1,4 @@
-class Elm.Player (Efl.Ui.Layout, Efl.Access.Widget.Action)
+class Elm.Player (Efl.Ui.Layout, Efl.Access.Widget.Action, Efl.Ui.Legacy)
{
[[Elementary player class]]
legacy_prefix: elm_player;
diff --git a/src/lib/elementary/elm_plug.eo b/src/lib/elementary/elm_plug.eo
index 674835c240..728e9fccaf 100644
--- a/src/lib/elementary/elm_plug.eo
+++ b/src/lib/elementary/elm_plug.eo
@@ -1,4 +1,4 @@
-class Elm.Plug (Efl.Ui.Widget, Efl.Ui.Clickable)
+class Elm.Plug (Efl.Ui.Widget, Efl.Ui.Clickable, Efl.Ui.Legacy)
{
[[Elementary plug class]]
legacy_prefix: elm_plug;
diff --git a/src/lib/elementary/elm_popup.eo b/src/lib/elementary/elm_popup.eo
index f611d915cd..133f237cbc 100644
--- a/src/lib/elementary/elm_popup.eo
+++ b/src/lib/elementary/elm_popup.eo
@@ -23,7 +23,7 @@ enum Elm.Popup.Orient
}
-class Elm.Popup (Efl.Ui.Layout, Efl.Access.Widget.Action)
+class Elm.Popup (Efl.Ui.Layout, Efl.Access.Widget.Action, Efl.Ui.Legacy)
{
[[Elementary popup class]]
legacy_prefix: elm_popup;
diff --git a/src/lib/elementary/elm_popup_item.eo b/src/lib/elementary/elm_popup_item.eo
index dcf95772b3..7668b17d41 100644
--- a/src/lib/elementary/elm_popup_item.eo
+++ b/src/lib/elementary/elm_popup_item.eo
@@ -1,4 +1,4 @@
-class Elm.Popup.Item(Elm.Widget.Item)
+class Elm.Popup.Item(Elm.Widget.Item, Efl.Ui.Legacy)
{
[[Elementary popup item class]]
legacy_prefix: elm_popup_item;
diff --git a/src/lib/elementary/elm_prefs.eo b/src/lib/elementary/elm_prefs.eo
index 2b7eb661b5..0f91b45f4e 100644
--- a/src/lib/elementary/elm_prefs.eo
+++ b/src/lib/elementary/elm_prefs.eo
@@ -3,7 +3,7 @@ import eina_types;
type Elm_Prefs_Data: __undefined_type; [[Elementary preferences data type]]
type Elm_Prefs_Reset_Mode: __undefined_type; [[Elementary preferences reset mode type]]
-class Elm.Prefs (Efl.Ui.Widget, Efl.File)
+class Elm.Prefs (Efl.Ui.Widget, Efl.File, Efl.Ui.Legacy)
{
[[Elementary preferences class]]
legacy_prefix: elm_prefs;
diff --git a/src/lib/elementary/elm_route.eo b/src/lib/elementary/elm_route.eo
index fa95398c67..fe41b6a5bf 100644
--- a/src/lib/elementary/elm_route.eo
+++ b/src/lib/elementary/elm_route.eo
@@ -1,4 +1,4 @@
-class Elm.Route (Efl.Ui.Widget)
+class Elm.Route (Efl.Ui.Widget, Efl.Ui.Legacy)
{
[[Elementary route class]]
legacy_prefix: elm_route;
diff --git a/src/lib/elementary/elm_scroller.eo b/src/lib/elementary/elm_scroller.eo
index cb0e3fe177..0abe1254ad 100644
--- a/src/lib/elementary/elm_scroller.eo
+++ b/src/lib/elementary/elm_scroller.eo
@@ -1,6 +1,6 @@
class Elm.Scroller (Efl.Ui.Layout, Elm.Interface_Scrollable,
Efl.Access.Widget.Action,
- Efl.Ui.Scrollable, Efl.Content)
+ Efl.Ui.Scrollable, Efl.Content, Efl.Ui.Legacy)
{
[[Elementary scroller class]]
legacy_prefix: elm_scroller;
diff --git a/src/lib/elementary/elm_segment_control.eo b/src/lib/elementary/elm_segment_control.eo
index 7c2cbeaed6..bd42439393 100644
--- a/src/lib/elementary/elm_segment_control.eo
+++ b/src/lib/elementary/elm_segment_control.eo
@@ -1,4 +1,4 @@
-class Elm.Segment_Control (Efl.Ui.Layout, Efl.Ui.Focus.Composition)
+class Elm.Segment_Control (Efl.Ui.Layout, Efl.Ui.Focus.Composition, Efl.Ui.Legacy)
{
[[Elementary segment control class]]
legacy_prefix: elm_segment_control;
diff --git a/src/lib/elementary/elm_segment_control_item.eo b/src/lib/elementary/elm_segment_control_item.eo
index 743b0586f5..dab3f9cc24 100644
--- a/src/lib/elementary/elm_segment_control_item.eo
+++ b/src/lib/elementary/elm_segment_control_item.eo
@@ -1,4 +1,4 @@
-class Elm.Segment_Control.Item(Elm.Widget.Item, Efl.Ui.Focus.Object)
+class Elm.Segment_Control.Item(Elm.Widget.Item, Efl.Ui.Focus.Object, Efl.Ui.Legacy)
{
[[Elementary segment control item class]]
legacy_prefix: elm_segment_control_item;
diff --git a/src/lib/elementary/elm_separator.eo b/src/lib/elementary/elm_separator.eo
index 3c7b23d369..c29585d6b8 100644
--- a/src/lib/elementary/elm_separator.eo
+++ b/src/lib/elementary/elm_separator.eo
@@ -1,4 +1,4 @@
-class Elm.Separator (Efl.Ui.Layout)
+class Elm.Separator (Efl.Ui.Layout, Efl.Ui.Legacy)
{
[[Elementary separator class]]
legacy_prefix: elm_separator;
diff --git a/src/lib/elementary/elm_slideshow.eo b/src/lib/elementary/elm_slideshow.eo
index 9f0b533dfa..acb6b24b44 100644
--- a/src/lib/elementary/elm_slideshow.eo
+++ b/src/lib/elementary/elm_slideshow.eo
@@ -1,6 +1,6 @@
type Elm_Slideshow_Item_Class: __undefined_type; [[Elementary slideshow item class type]]
-class Elm.Slideshow (Efl.Ui.Layout, Efl.Access.Widget.Action)
+class Elm.Slideshow (Efl.Ui.Layout, Efl.Access.Widget.Action, Efl.Ui.Legacy)
{
[[Elementary slideshow class]]
eo_prefix: elm_obj_slideshow;
diff --git a/src/lib/elementary/elm_spinner.eo b/src/lib/elementary/elm_spinner.eo
index 8cc571dde2..f0b0dc6955 100644
--- a/src/lib/elementary/elm_spinner.eo
+++ b/src/lib/elementary/elm_spinner.eo
@@ -1,5 +1,5 @@
class Elm.Spinner (Efl.Ui.Layout, Efl.Ui.Range, Efl.Ui.Focus.Composition,
- Efl.Access.Value, Efl.Access.Widget.Action)
+ Efl.Access.Value, Efl.Access.Widget.Action, Efl.Ui.Legacy)
{
[[Elementary spinner class]]
legacy_prefix: elm_spinner;
diff --git a/src/lib/elementary/elm_table.eo b/src/lib/elementary/elm_table.eo
index 8271373212..7eaae08231 100644
--- a/src/lib/elementary/elm_table.eo
+++ b/src/lib/elementary/elm_table.eo
@@ -1,4 +1,4 @@
-class Elm.Table (Efl.Ui.Widget, Efl.Ui.Focus.Composition)
+class Elm.Table (Efl.Ui.Widget, Efl.Ui.Focus.Composition, Efl.Ui.Legacy)
{
[[Elementary table class]]
legacy_prefix: elm_table;
diff --git a/src/lib/elementary/elm_theme.c b/src/lib/elementary/elm_theme.c
index 69028c6770..ed24b7a0f9 100644
--- a/src/lib/elementary/elm_theme.c
+++ b/src/lib/elementary/elm_theme.c
@@ -281,6 +281,7 @@ _elm_theme_object_set(Evas_Object *parent, Evas_Object *o, const char *clas, con
Elm_Theme *th = NULL;
if (parent) th = elm_widget_theme_get(parent);
+
return _elm_theme_set(th, o, clas, group, style, elm_widget_is_legacy(parent));
}
diff --git a/src/lib/elementary/elm_thumb.eo b/src/lib/elementary/elm_thumb.eo
index a6f9820ded..fa8a94a6e1 100644
--- a/src/lib/elementary/elm_thumb.eo
+++ b/src/lib/elementary/elm_thumb.eo
@@ -1,5 +1,5 @@
class Elm.Thumb (Efl.Ui.Layout, Efl.File, Efl.Ui.Clickable,
- Efl.Ui.Draggable)
+ Efl.Ui.Draggable, Efl.Ui.Legacy)
{
[[Elementary thumbnail class]]
legacy_prefix: elm_thumb;
diff --git a/src/lib/elementary/elm_toolbar.eo b/src/lib/elementary/elm_toolbar.eo
index 4847729292..00704c709a 100644
--- a/src/lib/elementary/elm_toolbar.eo
+++ b/src/lib/elementary/elm_toolbar.eo
@@ -25,7 +25,7 @@ enum Elm.Toolbar.Shrink_Mode
class Elm.Toolbar (Efl.Ui.Widget, Efl.Ui.Focus.Composition, Elm.Interface_Scrollable, Efl.Ui.Direction,
Efl.Access.Widget.Action, Efl.Access.Selection,
- Efl.Ui.Clickable, Efl.Ui.Selectable, Efl.Ui.Menu)
+ Efl.Ui.Clickable, Efl.Ui.Selectable, Efl.Ui.Menu, Efl.Ui.Legacy)
{
[[Elementary toolbar class]]
legacy_prefix: elm_toolbar;
diff --git a/src/lib/elementary/elm_toolbar_item.eo b/src/lib/elementary/elm_toolbar_item.eo
index a9af54ee0d..5143b8f7e7 100644
--- a/src/lib/elementary/elm_toolbar_item.eo
+++ b/src/lib/elementary/elm_toolbar_item.eo
@@ -23,7 +23,7 @@ struct Elm.Toolbar.Item.State
data: const(void_ptr); [[Item data]]
}
-class Elm.Toolbar.Item(Elm.Widget.Item, Efl.Ui.Item, Efl.Ui.Focus.Object)
+class Elm.Toolbar.Item(Elm.Widget.Item, Efl.Ui.Item, Efl.Ui.Focus.Object, Efl.Ui.Legacy)
{
[[Elementary toolbar item class]]
legacy_prefix: elm_toolbar_item;
diff --git a/src/lib/elementary/elm_web.eo b/src/lib/elementary/elm_web.eo
index 1ff13fe350..ee2e939a22 100644
--- a/src/lib/elementary/elm_web.eo
+++ b/src/lib/elementary/elm_web.eo
@@ -14,7 +14,7 @@ enum Elm.Web.Zoom_Mode
last [[Sentinel value to indicate last enum field during iteration]]
}
-class Elm.Web (Efl.Ui.Widget)
+class Elm.Web (Efl.Ui.Widget, Efl.Ui.Legacy)
{
[[Elementary web view class]]
legacy_prefix: elm_web;
diff --git a/src/lib/elementary/elm_widget.h b/src/lib/elementary/elm_widget.h
index 20673e5798..3a8267b76b 100644
--- a/src/lib/elementary/elm_widget.h
+++ b/src/lib/elementary/elm_widget.h
@@ -464,7 +464,6 @@ typedef struct _Elm_Widget_Smart_Data
Eina_Bool on_create : 1; /**< This is true when the widget is on creation(general widget constructor). */
Eina_Bool on_destroy: 1; /**< This is true when the widget is on destruction(general widget destructor). */
Eina_Bool provider_lookup : 1; /**< This is true when efl_provider_find is currently walking the tree */
- Eina_Bool legacy : 1; /**< Widget was created with a legacy API, not efl_add() */
Eina_Bool has_shadow : 1;
} Elm_Widget_Smart_Data;
@@ -822,10 +821,7 @@ _elm_widget_sub_object_redirect_to_top(Evas_Object *obj, Evas_Object *sobj)
return ret;
}
-/* Internal hack to mark legacy objects as such before construction.
- * No need for TLS: Only UI objects created in the main loop matter. */
-EAPI extern Eina_Bool _elm_legacy_add;
-#define elm_legacy_add(k, p, ...) ({ _elm_legacy_add = 1; \
+#define elm_legacy_add(k, p, ...) ({ \
efl_add(k, p, efl_canvas_object_legacy_ctor(efl_added), ##__VA_ARGS__); })
static inline Eo *
@@ -838,11 +834,7 @@ elm_widget_resize_object_get(const Eo *obj)
static inline Eina_Bool
elm_widget_is_legacy(const Eo *obj)
{
- Elm_Widget_Smart_Data *sd;
-
- if (_elm_legacy_add) return EINA_TRUE;
- sd = (Elm_Widget_Smart_Data *) efl_data_scope_safe_get(obj, EFL_UI_WIDGET_CLASS);
- return sd ? sd->legacy : EINA_FALSE;
+ return efl_isa(obj, EFL_UI_LEGACY_INTERFACE);
}
/** Takes in any canvas object and returns the first smart parent that is a widget */