elm_route: remove all legacy usage from eo files
authorMike Blumenkrantz <zmike@samsung.com>
Tue, 5 Mar 2019 22:00:37 +0000 (17:00 -0500)
committerJunsuChoi <jsuya.choi@samsung.com>
Thu, 14 Mar 2019 05:46:28 +0000 (14:46 +0900)
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/D8195

src/Makefile_Elementary.am
src/lib/elementary/elm_route.c
src/lib/elementary/elm_route.eo [deleted file]
src/lib/elementary/elm_route_eo.c [new file with mode: 0644]
src/lib/elementary/elm_route_eo.h [new file with mode: 0644]
src/lib/elementary/elm_route_eo.legacy.c [new file with mode: 0644]
src/lib/elementary/elm_route_eo.legacy.h [new file with mode: 0644]
src/lib/elementary/elm_route_legacy.h
src/lib/elementary/elm_widget_route.h
src/lib/elementary/meson.build

index 3d002d7cbf918162ffafcbca79ae7774132a8739..0a4ed5b1d5fe733fc3631ec2b2de64b744f26099 100644 (file)
@@ -195,7 +195,6 @@ endif
 elm_legacy_eolian_files = \
        lib/elementary/efl_ui_animation_view.eo \
        lib/elementary/efl_ui_clock_legacy.eo \
-       lib/elementary/elm_route.eo \
        lib/elementary/elm_scroller.eo \
        lib/elementary/elm_sys_notify_interface.eo \
        lib/elementary/elm_sys_notify.eo \
@@ -392,6 +391,8 @@ lib/elementary/elm_popup_eo.legacy.c \
 lib/elementary/elm_popup_item_eo.c \
 lib/elementary/elm_prefs_eo.c \
 lib/elementary/elm_prefs_eo.legacy.c \
+lib/elementary/elm_route_eo.c \
+lib/elementary/elm_route_eo.legacy.c \
 $(NULL)
 
 elm_legacy_eo_headers = \
@@ -563,6 +564,8 @@ lib/elementary/elm_popup_item_eo.h \
 lib/elementary/elm_popup_item_eo.legacy.h \
 lib/elementary/elm_prefs_eo.h \
 lib/elementary/elm_prefs_eo.legacy.h \
+lib/elementary/elm_route_eo.h \
+lib/elementary/elm_route_eo.legacy.h \
 $(NULL)
 
 
index 6b52ef17ccd7a4bd2501fd16fec22501fecc2167..3b9d3ecee347e6edc7ec78d2c9f3b81158d9abb0 100644 (file)
@@ -265,4 +265,4 @@ _elm_route_class_constructor(Efl_Class *klass)
 #define ELM_ROUTE_EXTRA_OPS \
    EFL_CANVAS_GROUP_ADD_DEL_OPS(elm_route)
 
-#include "elm_route.eo.c"
+#include "elm_route_eo.c"
diff --git a/src/lib/elementary/elm_route.eo b/src/lib/elementary/elm_route.eo
deleted file mode 100644 (file)
index 0df51d4..0000000
+++ /dev/null
@@ -1,47 +0,0 @@
-class Elm.Route extends Efl.Ui.Widget implements Efl.Ui.Legacy
-{
-   [[Elementary route class]]
-   legacy_prefix: elm_route;
-   eo_prefix: elm_obj_route;
-   methods {
-      @property emap {
-         set {
-            [[Set map widget for this route]]
-         }
-         values {
-            emap: void_ptr; [[Elementary map widget]]
-         }
-      }
-      @property longitude_min_max {
-         get {
-            [[Get the minimum and maximum values along the longitude.
-
-              Note: If only one value is needed, the other pointer can be
-              passed as null.
-            ]]
-         }
-         values {
-            min: double; [[Pointer to store the minimum value.]]
-            max: double; [[Pointer to store the maximum value.]]
-         }
-      }
-      @property latitude_min_max {
-         get {
-            [[Get the minimum and maximum values along the latitude.
-
-              Note: If only one value is needed, the other pointer can be
-              passed as null.
-            ]]
-         }
-         values {
-            min: double; [[Pointer to store the minimum value.]]
-            max: double; [[Pointer to store the maximum value.]]
-         }
-      }
-   }
-   implements {
-      class.constructor;
-      Efl.Object.constructor;
-      Efl.Ui.Widget.theme_apply;
-   }
-}
diff --git a/src/lib/elementary/elm_route_eo.c b/src/lib/elementary/elm_route_eo.c
new file mode 100644 (file)
index 0000000..930eacd
--- /dev/null
@@ -0,0 +1,56 @@
+
+void _elm_route_emap_set(Eo *obj, Elm_Route_Data *pd, void *emap);
+
+EOAPI EFL_VOID_FUNC_BODYV(elm_obj_route_emap_set, EFL_FUNC_CALL(emap), void *emap);
+
+void _elm_route_longitude_min_max_get(const Eo *obj, Elm_Route_Data *pd, double *min, double *max);
+
+EOAPI EFL_VOID_FUNC_BODYV_CONST(elm_obj_route_longitude_min_max_get, EFL_FUNC_CALL(min, max), double *min, double *max);
+
+void _elm_route_latitude_min_max_get(const Eo *obj, Elm_Route_Data *pd, double *min, double *max);
+
+EOAPI EFL_VOID_FUNC_BODYV_CONST(elm_obj_route_latitude_min_max_get, EFL_FUNC_CALL(min, max), double *min, double *max);
+
+Efl_Object *_elm_route_efl_object_constructor(Eo *obj, Elm_Route_Data *pd);
+
+
+Eina_Error _elm_route_efl_ui_widget_theme_apply(Eo *obj, Elm_Route_Data *pd);
+
+
+static Eina_Bool
+_elm_route_class_initializer(Efl_Class *klass)
+{
+   const Efl_Object_Ops *opsp = NULL;
+
+   const Efl_Object_Property_Reflection_Ops *ropsp = NULL;
+
+#ifndef ELM_ROUTE_EXTRA_OPS
+#define ELM_ROUTE_EXTRA_OPS
+#endif
+
+   EFL_OPS_DEFINE(ops,
+      EFL_OBJECT_OP_FUNC(elm_obj_route_emap_set, _elm_route_emap_set),
+      EFL_OBJECT_OP_FUNC(elm_obj_route_longitude_min_max_get, _elm_route_longitude_min_max_get),
+      EFL_OBJECT_OP_FUNC(elm_obj_route_latitude_min_max_get, _elm_route_latitude_min_max_get),
+      EFL_OBJECT_OP_FUNC(efl_constructor, _elm_route_efl_object_constructor),
+      EFL_OBJECT_OP_FUNC(efl_ui_widget_theme_apply, _elm_route_efl_ui_widget_theme_apply),
+      ELM_ROUTE_EXTRA_OPS
+   );
+   opsp = &ops;
+
+   return efl_class_functions_set(klass, opsp, ropsp);
+}
+
+static const Efl_Class_Description _elm_route_class_desc = {
+   EO_VERSION,
+   "Elm.Route",
+   EFL_CLASS_TYPE_REGULAR,
+   sizeof(Elm_Route_Data),
+   _elm_route_class_initializer,
+   _elm_route_class_constructor,
+   NULL
+};
+
+EFL_DEFINE_CLASS(elm_route_class_get, &_elm_route_class_desc, EFL_UI_WIDGET_CLASS, EFL_UI_LEGACY_INTERFACE, NULL);
+
+#include "elm_route_eo.legacy.c"
diff --git a/src/lib/elementary/elm_route_eo.h b/src/lib/elementary/elm_route_eo.h
new file mode 100644 (file)
index 0000000..a194623
--- /dev/null
@@ -0,0 +1,60 @@
+#ifndef _ELM_ROUTE_EO_H_
+#define _ELM_ROUTE_EO_H_
+
+#ifndef _ELM_ROUTE_EO_CLASS_TYPE
+#define _ELM_ROUTE_EO_CLASS_TYPE
+
+typedef Eo Elm_Route;
+
+#endif
+
+#ifndef _ELM_ROUTE_EO_TYPES
+#define _ELM_ROUTE_EO_TYPES
+
+
+#endif
+/** Elementary route class
+ *
+ * @ingroup Elm_Route
+ */
+#define ELM_ROUTE_CLASS elm_route_class_get()
+
+EWAPI const Efl_Class *elm_route_class_get(void);
+
+/**
+ * @brief Set map widget for this route
+ *
+ * @param[in] obj The object.
+ * @param[in] emap Elementary map widget
+ *
+ * @ingroup Elm_Route
+ */
+EOAPI void elm_obj_route_emap_set(Eo *obj, void *emap);
+
+/**
+ * @brief Get the minimum and maximum values along the longitude.
+ *
+ * @note If only one value is needed, the other pointer can be passed as null.
+ *
+ * @param[in] obj The object.
+ * @param[out] min Pointer to store the minimum value.
+ * @param[out] max Pointer to store the maximum value.
+ *
+ * @ingroup Elm_Route
+ */
+EOAPI void elm_obj_route_longitude_min_max_get(const Eo *obj, double *min, double *max);
+
+/**
+ * @brief Get the minimum and maximum values along the latitude.
+ *
+ * @note If only one value is needed, the other pointer can be passed as null.
+ *
+ * @param[in] obj The object.
+ * @param[out] min Pointer to store the minimum value.
+ * @param[out] max Pointer to store the maximum value.
+ *
+ * @ingroup Elm_Route
+ */
+EOAPI void elm_obj_route_latitude_min_max_get(const Eo *obj, double *min, double *max);
+
+#endif
diff --git a/src/lib/elementary/elm_route_eo.legacy.c b/src/lib/elementary/elm_route_eo.legacy.c
new file mode 100644 (file)
index 0000000..69d8a8b
--- /dev/null
@@ -0,0 +1,18 @@
+
+EAPI void
+elm_route_emap_set(Elm_Route *obj, void *emap)
+{
+   elm_obj_route_emap_set(obj, emap);
+}
+
+EAPI void
+elm_route_longitude_min_max_get(const Elm_Route *obj, double *min, double *max)
+{
+   elm_obj_route_longitude_min_max_get(obj, min, max);
+}
+
+EAPI void
+elm_route_latitude_min_max_get(const Elm_Route *obj, double *min, double *max)
+{
+   elm_obj_route_latitude_min_max_get(obj, min, max);
+}
diff --git a/src/lib/elementary/elm_route_eo.legacy.h b/src/lib/elementary/elm_route_eo.legacy.h
new file mode 100644 (file)
index 0000000..34650bd
--- /dev/null
@@ -0,0 +1,53 @@
+#ifndef _ELM_ROUTE_EO_LEGACY_H_
+#define _ELM_ROUTE_EO_LEGACY_H_
+
+#ifndef _ELM_ROUTE_EO_CLASS_TYPE
+#define _ELM_ROUTE_EO_CLASS_TYPE
+
+typedef Eo Elm_Route;
+
+#endif
+
+#ifndef _ELM_ROUTE_EO_TYPES
+#define _ELM_ROUTE_EO_TYPES
+
+
+#endif
+
+/**
+ * @brief Set map widget for this route
+ *
+ * @param[in] obj The object.
+ * @param[in] emap Elementary map widget
+ *
+ * @ingroup Elm_Route_Group
+ */
+EAPI void elm_route_emap_set(Elm_Route *obj, void *emap);
+
+/**
+ * @brief Get the minimum and maximum values along the longitude.
+ *
+ * @note If only one value is needed, the other pointer can be passed as null.
+ *
+ * @param[in] obj The object.
+ * @param[out] min Pointer to store the minimum value.
+ * @param[out] max Pointer to store the maximum value.
+ *
+ * @ingroup Elm_Route_Group
+ */
+EAPI void elm_route_longitude_min_max_get(const Elm_Route *obj, double *min, double *max);
+
+/**
+ * @brief Get the minimum and maximum values along the latitude.
+ *
+ * @note If only one value is needed, the other pointer can be passed as null.
+ *
+ * @param[in] obj The object.
+ * @param[out] min Pointer to store the minimum value.
+ * @param[out] max Pointer to store the maximum value.
+ *
+ * @ingroup Elm_Route_Group
+ */
+EAPI void elm_route_latitude_min_max_get(const Elm_Route *obj, double *min, double *max);
+
+#endif
index ad320dc5dda09b20e9c4567ea1c165dab0ee6609..7326024abd19b02451674f90c41c166bc76e25cf 100644 (file)
@@ -8,4 +8,4 @@
  */
 EAPI Evas_Object *elm_route_add(Evas_Object *parent);
 
-#include "elm_route.eo.legacy.h"
\ No newline at end of file
+#include "elm_route_eo.legacy.h"
\ No newline at end of file
index 6c6286bf4d0ca9a5df09646aaecebbe05e595463..651c67fd14e6c3496e036d3136724f119e229c5f 100644 (file)
@@ -1,7 +1,7 @@
 #ifndef ELM_WIDGET_ROUTE_H
 #define ELM_WIDGET_ROUTE_H
 
-#include "elm_route.eo.h"
+#include "elm_route_eo.h"
 
 /* DO NOT USE THIS HEADER UNLESS YOU ARE PREPARED FOR BREAKING OF YOUR
  * CODE. THIS IS ELEMENTARY'S INTERNAL WIDGET API (for now) AND IS NOT
index f66ae914e992ba52ea08d36cb868ec8fffdce19d..7478eaeb2dbc17cc6cf3f28f3c4dff56653c0c94 100644 (file)
@@ -1,6 +1,5 @@
 pub_legacy_eo_files = [
   'efl_ui_clock_legacy.eo',
-  'elm_route.eo',
   'elm_scroller.eo',
   'elm_sys_notify_interface.eo',
   'elm_sys_notify.eo',
@@ -906,6 +905,8 @@ elementary_pub_headers = [
   'elm_popup_item_eo.legacy.h',
   'elm_prefs_eo.h',
   'elm_prefs_eo.legacy.h',
+  'elm_route_eo.h',
+  'elm_route_eo.legacy.h',
 ]
 
 elementary_header_src = [