summaryrefslogtreecommitdiff
path: root/src
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 /src
parentfeba0d905c2b5bed773d8fb3ba89fbb26132ab1e (diff)
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
Diffstat (limited to 'src')
-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 2987c19..401454c 100644
--- a/src/Makefile_Elementary.am
+++ b/src/Makefile_Elementary.am
@@ -211,7 +211,6 @@ elm_legacy_eolian_files = \
211 lib/elementary/elm_actionslider_part.eo \ 211 lib/elementary/elm_actionslider_part.eo \
212 lib/elementary/elm_bubble_part.eo \ 212 lib/elementary/elm_bubble_part.eo \
213 lib/elementary/elm_fileselector_part.eo \ 213 lib/elementary/elm_fileselector_part.eo \
214 lib/elementary/elm_photo.eo \
215 lib/elementary/elm_prefs.eo \ 214 lib/elementary/elm_prefs.eo \
216 lib/elementary/elm_segment_control.eo \ 215 lib/elementary/elm_segment_control.eo \
217 lib/elementary/elm_segment_control_item.eo \ 216 lib/elementary/elm_segment_control_item.eo \
@@ -377,6 +376,7 @@ lib/elementary/elm_panel_eo.c \
377lib/elementary/elm_panel_eo.legacy.c \ 376lib/elementary/elm_panel_eo.legacy.c \
378lib/elementary/elm_pan_eo.c \ 377lib/elementary/elm_pan_eo.c \
379lib/elementary/elm_pan_eo.legacy.c \ 378lib/elementary/elm_pan_eo.legacy.c \
379lib/elementary/elm_photo_eo.c \
380$(NULL) 380$(NULL)
381 381
382elm_legacy_eo_headers = \ 382elm_legacy_eo_headers = \
@@ -536,6 +536,8 @@ lib/elementary/elm_panel_eo.h \
536lib/elementary/elm_panel_eo.legacy.h \ 536lib/elementary/elm_panel_eo.legacy.h \
537lib/elementary/elm_pan_eo.h \ 537lib/elementary/elm_pan_eo.h \
538lib/elementary/elm_pan_eo.legacy.h \ 538lib/elementary/elm_pan_eo.legacy.h \
539lib/elementary/elm_photo_eo.h \
540lib/elementary/elm_photo_eo.legacy.h \
539$(NULL) 541$(NULL)
540 542
541 543
diff --git a/src/lib/elementary/elm_photo.c b/src/lib/elementary/elm_photo.c
index 2f9dc66..1af5e2b 100644
--- a/src/lib/elementary/elm_photo.c
+++ b/src/lib/elementary/elm_photo.c
@@ -8,7 +8,7 @@
8 8
9#include "elm_priv.h" 9#include "elm_priv.h"
10#include "elm_widget_photo.h" 10#include "elm_widget_photo.h"
11#include "elm_photo.eo.h" 11#include "elm_photo_eo.h"
12#include "elm_icon_eo.h" 12#include "elm_icon_eo.h"
13 13
14#define MY_CLASS ELM_PHOTO_CLASS 14#define MY_CLASS ELM_PHOTO_CLASS
@@ -493,4 +493,4 @@ elm_photo_thumb_set(Evas_Object *obj, const char *file, const char *group)
493#define ELM_PHOTO_EXTRA_OPS \ 493#define ELM_PHOTO_EXTRA_OPS \
494 EFL_CANVAS_GROUP_ADD_DEL_OPS(elm_photo) 494 EFL_CANVAS_GROUP_ADD_DEL_OPS(elm_photo)
495 495
496#include "elm_photo.eo.c" 496#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 7263119..0000000
--- a/src/lib/elementary/elm_photo.eo
+++ /dev/null
@@ -1,18 +0,0 @@
1class Elm.Photo extends Efl.Ui.Widget implements Efl.File, Efl.Ui.Clickable, Efl.Ui.Draggable,
2 Efl.Ui.Legacy
3{
4 [[Elementary photo class]]
5 legacy_prefix: elm_photo;
6 eo_prefix: elm_obj_photo;
7 implements {
8 class.constructor;
9 Efl.Object.constructor;
10 Efl.Object.finalize;
11 Efl.File.file { get; set; }
12 Efl.File.key { get; set; }
13 Efl.File.mmap { get; set; }
14 Efl.File.load;
15 Efl.Ui.Widget.theme_apply;
16 Efl.Ui.Draggable.drag_target { get; set; }
17 }
18}
diff --git a/src/lib/elementary/elm_photo_eo.c b/src/lib/elementary/elm_photo_eo.c
new file mode 100644
index 0000000..02b8a28
--- /dev/null
+++ b/src/lib/elementary/elm_photo_eo.c
@@ -0,0 +1,79 @@
1
2Efl_Object *_elm_photo_efl_object_constructor(Eo *obj, Elm_Photo_Data *pd);
3
4
5Efl_Object *_elm_photo_efl_object_finalize(Eo *obj, Elm_Photo_Data *pd);
6
7
8Eina_Error _elm_photo_efl_file_file_set(Eo *obj, Elm_Photo_Data *pd, const char *file);
9
10
11const char *_elm_photo_efl_file_file_get(const Eo *obj, Elm_Photo_Data *pd);
12
13
14void _elm_photo_efl_file_key_set(Eo *obj, Elm_Photo_Data *pd, const char *key);
15
16
17const char *_elm_photo_efl_file_key_get(const Eo *obj, Elm_Photo_Data *pd);
18
19
20Eina_Error _elm_photo_efl_file_mmap_set(Eo *obj, Elm_Photo_Data *pd, const Eina_File *f);
21
22
23const Eina_File *_elm_photo_efl_file_mmap_get(const Eo *obj, Elm_Photo_Data *pd);
24
25
26Eina_Error _elm_photo_efl_file_load(Eo *obj, Elm_Photo_Data *pd);
27
28
29Eina_Error _elm_photo_efl_ui_widget_theme_apply(Eo *obj, Elm_Photo_Data *pd);
30
31
32void _elm_photo_efl_ui_draggable_drag_target_set(Eo *obj, Elm_Photo_Data *pd, Eina_Bool set);
33
34
35Eina_Bool _elm_photo_efl_ui_draggable_drag_target_get(const Eo *obj, Elm_Photo_Data *pd);
36
37
38static Eina_Bool
39_elm_photo_class_initializer(Efl_Class *klass)
40{
41 const Efl_Object_Ops *opsp = NULL;
42
43 const Efl_Object_Property_Reflection_Ops *ropsp = NULL;
44
45#ifndef ELM_PHOTO_EXTRA_OPS
46#define ELM_PHOTO_EXTRA_OPS
47#endif
48
49 EFL_OPS_DEFINE(ops,
50 EFL_OBJECT_OP_FUNC(efl_constructor, _elm_photo_efl_object_constructor),
51 EFL_OBJECT_OP_FUNC(efl_finalize, _elm_photo_efl_object_finalize),
52 EFL_OBJECT_OP_FUNC(efl_file_set, _elm_photo_efl_file_file_set),
53 EFL_OBJECT_OP_FUNC(efl_file_get, _elm_photo_efl_file_file_get),
54 EFL_OBJECT_OP_FUNC(efl_file_key_set, _elm_photo_efl_file_key_set),
55 EFL_OBJECT_OP_FUNC(efl_file_key_get, _elm_photo_efl_file_key_get),
56 EFL_OBJECT_OP_FUNC(efl_file_mmap_set, _elm_photo_efl_file_mmap_set),
57 EFL_OBJECT_OP_FUNC(efl_file_mmap_get, _elm_photo_efl_file_mmap_get),
58 EFL_OBJECT_OP_FUNC(efl_file_load, _elm_photo_efl_file_load),
59 EFL_OBJECT_OP_FUNC(efl_ui_widget_theme_apply, _elm_photo_efl_ui_widget_theme_apply),
60 EFL_OBJECT_OP_FUNC(efl_ui_draggable_drag_target_set, _elm_photo_efl_ui_draggable_drag_target_set),
61 EFL_OBJECT_OP_FUNC(efl_ui_draggable_drag_target_get, _elm_photo_efl_ui_draggable_drag_target_get),
62 ELM_PHOTO_EXTRA_OPS
63 );
64 opsp = &ops;
65
66 return efl_class_functions_set(klass, opsp, ropsp);
67}
68
69static const Efl_Class_Description _elm_photo_class_desc = {
70 EO_VERSION,
71 "Elm.Photo",
72 EFL_CLASS_TYPE_REGULAR,
73 sizeof(Elm_Photo_Data),
74 _elm_photo_class_initializer,
75 _elm_photo_class_constructor,
76 NULL
77};
78
79EFL_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 0000000..50cdb23
--- /dev/null
+++ b/src/lib/elementary/elm_photo_eo.h
@@ -0,0 +1,24 @@
1#ifndef _ELM_PHOTO_EO_H_
2#define _ELM_PHOTO_EO_H_
3
4#ifndef _ELM_PHOTO_EO_CLASS_TYPE
5#define _ELM_PHOTO_EO_CLASS_TYPE
6
7typedef Eo Elm_Photo;
8
9#endif
10
11#ifndef _ELM_PHOTO_EO_TYPES
12#define _ELM_PHOTO_EO_TYPES
13
14
15#endif
16/** Elementary photo class
17 *
18 * @ingroup Elm_Photo
19 */
20#define ELM_PHOTO_CLASS elm_photo_class_get()
21
22EWAPI const Efl_Class *elm_photo_class_get(void);
23
24#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 0000000..4258afa
--- /dev/null
+++ b/src/lib/elementary/elm_photo_eo.legacy.h
@@ -0,0 +1,17 @@
1#ifndef _ELM_PHOTO_EO_LEGACY_H_
2#define _ELM_PHOTO_EO_LEGACY_H_
3
4#ifndef _ELM_PHOTO_EO_CLASS_TYPE
5#define _ELM_PHOTO_EO_CLASS_TYPE
6
7typedef Eo Elm_Photo;
8
9#endif
10
11#ifndef _ELM_PHOTO_EO_TYPES
12#define _ELM_PHOTO_EO_TYPES
13
14
15#endif
16
17#endif
diff --git a/src/lib/elementary/elm_photo_legacy.h b/src/lib/elementary/elm_photo_legacy.h
index 36005de..3368bb7 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);
116 */ 116 */
117EAPI void elm_photo_thumb_set(Evas_Object *obj, const char *file, const char *group); 117EAPI void elm_photo_thumb_set(Evas_Object *obj, const char *file, const char *group);
118 118
119#include "elm_photo.eo.legacy.h" 119#include "elm_photo_eo.legacy.h"
diff --git a/src/lib/elementary/meson.build b/src/lib/elementary/meson.build
index e61e549..ac8c7ce 100644
--- a/src/lib/elementary/meson.build
+++ b/src/lib/elementary/meson.build
@@ -28,7 +28,6 @@ pub_legacy_eo_files = [
28 'elm_actionslider_part.eo', 28 'elm_actionslider_part.eo',
29 'elm_bubble_part.eo', 29 'elm_bubble_part.eo',
30 'elm_fileselector_part.eo', 30 'elm_fileselector_part.eo',
31 'elm_photo.eo',
32 'elm_prefs.eo', 31 'elm_prefs.eo',
33 'elm_segment_control.eo', 32 'elm_segment_control.eo',
34 'elm_segment_control_item.eo', 33 'elm_segment_control_item.eo',
@@ -780,6 +779,8 @@ elementary_pub_headers = [
780 'elm_panel_eo.legacy.h', 779 'elm_panel_eo.legacy.h',
781 'elm_pan_eo.h', 780 'elm_pan_eo.h',
782 'elm_pan_eo.legacy.h', 781 'elm_pan_eo.legacy.h',
782 'elm_photo_eo.h',
783 'elm_photo_eo.legacy.h',
783] 784]
784 785
785elementary_header_src = [ 786elementary_header_src = [