summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Blumenkrantz <zmike@samsung.com>2019-03-05 17:00:37 -0500
committerCedric BAIL <cedric.bail@free.fr>2019-03-07 14:16:01 -0800
commitf536d1030e02f06b75b27590db765ab3133571bb (patch)
treeb4dfed0a3ae9048c5c42f62eca34745f50f155de
parentfeba0d905c2b5bed773d8fb3ba89fbb26132ab1e (diff)
downloadefl-f536d1030e02f06b75b27590db765ab3133571bb.tar.gz
elm_photo: remove all legacy usage from eo files
this takes the current generated output from eolian for legacy code in efl and adds it to the tree, then removes legacy references from the corresponding eo files. in the case where the entire eo file was for a legacy object, that eo file has been removed from the tree ref T7724 Reviewed-by: Cedric BAIL <cedric.bail@free.fr> Differential Revision: https://phab.enlightenment.org/D8190
-rw-r--r--src/Makefile_Elementary.am4
-rw-r--r--src/lib/elementary/elm_photo.c4
-rw-r--r--src/lib/elementary/elm_photo.eo18
-rw-r--r--src/lib/elementary/elm_photo_eo.c79
-rw-r--r--src/lib/elementary/elm_photo_eo.h24
-rw-r--r--src/lib/elementary/elm_photo_eo.legacy.h17
-rw-r--r--src/lib/elementary/elm_photo_legacy.h2
-rw-r--r--src/lib/elementary/meson.build3
8 files changed, 128 insertions, 23 deletions
diff --git a/src/Makefile_Elementary.am b/src/Makefile_Elementary.am
index 2987c190b8..401454c0bf 100644
--- a/src/Makefile_Elementary.am
+++ b/src/Makefile_Elementary.am
@@ -211,7 +211,6 @@ elm_legacy_eolian_files = \
lib/elementary/elm_actionslider_part.eo \
lib/elementary/elm_bubble_part.eo \
lib/elementary/elm_fileselector_part.eo \
- lib/elementary/elm_photo.eo \
lib/elementary/elm_prefs.eo \
lib/elementary/elm_segment_control.eo \
lib/elementary/elm_segment_control_item.eo \
@@ -377,6 +376,7 @@ lib/elementary/elm_panel_eo.c \
lib/elementary/elm_panel_eo.legacy.c \
lib/elementary/elm_pan_eo.c \
lib/elementary/elm_pan_eo.legacy.c \
+lib/elementary/elm_photo_eo.c \
$(NULL)
elm_legacy_eo_headers = \
@@ -536,6 +536,8 @@ lib/elementary/elm_panel_eo.h \
lib/elementary/elm_panel_eo.legacy.h \
lib/elementary/elm_pan_eo.h \
lib/elementary/elm_pan_eo.legacy.h \
+lib/elementary/elm_photo_eo.h \
+lib/elementary/elm_photo_eo.legacy.h \
$(NULL)
diff --git a/src/lib/elementary/elm_photo.c b/src/lib/elementary/elm_photo.c
index 2f9dc661ea..1af5e2b872 100644
--- a/src/lib/elementary/elm_photo.c
+++ b/src/lib/elementary/elm_photo.c
@@ -8,7 +8,7 @@
#include "elm_priv.h"
#include "elm_widget_photo.h"
-#include "elm_photo.eo.h"
+#include "elm_photo_eo.h"
#include "elm_icon_eo.h"
#define MY_CLASS ELM_PHOTO_CLASS
@@ -493,4 +493,4 @@ elm_photo_thumb_set(Evas_Object *obj, const char *file, const char *group)
#define ELM_PHOTO_EXTRA_OPS \
EFL_CANVAS_GROUP_ADD_DEL_OPS(elm_photo)
-#include "elm_photo.eo.c"
+#include "elm_photo_eo.c"
diff --git a/src/lib/elementary/elm_photo.eo b/src/lib/elementary/elm_photo.eo
deleted file mode 100644
index 7263119fbb..0000000000
--- a/src/lib/elementary/elm_photo.eo
+++ /dev/null
@@ -1,18 +0,0 @@
-class Elm.Photo extends Efl.Ui.Widget implements Efl.File, Efl.Ui.Clickable, Efl.Ui.Draggable,
- Efl.Ui.Legacy
-{
- [[Elementary photo class]]
- legacy_prefix: elm_photo;
- eo_prefix: elm_obj_photo;
- implements {
- class.constructor;
- Efl.Object.constructor;
- Efl.Object.finalize;
- Efl.File.file { get; set; }
- Efl.File.key { get; set; }
- Efl.File.mmap { get; set; }
- Efl.File.load;
- Efl.Ui.Widget.theme_apply;
- Efl.Ui.Draggable.drag_target { get; set; }
- }
-}
diff --git a/src/lib/elementary/elm_photo_eo.c b/src/lib/elementary/elm_photo_eo.c
new file mode 100644
index 0000000000..02b8a28fcf
--- /dev/null
+++ b/src/lib/elementary/elm_photo_eo.c
@@ -0,0 +1,79 @@
+
+Efl_Object *_elm_photo_efl_object_constructor(Eo *obj, Elm_Photo_Data *pd);
+
+
+Efl_Object *_elm_photo_efl_object_finalize(Eo *obj, Elm_Photo_Data *pd);
+
+
+Eina_Error _elm_photo_efl_file_file_set(Eo *obj, Elm_Photo_Data *pd, const char *file);
+
+
+const char *_elm_photo_efl_file_file_get(const Eo *obj, Elm_Photo_Data *pd);
+
+
+void _elm_photo_efl_file_key_set(Eo *obj, Elm_Photo_Data *pd, const char *key);
+
+
+const char *_elm_photo_efl_file_key_get(const Eo *obj, Elm_Photo_Data *pd);
+
+
+Eina_Error _elm_photo_efl_file_mmap_set(Eo *obj, Elm_Photo_Data *pd, const Eina_File *f);
+
+
+const Eina_File *_elm_photo_efl_file_mmap_get(const Eo *obj, Elm_Photo_Data *pd);
+
+
+Eina_Error _elm_photo_efl_file_load(Eo *obj, Elm_Photo_Data *pd);
+
+
+Eina_Error _elm_photo_efl_ui_widget_theme_apply(Eo *obj, Elm_Photo_Data *pd);
+
+
+void _elm_photo_efl_ui_draggable_drag_target_set(Eo *obj, Elm_Photo_Data *pd, Eina_Bool set);
+
+
+Eina_Bool _elm_photo_efl_ui_draggable_drag_target_get(const Eo *obj, Elm_Photo_Data *pd);
+
+
+static Eina_Bool
+_elm_photo_class_initializer(Efl_Class *klass)
+{
+ const Efl_Object_Ops *opsp = NULL;
+
+ const Efl_Object_Property_Reflection_Ops *ropsp = NULL;
+
+#ifndef ELM_PHOTO_EXTRA_OPS
+#define ELM_PHOTO_EXTRA_OPS
+#endif
+
+ EFL_OPS_DEFINE(ops,
+ EFL_OBJECT_OP_FUNC(efl_constructor, _elm_photo_efl_object_constructor),
+ EFL_OBJECT_OP_FUNC(efl_finalize, _elm_photo_efl_object_finalize),
+ EFL_OBJECT_OP_FUNC(efl_file_set, _elm_photo_efl_file_file_set),
+ EFL_OBJECT_OP_FUNC(efl_file_get, _elm_photo_efl_file_file_get),
+ EFL_OBJECT_OP_FUNC(efl_file_key_set, _elm_photo_efl_file_key_set),
+ EFL_OBJECT_OP_FUNC(efl_file_key_get, _elm_photo_efl_file_key_get),
+ EFL_OBJECT_OP_FUNC(efl_file_mmap_set, _elm_photo_efl_file_mmap_set),
+ EFL_OBJECT_OP_FUNC(efl_file_mmap_get, _elm_photo_efl_file_mmap_get),
+ EFL_OBJECT_OP_FUNC(efl_file_load, _elm_photo_efl_file_load),
+ EFL_OBJECT_OP_FUNC(efl_ui_widget_theme_apply, _elm_photo_efl_ui_widget_theme_apply),
+ EFL_OBJECT_OP_FUNC(efl_ui_draggable_drag_target_set, _elm_photo_efl_ui_draggable_drag_target_set),
+ EFL_OBJECT_OP_FUNC(efl_ui_draggable_drag_target_get, _elm_photo_efl_ui_draggable_drag_target_get),
+ ELM_PHOTO_EXTRA_OPS
+ );
+ opsp = &ops;
+
+ return efl_class_functions_set(klass, opsp, ropsp);
+}
+
+static const Efl_Class_Description _elm_photo_class_desc = {
+ EO_VERSION,
+ "Elm.Photo",
+ EFL_CLASS_TYPE_REGULAR,
+ sizeof(Elm_Photo_Data),
+ _elm_photo_class_initializer,
+ _elm_photo_class_constructor,
+ NULL
+};
+
+EFL_DEFINE_CLASS(elm_photo_class_get, &_elm_photo_class_desc, EFL_UI_WIDGET_CLASS, EFL_FILE_MIXIN, EFL_UI_CLICKABLE_INTERFACE, EFL_UI_DRAGGABLE_INTERFACE, EFL_UI_LEGACY_INTERFACE, NULL);
diff --git a/src/lib/elementary/elm_photo_eo.h b/src/lib/elementary/elm_photo_eo.h
new file mode 100644
index 0000000000..50cdb235b5
--- /dev/null
+++ b/src/lib/elementary/elm_photo_eo.h
@@ -0,0 +1,24 @@
+#ifndef _ELM_PHOTO_EO_H_
+#define _ELM_PHOTO_EO_H_
+
+#ifndef _ELM_PHOTO_EO_CLASS_TYPE
+#define _ELM_PHOTO_EO_CLASS_TYPE
+
+typedef Eo Elm_Photo;
+
+#endif
+
+#ifndef _ELM_PHOTO_EO_TYPES
+#define _ELM_PHOTO_EO_TYPES
+
+
+#endif
+/** Elementary photo class
+ *
+ * @ingroup Elm_Photo
+ */
+#define ELM_PHOTO_CLASS elm_photo_class_get()
+
+EWAPI const Efl_Class *elm_photo_class_get(void);
+
+#endif
diff --git a/src/lib/elementary/elm_photo_eo.legacy.h b/src/lib/elementary/elm_photo_eo.legacy.h
new file mode 100644
index 0000000000..4258afa919
--- /dev/null
+++ b/src/lib/elementary/elm_photo_eo.legacy.h
@@ -0,0 +1,17 @@
+#ifndef _ELM_PHOTO_EO_LEGACY_H_
+#define _ELM_PHOTO_EO_LEGACY_H_
+
+#ifndef _ELM_PHOTO_EO_CLASS_TYPE
+#define _ELM_PHOTO_EO_CLASS_TYPE
+
+typedef Eo Elm_Photo;
+
+#endif
+
+#ifndef _ELM_PHOTO_EO_TYPES
+#define _ELM_PHOTO_EO_TYPES
+
+
+#endif
+
+#endif
diff --git a/src/lib/elementary/elm_photo_legacy.h b/src/lib/elementary/elm_photo_legacy.h
index 36005de149..3368bb7426 100644
--- a/src/lib/elementary/elm_photo_legacy.h
+++ b/src/lib/elementary/elm_photo_legacy.h
@@ -116,4 +116,4 @@ EAPI int elm_photo_size_get(const Evas_Object *obj);
*/
EAPI void elm_photo_thumb_set(Evas_Object *obj, const char *file, const char *group);
-#include "elm_photo.eo.legacy.h"
+#include "elm_photo_eo.legacy.h"
diff --git a/src/lib/elementary/meson.build b/src/lib/elementary/meson.build
index e61e549212..ac8c7cedc0 100644
--- a/src/lib/elementary/meson.build
+++ b/src/lib/elementary/meson.build
@@ -28,7 +28,6 @@ pub_legacy_eo_files = [
'elm_actionslider_part.eo',
'elm_bubble_part.eo',
'elm_fileselector_part.eo',
- 'elm_photo.eo',
'elm_prefs.eo',
'elm_segment_control.eo',
'elm_segment_control_item.eo',
@@ -780,6 +779,8 @@ elementary_pub_headers = [
'elm_panel_eo.legacy.h',
'elm_pan_eo.h',
'elm_pan_eo.legacy.h',
+ 'elm_photo_eo.h',
+ 'elm_photo_eo.legacy.h',
]
elementary_header_src = [