[EGIT] [core/efl] master 11/11: examples: Fix compilation (use legacy func)

2016-06-17 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=4e2d7b5f8b88a7a4c313cfbd1438d7cfc4a60142

commit 4e2d7b5f8b88a7a4c313cfbd1438d7cfc4a60142
Author: Jean-Philippe Andre 
Date:   Fri Jun 17 19:28:57 2016 +0900

examples: Fix compilation (use legacy func)

name has been removed (it's part of EO).
---
 src/examples/evas/evas-object-manipulation-eo.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/examples/evas/evas-object-manipulation-eo.c 
b/src/examples/evas/evas-object-manipulation-eo.c
index 1dd25cc..6c9e6f6 100644
--- a/src/examples/evas/evas-object-manipulation-eo.c
+++ b/src/examples/evas/evas-object-manipulation-eo.c
@@ -177,7 +177,7 @@ main(void)
d.bg = eo_add(EFL_CANVAS_RECTANGLE_CLASS, d.canvas);
 
/* Eo-styled way to perform actions on an object*/
-   evas_obj_name_set(d.bg, "background rectangle");
+   evas_object_name_set(d.bg, "background rectangle");
efl_gfx_color_set(d.bg, 255, 255, 255, 255);
/* white bg */
efl_gfx_position_set(d.bg, 0, 0);

-- 




[EGIT] [core/efl] master 04/11: Evas: Move smart data to legacy

2016-06-17 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=3d1e474fc6d88f5c883e3804d4ba16012f9588d6

commit 3d1e474fc6d88f5c883e3804d4ba16012f9588d6
Author: Jean-Philippe Andre 
Date:   Fri Jun 17 14:30:44 2016 +0900

Evas: Move smart data to legacy
---
 src/lib/evas/Evas_Legacy.h   | 15 +++
 src/lib/evas/canvas/evas_object_smart.c  | 10 ++
 src/lib/evas/canvas/evas_object_smart.eo | 14 --
 3 files changed, 21 insertions(+), 18 deletions(-)

diff --git a/src/lib/evas/Evas_Legacy.h b/src/lib/evas/Evas_Legacy.h
index eb827ab..74893f7 100644
--- a/src/lib/evas/Evas_Legacy.h
+++ b/src/lib/evas/Evas_Legacy.h
@@ -5177,6 +5177,21 @@ EAPI void 
evas_object_smart_callback_description_find(const Evas_Object *obj, co
 EAPI Evas_Smart *evas_object_smart_smart_get(const Evas_Object *obj) 
EINA_WARN_UNUSED_RESULT;
 
 /**
+ * @brief Store a pointer to user data for a given smart object.
+ *
+ * This data is stored independently of the one set by evas_object_data_set(),
+ * naturally.
+ *
+ * See also @ref evas_object_smart_data_get.
+ *
+ * @param[in] data A pointer to user data.
+ *
+ * @ingroup Evas_Object_Smart
+ */
+EAPI void evas_object_smart_data_set(Evas_Object *obj, void *data);
+EAPI void *evas_object_smart_data_get(const Evas_Object *obj);
+
+/**
  * This gets the internal counter that counts the number of smart calculations
  *
  * @param e The canvas to get the calculate counter from
diff --git a/src/lib/evas/canvas/evas_object_smart.c 
b/src/lib/evas/canvas/evas_object_smart.c
index 0a204d1..b304ed2 100644
--- a/src/lib/evas/canvas/evas_object_smart.c
+++ b/src/lib/evas/canvas/evas_object_smart.c
@@ -120,17 +120,19 @@ static const Evas_Object_Func object_func =
 
 
 /* public funcs */
-EOLIAN static void
-_evas_object_smart_data_set(Eo *eo_obj EINA_UNUSED, Evas_Smart_Data *o, void 
*data)
+EAPI void
+evas_object_smart_data_set(Evas_Object *eo_obj, void *data)
 {
+   EVAS_OBJECT_SMART_GET_OR_RETURN(eo_obj);
if (o->data) eo_data_unref(eo_obj, o->data);
o->data = data;
eo_data_ref(eo_obj, NULL);
 }
 
-EOLIAN void *
-_evas_object_smart_data_get(Evas_Object *eo_obj EINA_UNUSED, Evas_Smart_Data 
*o)
+EAPI void *
+evas_object_smart_data_get(const Evas_Object *eo_obj)
 {
+   EVAS_OBJECT_SMART_GET_OR_RETURN(eo_obj, NULL);
return o->data;
 }
 
diff --git a/src/lib/evas/canvas/evas_object_smart.eo 
b/src/lib/evas/canvas/evas_object_smart.eo
index 19e94bb..35edfd7 100644
--- a/src/lib/evas/canvas/evas_object_smart.eo
+++ b/src/lib/evas/canvas/evas_object_smart.eo
@@ -62,20 +62,6 @@ class Evas.Object.Smart (Evas.Object)
 a: int;
  }
   }
-  @property data {
- get {}
- set {
-[[Store a pointer to user data for a given smart object.
-
-  This data is stored independently of the one set by
-  evas_object_data_set(), naturally.
-
-  See also @.data.get.]]
- }
- values {
-data: void_ptr; [[A pointer to user data.]]
- }
-  }
   @property members {
  get {
 [[Retrieves the list of the member objects of a given Evas smart 
object.

-- 




[EGIT] [core/efl] master 05/11: Evas: Move smart_members_get to legacy

2016-06-17 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=2a0bb33f1d049f35914cc4597022702f297bdc3c

commit 2a0bb33f1d049f35914cc4597022702f297bdc3c
Author: Jean-Philippe Andre 
Date:   Fri Jun 17 14:42:07 2016 +0900

Evas: Move smart_members_get to legacy

Going forward, we prefer to return iterators rather than
lists.
---
 src/lib/evas/Evas_Legacy.h   | 20 
 src/lib/evas/canvas/evas_object_smart.c  |  5 +++--
 src/lib/evas/canvas/evas_object_smart.eo | 15 ---
 3 files changed, 23 insertions(+), 17 deletions(-)

diff --git a/src/lib/evas/Evas_Legacy.h b/src/lib/evas/Evas_Legacy.h
index 74893f7..15948a0 100644
--- a/src/lib/evas/Evas_Legacy.h
+++ b/src/lib/evas/Evas_Legacy.h
@@ -5192,6 +5192,26 @@ EAPI void evas_object_smart_data_set(Evas_Object *obj, 
void *data);
 EAPI void *evas_object_smart_data_get(const Evas_Object *obj);
 
 /**
+ * @brief Retrieves the list of the member objects of a given Evas smart
+ * object.
+ *
+ * The returned list should be freed with @c eina_list_free() when you no
+ * longer need it.
+ *
+ * This function will return @c null when a non-smart object is passed.
+ *
+ * See also @ref Evas.Object.Smart.member_add,
+ * @ref Evas.Object.Smart.member_del and @ref evas_object_smart_iterator_new.
+ *
+ * @return Returns the list of the member objects of @c obj.
+ *
+ * @since 1.7
+ *
+ * @ingroup Evas_Object_Smart
+ */
+EAPI Eina_List *evas_object_smart_members_get(const Evas_Object *obj) 
EINA_WARN_UNUSED_RESULT;
+
+/**
  * This gets the internal counter that counts the number of smart calculations
  *
  * @param e The canvas to get the calculate counter from
diff --git a/src/lib/evas/canvas/evas_object_smart.c 
b/src/lib/evas/canvas/evas_object_smart.c
index b304ed2..d824658 100644
--- a/src/lib/evas/canvas/evas_object_smart.c
+++ b/src/lib/evas/canvas/evas_object_smart.c
@@ -464,9 +464,10 @@ _evas_object_smart_iterator_new(const Eo *eo_obj, 
Evas_Smart_Data *priv)
return >iterator;
 }
 
-EOLIAN static Eina_List*
-_evas_object_smart_members_get(Eo *eo_obj EINA_UNUSED, Evas_Smart_Data *o)
+EAPI Eina_List*
+evas_object_smart_members_get(const Evas_Object *eo_obj)
 {
+   EVAS_OBJECT_SMART_GET_OR_RETURN(eo_obj, NULL);
Eina_List *members = NULL;
Eina_Inlist *member;
 
diff --git a/src/lib/evas/canvas/evas_object_smart.eo 
b/src/lib/evas/canvas/evas_object_smart.eo
index 35edfd7..37e1ed4 100644
--- a/src/lib/evas/canvas/evas_object_smart.eo
+++ b/src/lib/evas/canvas/evas_object_smart.eo
@@ -62,21 +62,6 @@ class Evas.Object.Smart (Evas.Object)
 a: int;
  }
   }
-  @property members {
- get {
-[[Retrieves the list of the member objects of a given Evas smart 
object.
-
-  The returned list should be freed with $eina_list_free() when you
-  no longer need it.
-
-  This function will return $null when a non-smart object is 
passed.
-
-  See also @.member_add, @.member_del and @.iterator_new.
-
-  @since 1.7]]
-return: list @warn_unused; [[Returns the list of the 
member objects of $obj.]]
- }
-  }
   show {
  [[No description supplied by the EAPI.]]
  legacy: null;

-- 




[EGIT] [core/efl] master 03/11: Evas: Move smart_callbacks_descriptions to legacy

2016-06-17 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=9a052a740d8ddc18a6f79ab5d45ce8148557e0c5

commit 9a052a740d8ddc18a6f79ab5d45ce8148557e0c5
Author: Jean-Philippe Andre 
Date:   Fri Jun 17 14:12:02 2016 +0900

Evas: Move smart_callbacks_descriptions to legacy
---
 src/lib/elementary/efl_ui_box.c   |  2 +-
 src/lib/elementary/efl_ui_flip.c  |  2 +-
 src/lib/elementary/efl_ui_image.c |  2 +-
 src/lib/elementary/efl_ui_nstate.c|  2 +-
 src/lib/elementary/efl_ui_text.c  |  2 +-
 src/lib/elementary/efl_ui_win.c   |  2 +-
 src/lib/elementary/elc_combobox.c |  2 +-
 src/lib/elementary/elc_ctxpopup.c |  2 +-
 src/lib/elementary/elc_fileselector.c |  2 +-
 src/lib/elementary/elc_fileselector_button.c  |  2 +-
 src/lib/elementary/elc_fileselector_entry.c   |  2 +-
 src/lib/elementary/elc_hoversel.c |  2 +-
 src/lib/elementary/elc_multibuttonentry.c |  2 +-
 src/lib/elementary/elc_naviframe.c|  2 +-
 src/lib/elementary/elc_player.c   |  2 +-
 src/lib/elementary/elc_popup.c|  2 +-
 src/lib/elementary/elm_actionslider.c |  2 +-
 src/lib/elementary/elm_box.c  |  2 +-
 src/lib/elementary/elm_bubble.c   |  2 +-
 src/lib/elementary/elm_button.c   |  2 +-
 src/lib/elementary/elm_calendar.c |  2 +-
 src/lib/elementary/elm_check.c|  2 +-
 src/lib/elementary/elm_clock.c|  2 +-
 src/lib/elementary/elm_colorselector.c|  2 +-
 src/lib/elementary/elm_conform.c  |  2 +-
 src/lib/elementary/elm_datetime.c |  2 +-
 src/lib/elementary/elm_dayselector.c  |  2 +-
 src/lib/elementary/elm_diskselector.c |  2 +-
 src/lib/elementary/elm_entry.c|  2 +-
 src/lib/elementary/elm_flipselector.c |  2 +-
 src/lib/elementary/elm_frame.c|  2 +-
 src/lib/elementary/elm_gengrid.c  |  2 +-
 src/lib/elementary/elm_genlist.c  |  2 +-
 src/lib/elementary/elm_glview.c   |  2 +-
 src/lib/elementary/elm_hover.c|  2 +-
 src/lib/elementary/elm_icon.c |  2 +-
 src/lib/elementary/elm_index.c|  2 +-
 src/lib/elementary/elm_interface_scrollable.c |  2 +-
 src/lib/elementary/elm_label.c|  2 +-
 src/lib/elementary/elm_layout.c   |  2 +-
 src/lib/elementary/elm_list.c |  2 +-
 src/lib/elementary/elm_map.c  |  2 +-
 src/lib/elementary/elm_menu.c |  2 +-
 src/lib/elementary/elm_panel.c|  2 +-
 src/lib/elementary/elm_panes.c|  2 +-
 src/lib/elementary/elm_photo.c|  2 +-
 src/lib/elementary/elm_photocam.c |  2 +-
 src/lib/elementary/elm_plug.c |  2 +-
 src/lib/elementary/elm_prefs.c|  2 +-
 src/lib/elementary/elm_progressbar.c  |  2 +-
 src/lib/elementary/elm_radio.c|  2 +-
 src/lib/elementary/elm_scroller.c |  2 +-
 src/lib/elementary/elm_segment_control.c  |  2 +-
 src/lib/elementary/elm_slider.c   |  2 +-
 src/lib/elementary/elm_slideshow.c|  2 +-
 src/lib/elementary/elm_spinner.c  |  2 +-
 src/lib/elementary/elm_thumb.c|  2 +-
 src/lib/elementary/elm_toolbar.c  |  2 +-
 src/lib/elementary/elm_video.c|  2 +-
 src/lib/elementary/elm_web2.c |  2 +-
 src/lib/elementary/elm_widget.c   |  2 +-
 src/lib/evas/Evas_Common.h|  7 ---
 src/lib/evas/Evas_Legacy.h| 89 +++
 src/lib/evas/canvas/evas_object_box.c |  2 +-
 src/lib/evas/canvas/evas_object_smart.c   | 17 ++---
 src/lib/evas/canvas/evas_object_smart.eo  | 83 -
 66 files changed, 161 insertions(+), 159 deletions(-)

diff --git a/src/lib/elementary/efl_ui_box.c b/src/lib/elementary/efl_ui_box.c
index eb14bff..4229871 100644
--- a/src/lib/elementary/efl_ui_box.c
+++ b/src/lib/elementary/efl_ui_box.c
@@ -259,7 +259,7 @@ _efl_ui_box_eo_base_constructor(Eo *obj, Efl_Ui_Box_Data 
*pd)
elm_interface_atspi_accessible_type_set(obj, ELM_ATSPI_TYPE_SKIPPED);
obj = eo_constructor(eo_super(obj, MY_CLASS));
evas_obj_type_set(obj, MY_CLASS_NAME);
-   evas_obj_smart_callbacks_descriptions_set(obj, _smart_callbacks);
+   evas_object_smart_callbacks_descriptions_set(obj, _smart_callbacks);
elm_interface_atspi_accessible_role_set(obj, ELM_ATSPI_ROLE_FILLER);
 
pd->orient = EFL_ORIENT_RIGHT;
diff --git a/src/lib/elementary/efl_ui_flip.c b/src/lib/elementary/efl_ui_flip.c
index 3b7f8c4..b8f86ba 100644
--- a/src/lib/elementary/efl_ui_flip.c
+++ b/src/lib/elementary/efl_ui_flip.c
@@ -1875,7 +1875,7 @@ 

[EGIT] [core/efl] master 09/11: Evas: Fix warnings in Efl.Ui.Text

2016-06-17 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=c8ee5583a961ff3d0f40c048548fe204b571cdef

commit c8ee5583a961ff3d0f40c048548fe204b571cdef
Author: Jean-Philippe Andre 
Date:   Fri Jun 17 15:35:21 2016 +0900

Evas: Fix warnings in Efl.Ui.Text

clang being overzealous with -Wmissing-field-initializers
---
 src/lib/elementary/efl_ui_internal_text_interactive.c | 8 
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/src/lib/elementary/efl_ui_internal_text_interactive.c 
b/src/lib/elementary/efl_ui_internal_text_interactive.c
index 4f2a245..514c53c 100644
--- a/src/lib/elementary/efl_ui_internal_text_interactive.c
+++ b/src/lib/elementary/efl_ui_internal_text_interactive.c
@@ -334,7 +334,7 @@ _entry_imf_event_delete_surrounding_cb(void *data, 
Ecore_IMF_Context *ctx EINA_U
Efl_Ui_Internal_Text_Interactive_Data *en = eo_data_scope_get(obj, 
MY_CLASS);
Ecore_IMF_Event_Delete_Surrounding *ev = event_info;
Evas_Textblock_Cursor *del_start, *del_end;
-   Efl_Ui_Text_Interactive_Change_Info info = {0};
+   Efl_Ui_Text_Interactive_Change_Info info = { NULL, 0, 0, 0, 0 };
int cursor_pos;
int start, end;
 
@@ -584,7 +584,7 @@ _range_del_emit(Evas_Object *obj, Efl_Canvas_Text_Cursor 
*cur1, Efl_Canvas_Text_
 {
size_t start, end;
char *tmp;
-   Efl_Ui_Text_Interactive_Change_Info info = {0};
+   Efl_Ui_Text_Interactive_Change_Info info = { NULL, 0, 0, 0, 0 };
 
start = evas_textblock_cursor_pos_get(cur1);
end = evas_textblock_cursor_pos_get(cur2);
@@ -615,7 +615,7 @@ _sel_range_del_emit(Evas_Object *obj, 
Efl_Ui_Internal_Text_Interactive_Data *en)
 static void
 _delete_emit(Evas_Textblock_Cursor *c, Efl_Ui_Internal_Text_Interactive_Data 
*en EINA_UNUSED, size_t pos)
 {
-   Efl_Ui_Text_Interactive_Change_Info info = {0};
+   Efl_Ui_Text_Interactive_Change_Info info = { NULL, 0, 0, 0, 0 };
Eina_Unicode content[2];
content[0] = efl_canvas_text_cursor_content_get(c);
content[1] = 0;
@@ -1002,7 +1002,7 @@ _key_down_cb(void *data EINA_UNUSED, Evas *e EINA_UNUSED, 
Evas_Object *obj, void
   }
 if (string)
   {
- Efl_Ui_Text_Interactive_Change_Info info = {0};
+ Efl_Ui_Text_Interactive_Change_Info info = { NULL, 0, 0, 0, 0 };
  if (en->have_selection)
{
   _sel_range_del_emit(obj, en);

-- 




[EGIT] [core/efl] master 01/01: evas: Fix type checking for legacy APIs

2016-06-19 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=17a51cffd3c5ded9364acc18a8bb3f21bfc5edf7

commit 17a51cffd3c5ded9364acc18a8bb3f21bfc5edf7
Author: Jean-Philippe Andre 
Date:   Mon Jun 20 14:04:09 2016 +0900

evas: Fix type checking for legacy APIs

This should fix canvas 3d examples (that were calling fill_set
and evas would reject with "object is not an image").
---
 src/lib/evas/canvas/evas_image_legacy.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/lib/evas/canvas/evas_image_legacy.c 
b/src/lib/evas/canvas/evas_image_legacy.c
index 08c5b90..64efbf2 100644
--- a/src/lib/evas/canvas/evas_image_legacy.c
+++ b/src/lib/evas/canvas/evas_image_legacy.c
@@ -4,7 +4,7 @@
 #include "evas_image.eo.h"
 
 #define EVAS_IMAGE_API(_o, ...) do { \
-   if (EINA_UNLIKELY(!eo_isa(_o, EVAS_IMAGE_CLASS))) { \
+   if (EINA_UNLIKELY(!eo_isa(_o, EFL_CANVAS_IMAGE_INTERNAL_CLASS))) { \
   EINA_SAFETY_ERROR("object is not an image!"); \
   return __VA_ARGS__; \
} } while (0)

-- 




[EGIT] [core/efl] master 04/04: evas 3d: Fix shader compilation with EGL

2016-06-20 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=c0dcb30c610209d862709efbce2fd62d2f1f8d7d

commit c0dcb30c610209d862709efbce2fd62d2f1f8d7d
Author: Jean-Philippe Andre 
Date:   Mon Jun 20 15:25:09 2016 +0900

evas 3d: Fix shader compilation with EGL

This fixes the following error:
 error C1059: non constant expression in initialization

It happened with the hedgehog example: evas_canvas3d_aabb
---
 .../gl_common/shader_3d/evas_gl_3d_shaders.x   | 104 ++---
 .../evas/engines/gl_common/shader_3d/include.shd   |   6 +-
 .../gl_common/shader_3d/shadow_map_frag.shd|   6 +-
 3 files changed, 32 insertions(+), 84 deletions(-)

diff --git a/src/modules/evas/engines/gl_common/shader_3d/evas_gl_3d_shaders.x 
b/src/modules/evas/engines/gl_common/shader_3d/evas_gl_3d_shaders.x
index 90aafab..a41c340 100644
--- a/src/modules/evas/engines/gl_common/shader_3d/evas_gl_3d_shaders.x
+++ b/src/modules/evas/engines/gl_common/shader_3d/evas_gl_3d_shaders.x
@@ -172,15 +172,11 @@ static const char diffuse_frag_glsl[] =
"#ifdef DIFFUSE_TEXTURE\n"
"uniform sampler2D  uTextureDiffuse0;\n"
"uniform mat3 uTextureMatrixTransformDiffuse0;\n"
-   "vec3 Tex0CoordDiffuse =\n"
-   "   vec3(vTexCoord, 1.0) * uTextureMatrixTransformDiffuse0;\n"
"#endif //DIFFUSE_TEXTURE\n"
"#ifdef DIFFUSE_TEXTURE_BLEND\n"
"uniform sampler2D  uTextureDiffuse1;\n"
"uniform float  uTextureDiffuseWeight;\n"
"uniform mat3 uTextureMatrixTransformDiffuse1;\n"
-   "vec3 Tex1CoordDiffuse =\n"
-   "   vec3(vTexCoord, 1.0) * uTextureMatrixTransformDiffuse1;\n"
"#endif //DIFFUSE_TEXTURE_BLEND\n"
"#endif //DIFFUSE\n"
"uniform int   uAlphaTestComparison;\n"
@@ -189,11 +185,13 @@ static const char diffuse_frag_glsl[] =
"   vec4  color;\n"
"   \n"
"#ifdef  DIFFUSE_TEXTURE_BLEND\n"
+   "   vec3 Tex0CoordDiffuse = vec3(vTexCoord, 1.0) * 
uTextureMatrixTransformDiffuse1;\n"
"   color = mix(texture2D(uTextureDiffuse1, vec2(Tex1CoordDiffuse)),\n"
"   texture2D(uTextureDiffuse0, vec2(Tex0CoordDiffuse)), 
uTextureDiffuseWeight);\n"
"   color *= uMaterialDiffuse;\n"
"#else\n"
"#ifdef  DIFFUSE_TEXTURE\n"
+   "   vec3 Tex0CoordDiffuse = vec3(vTexCoord, 1.0) * 
uTextureMatrixTransformDiffuse0;\n"
"   color = texture2D(uTextureDiffuse0, vec2(Tex0CoordDiffuse)) * 
uMaterialDiffuse;\n"
"#else\n"
"   color = uMaterialDiffuse;\n"
@@ -418,15 +416,11 @@ static const char flat_frag_glsl[] =
"#ifdef DIFFUSE_TEXTURE\n"
"uniform sampler2D  uTextureDiffuse0;\n"
"uniform mat3 uTextureMatrixTransformDiffuse0;\n"
-   "vec3 Tex0CoordDiffuse =\n"
-   "   vec3(vTexCoord, 1.0) * uTextureMatrixTransformDiffuse0;\n"
"#endif //DIFFUSE_TEXTURE\n"
"#ifdef DIFFUSE_TEXTURE_BLEND\n"
"uniform sampler2D  uTextureDiffuse1;\n"
"uniform float  uTextureDiffuseWeight;\n"
"uniform mat3 uTextureMatrixTransformDiffuse1;\n"
-   "vec3 Tex1CoordDiffuse =\n"
-   "   vec3(vTexCoord, 1.0) * uTextureMatrixTransformDiffuse1;\n"
"#endif //DIFFUSE_TEXTURE_BLEND\n"
"#endif //DIFFUSE\n"
"#ifdef SPECULAR\n"
@@ -436,15 +430,11 @@ static const char flat_frag_glsl[] =
"#ifdef SPECULAR_TEXTURE\n"
"uniform sampler2D  uTextureSpecular0;\n"
"uniform mat3 uTextureMatrixTransformSpecular0;\n"
-   "vec3 Tex0CoordSpecular =\n"
-   "   vec3(vTexCoord, 1.0) * uTextureMatrixTransformSpecular0;\n"
"#endif //SPECULAR_TEXTURE\n"
"#ifdef SPECULAR_TEXTURE_BLEND\n"
"uniform sampler2D  uTextureSpecular1;\n"
"uniform float  uTextureSpecularWeight;\n"
"uniform mat3 uTextureMatrixTransformSpecular1;\n"
-   "vec3 Tex1CoordSpecular =\n"
-   "   vec3(vTexCoord, 1.0) * uTextureMatrixTransformSpecular1;\n"
"#endif //SPECULAR_TEXTURE_BLEND\n"
"#endif //SPECULAR\n"
"#ifdef AMBIENT\n"
@@ -453,15 +443,11 @@ static const char flat_frag_glsl[] =
"#ifdef AMBIENT_TEXTURE\n"
"uniform sampler2D  uTextureAmbient0;\n"
"uniform mat3 uTextureMatrixTransformAmbient0;\n"
-   "vec3 Tex0CoordAmbient =\n"
-   "   vec3(vTexCoord, 1.0) * uTextureMatrixTransformAmbient0;\n"
"#endif //AMBIENT_TEXTURE\n"
"#ifdef AMBIENT_TEXTURE_BLEND\n"
"uniform sampler2D  uTextureAmbient1;\n"
"uniform float  uTextureAmbientWeight;\n"
"uniform mat3 uTextureMatrixTransformAmbient1;\n"
-   "vec3 Tex1CoordAmbient =\n"
-   "   vec3(vTexCoord, 1.0) * uTextureMatrixTransformAmbient1;\n"
"#endif //AMBIENT_TEXTURE_BLEND\n"
"#endif //AMBIENT\n"
"#ifdef EMISSION\n"
@@ -469,15 +455,11 @@ static const char flat_frag_glsl[] =
"#ifdef EMISSION_TEXTURE\n"
"uniform sampler2D  uTextureEmission0;\n"
"uniform mat3 uTextureMatrixTransformEmission0;\n"
-   "vec3 Tex0CoordEmission =\n"
-   "   vec3(vTexCoord, 1.0) * uTextureMatrixTransformEmission0;\n"
"#endif //EMISSION_TEXTURE\n"
"#ifdef EMISSION_TEXTURE_BLEND\n"
"uniform sampler2D  

[EGIT] [core/efl] master 01/04: evas: Use efl_gfx APIs where appropriate

2016-06-20 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=ccaf12e1b66b2b491fc9bd434f646528bff06526

commit ccaf12e1b66b2b491fc9bd434f646528bff06526
Author: Jean-Philippe Andre 
Date:   Mon Jun 20 14:11:32 2016 +0900

evas: Use efl_gfx APIs where appropriate

This is a better fix than the previous patch, as it keeps
the legacy API check. The point of that check is: if the object
has been created with legacy API (evas_object_image_[filled_]add,
then legacy APIs are allowed, otherwise they are disallowed. This
means only EO APIs should be used on an eo_add() image object.
---
 src/lib/evas/canvas/evas_image_legacy.c |  2 +-
 src/lib/evas/canvas/evas_object_image.c | 10 +-
 2 files changed, 6 insertions(+), 6 deletions(-)

diff --git a/src/lib/evas/canvas/evas_image_legacy.c 
b/src/lib/evas/canvas/evas_image_legacy.c
index 64efbf2..08c5b90 100644
--- a/src/lib/evas/canvas/evas_image_legacy.c
+++ b/src/lib/evas/canvas/evas_image_legacy.c
@@ -4,7 +4,7 @@
 #include "evas_image.eo.h"
 
 #define EVAS_IMAGE_API(_o, ...) do { \
-   if (EINA_UNLIKELY(!eo_isa(_o, EFL_CANVAS_IMAGE_INTERNAL_CLASS))) { \
+   if (EINA_UNLIKELY(!eo_isa(_o, EVAS_IMAGE_CLASS))) { \
   EINA_SAFETY_ERROR("object is not an image!"); \
   return __VA_ARGS__; \
} } while (0)
diff --git a/src/lib/evas/canvas/evas_object_image.c 
b/src/lib/evas/canvas/evas_object_image.c
index d179581..03aa933 100644
--- a/src/lib/evas/canvas/evas_object_image.c
+++ b/src/lib/evas/canvas/evas_object_image.c
@@ -564,8 +564,8 @@ _efl_canvas_image_internal_efl_gfx_fill_fill_auto_set(Eo 
*eo_obj, Evas_Image_Dat
  {
 Evas_Coord w, h;
 
-evas_object_geometry_get(eo_obj, NULL, NULL, , );
-evas_object_image_fill_set(eo_obj, 0, 0, w, h);
+efl_gfx_geometry_get(eo_obj, NULL, NULL, , );
+efl_gfx_fill_set(eo_obj, 0, 0, w, h);
 
 evas_object_event_callback_add(eo_obj, EVAS_CALLBACK_RESIZE,

evas_object_image_filled_resize_listener,
@@ -777,7 +777,7 @@ _efl_canvas_image_internal_efl_gfx_buffer_alpha_set(Eo 
*eo_obj, Evas_Image_Data
   }
 o->written = EINA_TRUE;
  }
-   evas_object_image_data_update_add(eo_obj, 0, 0, o->cur->image.w, 
o->cur->image.h);
+   efl_gfx_buffer_update_add(eo_obj, 0, 0, o->cur->image.w, o->cur->image.h);
EVAS_OBJECT_WRITE_IMAGE_FREE_FILE_AND_KEY(o);
 }
 
@@ -3152,10 +3152,10 @@ evas_object_image_filled_resize_listener(void *data 
EINA_UNUSED, Evas *e EINA_UN
 {
Evas_Coord w, h;
 
-   evas_object_geometry_get(obj, NULL, NULL, , );
+   efl_gfx_geometry_get(obj, NULL, NULL, , );
if (w < 1) w = 1;
if (h < 1) h = 1;
-   evas_object_image_fill_set(obj, 0, 0, w, h);
+   efl_gfx_fill_set(obj, 0, 0, w, h);
 }
 
 Eina_Bool

-- 




[EGIT] [core/efl] master 02/04: evas: Improve debug logs (print shader code)

2016-06-20 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=5964c335671b310726933a4212bf8a7f9f649158

commit 5964c335671b310726933a4212bf8a7f9f649158
Author: Jean-Philippe Andre 
Date:   Mon Jun 20 14:19:30 2016 +0900

evas: Improve debug logs (print shader code)
---
 src/modules/evas/engines/gl_common/evas_gl_3d_shader.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/src/modules/evas/engines/gl_common/evas_gl_3d_shader.c 
b/src/modules/evas/engines/gl_common/evas_gl_3d_shader.c
index 0ead38a..95be4a6 100644
--- a/src/modules/evas/engines/gl_common/evas_gl_3d_shader.c
+++ b/src/modules/evas/engines/gl_common/evas_gl_3d_shader.c
@@ -207,7 +207,8 @@ _shader_compile(GLuint shader, const char *src)
 glGetShaderiv(shader, GL_INFO_LOG_LENGTH, );
 log_str = (GLchar *)malloc(len);
 glGetShaderInfoLog(shader, len, _len, log_str);
-ERR("Shader compilation failed.\n%s", log_str);
+ERR("Shader compilation failed: %s", log_str);
+DBG("Shader source was:\n%s", src);
 free(log_str);
 
 return EINA_FALSE;

-- 




[EGIT] [core/efl] master 03/04: evas: Fix regeneration of shaders (normal and 3d)

2016-06-20 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=30ba6bfcac5fdd237e70a81026373f2036c977d8

commit 30ba6bfcac5fdd237e70a81026373f2036c977d8
Author: Jean-Philippe Andre 
Date:   Mon Jun 20 14:47:39 2016 +0900

evas: Fix regeneration of shaders (normal and 3d)

This will trigger a re-run of the shaders shell scripts even
in case of out-of-tree builds. BUILT_SOURCES is used here
because for whatever reason make does not rebuild the .x targets
in case of out-of-tree builds (even if the timestamps of
the dependencies have changed).
---
 src/Makefile_Evas.am | 9 ++---
 1 file changed, 6 insertions(+), 3 deletions(-)

diff --git a/src/Makefile_Evas.am b/src/Makefile_Evas.am
index 00a3a46..3630e4e 100644
--- a/src/Makefile_Evas.am
+++ b/src/Makefile_Evas.am
@@ -803,11 +803,12 @@ $(NULL)
 
 EXTRA_DIST2 += \
 modules/evas/engines/gl_common/shader_3d/gen_shaders_3d.sh \
+modules/evas/engines/gl_common/shader_3d/include.shd \
 $(GL_SHADERS_3D_GEN)
 
-modules/evas/engines/gl_common/shader_3d/evas_gl_3d_shaders.x: 
modules/evas/engines/gl_common/shader_3d/gen_shaders_3d.sh $(GL_SHADERS_3D_GEN)
+modules/evas/engines/gl_common/shader_3d/evas_gl_3d_shaders.x: 
modules/evas/engines/gl_common/shader_3d/gen_shaders_3d.sh $(GL_SHADERS_3D_GEN) 
modules/evas/engines/gl_common/shader_3d/include.shd
@echo "  SHADERS  $@"
-   @sh $^
+   @sh 
$(srcdir)/modules/evas/engines/gl_common/shader_3d/gen_shaders_3d.sh 
$(GL_SHADERS_3D_GEN)
 
 
 GL_GENERIC_SOURCES = \
@@ -831,7 +832,9 @@ evas_gl_generic_eolian_h = 
$(evas_gl_generic_eolian_files:%.eo=%.eo.h) \
 
 BUILT_SOURCES += \
  $(evas_gl_generic_eolian_c) \
- $(evas_gl_generic_eolian_h)
+ $(evas_gl_generic_eolian_h) \
+ modules/evas/engines/gl_common/shader_3d/evas_gl_3d_shaders.x 
\
+ modules/evas/engines/gl_common/shader/evas_gl_shaders.x
 
 EXTRA_DIST2 += $(evas_gl_generic_eolian_files)
 

-- 




[EGIT] [core/efl] master 01/01: ecore_evas: Try to fix mouse events on Windows

2016-06-20 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=a087ca84b058a499f7bb834d8e39f509587d1baa

commit a087ca84b058a499f7bb834d8e39f509587d1baa
Author: Jean-Philippe Andre 
Date:   Mon Jun 20 16:26:52 2016 +0900

ecore_evas: Try to fix mouse events on Windows

See also de5f293426965f9dc19 and T3789

I wrongly assumed that multi.{x,y} would be properly set.
I'm assuming here that multi.{x,y} == (0,0) means they are
not set, and that double comparison to 0 works fine.
---
 src/lib/ecore_evas/ecore_evas.c | 17 -
 1 file changed, 12 insertions(+), 5 deletions(-)

diff --git a/src/lib/ecore_evas/ecore_evas.c b/src/lib/ecore_evas/ecore_evas.c
index fb225ad..01b01af 100644
--- a/src/lib/ecore_evas/ecore_evas.c
+++ b/src/lib/ecore_evas/ecore_evas.c
@@ -4304,10 +4304,17 @@ ecore_evas_psl1ght_new(const char* name, int w, int h)
} while (0)
 
 static inline void
-_pointer_position_set(Efl_Event_Pointer_Data *ev, Ecore_Evas *ee, double mx, 
double my)
+_pointer_position_set(Efl_Event_Pointer_Data *ev, Ecore_Evas *ee, int x, int y,
+  double mx, double my)
 {
int fx, fy, fw, fh;
 
+   if (!mx && !my)
+ {
+mx = x;
+my = y;
+ }
+
evas_output_framespace_get(ee->evas, , , , );
if (ee->rotation == 0)
  EVENT_XY_SET(ev, mx, my, fx, fy);
@@ -4368,7 +4375,7 @@ _direct_mouse_updown(Ecore_Evas *ee, const 
Ecore_Event_Mouse_Button *info, Efl_P
if (info->triple_click) ev->button_flags |= EFL_POINTER_FLAGS_TRIPLE_CLICK;
ev->timestamp = info->timestamp;
ev->finger = info->multi.device;
-   _pointer_position_set(ev, ee, info->multi.x, info->multi.y);
+   _pointer_position_set(ev, ee, info->x, info->y, info->multi.x, 
info->multi.y);
ev->radius = info->multi.radius;
ev->radius_x = info->multi.radius_x;
ev->radius_y = info->multi.radius_y;
@@ -4425,7 +4432,7 @@ _direct_mouse_move_cb(Ecore_Evas *ee, const 
Ecore_Event_Mouse_Move *info)
ev->action = EFL_POINTER_ACTION_MOVE;
ev->timestamp = info->timestamp;
ev->finger = info->multi.device;
-   _pointer_position_set(ev, ee, info->multi.x, info->multi.y);
+   _pointer_position_set(ev, ee, info->x, info->y, info->multi.x, 
info->multi.y);
 
ev->radius = info->multi.radius;
ev->radius_x = info->multi.radius_x;
@@ -4461,7 +4468,7 @@ _direct_mouse_wheel_cb(Ecore_Evas *ee, const 
Ecore_Event_Mouse_Wheel *info)
 
ev->action = EFL_POINTER_ACTION_WHEEL;
ev->timestamp = info->timestamp;
-   _pointer_position_set(ev, ee, info->x, info->y);
+   _pointer_position_set(ev, ee, info->x, info->y, info->x, info->y);
ev->wheel.z = info->z;
ev->wheel.dir = info->direction ? EFL_ORIENT_HORIZONTAL : 
EFL_ORIENT_VERTICAL;
 
@@ -4490,7 +4497,7 @@ _direct_mouse_inout(Ecore_Evas *ee, const 
Ecore_Event_Mouse_IO *info, Efl_Pointe
 
ev->action = action;
ev->timestamp = info->timestamp;
-   _pointer_position_set(ev, ee, info->x, info->y);
+   _pointer_position_set(ev, ee, info->x, info->y, info->x, info->y);
 
eo_event_callback_call(e, _event_description_get(ev->action), evt);
processed = ev->evas_done;

-- 




[EGIT] [core/efl] master 01/01: evas: Fix usage of fill_set

2016-06-20 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=0ffa16d9cf729f16376689087b949f1e1d76a753

commit 0ffa16d9cf729f16376689087b949f1e1d76a753
Author: Jean-Philippe Andre 
Date:   Mon Jun 20 15:47:07 2016 +0900

evas: Fix usage of fill_set

efl.gfx.fill will reset the filled flag, so the internal function
needs to be called instead of the gfx api.

This test error was added in a very recent commit: ccaf12e1b66b2b49.
---
 src/lib/evas/canvas/evas_object_image.c | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/src/lib/evas/canvas/evas_object_image.c 
b/src/lib/evas/canvas/evas_object_image.c
index 03aa933..80dff1f 100644
--- a/src/lib/evas/canvas/evas_object_image.c
+++ b/src/lib/evas/canvas/evas_object_image.c
@@ -565,7 +565,7 @@ _efl_canvas_image_internal_efl_gfx_fill_fill_auto_set(Eo 
*eo_obj, Evas_Image_Dat
 Evas_Coord w, h;
 
 efl_gfx_geometry_get(eo_obj, NULL, NULL, , );
-efl_gfx_fill_set(eo_obj, 0, 0, w, h);
+_evas_image_fill_set(eo_obj, o, 0, 0, w, h);
 
 evas_object_event_callback_add(eo_obj, EVAS_CALLBACK_RESIZE,

evas_object_image_filled_resize_listener,
@@ -3150,12 +3150,13 @@ _evas_image_data_convert_internal(Evas_Image_Data *o, 
void *data, Evas_Colorspac
 static void
 evas_object_image_filled_resize_listener(void *data EINA_UNUSED, Evas *e 
EINA_UNUSED, Evas_Object *obj, void *einfo EINA_UNUSED)
 {
+   Evas_Image_Data *o = eo_data_scope_get(obj, 
EFL_CANVAS_IMAGE_INTERNAL_CLASS);
Evas_Coord w, h;
 
efl_gfx_geometry_get(obj, NULL, NULL, , );
if (w < 1) w = 1;
if (h < 1) h = 1;
-   efl_gfx_fill_set(obj, 0, 0, w, h);
+   _evas_image_fill_set(obj, o, 0, 0, w, h);
 }
 
 Eina_Bool

-- 




[EGIT] [core/efl] master 01/04: win: Add property accel_preference

2016-06-23 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=17c531658fa04a90e52e2dc32d42ce491988d04c

commit 17c531658fa04a90e52e2dc32d42ce491988d04c
Author: Jean-Philippe Andre 
Date:   Thu Jun 23 11:06:22 2016 +0900

win: Add property accel_preference

It supports the same syntax as the config value, but
overrides it. This provides a more convenient way to select
the acceleration for a single window.

Its get() value should be what was effective when the window was
created. So it can depend on the config or a previous call
to set().

@feature
---
 src/bin/elementary/test_glview.c |   9 ++-
 src/lib/elementary/efl_ui_win.c  |  70 ++
 src/lib/elementary/efl_ui_win.eo |  53 ++
 src/lib/elementary/elm_config.c  | 152 ++-
 src/lib/elementary/elm_priv.h|   2 +
 5 files changed, 204 insertions(+), 82 deletions(-)

diff --git a/src/bin/elementary/test_glview.c b/src/bin/elementary/test_glview.c
index 31c76cf..3136770 100644
--- a/src/bin/elementary/test_glview.c
+++ b/src/bin/elementary/test_glview.c
@@ -617,13 +617,14 @@ test_glview(void *data EINA_UNUSED, Evas_Object *obj 
EINA_UNUSED, void *event_in
Evas_Object *win, *bx, *bt, *gl, *lb;
Ecore_Animator *ani;
GLData *gld = NULL;
-   const char *accel;
 
// alloc a data struct to hold our relevant gl info in
if (!(gld = calloc(1, sizeof(GLData return;
gldata_init(gld);
 
+#if 0
// add a Z-depth buffer to the window and try to use GL
+   Eina_Stringshare *accel;
accel = eina_stringshare_add(elm_config_accel_preference_get());
elm_config_accel_preference_set("gl:depth");
 
@@ -634,6 +635,12 @@ test_glview(void *data EINA_UNUSED, Evas_Object *obj 
EINA_UNUSED, void *event_in
// restore previous accel preference
elm_config_accel_preference_set(accel);
eina_stringshare_del(accel);
+#else
+   win = eo_add(EFL_UI_WIN_STANDARD_CLASS, NULL,
+efl_ui_win_name_set(eo_self, "glview"),
+efl_text_set(eo_self, "GLView"),
+efl_ui_win_accel_preference_set(eo_self, "gl:depth"));
+#endif
 
bx = elm_box_add(win);
evas_object_size_hint_weight_set(bx, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
diff --git a/src/lib/elementary/efl_ui_win.c b/src/lib/elementary/efl_ui_win.c
index 26876e4..da31c73 100644
--- a/src/lib/elementary/efl_ui_win.c
+++ b/src/lib/elementary/efl_ui_win.c
@@ -188,6 +188,7 @@ struct _Efl_Ui_Win_Data
const char  *icon_name;
const char  *role;
Eina_Stringshare *name;
+   Eina_Stringshare *accel_pref;
 
Evas_Object *main_menu;
 
@@ -2538,6 +2539,7 @@ _efl_ui_win_efl_canvas_group_group_del(Eo *obj, 
Efl_Ui_Win_Data *sd)
eina_stringshare_del(sd->icon_name);
eina_stringshare_del(sd->role);
eina_stringshare_del(sd->name);
+   eina_stringshare_del(sd->accel_pref);
evas_object_del(sd->icon);
evas_object_del(sd->main_menu);
 
@@ -3920,13 +3922,19 @@ _window_layout_stack(Evas_Object *o, 
Evas_Object_Box_Data *p, void *data)
 }
 
 static Eina_Bool
-_accel_is_gl(void)
+_accel_is_gl(const char *accel)
 {
const char *env = NULL;
const char *str = NULL;
 
+   /* current elm config */
if (_elm_config->accel) str = _elm_config->accel;
if (_elm_accel_preference) str = _elm_accel_preference;
+
+   /* constructor function */
+   if (accel) str = accel;
+
+   /* global overrides */
if ((_elm_config->accel_override) && (_elm_config->accel))
  str = _elm_config->accel;
env = getenv("ELM_ACCEL");
@@ -3952,6 +3960,10 @@ _elm_win_finalize_internal(Eo *obj, Efl_Ui_Win_Data *sd, 
const char *name, Elm_W
Evas *e;
const Eina_List *l;
const char *fontpath, *engine = NULL, *enginelist[32], *disp;
+   int gl_depth = _elm_config->gl_depth;
+   int gl_stencil = _elm_config->gl_stencil;
+   int gl_msaa = _elm_config->gl_msaa;
+   Eina_Stringshare *accel = NULL;
int i, p = 0;
 
Efl_Ui_Win_Data tmp_sd;
@@ -3961,6 +3973,12 @@ _elm_win_finalize_internal(Eo *obj, Efl_Ui_Win_Data *sd, 
const char *name, Elm_W
/* just to store some data while trying out to create a canvas */
memset(_sd, 0, sizeof(Efl_Ui_Win_Data));
 
+   if (sd->accel_pref)
+ {
+_elm_config_accel_preference_parse(sd->accel_pref, , _depth,
+   _stencil, _msaa);
+ }
+
switch (type)
  {
   case ELM_WIN_FAKE:
@@ -4011,7 +4029,7 @@ _elm_win_finalize_internal(Eo *obj, Efl_Ui_Win_Data *sd, 
const char *name, Elm_W
 #ifdef HAVE_ELEMENTARY_X
 else if ((disp) && (!strcmp(disp, "x11")))
   {
- if (_accel_is_gl())
+ if (_accel_is_gl(accel))
{
   enginelist[p++] = ELM_OPENGL_X11;
   enginelist[p++] = ELM_SOFTWARE_X11;
@@ -4027,7 +4045,7 @@ _elm_win_finalize_internal(Eo *obj, Efl_Ui_Win_Data *sd, 
const char *name, Elm_W
 #ifdef HAVE_ELEMENTARY_WL2

[EGIT] [core/efl] master 04/04: evas: Fix distcheck by disabling shaders generation

2016-06-23 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=2b8912462e0ec81efb8e30a63383b811f52e16f5

commit 2b8912462e0ec81efb8e30a63383b811f52e16f5
Author: Jean-Philippe Andre 
Date:   Thu Jun 23 17:46:35 2016 +0900

evas: Fix distcheck by disabling shaders generation

make distcheck is verified by checking the env var "top_distdir"
This is not a great solution but should work.
---
 src/modules/evas/engines/gl_common/shader/gen_shaders.sh   | 7 +++
 src/modules/evas/engines/gl_common/shader_3d/gen_shaders_3d.sh | 6 ++
 2 files changed, 13 insertions(+)

diff --git a/src/modules/evas/engines/gl_common/shader/gen_shaders.sh 
b/src/modules/evas/engines/gl_common/shader/gen_shaders.sh
index 8861d95..c96f62e 100755
--- a/src/modules/evas/engines/gl_common/shader/gen_shaders.sh
+++ b/src/modules/evas/engines/gl_common/shader/gen_shaders.sh
@@ -3,9 +3,16 @@
 # This script will generate a C file containing all the shaders used by Evas
 
 DIR=`dirname $0`
+cd $DIR/../../../../../
 
 OUTPUT="$DIR/evas_gl_shaders.x"
 
+# Skip generation during make distcheck
+if [ "${top_distdir}" != "" ] ; then exit 0; fi
+
+# Skip generation if file can not be written to
+if [ ! -w ${OUTPUT} ] ; then exit 0; fi
+
 # Skip generation if there is no diff (or no git)
 if ! git rev-parse 2>> /dev/null >> /dev/null ; then exit 0 ; fi
 if git diff --quiet --exit-code -- "$DIR"
diff --git a/src/modules/evas/engines/gl_common/shader_3d/gen_shaders_3d.sh 
b/src/modules/evas/engines/gl_common/shader_3d/gen_shaders_3d.sh
index c92a239..529959d 100755
--- a/src/modules/evas/engines/gl_common/shader_3d/gen_shaders_3d.sh
+++ b/src/modules/evas/engines/gl_common/shader_3d/gen_shaders_3d.sh
@@ -7,6 +7,12 @@ cd $DIR/../../../../../
 
 OUTPUT="$DIR/evas_gl_3d_shaders.x"
 
+# Skip generation during make distcheck
+if [ "${top_distdir}" != "" ] ; then exit 0; fi
+
+# Skip generation if file can not be written to
+if [ ! -w ${OUTPUT} ] ; then exit 0; fi
+
 # Skip generation if there is no diff (or no git)
 if ! git rev-parse 2>> /dev/null >> /dev/null ; then exit 0 ; fi
 if git diff --quiet --exit-code -- "$DIR"

-- 




[EGIT] [core/efl] master 01/06: elm: Fix obvious warning (leak / typo)

2016-06-21 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=2f0b9edbb4b5e47d2d4a1380edc6ad1828134c41

commit 2f0b9edbb4b5e47d2d4a1380edc6ad1828134c41
Author: Jean-Philippe Andre 
Date:   Tue Jun 21 13:29:28 2016 +0900

elm: Fix obvious warning (leak / typo)

warning: ignoring return value of function declared with
warn_unused_result attribute [-Wunused-result]

Thanks GCC for pointing out the leak.
---
 src/lib/elementary/elc_fileselector.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/lib/elementary/elc_fileselector.c 
b/src/lib/elementary/elc_fileselector.c
index 34bce99..1944e9a 100644
--- a/src/lib/elementary/elc_fileselector.c
+++ b/src/lib/elementary/elc_fileselector.c
@@ -1697,7 +1697,7 @@ cancel:
eo_unref(obj);
eo_unref(it_data->model);
eo_unref(it_data->parent_model);
-   eina_stringshare_add(it_data->parent_path);
+   eina_stringshare_del(it_data->parent_path);
free(it_data);
 }
 

-- 




[EGIT] [core/efl] master 06/06: edje: Fix compilation of svg example (add -beta)

2016-06-21 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=dfe7e8892a547220979076832cd61fa613443e40

commit dfe7e8892a547220979076832cd61fa613443e40
Author: Jean-Philippe Andre 
Date:   Tue Jun 21 14:49:26 2016 +0900

edje: Fix compilation of svg example (add -beta)
---
 src/examples/edje/Makefile.am | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/src/examples/edje/Makefile.am b/src/examples/edje/Makefile.am
index f418cab..1317679 100644
--- a/src/examples/edje/Makefile.am
+++ b/src/examples/edje/Makefile.am
@@ -73,6 +73,9 @@ EDCS += $(PHYSICS_EDCS)
 endif
 DIST_EDCS += $(PHYSICS_EDCS)
 
+# Support for SVG
+EDJE_CC_FLAGS += -beta
+
 .edc.edj:
$(AM_V_EDJ)$(EDJE_CC) $(EDJE_CC_FLAGS) $(SND_DIR) $(MO_DIR) $< 
$(builddir)/$(@F)
 

-- 




[EGIT] [core/efl] master 02/02: examples: Fix misuse of evas image api on canvas 3d

2016-06-20 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=e2ebd8e95aecf59588e49b3395e33c72a1dec8cd

commit e2ebd8e95aecf59588e49b3395e33c72a1dec8cd
Author: Jean-Philippe Andre 
Date:   Tue Jun 21 10:16:27 2016 +0900

examples: Fix misuse of evas image api on canvas 3d

image_size_set is for legacy images
---
 src/examples/evas/evas-3d-cube-rotate.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/src/examples/evas/evas-3d-cube-rotate.c 
b/src/examples/evas/evas-3d-cube-rotate.c
index 100910b..bbd64e6 100644
--- a/src/examples/evas/evas-3d-cube-rotate.c
+++ b/src/examples/evas/evas-3d-cube-rotate.c
@@ -255,9 +255,7 @@ main(void)
 
/* Add an image object for 3D scene rendering. */
image = eo_add(EFL_CANVAS_SCENE3D_CLASS, evas);
-   evas_object_image_size_set(image, WIDTH, HEIGHT);
-   evas_object_move(image, 0, 0);
-   evas_object_resize(image, WIDTH, HEIGHT);
+   efl_gfx_geometry_set(image, 0, 0, WIDTH, HEIGHT);
evas_object_show(image);
 
/* Set the image object as render target for 3D scene. */

-- 




[EGIT] [core/efl] master 01/02: ecore: Fix _ecore_animator_shutdown (double free)

2016-06-20 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=e68e8d008846a827a758483313e4ee205a1181a5

commit e68e8d008846a827a758483313e4ee205a1181a5
Author: Jean-Philippe Andre 
Date:   Tue Jun 21 10:14:13 2016 +0900

ecore: Fix _ecore_animator_shutdown (double free)

evas 3d examples would always exit on a double free, since
EINA_INLIST_FREE was misused. Not surprising considering
it's different from EINA_LIST_FREE but has a similar name.
---
 src/lib/ecore/ecore_anim.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/src/lib/ecore/ecore_anim.c b/src/lib/ecore/ecore_anim.c
index 707916c..4bf148d 100644
--- a/src/lib/ecore/ecore_anim.c
+++ b/src/lib/ecore/ecore_anim.c
@@ -750,6 +750,8 @@ _ecore_animator_shutdown(void)
 if (animator->suspended) animators_suspended--;
 if (animator->delete_me) animators_delete_me--;
 
+animators = (Ecore_Animator *) eina_inlist_remove
+  (EINA_INLIST_GET(animators), EINA_INLIST_GET(animator));
 free(animator);
  }
 }

-- 




[EGIT] [core/efl] master 01/01: evas: Remove common interface and use provider_find

2016-06-21 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=269fc4f7a643358ac943b5454bafc14b5d14836c

commit 269fc4f7a643358ac943b5454bafc14b5d14836c
Author: Jean-Philippe Andre 
Date:   Tue Jun 21 15:45:31 2016 +0900

evas: Remove common interface and use provider_find

Evas.Common_Interface not only had a bad name, it also
wasn't in line with how we can get a loop object, for
instance.

Use eo_provider_find in each implementing class.
---
 src/Makefile_Evas.am   |  2 --
 src/lib/edje/edje_edit.c   |  2 +-
 src/lib/edje/edje_util.c   |  2 +-
 src/lib/elementary/efl_ui_grid_static.c|  2 +-
 .../elementary/efl_ui_internal_text_interactive.c  |  2 +-
 src/lib/elementary/elm_layout.c|  2 +-
 src/lib/evas/Evas_Eo.h |  2 --
 src/lib/evas/Evas_Legacy.h |  9 +++-
 src/lib/evas/canvas/efl_canvas_object.eo   |  7 +++---
 src/lib/evas/canvas/evas_canvas.eo |  5 ++--
 src/lib/evas/canvas/evas_canvas3d_camera.eo|  2 +-
 src/lib/evas/canvas/evas_canvas3d_light.eo |  2 +-
 src/lib/evas/canvas/evas_canvas3d_material.eo  |  2 +-
 src/lib/evas/canvas/evas_canvas3d_mesh.eo  |  2 +-
 src/lib/evas/canvas/evas_canvas3d_node.eo  |  2 +-
 src/lib/evas/canvas/evas_canvas3d_object.c |  6 +++--
 src/lib/evas/canvas/evas_canvas3d_object.eo|  4 ++--
 src/lib/evas/canvas/evas_canvas3d_primitive.eo |  2 +-
 src/lib/evas/canvas/evas_canvas3d_scene.eo |  2 +-
 src/lib/evas/canvas/evas_canvas3d_texture.c| 24 +--
 src/lib/evas/canvas/evas_canvas3d_texture.eo   |  2 +-
 src/lib/evas/canvas/evas_common_interface.c|  3 ---
 src/lib/evas/canvas/evas_common_interface.eo   | 15 
 src/lib/evas/canvas/evas_main.c|  9 +---
 src/lib/evas/canvas/evas_object_main.c | 27 --
 src/tests/edje/edje_test_edje.c|  8 +++
 src/tests/elementary/elm_test_layout.c |  4 ++--
 27 files changed, 76 insertions(+), 75 deletions(-)

diff --git a/src/Makefile_Evas.am b/src/Makefile_Evas.am
index b740914..d861ab6 100644
--- a/src/Makefile_Evas.am
+++ b/src/Makefile_Evas.am
@@ -8,7 +8,6 @@ evas_eolian_pub_files = \
lib/evas/canvas/efl_canvas_text.eo \
lib/evas/canvas/efl_canvas_text_cursor.eo \
lib/evas/canvas/efl_canvas_group.eo \
-   lib/evas/canvas/evas_common_interface.eo \
lib/evas/canvas/evas_canvas.eo \
lib/evas/canvas/efl_canvas_image_internal.eo \
lib/evas/canvas/efl_ui_draggable.eo \
@@ -153,7 +152,6 @@ lib_evas_libevas_la_SOURCES += \
 lib/evas/canvas/common_interfaces.c \
 lib/evas/canvas/evas_callbacks.c \
 lib/evas/canvas/evas_clip.c \
-lib/evas/canvas/evas_common_interface.c \
 lib/evas/canvas/evas_data.c \
 lib/evas/canvas/evas_device.c \
 lib/evas/canvas/evas_events.c \
diff --git a/src/lib/edje/edje_edit.c b/src/lib/edje/edje_edit.c
index ded6c81..e4f3c2a 100644
--- a/src/lib/edje/edje_edit.c
+++ b/src/lib/edje/edje_edit.c
@@ -353,7 +353,7 @@ _edje_real_part_free(Edje *ed, Edje_Real_Part *rp)
if ((rp->type == EDJE_RP_TYPE_SWALLOW) && (rp->typedata.swallow)
&& (rp->typedata.swallow->swallowed_object))
  {
-eo_parent_set(rp->typedata.swallow->swallowed_object, 
evas_common_evas_get(ed->obj));
+eo_parent_set(rp->typedata.swallow->swallowed_object, 
evas_object_evas_get(ed->obj));
 evas_object_smart_member_del(rp->typedata.swallow->swallowed_object);
 evas_object_event_callback_del(rp->typedata.swallow->swallowed_object,
EVAS_CALLBACK_FREE, 
_edje_object_part_swallow_free_cb);
diff --git a/src/lib/edje/edje_util.c b/src/lib/edje/edje_util.c
index caae67b..fead840 100644
--- a/src/lib/edje/edje_util.c
+++ b/src/lib/edje/edje_util.c
@@ -5101,7 +5101,7 @@ _eo_unparent_helper(Eo *child, Eo *parent)
 {
if (eo_parent_get(child) == parent)
  {
-eo_parent_set(child, evas_common_evas_get(parent));
+eo_parent_set(child, evas_object_evas_get(parent));
  }
 }
 
diff --git a/src/lib/elementary/efl_ui_grid_static.c 
b/src/lib/elementary/efl_ui_grid_static.c
index 8069f01..05855ab 100644
--- a/src/lib/elementary/efl_ui_grid_static.c
+++ b/src/lib/elementary/efl_ui_grid_static.c
@@ -35,7 +35,7 @@ _efl_ui_grid_static_efl_pack_layout_layout_do(Eo_Class *klass 
EINA_UNUSED,
gd = eo_data_scope_get(obj, EFL_UI_GRID_CLASS);
if (!gd->items) return;
 
-   e = evas_common_evas_get(obj);
+   e = evas_object_evas_get(obj);
eo_event_freeze(e);
 
efl_gfx_position_get(obj, , );
diff --git a/src/lib/elementary/efl_ui_internal_text_interactive.c 
b/src/lib/elementary/efl_ui_internal_text_interactive.c
index 0286727..a856403 100644
--- 

[EGIT] [core/efl] master 01/01: evas: Fix redefinition of Efl_Canvas_Object type

2016-06-21 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=e445e1bb084b3458b34c36e66c583e5c56f98c15

commit e445e1bb084b3458b34c36e66c583e5c56f98c15
Author: Jean-Philippe Andre 
Date:   Tue Jun 21 16:28:41 2016 +0900

evas: Fix redefinition of Efl_Canvas_Object type
---
 src/lib/evas/Evas_Common.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/lib/evas/Evas_Common.h b/src/lib/evas/Evas_Common.h
index 28e88c2..cb090d9 100644
--- a/src/lib/evas/Evas_Common.h
+++ b/src/lib/evas/Evas_Common.h
@@ -165,7 +165,7 @@ typedef Efl_Canvas_Object  Evas_Object;
 
 /* These defines are used in H files generated by Eolian to avoid
  * redefinition of types */
-#define _EVAS_OBJECT_EO_CLASS_TYPE
+#define _EFL_CANVAS_OBJECT_EO_CLASS_TYPE
 #define _EFL_VG_EO_CLASS_TYPE
 
 /**

-- 




[EGIT] [core/efl] master 02/05: Evas: Stop using Evas.Image in public inheritance

2016-06-15 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=74e1c9bb7591228d988b189812b206dc5575ac9c

commit 74e1c9bb7591228d988b189812b206dc5575ac9c
Author: Jean-Philippe Andre 
Date:   Thu Jun 16 11:06:04 2016 +0900

Evas: Stop using Evas.Image in public inheritance

So, it seems my previous commit 79abba52c50840c043e4b was a job
half done, as I forgot to remove Evas.Image from the inheritance
tree of all new evas image classes.
---
 src/lib/evas/canvas/efl_canvas_image.eo| 4 +++-
 src/lib/evas/canvas/efl_canvas_proxy.eo| 2 +-
 src/lib/evas/canvas/efl_canvas_scene3d.eo  | 2 +-
 src/lib/evas/canvas/efl_canvas_snapshot.eo | 2 +-
 src/lib/evas/canvas/efl_canvas_surface.eo  | 2 +-
 5 files changed, 7 insertions(+), 5 deletions(-)

diff --git a/src/lib/evas/canvas/efl_canvas_image.eo 
b/src/lib/evas/canvas/efl_canvas_image.eo
index d1cfd22..cb34c03 100644
--- a/src/lib/evas/canvas/efl_canvas_image.eo
+++ b/src/lib/evas/canvas/efl_canvas_image.eo
@@ -1,4 +1,6 @@
-class Efl.Canvas.Image (Evas.Image, Efl.Gfx.Buffer, Efl.Image.Load, 
Efl.Image.Animated)
+class Efl.Canvas.Image (Efl.Canvas.Image.Internal, Efl.Gfx.Buffer,
+Efl.Image.Load, Efl.Image.Animated,
+Efl.File)
 {
[[Low-level Image object.
 
diff --git a/src/lib/evas/canvas/efl_canvas_proxy.eo 
b/src/lib/evas/canvas/efl_canvas_proxy.eo
index aff0e8b..45a283a 100644
--- a/src/lib/evas/canvas/efl_canvas_proxy.eo
+++ b/src/lib/evas/canvas/efl_canvas_proxy.eo
@@ -1,4 +1,4 @@
-class Efl.Canvas.Proxy (Evas.Image, Efl.Gfx.Buffer)
+class Efl.Canvas.Proxy (Efl.Canvas.Image.Internal, Efl.Gfx.Buffer)
 {
[[Low-level proxy image object.
 
diff --git a/src/lib/evas/canvas/efl_canvas_scene3d.eo 
b/src/lib/evas/canvas/efl_canvas_scene3d.eo
index 4df2239..ee5df99 100644
--- a/src/lib/evas/canvas/efl_canvas_scene3d.eo
+++ b/src/lib/evas/canvas/efl_canvas_scene3d.eo
@@ -1,4 +1,4 @@
-class Efl.Canvas.Scene3d (Evas.Image, Efl.Gfx.Buffer)
+class Efl.Canvas.Scene3d (Efl.Canvas.Image.Internal, Efl.Gfx.Buffer)
 {
[[A UI view for EFL Canvas 3D.]]
data: null;
diff --git a/src/lib/evas/canvas/efl_canvas_snapshot.eo 
b/src/lib/evas/canvas/efl_canvas_snapshot.eo
index b2234ec..b9f5c10 100644
--- a/src/lib/evas/canvas/efl_canvas_snapshot.eo
+++ b/src/lib/evas/canvas/efl_canvas_snapshot.eo
@@ -1,4 +1,4 @@
-class Efl.Canvas.Snapshot (Evas.Image)
+class Efl.Canvas.Snapshot (Efl.Canvas.Image.Internal)
 {
[[Low-level snapshot image object.
 
diff --git a/src/lib/evas/canvas/efl_canvas_surface.eo 
b/src/lib/evas/canvas/efl_canvas_surface.eo
index b393296..b973c04 100644
--- a/src/lib/evas/canvas/efl_canvas_surface.eo
+++ b/src/lib/evas/canvas/efl_canvas_surface.eo
@@ -1,4 +1,4 @@
-mixin Efl.Canvas.Surface (Eo.Interface, Evas.Image)
+mixin Efl.Canvas.Surface (Eo.Interface, Efl.Canvas.Image.Internal)
 {
[[Native surfaces usually bound to an externally-managed buffer.
 

-- 




[EGIT] [core/efl] master 03/05: Evas: Fix usage of callback arrays

2016-06-15 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=da1e53820bf1786e2ada9be5e9f9ae7bb0704020

commit da1e53820bf1786e2ada9be5e9f9ae7bb0704020
Author: Jean-Philippe Andre 
Date:   Thu Jun 16 11:16:12 2016 +0900

Evas: Fix usage of callback arrays

This should fix compilation of EFL for Windows (at least
this is one more step...)

- evas box
- evas table
---
 src/lib/evas/canvas/evas_object_box.c   | 11 +--
 src/lib/evas/canvas/evas_object_table.c | 11 +--
 2 files changed, 10 insertions(+), 12 deletions(-)

diff --git a/src/lib/evas/canvas/evas_object_box.c 
b/src/lib/evas/canvas/evas_object_box.c
index d99ac4f..415a671 100644
--- a/src/lib/evas/canvas/evas_object_box.c
+++ b/src/lib/evas/canvas/evas_object_box.c
@@ -167,17 +167,16 @@ _evas_object_box_option_new(Evas_Object *o, 
Evas_Object_Box_Data *priv EINA_UNUS
return opt;
 }
 
-static const Eo_Callback_Array_Item evas_object_box_callbacks[] = {
+EO_CALLBACKS_ARRAY_DEFINE(evas_object_box_callbacks,
   { EFL_GFX_EVENT_RESIZE, _on_child_resize },
   { EO_EVENT_DEL, _on_child_del },
-  { EFL_GFX_EVENT_CHANGE_SIZE_HINTS, _on_child_hints_changed },
-  { NULL, NULL }
-};
+  { EFL_GFX_EVENT_CHANGE_SIZE_HINTS, _on_child_hints_changed }
+);
 
 static void
 _evas_object_box_child_callbacks_unregister(Evas_Object *obj, Evas_Object 
*parent)
 {
-   eo_event_callback_array_del(obj, evas_object_box_callbacks, parent);
+   eo_event_callback_array_del(obj, evas_object_box_callbacks(), parent);
 }
 
 static Evas_Object_Box_Option *
@@ -185,7 +184,7 @@ _evas_object_box_option_callbacks_register(Evas_Object *o, 
Evas_Object_Box_Data
 {
Evas_Object *obj = opt->obj;
 
-   eo_event_callback_array_add(obj, evas_object_box_callbacks, o);
+   eo_event_callback_array_add(obj, evas_object_box_callbacks(), o);
 
return opt;
 }
diff --git a/src/lib/evas/canvas/evas_object_table.c 
b/src/lib/evas/canvas/evas_object_table.c
index dd6d74e..f6c4486 100644
--- a/src/lib/evas/canvas/evas_object_table.c
+++ b/src/lib/evas/canvas/evas_object_table.c
@@ -263,22 +263,21 @@ _on_child_hints_changed(void *data, const Eo_Event *event 
EINA_UNUSED)
return EO_CALLBACK_CONTINUE;
 }
 
-static const Eo_Callback_Array_Item evas_object_table_callbacks[] = {
+EO_CALLBACKS_ARRAY_DEFINE(evas_object_table_callbacks,
   { EVAS_OBJECT_EVENT_DEL, _on_child_del },
-  { EFL_GFX_EVENT_CHANGE_SIZE_HINTS, _on_child_hints_changed },
-  { NULL, NULL }
-};
+  { EFL_GFX_EVENT_CHANGE_SIZE_HINTS, _on_child_hints_changed }
+);
 
 static void
 _evas_object_table_child_connect(Evas_Object *o, Evas_Object *child)
 {
-   eo_event_callback_array_add(child, evas_object_table_callbacks, o);
+   eo_event_callback_array_add(child, evas_object_table_callbacks(), o);
 }
 
 static void
 _evas_object_table_child_disconnect(Evas_Object *o, Evas_Object *child)
 {
-   eo_event_callback_array_del(child, evas_object_table_callbacks, o);
+   eo_event_callback_array_del(child, evas_object_table_callbacks(), o);
 }
 
 static void

-- 




[EGIT] [core/efl] master 01/05: Efl: Move Efl.Canvas to efl/interfaces

2016-06-15 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=d97c07d6750e88e9804845d555c150ef3a70651a

commit d97c07d6750e88e9804845d555c150ef3a70651a
Author: Jean-Philippe Andre 
Date:   Thu Jun 16 10:52:18 2016 +0900

Efl: Move Efl.Canvas to efl/interfaces

Not sure this is a good name for this interface, but it
definitely doesn't belong inside lib/evas/

Thanks Jiyoun for the question / report :)
---
 src/Makefile_Efl.am   | 1 +
 src/Makefile_Evas.am  | 1 -
 src/lib/efl/Efl.h | 2 ++
 src/lib/{evas/canvas => efl/interfaces}/efl_canvas.eo | 0
 src/lib/efl/interfaces/efl_interfaces_main.c  | 1 +
 src/lib/evas/Evas_Eo.h| 2 --
 src/lib/evas/canvas/evas_main.c   | 1 -
 7 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/src/Makefile_Efl.am b/src/Makefile_Efl.am
index 924d491..9fbc616 100644
--- a/src/Makefile_Efl.am
+++ b/src/Makefile_Efl.am
@@ -8,6 +8,7 @@ efl_eolian_legacy_files = \
$(NULL)
 
 efl_eolian_files = \
+  lib/efl/interfaces/efl_canvas.eo \
   lib/efl/interfaces/efl_control.eo \
   lib/efl/interfaces/efl_file.eo \
   lib/efl/interfaces/efl_image_load.eo \
diff --git a/src/Makefile_Evas.am b/src/Makefile_Evas.am
index f2168c1..87dcb70 100644
--- a/src/Makefile_Evas.am
+++ b/src/Makefile_Evas.am
@@ -3,7 +3,6 @@
 
 evas_eolian_pub_files = \
lib/evas/canvas/evas_object.eo \
-   lib/evas/canvas/efl_canvas.eo \
lib/evas/canvas/efl_canvas_polygon.eo \
lib/evas/canvas/efl_canvas_rectangle.eo \
lib/evas/canvas/evas_textblock.eo \
diff --git a/src/lib/efl/Efl.h b/src/lib/efl/Efl.h
index 8effe42..547f975 100644
--- a/src/lib/efl/Efl.h
+++ b/src/lib/efl/Efl.h
@@ -123,6 +123,8 @@ static inline void efl_gfx_color16_type_set(Efl_Gfx_Color 
*color,
 
 #include "interfaces/efl_gfx.x"
 
+#include "interfaces/efl_canvas.eo.h"
+
 /* Packing & containers */
 #include "interfaces/efl_container.eo.h"
 #include "interfaces/efl_pack.eo.h"
diff --git a/src/lib/evas/canvas/efl_canvas.eo 
b/src/lib/efl/interfaces/efl_canvas.eo
similarity index 100%
rename from src/lib/evas/canvas/efl_canvas.eo
rename to src/lib/efl/interfaces/efl_canvas.eo
diff --git a/src/lib/efl/interfaces/efl_interfaces_main.c 
b/src/lib/efl/interfaces/efl_interfaces_main.c
index 10ae01a..9acc833 100644
--- a/src/lib/efl/interfaces/efl_interfaces_main.c
+++ b/src/lib/efl/interfaces/efl_interfaces_main.c
@@ -27,6 +27,7 @@
 #include "interfaces/efl_gfx_filter.eo.c"
 
 #include "interfaces/efl_gfx_size_hint.eo.c"
+#include "interfaces/efl_canvas.eo.c"
 
 #include "interfaces/efl_vpath.eo.c"
 
diff --git a/src/lib/evas/Evas_Eo.h b/src/lib/evas/Evas_Eo.h
index c620f5c..2468db1 100644
--- a/src/lib/evas/Evas_Eo.h
+++ b/src/lib/evas/Evas_Eo.h
@@ -9,8 +9,6 @@
 #include "canvas/efl_ui_selectable.eo.h"
 #include "canvas/efl_ui_zoomable.eo.h"
 
-#include "canvas/efl_canvas.eo.h"
-
 #include "canvas/evas_canvas.eo.h"
 
 /**
diff --git a/src/lib/evas/canvas/evas_main.c b/src/lib/evas/canvas/evas_main.c
index 16d3314..2251e8d 100644
--- a/src/lib/evas/canvas/evas_main.c
+++ b/src/lib/evas/canvas/evas_main.c
@@ -874,5 +874,4 @@ evas_output_viewport_get(const Evas *eo_e, Evas_Coord *x, 
Evas_Coord *y, Evas_Co
if (h) *h = e->viewport.h;
 }
 
-#include "canvas/efl_canvas.eo.c"
 #include "canvas/evas_canvas.eo.c"

-- 




[EGIT] [core/efl] master 05/05: examples: Use EO_CALLBACKS_ARRAY_DEFINE in all examples

2016-06-15 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=3340745c65ef8b8361dc6eff5e746f7ce1104378

commit 3340745c65ef8b8361dc6eff5e746f7ce1104378
Author: Jean-Philippe Andre 
Date:   Thu Jun 16 13:02:19 2016 +0900

examples: Use EO_CALLBACKS_ARRAY_DEFINE in all examples

Again, for Windows.
---
 src/examples/emotion/emotion_border_example.c  |  8 +++-
 src/examples/emotion/emotion_generic_example.c |  8 +++-
 src/examples/emotion/emotion_signals_example.c | 11 ---
 3 files changed, 6 insertions(+), 21 deletions(-)

diff --git a/src/examples/emotion/emotion_border_example.c 
b/src/examples/emotion/emotion_border_example.c
index aac68fd..67c43a9 100644
--- a/src/examples/emotion/emotion_border_example.c
+++ b/src/examples/emotion/emotion_border_example.c
@@ -167,14 +167,12 @@ _canvas_resize_cb(Ecore_Evas *ee)
evas_object_resize(em, w - 20, h - 20);
 }
 
-static const Eo_Callback_Array_Item emotion_object_example_callbacks[] = {
+EO_CALLBACKS_ARRAY_DEFINE(emotion_object_example_callbacks,
{ EMOTION_OBJECT_EVENT_FRAME_DECODE, _frame_decode_cb },
{ EMOTION_OBJECT_EVENT_LENGTH_CHANGE, _length_change_cb },
{ EMOTION_OBJECT_EVENT_POSITION_UPDATE, _position_update_cb },
{ EMOTION_OBJECT_EVENT_PROGRESS_CHANGE, _progress_change_cb },
-   { EMOTION_OBJECT_EVENT_FRAME_RESIZE, _frame_resize_cb },
-   { NULL, NULL }
-};
+   { EMOTION_OBJECT_EVENT_FRAME_RESIZE, _frame_resize_cb });
 
 int
 main(int argc, const char *argv[])
@@ -234,7 +232,7 @@ main(int argc, const char *argv[])
 
ecore_evas_data_set(ee, "emotion", em);
 
-   eo_event_callback_array_add(em, emotion_object_example_callbacks, NULL);
+   eo_event_callback_array_add(em, emotion_object_example_callbacks(), NULL);
 
evas_object_event_callback_add(bg, EVAS_CALLBACK_KEY_DOWN, _on_key_down, 
em);
evas_object_focus_set(bg, EINA_TRUE);
diff --git a/src/examples/emotion/emotion_generic_example.c 
b/src/examples/emotion/emotion_generic_example.c
index ec15a61..f0d7fab 100644
--- a/src/examples/emotion/emotion_generic_example.c
+++ b/src/examples/emotion/emotion_generic_example.c
@@ -164,13 +164,11 @@ _progress_change_cb(void *data EINA_UNUSED, const 
Eo_Event *ev)
return EINA_TRUE;
 }
 
-static const Eo_Callback_Array_Item emotion_object_example_callbacks[] = {
+EO_CALLBACKS_ARRAY_DEFINE(emotion_object_example_callbacks,
{ EMOTION_OBJECT_EVENT_FRAME_DECODE, _frame_decode_cb },
{ EMOTION_OBJECT_EVENT_LENGTH_CHANGE, _length_change_cb },
{ EMOTION_OBJECT_EVENT_POSITION_UPDATE, _position_update_cb },
-   { EMOTION_OBJECT_EVENT_PROGRESS_CHANGE, _progress_change_cb },
-   { NULL, NULL }
-};
+   { EMOTION_OBJECT_EVENT_PROGRESS_CHANGE, _progress_change_cb });
 
 int
 main(int argc, const char *argv[])
@@ -221,7 +219,7 @@ main(int argc, const char *argv[])
evas_object_resize(em, WIDTH, HEIGHT);
evas_object_show(em);
 
-   eo_event_callback_array_add(em, emotion_object_example_callbacks, NULL);
+   eo_event_callback_array_add(em, emotion_object_example_callbacks(), NULL);
 
evas_object_event_callback_add(bg, EVAS_CALLBACK_KEY_DOWN, _on_key_down, 
em);
evas_object_focus_set(bg, EINA_TRUE);
diff --git a/src/examples/emotion/emotion_signals_example.c 
b/src/examples/emotion/emotion_signals_example.c
index 1a9dcbd..ecf30a7 100644
--- a/src/examples/emotion/emotion_signals_example.c
+++ b/src/examples/emotion/emotion_signals_example.c
@@ -98,17 +98,6 @@ _frame_resize_cb(void *data EINA_UNUSED, const Eo_Event *ev)
return EINA_TRUE;
 }
 
-static const Eo_Callback_Array_Item emotion_object_example_callbacks[] = {
-   { EMOTION_OBJECT_EVENT_PLAYBACK_STARTED, _playback_started_cb },
-   { EMOTION_OBJECT_EVENT_PLAYBACK_FINISHED, _playback_finished_cb },
-   { EMOTION_OBJECT_EVENT_OPEN_DONE, _open_done_cb },
-   { EMOTION_OBJECT_EVENT_POSITION_UPDATE, _position_update_cb },
-   { EMOTION_OBJECT_EVENT_FRAME_DECODE, _frame_decode_cb },
-   { EMOTION_OBJECT_EVENT_DECODE_STOP, _decode_stop_cb },
-   { EMOTION_OBJECT_EVENT_FRAME_RESIZE, _frame_resize_cb },
-   { NULL, NULL }
-};
-
 static void
 _setup_emotion_callbacks(Evas_Object *o)
 {

-- 




[EGIT] [core/efl] master 04/05: tests: Use EO_CALLBACKS_ARRAY_DEFINE in all tests

2016-06-15 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=2d995fdedc6ac67bb9b7fabb38a7b4e1b3e663c9

commit 2d995fdedc6ac67bb9b7fabb38a7b4e1b3e663c9
Author: Jean-Philippe Andre 
Date:   Thu Jun 16 13:01:50 2016 +0900

tests: Use EO_CALLBACKS_ARRAY_DEFINE in all tests

This should make them work on Windows, too.
---
 src/tests/emotion/emotion_test_main-eo.c |  9 
 src/tests/eo/suite/eo_test_general.c | 37 
 2 files changed, 23 insertions(+), 23 deletions(-)

diff --git a/src/tests/emotion/emotion_test_main-eo.c 
b/src/tests/emotion/emotion_test_main-eo.c
index f5b6702..c5adbe1 100644
--- a/src/tests/emotion/emotion_test_main-eo.c
+++ b/src/tests/emotion/emotion_test_main-eo.c
@@ -597,7 +597,7 @@ video_obj_signal_frame_move_cb(void *data EINA_UNUSED, 
Evas_Object *o, const cha
  }
 }
 
-static const Eo_Callback_Array_Item emotion_object_test_callbacks[] = {
+EO_CALLBACKS_ARRAY_DEFINE(emotion_object_test_callbacks,
{ EMOTION_OBJECT_EVENT_FRAME_DECODE, video_obj_frame_decode_cb },
{ EMOTION_OBJECT_EVENT_FRAME_RESIZE, video_obj_frame_resize_cb },
{ EMOTION_OBJECT_EVENT_LENGTH_CHANGE, video_obj_length_change_cb },
@@ -608,9 +608,8 @@ static const Eo_Callback_Array_Item 
emotion_object_test_callbacks[] = {
{ EMOTION_OBJECT_EVENT_PROGRESS_CHANGE, video_obj_progress_cb },
{ EMOTION_OBJECT_EVENT_REF_CHANGE, video_obj_ref_cb },
{ EMOTION_OBJECT_EVENT_BUTTON_NUM_CHANGE, video_obj_button_num_cb },
-   { EMOTION_OBJECT_EVENT_BUTTON_CHANGE, video_obj_button_cb },
-   { NULL, NULL }
-};
+   { EMOTION_OBJECT_EVENT_BUTTON_CHANGE, video_obj_button_cb }
+);
 
 static void
 init_video_object(const char *module_filename, const char *filename)
@@ -653,7 +652,7 @@ init_video_object(const char *module_filename, const char 
*filename)
edje_obj_size_min_calc(oe, , );
efl_gfx_size_set(oe, w, h);
 
-   eo_event_callback_array_add(o, emotion_object_test_callbacks, oe);
+   eo_event_callback_array_add(o, emotion_object_test_callbacks(), oe);
 
edje_obj_signal_callback_add(oe, "video_control", "play", 
video_obj_signal_play_cb, o);
edje_obj_signal_callback_add(oe, "video_control", "pause", 
video_obj_signal_pause_cb, o);
diff --git a/src/tests/eo/suite/eo_test_general.c 
b/src/tests/eo/suite/eo_test_general.c
index ddbe098..d92ce5c 100644
--- a/src/tests/eo/suite/eo_test_general.c
+++ b/src/tests/eo/suite/eo_test_general.c
@@ -151,42 +151,43 @@ Eina_Bool
 _eo_signals_cb_added_deled(void *data, const Eo_Event *event)
 {
const Eo_Callback_Array_Item *callback_array = event->info;
+   const Eo_Callback_Array_Item *(*callback_data)(void) = data;
 
-   fail_if((callback_array != data) &&
- (callback_array->func != _eo_signals_cb_added_deled));
+   fail_if((callback_data() != callback_array) &&
+   (callback_array->func != _eo_signals_cb_added_deled));
 
return EO_CALLBACK_CONTINUE;
 }
 
+EO_CALLBACKS_ARRAY_DEFINE(_eo_signals_callbacks,
+{ EV_A_CHANGED, _eo_signals_a_changed_cb },
+{ EV_A_CHANGED, _eo_signals_a_changed_cb2 },
+{ EV_A_CHANGED, _eo_signals_a_changed_never },
+{ EO_EVENT_DEL, _eo_signals_eo_del_cb });
+
 START_TEST(eo_signals)
 {
eo_init();
-   static const Eo_Callback_Array_Item callbacks[] = {
-  { EV_A_CHANGED, _eo_signals_a_changed_cb },
-  { EV_A_CHANGED, _eo_signals_a_changed_cb2 },
-  { EV_A_CHANGED, _eo_signals_a_changed_never },
-  { EO_EVENT_DEL, _eo_signals_eo_del_cb },
-  { NULL, NULL }
-   };
+
Eo *obj = eo_add(SIMPLE_CLASS, NULL);
Eina_Bool r;
 
-   eo_event_callback_add(obj, EO_EVENT_CALLBACK_ADD, 
_eo_signals_cb_added_deled, callbacks);
-   r = eo_event_callback_add(obj, EO_EVENT_CALLBACK_DEL, 
_eo_signals_cb_added_deled, callbacks);
+   eo_event_callback_add(obj, EO_EVENT_CALLBACK_ADD, 
_eo_signals_cb_added_deled, &_eo_signals_callbacks);
+   r = eo_event_callback_add(obj, EO_EVENT_CALLBACK_DEL, 
_eo_signals_cb_added_deled, &_eo_signals_callbacks);
fail_if(!r);
-   eo_event_callback_array_priority_add(obj, callbacks, -100, (void *) 1);
-   eo_event_callback_array_add(obj, callbacks, (void *) 3);
-   r = eo_event_callback_array_priority_add(obj, callbacks, -50, (void *) 2);
+   eo_event_callback_array_priority_add(obj, _eo_signals_callbacks(), -100, 
(void *) 1);
+   eo_event_callback_array_add(obj, _eo_signals_callbacks(), (void *) 3);
+   r = eo_event_callback_array_priority_add(obj, _eo_signals_callbacks(), -50, 
(void *) 2);
fail_if(!r);
simple_a_set(obj, 1);
ck_assert_int_eq(_eo_signals_cb_flag, 0x3);
 
-   eo_event_callback_array_del(obj, callbacks, (void *) 1);
-   eo_event_callback_array_del(obj, callbacks, (void *) 2);
-   r = eo_event_callback_array_del(obj, callbacks, (void *) 3);
+   eo_event_callback_array_del(obj, _eo_signals_callbacks(), (void *) 1);
+   eo_event_callback_array_del(obj, _eo_signals_callbacks(), (void *) 

[EGIT] [core/efl] master 03/09: config: Add support for some enums

2016-06-24 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=8b8430214a6559a0a540b298b768e49a39f84113

commit 8b8430214a6559a0a540b298b768e49a39f84113
Author: Jean-Philippe Andre 
Date:   Thu Jun 23 18:46:04 2016 +0900

config: Add support for some enums
---
 src/lib/elementary/elm_config.c| 106 +
 src/lib/elementary/elm_widget.eo   |   2 +-
 src/tests/elementary/elm_test_config.c |  15 +++--
 3 files changed, 108 insertions(+), 15 deletions(-)

diff --git a/src/lib/elementary/elm_config.c b/src/lib/elementary/elm_config.c
index 9d08a2e..7cdb925 100644
--- a/src/lib/elementary/elm_config.c
+++ b/src/lib/elementary/elm_config.c
@@ -4264,8 +4264,16 @@ typedef const char * cstring;
 static inline Eina_Bool
 _eina_value_to_int(const Eina_Value *val, int *i)
 {
-   Eina_Value *ival = eina_value_new(EINA_VALUE_TYPE_INT);
-   Eina_Bool ret = EINA_TRUE;
+   Eina_Value *ival;
+   Eina_Bool ret;
+
+   if (eina_value_type_get(val) == EINA_VALUE_TYPE_INT)
+ {
+eina_value_get(val, i);
+return EINA_TRUE;
+ }
+
+   ival = eina_value_new(EINA_VALUE_TYPE_INT);
if (!eina_value_convert(val, ival))
  ret = EINA_FALSE;
else
@@ -4287,6 +4295,43 @@ _eina_value_to_cstring(const Eina_Value *val, cstring *s)
return ret;
 }
 
+static const struct {
+   Efl_Ui_Focus_Autoscroll_Mode  val;
+   const char   *str;
+} _enum_map_focus_autoscroll_mode[] = {
+{ EFL_UI_FOCUS_AUTOSCROLL_MODE_SHOW, "show" },
+{ EFL_UI_FOCUS_AUTOSCROLL_MODE_NONE, "none" },
+{ EFL_UI_FOCUS_AUTOSCROLL_MODE_BRING_IN, "bring_in" }
+};
+
+static const struct {
+   Efl_Ui_Softcursor_Mode  val;
+   const char *str;
+} _enum_map_softcursor_mode[] = {
+{ EFL_UI_SOFTCURSOR_MODE_AUTO, "auto" },
+{ EFL_UI_SOFTCURSOR_MODE_ON, "on" },
+{ EFL_UI_SOFTCURSOR_MODE_OFF, "off" }
+};
+
+static const struct {
+   Efl_Ui_Slider_Indicator_Visible_Mode  val;
+   const char   *str;
+} _enum_map_slider_indicator_visible_mode[] = {
+{ EFL_UI_SLIDER_INDICATOR_VISIBLE_MODE_DEFAULT, "default" },
+{ EFL_UI_SLIDER_INDICATOR_VISIBLE_MODE_ALWAYS, "always" },
+{ EFL_UI_SLIDER_INDICATOR_VISIBLE_MODE_ON_FOCUS, "on_focus" },
+{ EFL_UI_SLIDER_INDICATOR_VISIBLE_MODE_NONE, "none" },
+};
+
+static const struct {
+   Efl_Ui_Focus_Move_Policy  val;
+   const char   *str;
+} _enum_map_focus_move_policy[] = {
+{ EFL_UI_FOCUS_MOVE_POLICY_CLICK, "click" },
+{ EFL_UI_FOCUS_MOVE_POLICY_IN, "in" },
+{ EFL_UI_FOCUS_MOVE_POLICY_KEY_ONLY, "key_only" }
+};
+
 EOLIAN static Eina_Bool
 _efl_config_internal_efl_config_config_set(Eo *obj EINA_UNUSED, void *_pd 
EINA_UNUSED,
const char *name, const Eina_Value 
*val)
@@ -4326,6 +4371,35 @@ _efl_config_internal_efl_config_config_set(Eo *obj 
EINA_UNUSED, void *_pd EINA_U
 #define CONFIG_SETD(opt) CONFIG_SET(opt, double, DOUBLE, int)
 #define CONFIG_SETS(opt) CONFIG_SET(opt, const char *, STRING, cstring)
 
+#define CONFIG_SETE(opt) do { \
+   if (!strcmp(name, #opt)) \
+ { \
+int v = -1; \
+if (eina_value_type_get(val) == EINA_VALUE_TYPE_STRING) \
+  { \
+ const char *str; \
+ eina_value_get(val, ); \
+ for (unsigned i = 0; i < (sizeof(_enum_map_ ## opt) / 
sizeof(_enum_map_ ## opt[0])); i++) \
+   { \
+ if (eina_streq(_enum_map_ ## opt[i].str, str)) { v = 
_enum_map_ ## opt[i].val; break; } \
+   } \
+ if (v == -1) \
+   { \
+ ERR("Invalid value for config '%s' (got '%s')", #opt, str); \
+ return EINA_FALSE; \
+   } \
+  } \
+else if (!_eina_value_to_int(val, )) \
+  { \
+ ERR("Invalid value type for config '%s' (got %s wanted int or 
string)", \
+ name, eina_value_type_name_get(eina_value_type_get(val))); \
+ return EINA_FALSE; \
+  } \
+elm_config_ ## opt ## _set(v); \
+return EINA_TRUE; \
+ } \
+   } while (0)
+
CONFIG_SETB(scroll_bounce_enabled);
CONFIG_SETD(scroll_bounce_friction);
CONFIG_SETD(scroll_page_scroll_friction);
@@ -4350,10 +4424,10 @@ _efl_config_internal_efl_config_config_set(Eo *obj 
EINA_UNUSED, void *_pd EINA_U
CONFIG_SETD(scroll_thumbscroll_acceleration_threshold);
CONFIG_SETD(scroll_thumbscroll_acceleration_time_limit);
CONFIG_SETD(scroll_thumbscroll_acceleration_weight);
-   //focus_autoscroll_mode Elm_Focus_Autoscroll_Mode mode);
-   //slider_indicator_visible_mode Elm_Slider_Indicator_Visible_Mode mode);
+   CONFIG_SETE(focus_autoscroll_mode);
+   CONFIG_SETE(slider_indicator_visible_mode);
CONFIG_SETD(longpress_timeout);
-   //softcursor_mode Elm_Softcursor_Mode mode);
+   CONFIG_SETE(softcursor_mode);
CONFIG_SETD(tooltip_delay);
CONFIG_SETB(cursor_engine_only);
CONFIG_SETD(scale);
@@ -4379,7 +4453,7 

[EGIT] [core/efl] master 02/09: elm: EO-ify some elm_config enums

2016-06-24 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=575c704b0206e416986bade8c1012bded20381f8

commit 575c704b0206e416986bade8c1012bded20381f8
Author: Jean-Philippe Andre 
Date:   Thu Jun 23 16:45:32 2016 +0900

elm: EO-ify some elm_config enums

Elm_Focus_Autoscroll_Mode
Elm_Softcursor_Mode
Elm_Slider_Indicator_Visible_Mode (rename only)
Elm_Focus_Move_Policy (rename only)

This is for Efl.Config API.
---
 src/lib/elementary/elm_config.h| 20 
 src/lib/elementary/elm_general.eot | 29 -
 src/lib/elementary/elm_general.h   | 24 
 src/lib/elementary/elm_slider.eo   |  2 +-
 4 files changed, 49 insertions(+), 26 deletions(-)

diff --git a/src/lib/elementary/elm_config.h b/src/lib/elementary/elm_config.h
index e6238a7..125ec77 100644
--- a/src/lib/elementary/elm_config.h
+++ b/src/lib/elementary/elm_config.h
@@ -793,19 +793,6 @@ EAPI double   
elm_config_scroll_thumbscroll_acceleration_weight_get(void);
 EAPI void elm_config_scroll_thumbscroll_acceleration_weight_set(double 
weight);
 
 /**
- * Focus Autoscroll Mode
- *
- * @since 1.10
- * @ingroup Elm_Focus
- */
-typedef enum
-{
-   ELM_FOCUS_AUTOSCROLL_MODE_SHOW, /**< directly show the focused region or 
item automatically */
-   ELM_FOCUS_AUTOSCROLL_MODE_NONE, /**< do not show the focused region or item 
automatically */
-   ELM_FOCUS_AUTOSCROLL_MODE_BRING_IN /**< bring_in the focused region or item 
automatically which might invole the scrolling */
-} Elm_Focus_Autoscroll_Mode;
-
-/**
  * Get focus auto scroll mode.
  *
  * When a region or an item is focused and it resides inside any scroller,
@@ -881,13 +868,6 @@ EAPI double   elm_config_longpress_timeout_get(void);
  */
 EAPI void elm_config_longpress_timeout_set(double longpress_timeout);
 
-typedef enum _Elm_Softcursor_Mode
-{
-   ELM_SOFTCURSOR_MODE_AUTO, /**< Auto-detect if a software cursor should be 
used (default) */
-   ELM_SOFTCURSOR_MODE_ON, /**< Always use a softcursor */
-   ELM_SOFTCURSOR_MODE_OFF /**< Never use a softcursor */
-} Elm_Softcursor_Mode; /**< @since 1.7 */
-
 /**
  * Set the mode used for software provided mouse cursors inline in the window
  * canvas.
diff --git a/src/lib/elementary/elm_general.eot 
b/src/lib/elementary/elm_general.eot
index 43920a4..eed0c98 100644
--- a/src/lib/elementary/elm_general.eot
+++ b/src/lib/elementary/elm_general.eot
@@ -200,7 +200,7 @@ enum Elm.Focus.Region.Show_Mode
item, [[As an item.]]
 }
 
-enum Elm.Focus.Move_Policy
+enum Efl.Ui.Focus.Move_Policy
 {
[[Focus Movement Policy.
  @since 1.10]]
@@ -252,11 +252,10 @@ enum Elm.Prefs.Item_Type
swallow [[swallow type, bound to an empty 'spot' on the UI meant to receive 
and display external content]]
 }
 
-
-enum Elm.Slider.Indicator_Visible_Mode
+enum Efl.Ui.Slider.Indicator_Visible_Mode
 {
-   [[
- Slider's indicator visiblity mode.
+   [[Slider's indicator visiblity mode.
+
  @since 1.13
]]
default,   [[show indicator on mouse down or change in slider value]]
@@ -265,4 +264,24 @@ enum Elm.Slider.Indicator_Visible_Mode
none   [[Never show the indicator ]]
 }
 
+enum Efl.Ui.Focus.Autoscroll_Mode
+{
+   [[Focus Autoscroll Mode
+
+ @since 1.10
+   ]]
+   show,[[Directly show the focused region or item automatically.]]
+   none,[[Do not show the focused region or item automatically.]]
+   bring_in [[Bring in the focused region or item automatically which might 
invole the scrolling.]]
+}
 
+enum Efl.Ui.Softcursor_Mode
+{
+   [[Software cursor mode.
+
+ @since 1.7
+   ]]
+   auto, [[Auto-detect if a software cursor should be used (default).]]
+   on,   [[Always use a softcursor.]]
+   off   [[Never use a softcursor.]]
+}
diff --git a/src/lib/elementary/elm_general.h b/src/lib/elementary/elm_general.h
index 365331e..b2d72b7 100644
--- a/src/lib/elementary/elm_general.h
+++ b/src/lib/elementary/elm_general.h
@@ -304,6 +304,30 @@ typedef enum _Elm_Process_State
  */
 EAPI Elm_Process_State  elm_process_state_get(void);
 
+
+/* legacy to eo translation */
+
+typedef Efl_Ui_Focus_Autoscroll_Mode   Elm_Focus_Autoscroll_Mode;
+#define ELM_FOCUS_AUTOSCROLL_MODE_SHOW EFL_UI_FOCUS_AUTOSCROLL_MODE_SHOW
+#define ELM_FOCUS_AUTOSCROLL_MODE_NONE EFL_UI_FOCUS_AUTOSCROLL_MODE_NONE
+#define ELM_FOCUS_AUTOSCROLL_MODE_BRING_IN 
EFL_UI_FOCUS_AUTOSCROLL_MODE_BRING_IN
+
+typedef Efl_Ui_Softcursor_Mode Elm_Softcursor_Mode;
+#define ELM_SOFTCURSOR_MODE_AUTO   EFL_UI_SOFTCURSOR_MODE_AUTO
+#define ELM_SOFTCURSOR_MODE_ON EFL_UI_SOFTCURSOR_MODE_ON
+#define ELM_SOFTCURSOR_MODE_OFFEFL_UI_SOFTCURSOR_MODE_OFF
+
+typedef Efl_Ui_Slider_Indicator_Visible_Mode   
Elm_Slider_Indicator_Visible_Mode;
+#define ELM_SLIDER_INDICATOR_VISIBLE_MODE_DEFAULT  
EFL_UI_SLIDER_INDICATOR_VISIBLE_MODE_DEFAULT
+#define 

[EGIT] [core/efl] master 05/09: config: Implement support for audio_mute

2016-06-24 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=3ee261780a0f1bf227eb491d2be0974374133192

commit 3ee261780a0f1bf227eb491d2be0974374133192
Author: Jean-Philippe Andre 
Date:   Thu Jun 23 20:02:41 2016 +0900

config: Implement support for audio_mute

Instead of being a key "audio_mute" + another key "channel"
I've simply implemented a number of different keys:
audio_mute (= all)
audio_mute_all
audio_mute_effect
...
---
 src/lib/elementary/elm_config.c| 70 +-
 src/tests/elementary/elm_test_config.c | 28 +-
 2 files changed, 95 insertions(+), 3 deletions(-)

diff --git a/src/lib/elementary/elm_config.c b/src/lib/elementary/elm_config.c
index 73b65db..14a3c72 100644
--- a/src/lib/elementary/elm_config.c
+++ b/src/lib/elementary/elm_config.c
@@ -4295,6 +4295,36 @@ _eina_value_to_cstring(const Eina_Value *val, cstring *s)
return ret;
 }
 
+static inline Eina_Bool
+_edje_channel_get(const char *channel, Edje_Channel *chan)
+{
+
+   if (!*channel)
+ *chan = EDJE_CHANNEL_ALL;
+   else
+ {
+if (!strcmp("_effect", channel))
+  *chan = EDJE_CHANNEL_EFFECT;
+else if (!strcmp("_background", channel))
+  *chan = EDJE_CHANNEL_BACKGROUND;
+else if (!strcmp("_music", channel))
+  *chan = EDJE_CHANNEL_MUSIC;
+else if (!strcmp("_foreground", channel))
+  *chan = EDJE_CHANNEL_FOREGROUND;
+else if (!strcmp("_interface", channel))
+  *chan = EDJE_CHANNEL_INTERFACE;
+else if (!strcmp("_input", channel))
+  *chan = EDJE_CHANNEL_INPUT;
+else if (!strcmp("_alert", channel))
+  *chan = EDJE_CHANNEL_ALERT;
+else if (!strcmp("_all", channel))
+  *chan = EDJE_CHANNEL_ALL;
+else
+  return EINA_FALSE;
+ }
+   return EINA_TRUE;
+}
+
 static const struct {
Efl_Ui_Focus_Autoscroll_Mode  val;
const char   *str;
@@ -4463,7 +4493,6 @@ _efl_config_internal_efl_config_config_set(Eo *obj 
EINA_UNUSED, void *_pd EINA_U
//elm_config.h:EAPI void  elm_config_color_overlay_unset(const char 
*color_class);
CONFIG_SETB(magnifier_enable);
CONFIG_SETD(magnifier_scale);
-   //audio_mute Edje_Channel channel,);
CONFIG_SETB(window_auto_focus_enable);
CONFIG_SETB(window_auto_focus_animate);
CONFIG_SETB(popup_scrollable);
@@ -4471,6 +4500,27 @@ _efl_config_internal_efl_config_config_set(Eo *obj 
EINA_UNUSED, void *_pd EINA_U
CONFIG_SETD(transition_duration_factor);
CONFIG_SETS(web_backend);
 
+   const size_t len = sizeof("audio_mute") - 1;
+   if (!strncmp(name, "audio_mute", len))
+ {
+const char *channel = name + len;
+Edje_Channel chan;
+int v;
+if (!_eina_value_to_int(val, ))
+  {
+ ERR("Invalid value type for config '%s' (got %s wanted int)",
+ name, eina_value_type_name_get(eina_value_type_get(val)));
+ return EINA_FALSE;
+  }
+if (!_edje_channel_get(channel, ))
+  {
+ ERR("Unknown audio channel '%s'", channel);
+ return EINA_FALSE;
+  }
+elm_config_audio_mute_set(chan, !!v);
+return EINA_TRUE;
+ }
+
ERR("Config '%s' does not exist", name);
return EINA_FALSE;
 }
@@ -4575,7 +4625,6 @@ _efl_config_internal_efl_config_config_get(const Eo *obj 
EINA_UNUSED, void *_pd
//color_overlay_unset
CONFIG_GETB(magnifier_enable);
CONFIG_GETD(magnifier_scale);
-   //audio_mute
CONFIG_GETB(window_auto_focus_enable);
CONFIG_GETB(window_auto_focus_animate);
CONFIG_GETB(popup_scrollable);
@@ -4583,6 +4632,23 @@ _efl_config_internal_efl_config_config_get(const Eo *obj 
EINA_UNUSED, void *_pd
CONFIG_GETD(transition_duration_factor);
CONFIG_GETS(web_backend);
 
+   const size_t len = sizeof("audio_mute") - 1;
+   if (!strncmp(name, "audio_mute", len))
+ {
+const char *channel = name + len;
+Edje_Channel chan;
+Eina_Bool b;
+if (!_edje_channel_get(channel, ))
+  {
+ ERR("Unknown audio channel '%s'", channel);
+ return NULL;
+  }
+val = eina_value_new(EINA_VALUE_TYPE_UCHAR);
+b = edje_audio_channel_mute_get(chan);
+eina_value_set(val, b);
+return val;
+ }
+
ERR("Config '%s' does not exist", name);
return NULL;
 }
diff --git a/src/tests/elementary/elm_test_config.c 
b/src/tests/elementary/elm_test_config.c
index bdedc11..51eee4f 100644
--- a/src/tests/elementary/elm_test_config.c
+++ b/src/tests/elementary/elm_test_config.c
@@ -108,7 +108,6 @@ START_TEST (elm_config_eoapi)
//color_overlay_unset
CONFIG_CHKB(magnifier_enable, 0);
CONFIG_CHKD(magnifier_scale, 0);
-   //audio_mute
CONFIG_CHKB(window_auto_focus_enable, 0);
CONFIG_CHKB(window_auto_focus_animate, 0);

[EGIT] [core/efl] master 06/09: config: Add support for profiles and save

2016-06-24 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=54e515bdca1dca97efbd60ee1a3800ae1cabc095

commit 54e515bdca1dca97efbd60ee1a3800ae1cabc095
Author: Jean-Philippe Andre 
Date:   Thu Jun 23 21:29:55 2016 +0900

config: Add support for profiles and save

Most of these functions actually shouldn't be used by
standard applications. Some are hidden behind @protected.

flush_all() and reload() have not been implemented, on
purpose (save() should flush, and reload is automatic).
---
 configure.ac  |   1 +
 src/Makefile_Elementary.am|   2 +-
 src/lib/elementary/Elementary.h.in|   1 +
 src/lib/elementary/efl_config_global.eo   | 113 ++
 src/lib/elementary/efl_config_internal.eo |  10 ---
 src/lib/elementary/elm_config.c   | 129 +++---
 src/lib/elementary/elm_widget.c   |   2 +-
 7 files changed, 237 insertions(+), 21 deletions(-)

diff --git a/configure.ac b/configure.ac
index 666f39b..bba3e2a 100644
--- a/configure.ac
+++ b/configure.ac
@@ -6369,3 +6369,4 @@ if test "x${efl_deprecated_option}" = "xyes"; then
   echo "#---#"
 fi
 
+
diff --git a/src/Makefile_Elementary.am b/src/Makefile_Elementary.am
index fbe6e08..3e81fbc 100644
--- a/src/Makefile_Elementary.am
+++ b/src/Makefile_Elementary.am
@@ -141,12 +141,12 @@ elm_public_eolian_files = \
 lib/elementary/efl_ui_text_interactive.eo \
lib/elementary/efl_ui_text.eo \
lib/elementary/efl_ui_text_editable.eo \
+   lib/elementary/efl_config_global.eo \
$(NULL)
 
 # Private classes (not exposed or shipped)
 elm_private_eolian_files = \
lib/elementary/efl_ui_internal_text_interactive.eo \
-   lib/elementary/efl_config_internal.eo \
$(NULL)
 
 # Legacy classes - not part of public EO API
diff --git a/src/lib/elementary/Elementary.h.in 
b/src/lib/elementary/Elementary.h.in
index 405afc1..0257805 100644
--- a/src/lib/elementary/Elementary.h.in
+++ b/src/lib/elementary/Elementary.h.in
@@ -269,6 +269,7 @@ EAPI extern Elm_Version *elm_version;
 #include 
 
 #ifdef EFL_EO_API_SUPPORT
+# include 
 # include 
 # include 
 # include 
diff --git a/src/lib/elementary/efl_config_global.eo 
b/src/lib/elementary/efl_config_global.eo
new file mode 100644
index 000..ae26b34
--- /dev/null
+++ b/src/lib/elementary/efl_config_global.eo
@@ -0,0 +1,113 @@
+class Efl.Config.Global (Eo.Base, Efl.Config)
+{
+   [[This class is a singleton representing the global configuration for the
+ running application.
+   ]]
+   data: null;
+   eo_prefix: efl_config;
+   methods {
+  save @protected {
+ [[Saves Elementary configuration to disk.
+
+   This function will take effect (does I/O) immediately. Use it when
+   you want to save all configuration changes at once. The current
+   configuration set will get saved onto the current profile
+   configuration file.
+
+   If $profile is $null, this will flush all settings to all
+   applications running on the same profile.
+
+   If $profile is not $null, this will take the current in-memory
+   config and write it out to the named $profile. This will not
+   change profile for the application or make other processes switch
+   profile.
+ ]]
+ params {
+profile: string @optional; [[The profile name.]]
+ }
+ return: bool;
+  }
+  @property profile {
+ [[The profile for the running application.
+
+   Profiles are pre-set options that affect the whole look-and-feel of
+   Elementary-based applications. There are, for example, profiles
+   aimed at desktop computer applications and others aimed at mobile,
+   touchscreen-based ones. You most probably don't want to use the
+   functions in this group unless you're writing an elementary
+   configuration manager.
+
+   This gets or sets the global profile that is applied to all
+   Elementary applications.
+ ]]
+ values {
+profile: string;
+ }
+  }
+  profile_iterate {
+ [[Returns the list of available profiles.]]
+ params {
+hidden: bool @optional; [[If $true, gets the full list of profiles,
+  including those stored in hidden files.]]
+ }
+ return: free(own(iterator), eina_iterator_free);
+  }
+  profile_exists {
+ [[Returns whether a profile exists or not.]]
+ params {
+profile: string;
+ }
+ return: bool;
+  }
+  profile_dir_get {
+ [[Returns the directory where a profile is stored.]]
+ params {
+profile: string;
+is_user: bool; [[$true to lookup 

[EGIT] [core/efl] master 04/09: config: Simplify Efl.Config API, make C helpers only

2016-06-24 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=07613bf2f6ef322e6a4b9cf68249b3b8297788b7

commit 07613bf2f6ef322e6a4b9cf68249b3b8297788b7
Author: Jean-Philippe Andre 
Date:   Thu Jun 23 19:33:34 2016 +0900

config: Simplify Efl.Config API, make C helpers only

This removes the mixin functions and uses static inline functions
instead. Much cleaner, looks the same to C devs.
---
 src/Makefile_Efl.am  |   1 -
 src/lib/efl/Efl.h|   4 -
 src/lib/efl/interfaces/efl_config.c  | 128 ---
 src/lib/efl/interfaces/efl_config.eo |  91 +--
 src/lib/efl/interfaces/efl_interfaces_main.c |   1 +
 src/lib/elementary/elm_config.c  |  18 ++--
 src/lib/elementary/elm_config.h  |  99 +
 src/lib/elementary/elm_widget.c  |   2 +-
 src/tests/elementary/elm_test_config.c   |   9 +-
 9 files changed, 117 insertions(+), 236 deletions(-)

diff --git a/src/Makefile_Efl.am b/src/Makefile_Efl.am
index 0a3e521..eb976e9 100644
--- a/src/Makefile_Efl.am
+++ b/src/Makefile_Efl.am
@@ -83,7 +83,6 @@ lib_LTLIBRARIES += lib/efl/libefl.la
 
 lib_efl_libefl_la_SOURCES = \
 lib/efl/interfaces/efl_interfaces_main.c \
-lib/efl/interfaces/efl_config.c \
 lib/efl/interfaces/efl_model_common.c \
 lib/efl/interfaces/efl_gfx_shape.c \
 lib/efl/interfaces/efl_vpath_file.c \
diff --git a/src/lib/efl/Efl.h b/src/lib/efl/Efl.h
index 731f318..4d5629e 100644
--- a/src/lib/efl/Efl.h
+++ b/src/lib/efl/Efl.h
@@ -141,10 +141,6 @@ static inline void efl_gfx_color16_type_set(Efl_Gfx_Color 
*color,
 #include "interfaces/efl_input_interface.eo.h"
 #include "interfaces/efl_event.eo.h"
 
-#ifdef EFL_EFL_BUILD
-EAPI void __efl_internal_elm_config_set(Efl_Config *cfg);
-#endif
-
 #else
 
 #ifndef EFL_NOLEGACY_API_SUPPORT
diff --git a/src/lib/efl/interfaces/efl_config.c 
b/src/lib/efl/interfaces/efl_config.c
deleted file mode 100644
index 75d8388..000
--- a/src/lib/efl/interfaces/efl_config.c
+++ /dev/null
@@ -1,128 +0,0 @@
-#ifdef HAVE_CONFIG_H
-# include 
-#endif
-
-#include 
-
-static Efl_Config *_main_config = NULL;
-
-EAPI void
-__efl_internal_elm_config_set(Efl_Config *cfg)
-{
-   _main_config = cfg;
-}
-
-EOLIAN static Eina_Bool
-_efl_config_config_bool_set(Eo *obj, void *_pd EINA_UNUSED, const char * name, 
Eina_Bool val)
-{
-   Eina_Value *v = eina_value_new(EINA_VALUE_TYPE_UCHAR);
-   Eina_Bool b;
-   eina_value_set(v, val);
-   b = efl_config_set(obj, name, v);
-   eina_value_free(v);
-   return b;
-}
-
-EOLIAN static Eina_Bool
-_efl_config_config_bool_get(Eo *obj, void *_pd EINA_UNUSED, const char * name)
-{
-   Eina_Value *v = efl_config_get(obj, name);
-   Eina_Bool b = 0;
-   eina_value_get(v, );
-   eina_value_free(v);
-   return b;
-}
-
-EOLIAN static Eina_Bool
-_efl_config_config_int_set(Eo *obj, void *_pd EINA_UNUSED, const char * name, 
int val)
-{
-   Eina_Value *v = eina_value_new(EINA_VALUE_TYPE_INT);
-   Eina_Bool b;
-   eina_value_set(v, val);
-   b = efl_config_set(obj, name, v);
-   eina_value_free(v);
-   return b;
-}
-
-EOLIAN static int
-_efl_config_config_int_get(Eo *obj, void *_pd EINA_UNUSED, const char * name)
-{
-   Eina_Value *v = efl_config_get(obj, name);
-   int b = 0;
-   eina_value_get(v, );
-   eina_value_free(v);
-   return b;
-}
-
-EOLIAN static Eina_Bool
-_efl_config_config_uint_set(Eo *obj, void *_pd EINA_UNUSED, const char * name, 
unsigned int val)
-{
-   Eina_Value *v = eina_value_new(EINA_VALUE_TYPE_UINT);
-   Eina_Bool b;
-   eina_value_set(v, val);
-   b = efl_config_set(obj, name, v);
-   eina_value_free(v);
-   return b;
-}
-
-EOLIAN static unsigned int
-_efl_config_config_uint_get(Eo *obj, void *_pd EINA_UNUSED, const char * name)
-{
-   Eina_Value *v = efl_config_get(obj, name);
-   unsigned int b = 0;
-   eina_value_get(v, );
-   eina_value_free(v);
-   return b;
-}
-
-EOLIAN static Eina_Bool
-_efl_config_config_double_set(Eo *obj, void *_pd EINA_UNUSED, const char * 
name, double val)
-{
-   Eina_Value *v = eina_value_new(EINA_VALUE_TYPE_DOUBLE);
-   Eina_Bool b;
-   eina_value_set(v, val);
-   b = efl_config_set(obj, name, v);
-   eina_value_free(v);
-   return b;
-}
-
-EOLIAN static double
-_efl_config_config_double_get(Eo *obj, void *_pd EINA_UNUSED, const char * 
name)
-{
-   Eina_Value *v = efl_config_get(obj, name);
-   double b = 0;
-   eina_value_get(v, );
-   eina_value_free(v);
-   return b;
-}
-
-EOLIAN static Eina_Bool
-_efl_config_config_string_set(Eo *obj, void *_pd EINA_UNUSED, const char 
*name, const char *val)
-{
-   Eina_Value *v = eina_value_new(EINA_VALUE_TYPE_STRING);
-   Eina_Bool b;
-   eina_value_set(v, val);
-   b = efl_config_set(obj, name, v);
-   eina_value_free(v);
-   return b;
-}
-
-EOLIAN static const char *
-_efl_config_config_string_get(Eo *obj, void *_pd EINA_UNUSED, const char *name)
-{
-   Eina_Value *v = efl_config_get(obj, 

[EGIT] [core/efl] master 08/09: config: Test profile APIs

2016-06-24 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=d299515788ac451d8b9fbf5b68b9ccedf5c419bb

commit d299515788ac451d8b9fbf5b68b9ccedf5c419bb
Author: Jean-Philippe Andre 
Date:   Thu Jun 23 21:54:11 2016 +0900

config: Test profile APIs
---
 src/tests/elementary/elm_test_config.c | 67 +-
 1 file changed, 65 insertions(+), 2 deletions(-)

diff --git a/src/tests/elementary/elm_test_config.c 
b/src/tests/elementary/elm_test_config.c
index f74d492..a30860e 100644
--- a/src/tests/elementary/elm_test_config.c
+++ b/src/tests/elementary/elm_test_config.c
@@ -142,8 +142,6 @@ START_TEST (elm_config_eoapi)
   fail(channels[i].name);
  }
 
-
-
elm_shutdown();
 }
 END_TEST
@@ -167,9 +165,74 @@ START_TEST (elm_config_win)
 }
 END_TEST
 
+static inline Eina_Bool
+_eina_list_string_has(const Eina_List *list, const char *str)
+{
+   const char *s;
+   Eina_List *l;
+
+   EINA_LIST_FOREACH(list, l, s)
+ if (eina_streq(str, s))
+   return EINA_TRUE;
+
+   return EINA_FALSE;
+}
+
+START_TEST (elm_config_profiles)
+{
+   elm_init(1, NULL);
+
+   // this only tests some of the profile APIs. we're not going to mess with
+   // the global config during make check :)
+
+   Eo *cfg = eo_provider_find(ecore_main_loop_get(), EFL_CONFIG_INTERFACE);
+   fail_if(!cfg);
+
+   for (int hidden = 0; hidden <= 1; hidden++)
+ {
+Eina_List *list;
+Eina_Iterator *it;
+const char *prof;
+int cnt = 0;
+
+list = (!hidden) ? elm_config_profile_list_get()
+ : elm_config_profile_list_full_get();
+it = efl_config_profile_iterate(cfg, hidden);
+EINA_ITERATOR_FOREACH(it, prof)
+  {
+ fail_if(!_eina_list_string_has(list, prof));
+ cnt++;
+  }
+fail_if(cnt != eina_list_count(list));
+elm_config_profile_list_free(list);
+eina_iterator_free(it);
+ }
+
+   const char *dir, *profile;
+   Eina_Stringshare *str;
+
+   profile = elm_config_profile_get();
+   dir = elm_config_profile_dir_get(elm_config_profile_get(), EINA_TRUE);
+   str = efl_config_profile_dir_get(cfg, profile, EINA_TRUE);
+   fail_if(!eina_streq(dir, str));
+   elm_config_profile_dir_free(dir);
+   eina_stringshare_del(str);
+
+   dir = elm_config_profile_dir_get(elm_config_profile_get(), EINA_FALSE);
+   str = efl_config_profile_dir_get(cfg, profile, EINA_FALSE);
+   fail_if(!eina_streq(dir, str));
+   elm_config_profile_dir_free(dir);
+   eina_stringshare_del(str);
+
+   fail_if(!elm_config_profile_exists(profile));
+
+   elm_shutdown();
+}
+END_TEST
 
 void elm_test_config(TCase *tc)
 {
tcase_add_test(tc, elm_config_eoapi);
tcase_add_test(tc, elm_config_win);
+   tcase_add_test(tc, elm_config_profiles);
 }

-- 




[EGIT] [core/efl] master 07/09: win: Attach config API with eo compositing

2016-06-24 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=0f6268ff44ad3f4f75340b0a171c1f7418e4291e

commit 0f6268ff44ad3f4f75340b0a171c1f7418e4291e
Author: Jean-Philippe Andre 
Date:   Thu Jun 23 21:39:33 2016 +0900

win: Attach config API with eo compositing
---
 src/lib/elementary/efl_ui_win.c|  3 +++
 src/tests/elementary/elm_test_config.c | 25 -
 2 files changed, 27 insertions(+), 1 deletion(-)

diff --git a/src/lib/elementary/efl_ui_win.c b/src/lib/elementary/efl_ui_win.c
index da31c73..9c2d16f 100644
--- a/src/lib/elementary/efl_ui_win.c
+++ b/src/lib/elementary/efl_ui_win.c
@@ -4568,6 +4568,9 @@ _elm_win_finalize_internal(Eo *obj, Efl_Ui_Win_Data *sd, 
const char *name, Elm_W
if (_elm_config->atspi_mode)
  elm_interface_atspi_window_created_signal_emit(obj);
 
+   // attach config API
+   eo_composite_attach(obj, eo_provider_find(ecore_main_loop_get(), 
EFL_CONFIG_GLOBAL_CLASS));
+
eo_event_callback_array_add(obj, _elm_win_evas_feed_fake_callbacks(), 
sd->evas);
eo_event_callback_add(obj, EO_EVENT_CALLBACK_ADD, _win_event_add_cb, sd);
eo_event_callback_add(obj, EO_EVENT_CALLBACK_DEL, _win_event_del_cb, sd);
diff --git a/src/tests/elementary/elm_test_config.c 
b/src/tests/elementary/elm_test_config.c
index 51eee4f..f74d492 100644
--- a/src/tests/elementary/elm_test_config.c
+++ b/src/tests/elementary/elm_test_config.c
@@ -142,11 +142,34 @@ START_TEST (elm_config_eoapi)
   fail(channels[i].name);
  }
 
+
+
elm_shutdown();
 }
 END_TEST
 
+START_TEST (elm_config_win)
+{
+   elm_init(1, NULL);
+
+   Eo *cfg = eo_provider_find(ecore_main_loop_get(), EFL_CONFIG_INTERFACE);
+   fail_if(!cfg);
+
+   Eo *win = eo_add(EFL_UI_WIN_CLASS, NULL);
+   Eo *cfg2 = eo_provider_find(win, EFL_CONFIG_INTERFACE);
+   fail_if(cfg != cfg2);
+
+   elm_config_cache_flush_interval_set(42);
+   fail_if(efl_config_int_get(win, "cache_flush_interval") != 42);
+
+   eo_del(win);
+   elm_shutdown();
+}
+END_TEST
+
+
 void elm_test_config(TCase *tc)
 {
- tcase_add_test(tc, elm_config_eoapi);
+   tcase_add_test(tc, elm_config_eoapi);
+   tcase_add_test(tc, elm_config_win);
 }

-- 




[EGIT] [core/efl] master 01/09: efl: Introduce general Efl.Config API

2016-06-24 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=47a1fae200c824672c06c6b63a098dc54af033a4

commit 47a1fae200c824672c06c6b63a098dc54af033a4
Author: Jean-Philippe Andre 
Date:   Tue Jun 21 17:54:56 2016 +0900

efl: Introduce general Efl.Config API

This is to port elm_config to EO APIs.

The current implementation relies on the legacy API, by
simply forwarding calls.

The new API is simply efl_config_set("config_name", value)
where value is an Eina_Value (aka. generic_value).
The C interface proposes a few helpers like config_int_set,
config_double_set, etc...

Unfortunately at the moment, not all config options are
supported, as some rely on more complex types:
- lists
- color class and multiple arguments
- unset functions
- enums

Profiles are also not handled at this point.

@feature
---
 src/Makefile_Efl.am   |   2 +
 src/Makefile_Elementary.am|   2 +
 src/lib/efl/Efl.h |   5 +
 src/lib/efl/interfaces/efl_config.c   | 128 ++
 src/lib/efl/interfaces/efl_config.eo  | 119 +
 src/lib/elementary/efl_config_internal.eo |  10 ++
 src/lib/elementary/efl_ui_win.eo  |   2 +-
 src/lib/elementary/elm_config.c   | 266 ++
 src/lib/elementary/elm_priv.h |   1 +
 src/lib/elementary/elm_widget.c   |   3 +
 src/tests/elementary/elm_suite.c  |   1 +
 src/tests/elementary/elm_suite.h  |   1 +
 src/tests/elementary/elm_test_config.c| 120 ++
 13 files changed, 659 insertions(+), 1 deletion(-)

diff --git a/src/Makefile_Efl.am b/src/Makefile_Efl.am
index c8fe1f0..0a3e521 100644
--- a/src/Makefile_Efl.am
+++ b/src/Makefile_Efl.am
@@ -9,6 +9,7 @@ efl_eolian_legacy_files = \
 
 efl_eolian_files = \
   lib/efl/interfaces/efl_canvas.eo \
+  lib/efl/interfaces/efl_config.eo \
   lib/efl/interfaces/efl_control.eo \
   lib/efl/interfaces/efl_file.eo \
   lib/efl/interfaces/efl_image_load.eo \
@@ -82,6 +83,7 @@ lib_LTLIBRARIES += lib/efl/libefl.la
 
 lib_efl_libefl_la_SOURCES = \
 lib/efl/interfaces/efl_interfaces_main.c \
+lib/efl/interfaces/efl_config.c \
 lib/efl/interfaces/efl_model_common.c \
 lib/efl/interfaces/efl_gfx_shape.c \
 lib/efl/interfaces/efl_vpath_file.c \
diff --git a/src/Makefile_Elementary.am b/src/Makefile_Elementary.am
index 27948de..fbe6e08 100644
--- a/src/Makefile_Elementary.am
+++ b/src/Makefile_Elementary.am
@@ -146,6 +146,7 @@ elm_public_eolian_files = \
 # Private classes (not exposed or shipped)
 elm_private_eolian_files = \
lib/elementary/efl_ui_internal_text_interactive.eo \
+   lib/elementary/efl_config_internal.eo \
$(NULL)
 
 # Legacy classes - not part of public EO API
@@ -1338,6 +1339,7 @@ tests_elementary_elm_suite_SOURCES = \
tests/elementary/elm_test_slideshow.c \
tests/elementary/elm_test_spinner.c \
tests/elementary/elm_test_plug.c \
+   tests/elementary/elm_test_config.c \
tests/elementary/elm_code_file_test_load.c \
tests/elementary/elm_code_file_test_memory.c \
tests/elementary/elm_code_test_basic.c \
diff --git a/src/lib/efl/Efl.h b/src/lib/efl/Efl.h
index c5ff46b..731f318 100644
--- a/src/lib/efl/Efl.h
+++ b/src/lib/efl/Efl.h
@@ -68,6 +68,7 @@ typedef struct tm Efl_Time;
 typedef Efl_Gfx_Path_Command_Type Efl_Gfx_Path_Command;
 
 /* Interfaces */
+#include "interfaces/efl_config.eo.h"
 #include "interfaces/efl_control.eo.h"
 #include "interfaces/efl_file.eo.h"
 #include "interfaces/efl_image.eo.h"
@@ -140,6 +141,10 @@ static inline void efl_gfx_color16_type_set(Efl_Gfx_Color 
*color,
 #include "interfaces/efl_input_interface.eo.h"
 #include "interfaces/efl_event.eo.h"
 
+#ifdef EFL_EFL_BUILD
+EAPI void __efl_internal_elm_config_set(Efl_Config *cfg);
+#endif
+
 #else
 
 #ifndef EFL_NOLEGACY_API_SUPPORT
diff --git a/src/lib/efl/interfaces/efl_config.c 
b/src/lib/efl/interfaces/efl_config.c
new file mode 100644
index 000..75d8388
--- /dev/null
+++ b/src/lib/efl/interfaces/efl_config.c
@@ -0,0 +1,128 @@
+#ifdef HAVE_CONFIG_H
+# include 
+#endif
+
+#include 
+
+static Efl_Config *_main_config = NULL;
+
+EAPI void
+__efl_internal_elm_config_set(Efl_Config *cfg)
+{
+   _main_config = cfg;
+}
+
+EOLIAN static Eina_Bool
+_efl_config_config_bool_set(Eo *obj, void *_pd EINA_UNUSED, const char * name, 
Eina_Bool val)
+{
+   Eina_Value *v = eina_value_new(EINA_VALUE_TYPE_UCHAR);
+   Eina_Bool b;
+   eina_value_set(v, val);
+   b = efl_config_set(obj, name, v);
+   eina_value_free(v);
+   return b;
+}
+
+EOLIAN static Eina_Bool
+_efl_config_config_bool_get(Eo *obj, void *_pd EINA_UNUSED, const char * name)
+{
+   Eina_Value *v = efl_config_get(obj, name);
+   Eina_Bool b = 0;
+   eina_value_get(v, );
+   eina_value_free(v);
+   return b;
+}
+
+EOLIAN static Eina_Bool

[EGIT] [core/efl] master 03/16: Evas: Move object static_clip to legacy

2016-06-16 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=ab4e15e9c396e22406ee7c887c2daf333d74a206

commit ab4e15e9c396e22406ee7c887c2daf333d74a206
Author: Jean-Philippe Andre 
Date:   Thu Jun 16 16:20:25 2016 +0900

Evas: Move object static_clip to legacy

This is a horrible API used for internal optimizations. Which
may or may not be partly broken anyway.

We can do better, in the future. Let's not expose this kind
of API.
---
 src/lib/evas/Evas_Legacy.h | 24 +++
 src/lib/evas/canvas/evas_object.eo | 19 --
 src/lib/evas/canvas/evas_object_main.c | 35 +-
 src/lib/evas/include/evas_private.h|  7 +++
 4 files changed, 49 insertions(+), 36 deletions(-)

diff --git a/src/lib/evas/Evas_Legacy.h b/src/lib/evas/Evas_Legacy.h
index a929644..947dbc9 100644
--- a/src/lib/evas/Evas_Legacy.h
+++ b/src/lib/evas/Evas_Legacy.h
@@ -1366,6 +1366,30 @@ EAPI void evas_object_stack_above(Evas_Object *obj, 
Evas_Object *above) EINA_ARG
  */
 EAPI void evas_object_lower(Evas_Object *obj);
 
+/**
+ * @brief Set a hint flag on the given Evas object that it's used as a "static
+ * clipper".
+ *
+ * This is a hint to Evas that this object is used as a big static clipper and
+ * shouldn't be moved with children and otherwise considered specially. The
+ * default value for new objects is @c false.
+ *
+ * @param[in] is_static_clip @c true if it's to be used as a static clipper,
+ * @c false otherwise.
+ *
+ * @ingroup Evas_Object
+ */
+EAPI void evas_object_static_clip_set(Evas_Object *obj, Eina_Bool 
is_static_clip);
+
+/**
+ * @brief Get the "static clipper" hint flag for a given Evas object.
+ *
+ * @return @c true if it's to be used as a static clipper, @c false otherwise.
+ *
+ * @ingroup Evas_Object
+ */
+EAPI Eina_Bool evas_object_static_clip_get(const Evas_Object *obj);
+
 #include "canvas/evas_common_interface.eo.legacy.h"
 #include "canvas/evas_object.eo.legacy.h"
 
diff --git a/src/lib/evas/canvas/evas_object.eo 
b/src/lib/evas/canvas/evas_object.eo
index 8c6555d..bce44da 100644
--- a/src/lib/evas/canvas/evas_object.eo
+++ b/src/lib/evas/canvas/evas_object.eo
@@ -296,25 +296,6 @@ abstract Evas.Object (Eo.Base, Evas.Common_Interface, 
Efl.Gfx, Efl.Gfx.Stack,
  default size.]]
  }
   }
-  @property static_clip {
- set {
-[[Set a hint flag on the given Evas object that it's used as a
-  "static clipper".
-
-  This is a hint to Evas that this object is used as a big
-  static clipper and shouldn't be moved with children and
-  otherwise considered specially. The default value for new
-  objects is $false.
-]]
- }
- get {
-[[Get the "static clipper" hint flag for a given Evas object.]]
- }
- values {
-is_static_clip: bool; [[$true if it's to be used as a static
-clipper, $false otherwise.]]
- }
-  }
   @property focus {
  set {
 [[Sets or unsets a given object as the currently focused one on
diff --git a/src/lib/evas/canvas/evas_object_main.c 
b/src/lib/evas/canvas/evas_object_main.c
index b9ae7da..8058398 100644
--- a/src/lib/evas/canvas/evas_object_main.c
+++ b/src/lib/evas/canvas/evas_object_main.c
@@ -1778,7 +1778,7 @@ _evas_object_eo_base_dbg_info_get(Eo *eo_obj, 
Evas_Object_Protected_Data *obj EI
 
visible = efl_gfx_visible_get(eo_obj);
layer = efl_gfx_stack_layer_get(eo_obj);
-   name = evas_obj_name_get(eo_obj);
+   name = eo_name_get(eo_obj); // evas_object_name_get(eo_obj);
efl_gfx_position_get(eo_obj, , );
efl_gfx_size_get(eo_obj, , );
scale = evas_obj_scale_get(eo_obj);
@@ -2095,19 +2095,6 @@ _evas_object_precise_is_inside_get(Eo *eo_obj 
EINA_UNUSED, Evas_Object_Protected
return obj->precise_is_inside;
 }
 
-EOLIAN static void
-_evas_object_static_clip_set(Eo *eo_obj EINA_UNUSED, 
Evas_Object_Protected_Data *obj, Eina_Bool is_static_clip)
-{
-   evas_object_async_block(obj);
-   obj->is_static_clip = is_static_clip;
-}
-
-EOLIAN static Eina_Bool
-_evas_object_static_clip_get(Eo *eo_obj EINA_UNUSED, 
Evas_Object_Protected_Data *obj)
-{
-   return obj->is_static_clip;
-}
-
 static void
 _is_frame_flag_set(Evas_Object_Protected_Data *obj, Eina_Bool is_frame)
 {
@@ -2190,13 +2177,27 @@ _evas_object_legacy_ctor(Eo *eo_obj, 
Evas_Object_Protected_Data *obj)
 EAPI const char *
 evas_object_type_get(const Evas_Object *eo_obj)
 {
-   Evas_Object_Protected_Data *obj = eo_isa(eo_obj, EVAS_OBJECT_CLASS) ?
-eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS) : NULL;
-   if (!obj || obj->delete_me) return "";
+   Evas_Object_Protected_Data *obj = EVAS_OBJ_GET_OR_RETURN(eo_obj, NULL);
+   if (obj->delete_me) return "";
return obj->type;
 }
 
 EAPI void

[EGIT] [core/efl] master 10/16: Evas: Fix clipees_get and return an iterator

2016-06-16 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=bb7edc2ed487d9d19950e1840a1fcf53c130bb92

commit bb7edc2ed487d9d19950e1840a1fcf53c130bb92
Author: Jean-Philippe Andre 
Date:   Thu Jun 16 18:11:11 2016 +0900

Evas: Fix clipees_get and return an iterator

The legacy function was broken: it was returning the
private data.
---
 src/lib/evas/Evas_Legacy.h  | 22 
 src/lib/evas/canvas/evas_clip.c | 61 +++--
 src/lib/evas/canvas/evas_image_legacy.c |  2 ++
 src/lib/evas/canvas/evas_object.eo  | 25 +++---
 4 files changed, 86 insertions(+), 24 deletions(-)

diff --git a/src/lib/evas/Evas_Legacy.h b/src/lib/evas/Evas_Legacy.h
index cdf4992..81c9d5a 100644
--- a/src/lib/evas/Evas_Legacy.h
+++ b/src/lib/evas/Evas_Legacy.h
@@ -1382,6 +1382,28 @@ EAPI void evas_object_lower(Evas_Object *obj);
 EAPI void evas_object_static_clip_set(Evas_Object *obj, Eina_Bool 
is_static_clip);
 
 /**
+ * @brief Return a list of objects currently clipped by @c obj.
+ *
+ * This returns the internal list handle that contains all objects clipped by
+ * the object @c obj. If none are clipped by it, the call returns @c null. This
+ * list is only valid until the clip list is changed and should be fetched
+ * again with another call to this function if any objects being clipped by
+ * this object are unclipped, clipped by a new object, deleted or get the
+ * clipper deleted. These operations will invalidate the list returned, so it
+ * should not be used anymore after that point. Any use of the list after this
+ * may have undefined results, possibly leading to crashes. The object @c obj
+ * must be a valid Evas_Object.
+ *
+ * See also @ref evas_object_clip_set, @ref evas_object_clip_unset and
+ * @ref evas_object_clip_get.
+ *
+ * @return A list of objects being clipped by @c obj.
+ *
+ * @ingroup Evas_Object
+ */
+EAPI const Eina_List *evas_object_clipees_get(const Evas_Object *obj) 
EINA_WARN_UNUSED_RESULT;
+
+/**
  * @brief Get the "static clipper" hint flag for a given Evas object.
  *
  * @return @c true if it's to be used as a static clipper, @c false otherwise.
diff --git a/src/lib/evas/canvas/evas_clip.c b/src/lib/evas/canvas/evas_clip.c
index 4374d0b..da471a6 100644
--- a/src/lib/evas/canvas/evas_clip.c
+++ b/src/lib/evas/canvas/evas_clip.c
@@ -514,22 +514,77 @@ _evas_object_clip_prev_reset(Evas_Object_Protected_Data 
*obj, Eina_Bool cur_prev
  }
 }
 
-EOLIAN Eina_List *
-_evas_object_clipees_get(Eo *eo_obj EINA_UNUSED, Evas_Object_Protected_Data 
*obj)
+EAPI const Eina_List *
+evas_object_clipees_get(const Evas_Object *eo_obj)
 {
const Evas_Object_Protected_Data *tmp;
Eina_List *l;
Eina_List *answer = NULL;
 
+   Evas_Object_Protected_Data *obj = EVAS_OBJ_GET_OR_RETURN(eo_obj, NULL);
obj->clip.cache_clipees_answer = 
eina_list_free(obj->clip.cache_clipees_answer);
 
EINA_LIST_FOREACH(obj->clip.clipees, l, tmp)
- answer = eina_list_append(answer, tmp);
+ answer = eina_list_append(answer, tmp->object);
 
obj->clip.cache_clipees_answer = answer;
return answer;
 }
 
+typedef struct
+{
+   Eina_Iterator  iterator;
+   Eina_List *list;
+   Eina_Iterator *real_iterator;
+   Evas_Object   *object;
+} Clipee_Iterator;
+
+static Eina_Bool
+_clipee_iterator_next(Clipee_Iterator *it, void **data)
+{
+   Evas_Object_Protected_Data *sub;
+
+   if (!eina_iterator_next(it->real_iterator, (void **) ))
+ return EINA_FALSE;
+
+   if (data) *data = sub ? sub->object : NULL;
+   return EINA_TRUE;
+}
+
+static void *
+_clipee_iterator_get_container(Clipee_Iterator *it)
+{
+   return it->object;
+}
+
+static void
+_clipee_iterator_free(Clipee_Iterator *it)
+{
+   eina_iterator_free(it->real_iterator);
+   free(it);
+}
+
+EOLIAN Eina_Iterator *
+_evas_object_clipees_get(Eo *eo_obj, Evas_Object_Protected_Data *obj)
+{
+   Clipee_Iterator *it;
+
+   it = calloc(1, sizeof(*it));
+   if (!it) return NULL;
+
+   EINA_MAGIC_SET(>iterator, EINA_MAGIC_ITERATOR);
+
+   it->list = obj->clip.clipees;
+   it->real_iterator = eina_list_iterator_new(it->list);
+   it->iterator.version = EINA_ITERATOR_VERSION;
+   it->iterator.next = FUNC_ITERATOR_NEXT(_clipee_iterator_next);
+   it->iterator.get_container = 
FUNC_ITERATOR_GET_CONTAINER(_clipee_iterator_get_container);
+   it->iterator.free = FUNC_ITERATOR_FREE(_clipee_iterator_free);
+   it->object = eo_obj;
+
+   return >iterator;
+}
+
 EOLIAN Eina_Bool
 _evas_object_clipees_has(Eo *eo_obj EINA_UNUSED, Evas_Object_Protected_Data 
*obj)
 {
diff --git a/src/lib/evas/canvas/evas_image_legacy.c 
b/src/lib/evas/canvas/evas_image_legacy.c
index fe8298a..153991e 100644
--- a/src/lib/evas/canvas/evas_image_legacy.c
+++ b/src/lib/evas/canvas/evas_image_legacy.c
@@ -1,3 +1,5 @@
+#define EVAS_OBJECT_BETA
+
 #include "evas_image_private.h"
 #include "evas_image.eo.h"
 
diff --git a/src/lib/evas/canvas/evas_object.eo 

[EGIT] [core/efl] master 09/16: Evas: Mark legacy_ctor as constructor and beta

2016-06-16 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=5177725ed8362f7500c799cb166b38c267945813

commit 5177725ed8362f7500c799cb166b38c267945813
Author: Jean-Philippe Andre 
Date:   Thu Jun 16 18:03:32 2016 +0900

Evas: Mark legacy_ctor as constructor and beta

This is a futile attempt at hiding an internal function.
---
 src/lib/evas/canvas/evas_object.eo | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/src/lib/evas/canvas/evas_object.eo 
b/src/lib/evas/canvas/evas_object.eo
index dc004d2..3b83302 100644
--- a/src/lib/evas/canvas/evas_object.eo
+++ b/src/lib/evas/canvas/evas_object.eo
@@ -8,7 +8,7 @@ abstract Evas.Object (Eo.Base, Evas.Common_Interface, Efl.Gfx, 
Efl.Gfx.Stack,
event_prefix: evas_object;
data: Evas_Object_Protected_Data;
methods {
-  legacy_ctor @protected {
+  legacy_ctor @protected @beta {
   [[Internal function. Do not use.]]
   }
   @property type @protected {
@@ -691,6 +691,7 @@ abstract Evas.Object (Eo.Base, Evas.Common_Interface, 
Efl.Gfx, Efl.Gfx.Stack,
   }
}
constructors {
+  .legacy_ctor;
   .type;
}
implements {

-- 




[EGIT] [core/efl] master 11/16: tests: Add test case for evas clipees get

2016-06-16 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=ace95e2f81a8979857b1674c2561ce4b80647ce5

commit ace95e2f81a8979857b1674c2561ce4b80647ce5
Author: Jean-Philippe Andre 
Date:   Thu Jun 16 19:05:36 2016 +0900

tests: Add test case for evas clipees get

This tests both legacy (list) and eo (iterator) APIs.
THis is a terrible test with a single item, though.
---
 src/tests/evas/evas_test_mask.c | 23 +++
 1 file changed, 23 insertions(+)

diff --git a/src/tests/evas/evas_test_mask.c b/src/tests/evas/evas_test_mask.c
index d3518d0..033ffb4 100644
--- a/src/tests/evas/evas_test_mask.c
+++ b/src/tests/evas/evas_test_mask.c
@@ -63,6 +63,10 @@ START_TEST(evas_mask_test_setget)
 {
Evas *e = _setup_evas();
Evas_Object *obj = NULL, *mask = NULL;
+   const Eina_List *list, *l;
+   Eina_Iterator *it;
+   Evas_Object *o;
+   int i;
 
obj = evas_object_text_add(e);
fail_if(evas_object_clip_get(obj) != NULL);
@@ -71,6 +75,25 @@ START_TEST(evas_mask_test_setget)
evas_object_clip_set(obj, mask);
fail_if(evas_object_clip_get(obj) != mask);
 
+   list = evas_object_clipees_get(mask);
+   i = 0;
+   EINA_LIST_FOREACH(list, l, o)
+ {
+if (!i) fail_if(o != obj);
+i++;
+ }
+   fail_if(i != 1);
+
+   it = evas_obj_clipees_get(mask);
+   i = 0;
+   EINA_ITERATOR_FOREACH(it, o)
+ {
+if (!i) fail_if(o != obj);
+i++;
+ }
+   fail_if(i != 1);
+   eina_iterator_free(it);
+
evas_object_clip_unset(obj);
fail_if(evas_object_clip_get(obj) != NULL);
 

-- 




[EGIT] [core/efl] master 04/16: Evas: Rename object focus to key_focus

2016-06-16 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=e2eebc12213774a179316d60a9b0bdc8ce30c917

commit e2eebc12213774a179316d60a9b0bdc8ce30c917
Author: Jean-Philippe Andre 
Date:   Thu Jun 16 17:19:23 2016 +0900

Evas: Rename object focus to key_focus

The evas focus concept is valid and applies only to the
keyboard inputs.
---
 src/examples/evas/evas-object-manipulation-eo.c |  2 +-
 src/lib/evas/canvas/evas_focus.c|  6 +--
 src/lib/evas/canvas/evas_object.eo  | 49 +++--
 src/lib/evas/canvas/evas_object_main.c  |  2 +-
 src/tests/emotion/emotion_test_main-eo.c|  2 +-
 5 files changed, 20 insertions(+), 41 deletions(-)

diff --git a/src/examples/evas/evas-object-manipulation-eo.c 
b/src/examples/evas/evas-object-manipulation-eo.c
index be50221..1dd25cc 100644
--- a/src/examples/evas/evas-object-manipulation-eo.c
+++ b/src/examples/evas/evas-object-manipulation-eo.c
@@ -185,7 +185,7 @@ main(void)
efl_gfx_size_set(d.bg, WIDTH, HEIGHT);
/* covers full canvas */
efl_gfx_visible_set(d.bg, EINA_TRUE);
-   evas_obj_focus_set(d.bg, EINA_TRUE);
+   evas_object_focus_set(d.bg, EINA_TRUE);
 
evas_object_event_callback_add(
  d.bg, EVAS_CALLBACK_KEY_DOWN, _on_keydown, NULL);
diff --git a/src/lib/evas/canvas/evas_focus.c b/src/lib/evas/canvas/evas_focus.c
index f9344e1..939a6d2 100644
--- a/src/lib/evas/canvas/evas_focus.c
+++ b/src/lib/evas/canvas/evas_focus.c
@@ -8,7 +8,7 @@
 /* public calls */
 
 EOLIAN void
-_evas_object_focus_set(Eo *eo_obj, Evas_Object_Protected_Data *obj, Eina_Bool 
focus)
+_evas_object_key_focus_set(Eo *eo_obj, Evas_Object_Protected_Data *obj, 
Eina_Bool focus)
 {
 
int event_id = 0;
@@ -24,7 +24,7 @@ _evas_object_focus_set(Eo *eo_obj, Evas_Object_Protected_Data 
*obj, Eina_Bool fo
if (focus)
  {
 if (obj->layer->evas->focused)
- evas_obj_focus_set(obj->layer->evas->focused, 0);
+  evas_object_focus_set(obj->layer->evas->focused, 0);

 if (obj->layer->evas->focused) goto end;
 obj->focused = 1;
@@ -47,7 +47,7 @@ _evas_object_focus_set(Eo *eo_obj, Evas_Object_Protected_Data 
*obj, Eina_Bool fo
 }
 
 EOLIAN Eina_Bool
-_evas_object_focus_get(Eo *eo_obj EINA_UNUSED, Evas_Object_Protected_Data *obj)
+_evas_object_key_focus_get(Eo *eo_obj EINA_UNUSED, Evas_Object_Protected_Data 
*obj)
 {
return obj->focused;
 }
diff --git a/src/lib/evas/canvas/evas_object.eo 
b/src/lib/evas/canvas/evas_object.eo
index bce44da..fd2c180 100644
--- a/src/lib/evas/canvas/evas_object.eo
+++ b/src/lib/evas/canvas/evas_object.eo
@@ -296,42 +296,21 @@ abstract Evas.Object (Eo.Base, Evas.Common_Interface, 
Efl.Gfx, Efl.Gfx.Stack,
  default size.]]
  }
   }
-  @property focus {
+  @property key_focus {
+ [[Indicates that this object is the keyboard event receiver on
+   its canvas.
+
+   Changing focus only affects where (key) input events go.
+   There can be only one object focused at any time. If $focus
+   is $true, $obj will be set as the currently focused object
+   and it will receive all keyboard events that are not
+   exclusive key grabs on other objects.
+ ]]
  set {
-[[Sets or unsets a given object as the currently focused one on
-  its canvas.
-
-  Changing focus only affects where (key) input events go.
-  There can be only one object focused at any time. If $focus
-  is $true, $obj will be set as the currently focused object
-  and it will receive all keyboard events that are not
-  exclusive key grabs on other objects.
-
-  See also @.key_grab, @.key_ungrab.
-]]
-/* FIXME-doc
-Example:
-@dontinclude evas-events.c
-@skip evas_object_focus_set
-@until evas_object_focus_set
-
-See the full example @ref Example_Evas_Events "here".
-*/
+legacy: evas_object_focus_set;
  }
  get {
-[[Retrieve whether an object has the focus.
-
-  If the passed object is the currently focused one, $true is
-  returned. $false is returned, otherwise.
-]]
-/* FIXME-doc
-Example:
-@dontinclude evas-events.c
-@skip And again
-@until something is bad
-
-See the full example @ref Example_Evas_Events "here".
-*/
+legacy: evas_object_focus_get;
  }
  values {
 focus: bool; [[$true when set as focused or $false otherwise.]]
@@ -628,7 +607,7 @@ abstract Evas.Object (Eo.Base, Evas.Common_Interface, 
Efl.Gfx, Efl.Gfx.Stack,
Warning: Providing impossible modifier sets creates undefined

[EGIT] [core/efl] master 02/16: Evas: Move object name to legacy

2016-06-16 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=cc427152bd8e4a3bb6ddc105d09741b682875876

commit cc427152bd8e4a3bb6ddc105d09741b682875876
Author: Jean-Philippe Andre 
Date:   Thu Jun 16 16:09:49 2016 +0900

Evas: Move object name to legacy

All EO objects have a name now. No need for evas object
names anymore.

Also move name_child_find.
---
 src/lib/evas/Evas_Legacy.h | 48 +-
 src/lib/evas/canvas/evas_name.c| 18 
 src/lib/evas/canvas/evas_object.eo | 60 --
 3 files changed, 59 insertions(+), 67 deletions(-)

diff --git a/src/lib/evas/Evas_Legacy.h b/src/lib/evas/Evas_Legacy.h
index b7e22bc..a929644 100644
--- a/src/lib/evas/Evas_Legacy.h
+++ b/src/lib/evas/Evas_Legacy.h
@@ -686,11 +686,57 @@ EAPI void evas_object_del(Evas_Object *obj) 
EINA_ARG_NONNULL(1);
  *
  * @return The type of the object.
  *
- * @ingroup Evas_Object
+ * @ingroup Evas_Object_Group_Basic
  */
 EAPI const char  *evas_object_type_get(const Evas_Object *obj);
 
 /**
+ * @brief Sets the name of the given Evas object to the given name.
+ *
+ * There might be occasions where one would like to name his/her objects.
+ *
+ * @param[in] name The given name.
+ *
+ * @ingroup Evas_Object_Group_Basic
+ */
+EAPI void evas_object_name_set(Evas_Object *obj, const char *name);
+
+/**
+ * @brief Retrieves the name of the given Evas object.
+ *
+ * Return: The name of the object or @c null, if no name has been given to it.
+ *
+ * @return The given name.
+ *
+ * @ingroup Evas_Object_Group_Basic
+ */
+EAPI const char *evas_object_name_get(const Evas_Object *obj);
+
+/**
+ * @brief Retrieves the object from children of the given object with the given
+ * name.
+ *
+ * This looks for the evas object given a name by @ref evas_object_name_set,
+ * but it ONLY looks at the children of the object *p obj, and will only
+ * recurse into those children if @c recurse is greater than 0. If the name is
+ * not unique within immediate children (or the whole child tree) then it is
+ * not defined which child object will be returned. If @c recurse is set to -1
+ * then it will recurse without limit.
+ *
+ * @param[in] name The given name.
+ * @param[in] recurse Set to the number of child levels to recurse (0 == don't
+ * recurse, 1 == only look at the children of @c obj or their immediate
+ * children, but no further etc.).
+ *
+ * @return The Evas object with the given name on success, Otherwise @c null.
+ *
+ * @since 1.2
+ *
+ * @ingroup Evas_Object_Group_Basic
+ */
+EAPI Evas_Object *evas_object_name_child_find(const Evas_Object *obj, const 
char *name, int recurse) EINA_WARN_UNUSED_RESULT;
+
+/**
  * Retrieves the position and (rectangular) size of the given Evas
  * object.
  *
diff --git a/src/lib/evas/canvas/evas_name.c b/src/lib/evas/canvas/evas_name.c
index 55ca83f..373d055 100644
--- a/src/lib/evas/canvas/evas_name.c
+++ b/src/lib/evas/canvas/evas_name.c
@@ -1,9 +1,12 @@
 #include "evas_common_private.h"
 #include "evas_private.h"
 
-EOLIAN void
-_evas_object_name_set(Eo *eo_obj, Evas_Object_Protected_Data *obj, const char 
*name)
+EAPI void
+evas_object_name_set(Evas_Object *eo_obj, const char *name)
 {
+   Evas_Object_Protected_Data *obj = eo_isa(eo_obj, EVAS_OBJECT_CLASS) ?
+eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS) : NULL;
+   if (!obj) return;
if (obj->name)
  {
 if (obj->layer && obj->layer->evas && obj->layer->evas->name_hash)
@@ -19,9 +22,12 @@ _evas_object_name_set(Eo *eo_obj, Evas_Object_Protected_Data 
*obj, const char *n
  }
 }
 
-EOLIAN const char *
-_evas_object_name_get(Eo *eo_obj EINA_UNUSED, Evas_Object_Protected_Data *obj)
+EAPI const char *
+evas_object_name_get(const Evas_Object *eo_obj)
 {
+   Evas_Object_Protected_Data *obj = eo_isa(eo_obj, EVAS_OBJECT_CLASS) ?
+eo_data_scope_get(eo_obj, EVAS_OBJECT_CLASS) : NULL;
+   if (!obj) return NULL;
return obj->name;
 }
 
@@ -54,8 +60,8 @@ _priv_evas_object_name_child_find(const Evas_Object *eo_obj, 
const char *name, i
return NULL;
 }
 
-EOLIAN Evas_Object *
-_evas_object_name_child_find(Eo *eo_obj, Evas_Object_Protected_Data *obj 
EINA_UNUSED, const char *name, int recurse)
+EAPI Evas_Object *
+evas_object_name_child_find(const Evas_Object *eo_obj, const char *name, int 
recurse)
 {
return (!name ?  NULL : _priv_evas_object_name_child_find(eo_obj, name, 
recurse));
 }
diff --git a/src/lib/evas/canvas/evas_object.eo 
b/src/lib/evas/canvas/evas_object.eo
index 44c98fb..8c6555d 100644
--- a/src/lib/evas/canvas/evas_object.eo
+++ b/src/lib/evas/canvas/evas_object.eo
@@ -275,41 +275,6 @@ abstract Evas.Object (Eo.Base, Evas.Common_Interface, 
Efl.Gfx, Efl.Gfx.Stack,
 not ($false).]]
  }
   }
-  @property name {
- set {
-[[Sets the name of the given Evas object to the given name.
-
-   

[EGIT] [core/efl] master 05/16: Evas: Nove smart data get to smart class

2016-06-16 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=93fad2a19f2507a7b447d51b1259c15db5363f1f

commit 93fad2a19f2507a7b447d51b1259c15db5363f1f
Author: Jean-Philippe Andre 
Date:   Thu Jun 16 17:33:42 2016 +0900

Evas: Nove smart data get to smart class

It didn't make sense where it was.
No idea why evas_box was overwriting smart_data.get
(esp. since it was returning a private struct).
---
 src/lib/evas/canvas/evas_box.eo  | 1 -
 src/lib/evas/canvas/evas_object.eo   | 6 --
 src/lib/evas/canvas/evas_object_box.c| 7 ---
 src/lib/evas/canvas/evas_object_main.c   | 6 --
 src/lib/evas/canvas/evas_object_smart.c  | 9 +++--
 src/lib/evas/canvas/evas_object_smart.eo | 2 +-
 src/lib/evas/include/evas_private.h  | 2 +-
 7 files changed, 9 insertions(+), 24 deletions(-)

diff --git a/src/lib/evas/canvas/evas_box.eo b/src/lib/evas/canvas/evas_box.eo
index 5e74b80..54d440a 100644
--- a/src/lib/evas/canvas/evas_box.eo
+++ b/src/lib/evas/canvas/evas_box.eo
@@ -657,7 +657,6 @@ class Evas.Box (Evas.Smart.Clipped)
implements {
   class.constructor;
   Eo.Base.constructor;
-  Evas.Object.smart_data.get;
   Evas.Object.Smart.calculate;
   Evas.Object.Smart.add;
   Evas.Object.Smart.del;
diff --git a/src/lib/evas/canvas/evas_object.eo 
b/src/lib/evas/canvas/evas_object.eo
index fd2c180..3cadac8 100644
--- a/src/lib/evas/canvas/evas_object.eo
+++ b/src/lib/evas/canvas/evas_object.eo
@@ -467,12 +467,6 @@ abstract Evas.Object (Eo.Base, Evas.Common_Interface, 
Efl.Gfx, Efl.Gfx.Stack,
 $false otherwise.]]
  }
   }
-  @property smart_data {
- get {
-[[Retrieve user data stored on a given smart object.]]
-return: void_ptr @warn_unused; [[A pointer to data or $null.]]
- }
-  }
   @property smart_clipped_clipper {
  get {
 [[Get the clipper object for the given clipped smart object.
diff --git a/src/lib/evas/canvas/evas_object_box.c 
b/src/lib/evas/canvas/evas_object_box.c
index 415a671..0e71434 100644
--- a/src/lib/evas/canvas/evas_object_box.c
+++ b/src/lib/evas/canvas/evas_object_box.c
@@ -1973,17 +1973,10 @@ _evas_box_option_property_vget(const Eo *o EINA_UNUSED, 
Evas_Object_Box_Data *_p
return EINA_FALSE;
 }
 
-EOLIAN static void*
-_evas_box_evas_object_smart_data_get(Eo *obj EINA_UNUSED, Evas_Object_Box_Data 
*_pd)
-{
-   return (void *)_pd;
-}
-
 EOLIAN static void
 _evas_box_class_constructor(Eo_Class *klass)
 {
evas_smart_legacy_type_register(MY_CLASS_NAME_LEGACY, klass);
 }
 
-
 #include "canvas/evas_box.eo.c"
diff --git a/src/lib/evas/canvas/evas_object_main.c 
b/src/lib/evas/canvas/evas_object_main.c
index fa24674..ecca759 100644
--- a/src/lib/evas/canvas/evas_object_main.c
+++ b/src/lib/evas/canvas/evas_object_main.c
@@ -2135,12 +2135,6 @@ _evas_object_render_parent_get(Eo *eo_obj EINA_UNUSED, 
Evas_Object_Protected_Dat
return obj->smart.parent;
 }
 
-EOLIAN static void *
-_evas_object_smart_data_get(Eo *eo_obj EINA_UNUSED, Evas_Object_Protected_Data 
*obj EINA_UNUSED)
-{
-   return NULL;
-}
-
 EOLIAN static Eina_Bool
 _evas_object_smart_type_check(const Eo *eo_obj EINA_UNUSED, 
Evas_Object_Protected_Data *obj EINA_UNUSED, const char *type EINA_UNUSED)
 {
diff --git a/src/lib/evas/canvas/evas_object_smart.c 
b/src/lib/evas/canvas/evas_object_smart.c
index 0f02909..e94a54b 100644
--- a/src/lib/evas/canvas/evas_object_smart.c
+++ b/src/lib/evas/canvas/evas_object_smart.c
@@ -6,6 +6,11 @@
 #define MY_CLASS_NAME "Evas_Smart"
 #define MY_CLASS_NAME_LEGACY "Evas_Object_Smart"
 
+#define EVAS_OBJECT_SMART_GET_OR_RETURN(eo_obj, ...) \
+   Evas_Smart_Data *o = eo_isa(eo_obj, EVAS_OBJECT_SMART_CLASS) ? \
+ eo_data_scope_get(eo_obj, EVAS_OBJECT_SMART_CLASS) : NULL; \
+   do { if (!o) { MAGIC_CHECK_FAILED(eo_obj,0,MAGIC_SMART) return __VA_ARGS__; 
} } while (0)
+
 extern Eina_Hash* signals_hash_table;
 
 static Eina_Hash *_evas_smart_class_names_hash_table = NULL;
@@ -123,8 +128,8 @@ _evas_object_smart_data_set(Eo *eo_obj EINA_UNUSED, 
Evas_Smart_Data *o, void *da
eo_data_ref(eo_obj, NULL);
 }
 
-EOLIAN static void *
-_evas_object_smart_evas_object_smart_data_get(Eo *eo_obj EINA_UNUSED, 
Evas_Smart_Data *o)
+EOLIAN void *
+_evas_object_smart_data_get(Evas_Object *eo_obj EINA_UNUSED, Evas_Smart_Data 
*o)
 {
return o->data;
 }
diff --git a/src/lib/evas/canvas/evas_object_smart.eo 
b/src/lib/evas/canvas/evas_object_smart.eo
index 3f2c2e3..62497e3 100644
--- a/src/lib/evas/canvas/evas_object_smart.eo
+++ b/src/lib/evas/canvas/evas_object_smart.eo
@@ -68,6 +68,7 @@ class Evas.Object.Smart (Evas.Object)
  }
   }
   @property data {
+ get {}
  set {
 [[Store a pointer to user data for a given smart object.
 
@@ -305,7 +306,6 @@ class Evas.Object.Smart (Evas.Object)
   Eo.Base.constructor;
   

[EGIT] [core/efl] master 08/16: Evas: Move smart_move_children_relative to evas smart

2016-06-16 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=1535135580825db08fe6a77db24f5d3bc926799d

commit 1535135580825db08fe6a77db24f5d3bc926799d
Author: Jean-Philippe Andre 
Date:   Thu Jun 16 17:56:18 2016 +0900

Evas: Move smart_move_children_relative to evas smart

This is temporary...
---
 src/lib/evas/canvas/evas_object.eo   | 17 -
 src/lib/evas/canvas/evas_object_smart.eo | 17 +
 2 files changed, 17 insertions(+), 17 deletions(-)

diff --git a/src/lib/evas/canvas/evas_object.eo 
b/src/lib/evas/canvas/evas_object.eo
index 952e97f..dc004d2 100644
--- a/src/lib/evas/canvas/evas_object.eo
+++ b/src/lib/evas/canvas/evas_object.eo
@@ -652,23 +652,6 @@ abstract Evas.Object (Eo.Base, Evas.Common_Interface, 
Efl.Gfx, Efl.Gfx.Stack,
See also @.clip.set, @.clipees.get and @.clip.get.
  ]]
   }
-  smart_move_children_relative {
- [[Moves all children objects of a given smart object relative to a
-   given offset.
-
-   This will make each of $obj object's children to move, from where
-   they before, with those delta values (offsets) on both directions.
-
-   Note: This is most useful on custom smart $move functions.
-
-   Note: Clipped smart objects already make use of this function on
-   their $move smart function definition.
- ]]
- params {
-@in dx: Evas.Coord; [[Horizontal offset (delta).]]
-@in dy: Evas.Coord; [[Vertical offset (delta).]]
- }
-  }
   @property no_render {
  get {
 [[Returns the state of the "no-render" flag, which means, when
diff --git a/src/lib/evas/canvas/evas_object_smart.eo 
b/src/lib/evas/canvas/evas_object_smart.eo
index 4859528..754c0bb 100644
--- a/src/lib/evas/canvas/evas_object_smart.eo
+++ b/src/lib/evas/canvas/evas_object_smart.eo
@@ -299,6 +299,23 @@ class Evas.Object.Smart (Evas.Object)
  }
  legacy: null;
   }
+  move_children_relative {
+ [[Moves all children objects of a given smart object relative to a
+   given offset.
+
+   This will make each of $obj object's children to move, from where
+   they before, with those delta values (offsets) on both directions.
+
+   Note: This is most useful on custom smart $move functions.
+
+   Note: Clipped smart objects already make use of this function on
+   their $move smart function definition.
+ ]]
+ params {
+@in dx: Evas.Coord; [[Horizontal offset (delta).]]
+@in dy: Evas.Coord; [[Vertical offset (delta).]]
+ }
+  }
}
implements {
   class.constructor;

-- 




[EGIT] [core/efl] master 14/16: Evas: Move Evas.Load_Error to legacy, use Efl.Image.Load.Error

2016-06-16 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=fc6ba5561ea638312acf854665af3e24b48d2dc4

commit fc6ba5561ea638312acf854665af3e24b48d2dc4
Author: Jean-Philippe Andre 
Date:   Thu Jun 16 20:01:32 2016 +0900

Evas: Move Evas.Load_Error to legacy, use Efl.Image.Load.Error

This also disables the unused interface "load_state".
---
 src/lib/efl/interfaces/efl_gfx_types.eot | 11 +++
 src/lib/efl/interfaces/efl_image_load.eo | 21 +
 src/lib/evas/Evas_Legacy.h   |  2 ++
 src/lib/evas/Evas_Loader.h   | 18 +-
 src/lib/evas/canvas/efl_canvas_image.c   |  2 +-
 src/lib/evas/canvas/evas_image_legacy.c  |  2 +-
 6 files changed, 29 insertions(+), 27 deletions(-)

diff --git a/src/lib/efl/interfaces/efl_gfx_types.eot 
b/src/lib/efl/interfaces/efl_gfx_types.eot
index 9821784..dfabeec 100644
--- a/src/lib/efl/interfaces/efl_gfx_types.eot
+++ b/src/lib/efl/interfaces/efl_gfx_types.eot
@@ -193,3 +193,14 @@ enum Efl.Gfx.Size.Hint.Aspect
   object (never growing it out of those bounds), using the given
   aspect.]]
 }
+
+enum Efl.Image.Load.Error
+{
+   none = 0,   [[No error on load]]
+   generic = 1,[[A non-specific error occurred]]
+   does_not_exist = 2, [[File (or file path) does not exist]]
+   permission_denied = 3,  [[Permission denied to an existing file (or 
path)]]
+   resource_allocation_failed = 4, [[Allocation of resources failure prevented 
load]]
+   corrupt_file = 5,   [[File corrupt (but was detected as a known 
format)]]
+   unknown_format = 6  [[File is not a known format]]
+}
diff --git a/src/lib/efl/interfaces/efl_image_load.eo 
b/src/lib/efl/interfaces/efl_image_load.eo
index 38ef297..b373551 100644
--- a/src/lib/efl/interfaces/efl_image_load.eo
+++ b/src/lib/efl/interfaces/efl_image_load.eo
@@ -1,16 +1,6 @@
-/* FIXME: maybe add error code for "currently running" or "pending" ? */
-enum Efl.Image.Load.Error
-{
-   none = 0,   [[No error on load]]
-   generic = 1,[[A non-specific error occurred]]
-   does_not_exist = 2, [[File (or file path) does not exist]]
-   permission_denied = 3,  [[Permission denied to an existing file (or 
path)]]
-   resource_allocation_failed = 4, [[Allocation of resources failure prevented 
load]]
-   corrupt_file = 5,   [[File corrupt (but was detected as a known 
format)]]
-   unknown_format = 6  [[File is not a known format]]
-}
+import efl_gfx_types;
 
-/* FIXME: state or status??? */
+/*
 enum Efl.Image.Load.State
 {
none = 0,  [[Not loading any image.]]
@@ -20,8 +10,8 @@ enum Efl.Image.Load.State
error = 4, [[Image load has failed. Call @Efl.Image.Load.load_error.get 
to know why.]]
cancelled = 5  [[Image load has been cancelled.]]
 }
+*/
 
-/* FIXME: Efl.Image.Load */
 interface Efl.Image.Load ()
 {
[[Common APIs for all loadable 2D images.]]
@@ -43,6 +33,7 @@ interface Efl.Image.Load ()
will be kept in memory.
  ]]
   }
+  /*
   @property load_state {
  get {
 [[Queries information on the current state of load of the image.
@@ -55,6 +46,7 @@ interface Efl.Image.Load ()
 state: Efl.Image.Load.State;
  }
   }
+  */
   @property load_size {
  [[The load size of an image.
 
@@ -178,9 +170,6 @@ interface Efl.Image.Load ()
 div: int; [[The scale down dividing factor.]]
  }
   }
-  /* FIXME: do we want this? or only rely on the events?
-   * what if preload is currently running?
-   */
   @property load_error {
  get {
 [[Retrieves a number representing any error that occurred during
diff --git a/src/lib/evas/Evas_Legacy.h b/src/lib/evas/Evas_Legacy.h
index c149555..cd4b2c3 100644
--- a/src/lib/evas/Evas_Legacy.h
+++ b/src/lib/evas/Evas_Legacy.h
@@ -3759,6 +3759,8 @@ EAPI void 
evas_object_image_load_scale_down_set(Evas_Object *obj, int scale_down
  */
 EAPI int evas_object_image_load_scale_down_get(const Evas_Object *obj);
 
+typedef Efl_Image_Load_Error Evas_Load_Error;
+
 /**
  * @brief Retrieves a number representing any error that occurred during the
  * last loading of the given image object's source image.
diff --git a/src/lib/evas/Evas_Loader.h b/src/lib/evas/Evas_Loader.h
index f8e4da4..62e0d7a 100644
--- a/src/lib/evas/Evas_Loader.h
+++ b/src/lib/evas/Evas_Loader.h
@@ -123,15 +123,15 @@ typedef Emile_Image_Property  Evas_Image_Property;
 
 typedef struct _Evas_Image_Load_Func Evas_Image_Load_Func;
 
-typedef Emile_Image_Load_Error Evas_Load_Error;
-
-#define EVAS_LOAD_ERROR_NONE EMILE_IMAGE_LOAD_ERROR_NONE
-#define EVAS_LOAD_ERROR_GENERIC EMILE_IMAGE_LOAD_ERROR_GENERIC
-#define EVAS_LOAD_ERROR_DOES_NOT_EXIST EMILE_IMAGE_LOAD_ERROR_DOES_NOT_EXIST
-#define 

[EGIT] [core/efl] master 13/16: Evas: Remove Evas.Render_Op and switch to Efl.Gfx

2016-06-16 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=e77c056c5fb22533d210d6012f7e30c0c90568d4

commit e77c056c5fb22533d210d6012f7e30c0c90568d4
Author: Jean-Philippe Andre 
Date:   Thu Jun 16 19:49:06 2016 +0900

Evas: Remove Evas.Render_Op and switch to Efl.Gfx

Note: Only two modes are supported (blend and copy).
The Efl.Gfx and Evas enums were different. All other values
were not supported. For legacy compatibility (since GL engine
actually implements some kind of support for all operations),
render_op_set() should still work fine, even though it's not
recommended, and won't work anymore with EO API.
---
 src/lib/evas/Evas_Legacy.h | 59 ++
 src/lib/evas/canvas/evas_object.eo | 37 ++---
 src/lib/evas/canvas/evas_object_main.c | 32 ++
 src/lib/evas/canvas/evas_types.eot | 18 ---
 4 files changed, 101 insertions(+), 45 deletions(-)

diff --git a/src/lib/evas/Evas_Legacy.h b/src/lib/evas/Evas_Legacy.h
index 83baae2..c149555 100644
--- a/src/lib/evas/Evas_Legacy.h
+++ b/src/lib/evas/Evas_Legacy.h
@@ -1403,6 +1403,65 @@ EAPI void evas_object_static_clip_set(Evas_Object *obj, 
Eina_Bool is_static_clip
  */
 EAPI const Eina_List *evas_object_clipees_get(const Evas_Object *obj) 
EINA_WARN_UNUSED_RESULT;
 
+/** How the object should be rendered to output.
+ *
+ * @ingroup Evas
+ */
+typedef enum
+{
+  EVAS_RENDER_BLEND = 0, /** Default render operation: d = d*(1-sa) + s. The
+  * object will be merged onto the bottom objects using
+  * simple alpha compositing (a over b). */
+  EVAS_RENDER_BLEND_REL = 1, /** DEPRECATED. d = d*(1 - sa) + s*da */
+  EVAS_RENDER_COPY = 2, /** Copy mode, d = s. The object's pixels will replace
+ * everything that was below, effectively hiding them.
+ */
+  EVAS_RENDER_COPY_REL = 3, /** DEPRECATED. d = s*da */
+  EVAS_RENDER_ADD = 4, /** DEPRECATED. d = d + s */
+  EVAS_RENDER_ADD_REL = 5, /** DEPRECATED. d = d + s*da */
+  EVAS_RENDER_SUB = 6, /** DEPRECATED. d = d - s */
+  EVAS_RENDER_SUB_REL = 7, /** DEPRECATED. d = d - s*da */
+  EVAS_RENDER_TINT = 8, /** DEPRECATED. d = d*s + d*(1 - sa) + s*(1 - da) */
+  EVAS_RENDER_TINT_REL = 9, /** DEPRECATED. d = d*(1 - sa + s) */
+  EVAS_RENDER_MASK = 10, /** DEPRECATED. d = d*sa. For masking support, please
+  * use Evas.Object.clip_set or EDC "clip_to" instead.
+  */
+  EVAS_RENDER_MUL = 11 /** DEPRECATED. d = d*s */
+} Evas_Render_Op;
+
+/**
+ * @brief Sets the render mode to be used for compositing the Evas object.
+ *
+ * Note that only copy and blend modes are actually supported: -
+ * @ref Evas_Render_Op.EVAS_RENDER_BLEND means the object will be merged on top
+ * of objects below it using simple alpha compositing. -
+ * @ref Evas_Render_Op.EVAS_RENDER_COPY means this object's pixels will replace
+ * everything that is below, making this object opaque.
+ *
+ * Please do not assume that @ref Evas_Render_Op.EVAS_RENDER_COPY mode can be
+ * used to "poke" holes in a window (to see through it), as only the compositor
+ * can ensure that. Copy mode should only be used with otherwise opaque
+ * widgets, or inside non-window surfaces (eg. a transparent background inside
+ * an Ecore.Evas.Buffer).
+ *
+ * @param[in] render_op One of the Evas_Render_Op values. Only blend (default)
+ * and copy modes are supported.
+ *
+ * @ingroup Evas_Object
+ */
+EAPI void evas_object_render_op_set(Evas_Object *obj, Evas_Render_Op 
render_op);
+
+/**
+ * @brief Retrieves the current value of the operation used for rendering the
+ * Evas object.
+ *
+ * @return One of the Evas_Render_Op values. Only blend (default) and copy
+ * modes are supported.
+ *
+ * @ingroup Evas_Object
+ */
+EAPI Evas_Render_Op evas_object_render_op_get(const Evas_Object *obj);
+
 /**
  * @brief Get the "static clipper" hint flag for a given Evas object.
  *
diff --git a/src/lib/evas/canvas/evas_object.eo 
b/src/lib/evas/canvas/evas_object.eo
index 49b23cb0..88a2ef2 100644
--- a/src/lib/evas/canvas/evas_object.eo
+++ b/src/lib/evas/canvas/evas_object.eo
@@ -46,31 +46,28 @@ abstract Evas.Object (Eo.Base, Evas.Common_Interface, 
Efl.Gfx, Efl.Gfx.Stack,
  }
   }
   @property render_op {
+ [[Render mode to be used for compositing the Evas object.
+
+   Only two modes are supported:
+   - @Efl.Gfx.Render_Op.blend means the object will be merged on
+   top of objects below it using simple alpha compositing.
+   - @Efl.Gfx.Render_Op.copy means this object's pixels will replace
+   everything that is below, making this object opaque.
+
+   Please do not assume that @Efl.Gfx.Render_Op.copy mode can be
+   used to "poke" holes in a window (to see through it), as only the
+   

[EGIT] [core/efl] master 12/16: Evas: Move Evas_Native_Surface to legacy

2016-06-16 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=dc3c6703f3919a4e2c3048737b205acd332b00a6

commit dc3c6703f3919a4e2c3048737b205acd332b00a6
Author: Jean-Philippe Andre 
Date:   Thu Jun 16 19:38:21 2016 +0900

Evas: Move Evas_Native_Surface to legacy
---
 src/lib/evas/Evas_Legacy.h | 4 ++--
 src/lib/evas/canvas/evas_types.eot | 3 ---
 2 files changed, 2 insertions(+), 5 deletions(-)

diff --git a/src/lib/evas/Evas_Legacy.h b/src/lib/evas/Evas_Legacy.h
index 81c9d5a..83baae2 100644
--- a/src/lib/evas/Evas_Legacy.h
+++ b/src/lib/evas/Evas_Legacy.h
@@ -3199,7 +3199,7 @@ typedef enum _Evas_Native_Surface_Type
  *
  * @see evas_object_image_native_surface_set()
  */
-struct _Evas_Native_Surface
+typedef struct _Evas_Native_Surface
 {
int  version; /**< Current Native Surface Version. Use 
EVAS_NATIVE_SURFACE_VERSION */
Evas_Native_Surface_Type type; /**< Surface type. @see 
Evas_Native_Surface_Type */
@@ -3236,7 +3236,7 @@ struct _Evas_Native_Surface
  void *surface; /**< evas gl surface to use @since 1.14 */
   } evasgl; /**< Set this struct fields if surface data is Evas GL based. 
@since 1.14 */
} data; /**< Choose one union data according to your surface. */
-};
+} Evas_Native_Surface;
 
 /**
  * Set the native surface of a given image of the canvas
diff --git a/src/lib/evas/canvas/evas_types.eot 
b/src/lib/evas/canvas/evas_types.eot
index af8529a..109de28 100644
--- a/src/lib/evas/canvas/evas_types.eot
+++ b/src/lib/evas/canvas/evas_types.eot
@@ -1,9 +1,6 @@
 type @extern Evas.Load_Error: int; /* FIXME: Need to migrate emile. */
 struct @extern Evas.Video_Surface; /* FIXME: The structure is full of the 
unsupported func pointers. */
 
-/* FIXME: Unsupported annonymous structures inside */
-struct Evas.Native_Surface; [[A generic datatype for engine specific native 
surface information]]
-
 type Evas.Modifier_Mask: ullong;  [[An Evas modifier mask type]]
 type Evas.Coord: int; [[A type for coordinates]]
 

-- 




[EGIT] [core/efl] master 06/16: Evas: Move smart_clipped_clipper to its class

2016-06-16 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=5974ff017525024fbcdb124148159a8f80f69323

commit 5974ff017525024fbcdb124148159a8f80f69323
Author: Jean-Philippe Andre 
Date:   Thu Jun 16 17:45:29 2016 +0900

Evas: Move smart_clipped_clipper to its class

It was in Evas.Object, probably to make it work without any ERR
message on invalid objects. Not worth it right now...
---
 src/lib/evas/canvas/evas_object.eo  | 10 --
 src/lib/evas/canvas/evas_object_smart_clipped.c |  8 +++-
 src/lib/evas/canvas/evas_smart_clipped.eo   | 13 +
 3 files changed, 16 insertions(+), 15 deletions(-)

diff --git a/src/lib/evas/canvas/evas_object.eo 
b/src/lib/evas/canvas/evas_object.eo
index 3cadac8..df19118 100644
--- a/src/lib/evas/canvas/evas_object.eo
+++ b/src/lib/evas/canvas/evas_object.eo
@@ -467,16 +467,6 @@ abstract Evas.Object (Eo.Base, Evas.Common_Interface, 
Efl.Gfx, Efl.Gfx.Stack,
 $false otherwise.]]
  }
   }
-  @property smart_clipped_clipper {
- get {
-[[Get the clipper object for the given clipped smart object.
-
-  Use this function if you want to change any of this clipper's
-  properties, like colors.
-]]
-return: Evas.Object @warn_unused;
- }
-  }
   @property clipees {
  get {
 [[Return a list of objects currently clipped by $obj.
diff --git a/src/lib/evas/canvas/evas_object_smart_clipped.c 
b/src/lib/evas/canvas/evas_object_smart_clipped.c
index 8584223..d8061de 100644
--- a/src/lib/evas/canvas/evas_object_smart_clipped.c
+++ b/src/lib/evas/canvas/evas_object_smart_clipped.c
@@ -35,12 +35,10 @@ _evas_object_smart_move_children_relative(Eo *eo_obj, 
Evas_Object_Protected_Data
  }
 }
 
-EOLIAN Evas_Object *
-_evas_object_smart_clipped_clipper_get(Eo *eo_obj, Evas_Object_Protected_Data 
*obj EINA_UNUSED)
+static EOLIAN Evas_Object *
+_evas_object_smart_clipped_smart_clipped_clipper_get(Eo *eo_obj EINA_UNUSED, 
Evas_Object_Smart_Clipped_Data *obj)
 {
-   CSO_DATA_GET(eo_obj, cso)
-   if (!cso) return NULL;
-   else return cso->clipper;
+   return obj->clipper;
 }
 
 static void
diff --git a/src/lib/evas/canvas/evas_smart_clipped.eo 
b/src/lib/evas/canvas/evas_smart_clipped.eo
index 4f0b93a..42aae3d 100644
--- a/src/lib/evas/canvas/evas_smart_clipped.eo
+++ b/src/lib/evas/canvas/evas_smart_clipped.eo
@@ -7,6 +7,19 @@ class Evas.Smart.Clipped (Evas.Object.Smart)
eo_prefix: evas_obj_smart_clipped;
data: Evas_Object_Smart_Clipped_Data;
 
+   methods {
+  @property smart_clipped_clipper {
+ get {
+[[Get the clipper object for the given clipped smart object.
+
+  Use this function if you want to change any of this clipper's
+  properties, like colors.
+]]
+return: Evas.Object @warn_unused;
+ }
+  }
+   }
+
implements {
   Eo.Base.constructor;
   Evas.Object.Smart.hide;

-- 




[EGIT] [core/efl] master 16/16: Evas: Move Object_Pointer_Mode to Efl.Event

2016-06-16 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=a50a0f5d76e280456352b380cd4c06fc7cd56e2d

commit a50a0f5d76e280456352b380cd4c06fc7cd56e2d
Author: Jean-Philippe Andre 
Date:   Fri Jun 17 11:32:25 2016 +0900

Evas: Move Object_Pointer_Mode to Efl.Event
---
 src/lib/efl/interfaces/efl_event_types.eot | 26 +-
 src/lib/evas/Evas_Common.h |  6 ++
 src/lib/evas/canvas/evas_object.eo | 30 +-
 src/lib/evas/canvas/evas_types.eot | 24 
 4 files changed, 44 insertions(+), 42 deletions(-)

diff --git a/src/lib/efl/interfaces/efl_event_types.eot 
b/src/lib/efl/interfaces/efl_event_types.eot
index 41a399a..2cb1fa7 100644
--- a/src/lib/efl/interfaces/efl_event_types.eot
+++ b/src/lib/efl/interfaces/efl_event_types.eot
@@ -15,7 +15,7 @@ enum Efl.Pointer.Action
in, [[Mouse or pointer entered the object.]]
out,[[Mouse or pointer exited the object.]]
wheel,  [[Mouse wheel scroll, horizontally or vertically.]]
-   axis,   [[Joystick event.]]
+   axis,   [[Axis event (pen, stick, ...).]]
 }
 
 enum Efl.Pointer.Flags
@@ -41,3 +41,27 @@ enum Efl.Event.Flags
purposes and maybe some indications visually, but 
not
actually perform anything.]]
 }
+
+enum Efl.Event.Object_Pointer_Mode {
+   [[How the mouse pointer should be handled by EFL.
+
+ In the mode $autograb, when a mouse button is pressed down over an
+ object and held down, with the mouse pointer being moved outside of it,
+ the pointer still behaves as being bound to that object, albeit out
+ of its drawing region. When the button is released, the event will
+ be fed to the object, that may check if the final position is over it
+ or not and do something about it.
+
+ In the mode $nograb, the pointer will always be bound to the object
+ right below it.
+   ]]
+   auto_grab, [[Default, X11-like.]]
+   no_grab,   [[Pointer always bound to the object right below it.]]
+   no_grab_no_repeat_updown [[Useful on object with "repeat events" enabled,
+  where mouse/touch up and down events WON'T be
+  repeated to objects and these objects wont be
+  auto-grabbed.
+
+  @since 1.2
+]]
+}
diff --git a/src/lib/evas/Evas_Common.h b/src/lib/evas/Evas_Common.h
index a6ccb3f..296f49f 100644
--- a/src/lib/evas/Evas_Common.h
+++ b/src/lib/evas/Evas_Common.h
@@ -371,6 +371,12 @@ typedef Efl_Text_Bidirectional_Type
Evas_BiDi_Direction;
 #define EVAS_BIDI_DIRECTION_RTLEFL_TEXT_BIDIRECTIONAL_TYPE_RTL
 #define EVAS_BIDI_DIRECTION_INHERITEFL_TEXT_BIDIRECTIONAL_TYPE_INHERIT
 
+typedef Efl_Event_Object_Pointer_Mode  Evas_Object_Pointer_Mode;
+
+#define EVAS_OBJECT_POINTER_MODE_AUTOGRAB 
EFL_EVENT_OBJECT_POINTER_MODE_AUTO_GRAB
+#define EVAS_OBJECT_POINTER_MODE_NOGRAB   EFL_EVENT_OBJECT_POINTER_MODE_NO_GRAB
+#define EVAS_OBJECT_POINTER_MODE_NOGRAB_NO_REPEAT_UPDOWN 
EFL_EVENT_OBJECT_POINTER_MODE_NO_GRAB_NO_REPEAT_UPDOWN
+
 struct _Evas_Engine_Info /** Generic engine information. Generic info is 
useless */
 {
int magic; /**< Magic number */
diff --git a/src/lib/evas/canvas/evas_object.eo 
b/src/lib/evas/canvas/evas_object.eo
index 6d3fb54..c362bb3 100644
--- a/src/lib/evas/canvas/evas_object.eo
+++ b/src/lib/evas/canvas/evas_object.eo
@@ -22,28 +22,24 @@ abstract Evas.Object (Eo.Base, Evas.Common_Interface, 
Efl.Gfx, Efl.Gfx.Stack,
  }
   }
   @property pointer_mode {
- set {
-[[Set pointer behavior.
+ [[Low-level pointer behaviour.
 
-  This function has direct effect on event callbacks related to
-  mouse.
+   This function has a direct effect on event callbacks related to
+   pointers (mouse, ...).
 
-  If $setting is EVAS_OBJECT_POINTER_MODE_AUTOGRAB, then when
-  mouse is down at this object, events will be restricted to
-  it as source, mouse moves, for example, will be emitted even
-  if outside this object area.
+   If the value is @Efl.Event.Object_Pointer_Mode.auto_grab (default),
+   then when mouse is pressed down over this object, events will be
+   restricted to it as source, mouse moves, for example, will be
+   emitted even when the pointer goes outside this objects
+   geometry.
 
-  If $setting is EVAS_OBJECT_POINTER_MODE_NOGRAB, then events
-  will be emitted just when inside this object area.
+   If the value is @Efl.Event.Object_Pointer_Mode.no_grab, then events
+   will be emitted just when inside this object area.
 
-  The default value is EVAS_OBJECT_POINTER_MODE_AUTOGRAB.
-]]
- }
- 

[EGIT] [core/efl] master 15/16: Evas: Move BiDi type to Efl.Text

2016-06-16 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=f2fafb8044ff14eb18b39fbb392ba1503a327177

commit f2fafb8044ff14eb18b39fbb392ba1503a327177
Author: Jean-Philippe Andre 
Date:   Thu Jun 16 20:44:45 2016 +0900

Evas: Move BiDi type to Efl.Text

This renames it to Efl.Text.Bidirectional_Type.
---
 src/Makefile_Efl.am   |  1 +
 src/lib/efl/Efl.h |  2 ++
 src/lib/efl/interfaces/efl_text_types.eot |  7 +++
 src/lib/evas/Evas_Common.h|  8 
 src/lib/evas/canvas/evas_object.eo| 14 ++
 src/lib/evas/canvas/evas_text.eo  |  2 +-
 src/lib/evas/canvas/evas_types.eot| 10 --
 7 files changed, 25 insertions(+), 19 deletions(-)

diff --git a/src/Makefile_Efl.am b/src/Makefile_Efl.am
index 9fbc616..8e97cd5 100644
--- a/src/Makefile_Efl.am
+++ b/src/Makefile_Efl.am
@@ -52,6 +52,7 @@ efl_eolian_type_files = \
lib/efl/interfaces/efl_gfx_types.eot \
lib/efl/interfaces/efl_event_types.eot \
lib/efl/interfaces/efl_types.eot \
+   lib/efl/interfaces/efl_text_types.eot \
$(NULL)
 
 efl_eolian_files_h = $(efl_eolian_files:%.eo=%.eo.h) \
diff --git a/src/lib/efl/Efl.h b/src/lib/efl/Efl.h
index 547f975..c5ff46b 100644
--- a/src/lib/efl/Efl.h
+++ b/src/lib/efl/Efl.h
@@ -76,6 +76,7 @@ typedef Efl_Gfx_Path_Command_Type Efl_Gfx_Path_Command;
 #include "interfaces/efl_part.eo.h"
 #include "interfaces/efl_player.eo.h"
 #include "interfaces/efl_text.eo.h"
+#include "interfaces/efl_text_types.eot.h"
 #include "interfaces/efl_text_properties.eo.h"
 #include "interfaces/efl_orientation.eo.h"
 #include "interfaces/efl_flipable.eo.h"
@@ -149,6 +150,7 @@ static inline void efl_gfx_color16_type_set(Efl_Gfx_Color 
*color,
 #include "interfaces/efl_image.eo.legacy.h"
 #include "interfaces/efl_image_animated.eo.legacy.h"
 #include "interfaces/efl_input_device.eo.legacy.h"
+#include "interfaces/efl_text_types.eot.h"
 #endif
 
 typedef Efl_Gfx_Path_Command_Type Efl_Gfx_Path_Command;
diff --git a/src/lib/efl/interfaces/efl_text_types.eot 
b/src/lib/efl/interfaces/efl_text_types.eot
new file mode 100644
index 000..c44f0ec
--- /dev/null
+++ b/src/lib/efl/interfaces/efl_text_types.eot
@@ -0,0 +1,7 @@
+enum Efl.Text.Bidirectional_Type {
+   natural = 0,
+   neutral = 0,
+   ltr,
+   rtl,
+   inherit
+}
diff --git a/src/lib/evas/Evas_Common.h b/src/lib/evas/Evas_Common.h
index 1dc0e10..a6ccb3f 100644
--- a/src/lib/evas/Evas_Common.h
+++ b/src/lib/evas/Evas_Common.h
@@ -363,6 +363,14 @@ typedef Efl_Gfx_Size_Hint_Aspect   
Evas_Aspect_Control; /**< Aspect type
 #define EVAS_ASPECT_CONTROL_VERTICAL   EFL_GFX_SIZE_HINT_ASPECT_VERTICAL
 #define EVAS_ASPECT_CONTROL_BOTH   EFL_GFX_SIZE_HINT_ASPECT_BOTH
 
+typedef Efl_Text_Bidirectional_TypeEvas_BiDi_Direction;
+
+#define EVAS_BIDI_DIRECTION_NATURALEFL_TEXT_BIDIRECTIONAL_TYPE_NATURAL
+#define EVAS_BIDI_DIRECTION_NEUTRALEFL_TEXT_BIDIRECTIONAL_TYPE_NEUTRAL
+#define EVAS_BIDI_DIRECTION_LTREFL_TEXT_BIDIRECTIONAL_TYPE_LTR
+#define EVAS_BIDI_DIRECTION_RTLEFL_TEXT_BIDIRECTIONAL_TYPE_RTL
+#define EVAS_BIDI_DIRECTION_INHERITEFL_TEXT_BIDIRECTIONAL_TYPE_INHERIT
+
 struct _Evas_Engine_Info /** Generic engine information. Generic info is 
useless */
 {
int magic; /**< Magic number */
diff --git a/src/lib/evas/canvas/evas_object.eo 
b/src/lib/evas/canvas/evas_object.eo
index 88a2ef2..6d3fb54 100644
--- a/src/lib/evas/canvas/evas_object.eo
+++ b/src/lib/evas/canvas/evas_object.eo
@@ -1,4 +1,5 @@
 import evas_types;
+import efl_text_types;
 
 abstract Evas.Object (Eo.Base, Evas.Common_Interface, Efl.Gfx, Efl.Gfx.Stack,
   Efl.Animator, Efl.Input.Interface, Efl.Gfx.Size.Hint)
@@ -526,15 +527,12 @@ abstract Evas.Object (Eo.Base, Evas.Common_Interface, 
Efl.Gfx, Efl.Gfx.Stack,
   }
   @property paragraph_direction {
  [[This handles text paragraph direction of the given object.
-   Even if the given object is not textblock or text, its smart child 
objects
-   can inherit the paragraph direction from the given object.
-   The default paragraph direction is @Evas.BiDi_Direction.inherit.]]
- set {
- }
- get {
- }
+   Even if the given object is not textblock or text, its smart child
+   objects can inherit the paragraph direction from the given object.
+   The default paragraph direction is $inherit.
+ ]]
  values {
-dir: Evas.BiDi_Direction; [[Paragraph direction for the given 
object.]]
+dir: Efl.Text.Bidirectional_Type; [[Paragraph direction for the 
given object.]]
  }
   }
   clipees_has @const {
diff --git a/src/lib/evas/canvas/evas_text.eo b/src/lib/evas/canvas/evas_text.eo
index 3c33ba4..47d85c3 100644
--- a/src/lib/evas/canvas/evas_text.eo
+++ 

[EGIT] [core/efl] master 07/16: Evas: Move smart_type_check[_ptr] to legacy

2016-06-16 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=84a91ec6d4d9273bc8bacd798786af377e853833

commit 84a91ec6d4d9273bc8bacd798786af377e853833
Author: Jean-Philippe Andre 
Date:   Thu Jun 16 17:50:20 2016 +0900

Evas: Move smart_type_check[_ptr] to legacy
---
 src/lib/evas/Evas_Legacy.h  | 35 +
 src/lib/evas/canvas/evas_object.eo  | 31 --
 src/lib/evas/canvas/evas_object_main.c  | 12 -
 src/lib/evas/canvas/evas_object_smart.c | 14 +-
 src/lib/evas/canvas/evas_object_smart.eo|  2 --
 src/lib/evas/canvas/evas_object_smart_clipped.c |  2 +-
 6 files changed, 42 insertions(+), 54 deletions(-)

diff --git a/src/lib/evas/Evas_Legacy.h b/src/lib/evas/Evas_Legacy.h
index 947dbc9..cdf4992 100644
--- a/src/lib/evas/Evas_Legacy.h
+++ b/src/lib/evas/Evas_Legacy.h
@@ -4969,6 +4969,41 @@ EAPI const void   
*evas_object_smart_interface_get(const Evas_Object *obj, c
 EAPI void *evas_object_smart_interface_data_get(const Evas_Object 
*obj, const Evas_Smart_Interface *iface);
 
 /**
+ * @brief Checks whether a given smart object or any of its smart object
+ * parents is of a given smart class.
+ *
+ * If @c obj is not a smart object, this call will fail immediately.
+ *
+ * This function supports Eo and legacy inheritance mechanisms. However, it is
+ * recommended to use @ref eo_isa instead if your object is using Eo from top
+ * to bottom.
+ *
+ * The checks use smart classes names and string comparison. There is a version
+ * of this same check using pointer comparison, since a smart class' name is a
+ * single string in Evas.
+ *
+ * See also @ref evas_object_smart_type_check_ptr.
+ *
+ * @param[in] type The name (type) of the smart class to check for.
+ *
+ * @ingroup Evas_Object
+ */
+EAPI Eina_Bool evas_object_smart_type_check(const Evas_Object *obj, const char 
*type) EINA_WARN_UNUSED_RESULT EINA_ARG_NONNULL(2);
+
+/**
+ * @brief Checks whether a given smart object or any of its smart object
+ * parents is of a given smart class, using pointer comparison.
+ *
+ * @param[in] type The type (name string) to check for. Must be the name.
+ *
+ * @return @c true if @c obj or any of its parents is of type @c type, @c false
+ * otherwise.
+ *
+ * @ingroup Evas_Object
+ */
+EAPI Eina_Bool evas_object_smart_type_check_ptr(const Evas_Object *obj, const 
char *type) EINA_WARN_UNUSED_RESULT EINA_ARG_NONNULL(2);
+
+/**
  * This gets the internal counter that counts the number of smart calculations
  *
  * @param e The canvas to get the calculate counter from
diff --git a/src/lib/evas/canvas/evas_object.eo 
b/src/lib/evas/canvas/evas_object.eo
index df19118..952e97f 100644
--- a/src/lib/evas/canvas/evas_object.eo
+++ b/src/lib/evas/canvas/evas_object.eo
@@ -614,27 +614,6 @@ abstract Evas.Object (Eo.Base, Evas.Common_Interface, 
Efl.Gfx, Efl.Gfx.Stack,
receiving the $keyname events.]]
  }
   }
-  smart_type_check @const {
- [[Checks whether a given smart object or any of its smart object
-   parents is of a given smart class.
-
-   If $obj is not a smart object, this call will fail immediately.
-
-   This function supports Eo and legacy inheritance mechanisms.
-   However, it is recommended to use \@ref eo_isa instead if your
-   object is using Eo from top to bottom.
-
-   The checks use smart classes names and string comparison. There
-   is a version of this same check using pointer comparison, since
-   a smart class' name is a single string in Evas.
-
-   See also @.smart_type_check_ptr.
- ]]
- return: bool @warn_unused;
- params {
-@in type: string @nonull; [[The name (type) of the smart class to 
check for.]]
- }
-  }
   key_ungrab {
  [[Removes the grab on $keyname key events by $obj.
 
@@ -690,16 +669,6 @@ abstract Evas.Object (Eo.Base, Evas.Common_Interface, 
Efl.Gfx, Efl.Gfx.Stack,
 @in dy: Evas.Coord; [[Vertical offset (delta).]]
  }
   }
-  smart_type_check_ptr @const {
- [[Checks whether a given smart object or any of its smart object
-   parents is of a given smart class, using pointer comparison.
- ]]
- return: bool @warn_unused; [[$true if $obj or any of its parents
-  is of type $type, $false otherwise.]]
- params {
-@in type: string @nonull; [[The type (name string) to check for. 
Must be the name.]]
- }
-  }
   @property no_render {
  get {
 [[Returns the state of the "no-render" flag, which means, when
diff --git a/src/lib/evas/canvas/evas_object_main.c 
b/src/lib/evas/canvas/evas_object_main.c
index ecca759..2106a33 100644
--- a/src/lib/evas/canvas/evas_object_main.c
+++ 

[EGIT] [core/efl] master 01/16: Evas: Mark type as legacy and protected

2016-06-16 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=d4b96d33d6d0cd0898beb429bccb35da11fc7d4a

commit d4b96d33d6d0cd0898beb429bccb35da11fc7d4a
Author: Jean-Philippe Andre 
Date:   Thu Jun 16 16:05:00 2016 +0900

Evas: Mark type as legacy and protected

Only set() is allowed for EO, and it's a constructor,
protected function. Unfortunately, this means a lot
of #define EVAS_OBJECT_PROTECTED
---
 src/examples/evas/evas-object-manipulation-eo.c |  6 ++
 src/lib/edje/edje_private.h |  2 ++
 src/lib/elementary/elementary_config.h  |  2 +-
 src/lib/emotion/emotion_smart.c |  2 ++
 src/lib/evas/Evas_Legacy.h  | 18 
 src/lib/evas/canvas/evas_object.eo  | 28 +
 src/lib/evas/canvas/evas_object_main.c  | 23 +---
 src/lib/evas/include/evas_common_private.h  |  5 +
 src/lib/evas/include/evas_private.h |  4 
 9 files changed, 54 insertions(+), 36 deletions(-)

diff --git a/src/examples/evas/evas-object-manipulation-eo.c 
b/src/examples/evas/evas-object-manipulation-eo.c
index f32de7b..be50221 100644
--- a/src/examples/evas/evas-object-manipulation-eo.c
+++ b/src/examples/evas/evas-object-manipulation-eo.c
@@ -209,10 +209,8 @@ main(void)
 efl_gfx_position_set(d.img, 0, 0);
 efl_gfx_size_set(d.img, WIDTH, HEIGHT);
 efl_gfx_visible_set(d.img, EINA_TRUE);
-
-const char *type = NULL;
-type = evas_obj_type_get(d.img);
-fprintf(stdout, "Image object added, type is: %s\n", type);
+fprintf(stdout, "Image object added, class name is: %s\n",
+eo_class_name_get(d.img));
  }
 
/* border on the image's clipper, here just to emphasize its position */
diff --git a/src/lib/edje/edje_private.h b/src/lib/edje/edje_private.h
index db75df4..c4b16f5 100644
--- a/src/lib/edje/edje_private.h
+++ b/src/lib/edje/edje_private.h
@@ -39,6 +39,8 @@
 # include 
 #endif
 
+#define EVAS_OBJECT_PROTECTED
+
 #include 
 #include 
 #include 
diff --git a/src/lib/elementary/elementary_config.h 
b/src/lib/elementary/elementary_config.h
index ae14f49..0e84d6e 100644
--- a/src/lib/elementary/elementary_config.h
+++ b/src/lib/elementary/elementary_config.h
@@ -8,4 +8,4 @@
  */
 
 #define ELM_CONFIG_ICON_THEME_ELEMENTARY "_Elementary_Icon_Theme"
-
+#define EVAS_OBJECT_PROTECTED
diff --git a/src/lib/emotion/emotion_smart.c b/src/lib/emotion/emotion_smart.c
index 804b865..7bfa18a 100644
--- a/src/lib/emotion/emotion_smart.c
+++ b/src/lib/emotion/emotion_smart.c
@@ -2,6 +2,8 @@
 # include "config.h"
 #endif
 
+#define EVAS_OBJECT_PROTECTED
+
 #include 
 #include 
 
diff --git a/src/lib/evas/Evas_Legacy.h b/src/lib/evas/Evas_Legacy.h
index 7ca9080..b7e22bc 100644
--- a/src/lib/evas/Evas_Legacy.h
+++ b/src/lib/evas/Evas_Legacy.h
@@ -673,6 +673,24 @@ EAPI int  evas_object_ref_get(const 
Evas_Object *obj);
 EAPI void evas_object_del(Evas_Object *obj) EINA_ARG_NONNULL(1);
 
 /**
+ * @brief Retrieves the type of the given Evas object.
+ *
+ * For Evas' builtin types, the return strings will be one of "rectangle",
+ * "line", "polygon", "text", "textblock" or "image".
+ *
+ * For Evas smart objects (see @ref Evas_Smart_Group), the name of the smart
+ * class itself is returned on this call. For the built-in smart objects, these
+ * names are "EvasObjectSmartClipped" for the clipped smart object,
+ * "Evas_Object_Box" for the box object and "Evas_Object_Table for the table
+ * object.
+ *
+ * @return The type of the object.
+ *
+ * @ingroup Evas_Object
+ */
+EAPI const char  *evas_object_type_get(const Evas_Object *obj);
+
+/**
  * Retrieves the position and (rectangular) size of the given Evas
  * object.
  *
diff --git a/src/lib/evas/canvas/evas_object.eo 
b/src/lib/evas/canvas/evas_object.eo
index 587578c..44c98fb 100644
--- a/src/lib/evas/canvas/evas_object.eo
+++ b/src/lib/evas/canvas/evas_object.eo
@@ -11,32 +11,11 @@ abstract Evas.Object (Eo.Base, Evas.Common_Interface, 
Efl.Gfx, Efl.Gfx.Stack,
   legacy_ctor @protected {
   [[Internal function. Do not use.]]
   }
-  @property type {
+  @property type @protected {
  set {
-[[Sets the type of the given Evas object.]]
+[[Sets the legacy type name of this Evas object.]]
 legacy: null;
  }
- get {
-[[Retrieves the type of the given Evas object.
-
-  For Evas' builtin types, the return strings will be one of
-  "rectangle", "line", "polygon", "text", "textblock" or "image".
-
-  For Evas smart objects (see \@ref Evas_Smart_Group), the name
-  of the smart class itself is returned on this call. For the
-  built-in smart objects, these names are "EvasObjectSmartClipped"
-  for the clipped smart object, 

[EGIT] [core/efl] master 01/01: evas: (Try to) fix shaders gen without breaking everything

2016-06-24 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=e1d5d5e4a1817e148e51a8e1ae15969f826f4b1d

commit e1d5d5e4a1817e148e51a8e1ae15969f826f4b1d
Author: Jean-Philippe Andre 
Date:   Fri Jun 24 14:36:10 2016 +0900

evas: (Try to) fix shaders gen without breaking everything

So... adding the .x files to BUILT_SOURCES means they would
get deleted during clean. This was bad, but turned to be awful
when this made the check for writability fail.

See:
8a273158788d630e56b4dc14cdd44f0eaae6b7b5
2b8912462e0ec81efb8e30a63383b811f52e16f5

This commit reverts:
0b69356f1bbceab3261835bc2d4632f8f4669206

Notes:
Please revert if this breaks the build for anyone.
I'm pretty sure the use of top_srcdir is not recommended the
way I've done it.

I hate autofoo.
---
 src/Makefile_Evas.am   | 22 +-
 .../evas/engines/gl_common/shader/gen_shaders.sh   |  7 +++
 .../engines/gl_common/shader_3d/gen_shaders_3d.sh  |  6 ++
 3 files changed, 26 insertions(+), 9 deletions(-)

diff --git a/src/Makefile_Evas.am b/src/Makefile_Evas.am
index ac7840e..9d45c16 100644
--- a/src/Makefile_Evas.am
+++ b/src/Makefile_Evas.am
@@ -727,7 +727,6 @@ modules_evas_engines_fb_module_la_LIBTOOLFLAGS = 
--tag=disable-static
 endif
 endif
 
-if BUILD_ENGINE_GL_COMMON
 GL_COMMON_SOURCES = \
 modules/evas/engines/gl_common/evas_gl_private.h \
 modules/evas/engines/gl_common/evas_gl_common.h \
@@ -753,7 +752,6 @@ modules/evas/engines/gl_common/evas_gl_api_gles1.c \
 modules/evas/engines/gl_common/evas_gl_api_gles3_def.h \
 modules/evas/engines/gl_common/evas_gl_api_ext.c \
 modules/evas/engines/gl_common/shader/evas_gl_shaders.x \
-modules/evas/engines/gl_common/shader_3d/evas_gl_3d_shaders.x \
 $(NULL)
 
 # 3D
@@ -762,7 +760,9 @@ modules/evas/engines/gl_common/evas_gl_3d_common.h \
 modules/evas/engines/gl_common/evas_gl_3d_private.h \
 modules/evas/engines/gl_common/evas_gl_3d.c \
 modules/evas/engines/gl_common/evas_gl_3d_renderer.c \
-modules/evas/engines/gl_common/evas_gl_3d_shader.c
+modules/evas/engines/gl_common/evas_gl_3d_shader.c \
+modules/evas/engines/gl_common/shader_3d/evas_gl_3d_shaders.x \
+$(NULL)
 
 EVAS_GL_SHADERS_GEN = \
 modules/evas/engines/gl_common/shader/gen_shaders.sh \
@@ -773,9 +773,11 @@ $(NULL)
 
 EXTRA_DIST2 += $(EVAS_GL_SHADERS_GEN)
 
-modules/evas/engines/gl_common/shader/evas_gl_shaders.x: $(EVAS_GL_SHADERS_GEN)
+modules/evas/engines/gl_common/shader/evas_gl_shaders.x: 
$(EVAS_GL_SHADERS_GEN) 
$(top_srcdir)/src/modules/evas/engines/gl_common/shader/gen_shaders.sh
@echo "  SHADERS  $@"
-   @sh $(srcdir)/modules/evas/engines/gl_common/shader/gen_shaders.sh
+   @sh 
$(top_srcdir)/src/modules/evas/engines/gl_common/shader/gen_shaders.sh
+
+modules/evas/engines/gl_common/evas_gl_shader.c: 
modules/evas/engines/gl_common/shader/evas_gl_shaders.x
 
 # NOTE: order here should be equal with modes in file Evas_Eo.h
 GL_SHADERS_3D_GEN = \
@@ -804,9 +806,11 @@ modules/evas/engines/gl_common/shader_3d/gen_shaders_3d.sh 
\
 modules/evas/engines/gl_common/shader_3d/include.shd \
 $(GL_SHADERS_3D_GEN)
 
-modules/evas/engines/gl_common/shader_3d/evas_gl_3d_shaders.x: 
modules/evas/engines/gl_common/shader_3d/gen_shaders_3d.sh $(GL_SHADERS_3D_GEN) 
modules/evas/engines/gl_common/shader_3d/include.shd
+modules/evas/engines/gl_common/shader_3d/evas_gl_3d_shaders.x: 
$(top_srcdir)/src/modules/evas/engines/gl_common/shader_3d/gen_shaders_3d.sh 
$(GL_SHADERS_3D_GEN) 
$(top_srcdir)/src/modules/evas/engines/gl_common/shader_3d/include.shd
@echo "  SHADERS  $@"
-   @sh 
$(srcdir)/modules/evas/engines/gl_common/shader_3d/gen_shaders_3d.sh 
$(GL_SHADERS_3D_GEN)
+   @sh 
$(top_srcdir)/src/modules/evas/engines/gl_common/shader_3d/gen_shaders_3d.sh 
$(GL_SHADERS_3D_GEN)
+
+modules/evas/engines/gl_common/evas_gl_3d_shader.c: 
modules/evas/engines/gl_common/shader_3d/evas_gl_3d_shaders.x
 
 
 GL_GENERIC_SOURCES = \
@@ -831,8 +835,7 @@ evas_gl_generic_eolian_h = 
$(evas_gl_generic_eolian_files:%.eo=%.eo.h) \
 BUILT_SOURCES += \
  $(evas_gl_generic_eolian_c) \
  $(evas_gl_generic_eolian_h) \
- modules/evas/engines/gl_common/shader_3d/evas_gl_3d_shaders.x 
\
- modules/evas/engines/gl_common/shader/evas_gl_shaders.x
+ $(NULL)
 
 EXTRA_DIST2 += $(evas_gl_generic_eolian_files)
 
@@ -840,6 +843,7 @@ EXTRA_DIST2 += $(evas_gl_generic_eolian_files)
 #evaseolianfiles_DATA += $(evas_gl_generic_eolian_files)
 
 
+if BUILD_ENGINE_GL_COMMON
 if EVAS_STATIC_BUILD_GL_COMMON
 lib_evas_libevas_la_SOURCES += $(GL_COMMON_SOURCES) $(GL_GENERIC_SOURCES)
 lib_evas_libevas_la_LIBADD += @evas_engine_gl_common_libs@
diff --git a/src/modules/evas/engines/gl_common/shader/gen_shaders.sh 
b/src/modules/evas/engines/gl_common/shader/gen_shaders.sh
index 8861d95..7c2fec1 100755
--- 

[EGIT] [core/efl] master 09/09: config: Prevent accidental deletion of the config object

2016-06-24 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=868dc1ba2b2d23e0310ec8a7a861e0aa4157e06b

commit 868dc1ba2b2d23e0310ec8a7a861e0aa4157e06b
Author: Jean-Philippe Andre 
Date:   Thu Jun 23 21:55:58 2016 +0900

config: Prevent accidental deletion of the config object
---
 src/lib/elementary/elm_config.c | 8 
 1 file changed, 8 insertions(+)

diff --git a/src/lib/elementary/elm_config.c b/src/lib/elementary/elm_config.c
index d14aee8..204ee34 100644
--- a/src/lib/elementary/elm_config.c
+++ b/src/lib/elementary/elm_config.c
@@ -1680,11 +1680,18 @@ _config_system_load(void)
 }
 
 static void
+_efl_config_obj_del(Eo *obj EINA_UNUSED)
+{
+   ERR("You can not delete the global configuration object!");
+}
+
+static void
 _config_load(void)
 {
_efl_config_obj = eo_add(EFL_CONFIG_GLOBAL_CLASS, NULL);
efl_loop_register(ecore_main_loop_get(), EFL_CONFIG_INTERFACE, 
_efl_config_obj);
efl_loop_register(ecore_main_loop_get(), EFL_CONFIG_GLOBAL_CLASS, 
_efl_config_obj);
+   eo_del_intercept_set(_efl_config_obj, _efl_config_obj_del);
_elm_config = _config_user_load();
if (_elm_config)
  {
@@ -4243,6 +4250,7 @@ _elm_config_profile_set(const char *profile)
 void
 _elm_config_shutdown(void)
 {
+   eo_del_intercept_set(_efl_config_obj, NULL);
efl_loop_register(ecore_main_loop_get(), EFL_CONFIG_INTERFACE, NULL);
efl_loop_register(ecore_main_loop_get(), EFL_CONFIG_GLOBAL_CLASS, NULL);
ELM_SAFE_FREE(_efl_config_obj, eo_del);

-- 




Re: [E-devel] [EGIT] [core/efl] master 01/01: configure: Fail if opengl=full is used with EGL

2016-01-17 Thread Jean-Philippe André
On 16 January 2016 at 09:58, Simon Lees <si...@simotek.net> wrote:

>
>
> On 01/11/2016 05:18 PM, Jean-Philippe ANDRÉ wrote:
> > jpeg pushed a commit to branch master.
> >
> >
> http://git.enlightenment.org/core/efl.git/commit/?id=1f7e8d4253cf5265cba5a8968fb43fa720dde934
> >
> > commit 1f7e8d4253cf5265cba5a8968fb43fa720dde934
> > Author: Jean-Philippe Andre <jp.an...@samsung.com>
> > Date:   Mon Jan 11 13:47:41 2016 +0900
> >
> >  configure: Fail if opengl=full is used with EGL
> >
> >  So many problems from people who customize their builds in this
> >  incompatible manner.
> >
> >  There really should be only one configure option as we don't
> >  support opengl+egl (although possible in theory) or gles without
> >  egl. Keeping both to not break existing builds.
> How does this effect distro packaging where some users presumably want
> opengl=full for X11 and then others EGL for wayland? or should that not
> be possible at the moment, id rather not use separate efl packages for
> wayland vs x11 that would just be messy.
>

Considering how the configure currently works, I believe this was not
possible.
Here I'm just trying to clarify the limitations of our build system.

If you want wayland, then you want EGL, which will mean you also want
GL-ES. Since this is a global option, this will also apply to X11 (so, EGL
instead of GLX).

I'm not saying that it would be impossible to support EGL with full opengl,
or GLX and Wayland. Just that it probably doesn't work right now.

JP


> Cheers
> Simon
> > ---
> >   configure.ac | 18 --
> >   1 file changed, 16 insertions(+), 2 deletions(-)
> >
> > diff --git a/configure.ac b/configure.ac
> > index 35c166b..5e4865e 100644
> > --- a/configure.ac
> > +++ b/configure.ac
> > @@ -1636,7 +1636,7 @@ if test "${want_sdl}" = "yes"; then
> >  EFL_PKG_CHECK_STRICT([sdl2 >= 2.0.0])
> >   fi
> >
> > -# We only enable SDL with opengl if it is not the full version and not
> ES
> > +# We only enable SDL with opengl if it is the full version and not ES
> >   # This can be changed if we ported our SDL code over to SDL 2.0. For
> older
> >   # versions the SDL_opengles.h has never been released.
> >   want_gl_sdl="no"
> > @@ -1829,6 +1829,14 @@ AC_ARG_ENABLE([egl],
> >  ],
> >  [want_egl="no"])
> >
> > +# Verify OpenGL + EGL modes match (full+glx or es+egl)
> > +if test "x${want_egl}" = "xyes" && test "x${with_opengl}" != "xes" ;
> then
> > +  AC_MSG_ERROR([Full OpenGL with EGL is not supported, please add
> --with-opengl=es to your configure options to switch to EGL + OpenGL ES.])
> > +fi
> > +if test "x${want_egl}" = "xno" && test "x${with_opengl}" = "xes" ; then
> > +  AC_MSG_ERROR([OpenGL ES requires EGL, please add --enable-egl to your
> configure options to switch to EGL + OpenGL ES.])
> > +fi
> > +
> >   # Pixman
> >   AC_ARG_ENABLE([pixman],
> >  [AS_HELP_STRING([--enable-pixman],[enable pixman for software
> rendering. @<:@default=disabled@:>@])],
> > @@ -5247,6 +5255,12 @@ else
> >  osname="${host_os}"
> >   fi
> >
> > +if test "x${want_egl}" = "xyes" ; then
> > +   opengl_egl="(EGL)"
> > +else
> > +   opengl_egl=""
> > +fi
> > +
> >   echo "Configuration...: ${COLOR_OTHER}profile=${build_profile}
> os=${osname}${COLOR_RESET}"
> >   echo "  EFL API Set...: ${efl_api}"
> >   echo "  CPU Extensions: ${host_cpu} (${features_cpu})"
> > @@ -5254,7 +5268,7 @@ echo "  System Feature: ${features_system}"
> >   echo "  Threads...: ${efl_have_threads} (${features_thread})"
> >   echo "  Cryptography..: ${build_crypto}"
> >   echo "  X11...: ${with_x11}"
> > -echo "  OpenGL: ${with_opengl}"
> > +echo "  OpenGL: ${with_opengl} ${opengl_egl}"
> >   echo "  C++11.....: ${have_cxx11}"
> >   echo "  JavaScript: ${want_js}"
> >   echo "  JavaScript flg: $EINA_JS_LIBS"
> >
>
>
>
> --
> Site24x7 APM Insight: Get Deep Visibility into Application Performance
> APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month
> Monitor end-to-end web transactions and take corrective actions now
> Troubleshoot f

[EGIT] [core/efl] master 01/01: efl: Remove eo struct Efl.Gfx.Color

2016-06-27 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=d931c53919b85ef7b2b6120d7bc60d8ddd207653

commit d931c53919b85ef7b2b6120d7bc60d8ddd207653
Author: Jean-Philippe Andre 
Date:   Tue Jun 28 10:52:28 2016 +0900

efl: Remove eo struct Efl.Gfx.Color

So far this was protected behind ifdef EO_API_SUPPORT. It also
was not used internally. Dropping this before the release, since
we will soon have a (hopefully) better solution to handle various
color representations.
---
 src/Makefile_Efl.am  |  3 ---
 src/lib/efl/Efl.h| 13 
 src/lib/efl/Makefile.am  |  3 ---
 src/lib/efl/interfaces/efl_gfx.x | 36 
 src/lib/efl/interfaces/efl_gfx_types.eot | 16 --
 5 files changed, 71 deletions(-)

diff --git a/src/Makefile_Efl.am b/src/Makefile_Efl.am
index eb976e9..ac5edda 100644
--- a/src/Makefile_Efl.am
+++ b/src/Makefile_Efl.am
@@ -104,9 +104,6 @@ dist_installed_eflheaders_DATA = \
   lib/efl/Efl.h
 
 installed_eflinterfacesdir = $(includedir)/efl-@VMAJ@/interfaces
-dist_installed_eflinterfaces_DATA = \
-lib/efl/interfaces/efl_gfx.x
-
 nodist_installed_eflinterfaces_DATA = \
$(efl_eolian_files_h) \
$(efl_eolian_legacy_files_h)
diff --git a/src/lib/efl/Efl.h b/src/lib/efl/Efl.h
index 4d5629e..3a00bb5 100644
--- a/src/lib/efl/Efl.h
+++ b/src/lib/efl/Efl.h
@@ -112,19 +112,6 @@ EAPI extern const Eo_Event_Description 
_EFL_GFX_PATH_CHANGED;
 #include "interfaces/efl_gfx_filter.eo.h"
 #include "interfaces/efl_gfx_size_hint.eo.h"
 
-#define EFL_GFX_COLOR_SET(value) (value << 8)
-#define EFL_GFX_COLOR16_SET(value) (value)
-
-static inline void efl_gfx_color_type_set(Efl_Gfx_Color *color,
-  unsigned char r, unsigned char g,
-  unsigned char b, unsigned char a);
-
-static inline void efl_gfx_color16_type_set(Efl_Gfx_Color *color,
-unsigned short r, unsigned short g,
-unsigned short b, unsigned short 
a);
-
-#include "interfaces/efl_gfx.x"
-
 #include "interfaces/efl_canvas.eo.h"
 
 /* Packing & containers */
diff --git a/src/lib/efl/Makefile.am b/src/lib/efl/Makefile.am
index f6138e6..3cae7dd 100644
--- a/src/lib/efl/Makefile.am
+++ b/src/lib/efl/Makefile.am
@@ -82,9 +82,6 @@ Efl_Model_Common.h \
 Efl.h
 
 installed_eflinterfacesdir = $(includedir)/efl-@VMAJ@/interfaces
-dist_installed_eflinterfaces_DATA = \
-   interfaces/efl_gfx.x
-
 nodist_installed_eflinterfaces_DATA = \
$(efl_eolian_files_h) \
$(efl_eolian_legacy_files_h)
diff --git a/src/lib/efl/interfaces/efl_gfx.x b/src/lib/efl/interfaces/efl_gfx.x
deleted file mode 100644
index ed0d48a..000
--- a/src/lib/efl/interfaces/efl_gfx.x
+++ /dev/null
@@ -1,36 +0,0 @@
-#ifndef EFL_GFX_X
-# define EFL_GFX_X
-
-static inline void
-efl_gfx_color_type_set(Efl_Gfx_Color *color,
-   unsigned char r, unsigned char g,
-   unsigned char b, unsigned char a)
-{
-   color->r = EFL_GFX_COLOR_SET(r);
-   color->g = EFL_GFX_COLOR_SET(g);
-   color->b = EFL_GFX_COLOR_SET(b);
-   color->a = EFL_GFX_COLOR_SET(a);
-
-   color->type = EFL_GFX_COLOR_TYPE_BITS8;
-}
-
-static inline void
-efl_gfx_color16_type_set(Efl_Gfx_Color *color,
- unsigned short r, unsigned short g,
- unsigned short b, unsigned short a)
-{
-   color->r = EFL_GFX_COLOR16_SET(r);
-   color->g = EFL_GFX_COLOR16_SET(g);
-   color->b = EFL_GFX_COLOR16_SET(b);
-   color->a = EFL_GFX_COLOR16_SET(a);
-
-   color->type = EFL_GFX_COLOR_TYPE_BITS16;
-}
-
-static inline Efl_Gfx_Color_Type
-efl_gfx_color_type_get(Efl_Gfx_Color *color)
-{
-   return color->type;
-}
-
-#endif
diff --git a/src/lib/efl/interfaces/efl_gfx_types.eot 
b/src/lib/efl/interfaces/efl_gfx_types.eot
index dfabeec..3a70a62 100644
--- a/src/lib/efl/interfaces/efl_gfx_types.eot
+++ b/src/lib/efl/interfaces/efl_gfx_types.eot
@@ -26,22 +26,6 @@ enum Efl.Gfx.Render_Op {
   last
 }
 
-enum Efl.Gfx.Color_Type {
-  bits8, [[Color is encoded in the top 8 bits of the unsigned short as a 
unsigned char.]]
-  bits16,[[Color is encoded in the 16 bits as an unsigned short.]]
-  last
-}
-
-struct Efl.Gfx.Color {
-  [[Define an RGBA color.]]
-  r: ushort; [[The red component.]]
-  g: ushort; [[The green component.]]
-  b: ushort; [[The blue component.]]
-  a: ushort; [[The alpha component.]]
-
-  type: Efl.Gfx.Color_Type; [[Defines whether the color is 8-bit or 16-bit 
encoded.]]
-}
-
 enum Efl.Gfx.Path.Command_Type {
   [[These values determine how the points are interpreted in a stream of 
points.
 @since 1.14

-- 




[EGIT] [core/efl] master 01/03: evas: Fix double stringshare_del

2016-06-28 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=d4b9328dcdc808d38d50498af05e13ea0a39cb46

commit d4b9328dcdc808d38d50498af05e13ea0a39cb46
Author: Jean-Philippe Andre 
Date:   Tue Jun 28 19:17:24 2016 +0900

evas: Fix double stringshare_del

A stringshare for font "style" was not properly duplicated,
resulting in lots of invalid stringshare pointers.

Ping @id213sin (commit 2ce33e73a7d48d4b54a075c07f12c0162).
---
 src/lib/evas/canvas/evas_font_dir.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/src/lib/evas/canvas/evas_font_dir.c 
b/src/lib/evas/canvas/evas_font_dir.c
index 1369dfe..b5c1d31 100644
--- a/src/lib/evas/canvas/evas_font_dir.c
+++ b/src/lib/evas/canvas/evas_font_dir.c
@@ -456,6 +456,7 @@ evas_font_desc_dup(const Evas_Font_Description *fdesc)
new->name = eina_stringshare_ref(new->name);
new->fallbacks = eina_stringshare_ref(new->fallbacks);
new->lang = eina_stringshare_ref(new->lang);
+   new->style = eina_stringshare_ref(new->style);
 
return new;
 }

-- 




[EGIT] [core/efl] master 03/03: eo: Fix composite objects destruction

2016-06-28 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=d8db7b2637528dbc89605720a371b0677c84ae88

commit d8db7b2637528dbc89605720a371b0677c84ae88
Author: Jean-Philippe Andre 
Date:   Tue Jun 28 19:29:31 2016 +0900

eo: Fix composite objects destruction

This walks the list and removes objects from it. Not
using EINA_LIST_FREE as the actual list_remove is done
inside eo_composite_detach.
---
 src/lib/eo/eo_base_class.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/lib/eo/eo_base_class.c b/src/lib/eo/eo_base_class.c
index fe12067..82ab7d6 100644
--- a/src/lib/eo/eo_base_class.c
+++ b/src/lib/eo/eo_base_class.c
@@ -1439,9 +1439,9 @@ _eo_base_destructor(Eo *obj, Eo_Base_Data *pd)
/* If we are a composite object, detach children */
  {
 EO_OBJ_POINTER_RETURN(obj, obj_data);
-Eina_List *itr;
+Eina_List *itr, *next;
 Eo *emb_obj_id;
-EINA_LIST_FOREACH(obj_data->composite_objects, itr, emb_obj_id)
+EINA_LIST_FOREACH_SAFE(obj_data->composite_objects, itr, next, 
emb_obj_id)
   {
  eo_composite_detach(obj, emb_obj_id);
   }

-- 




[EGIT] [core/efl] master 02/03: evas: Use proper type for stringshares

2016-06-28 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=2078b74e2899948b8c18cf4ab38e1636728d23b5

commit 2078b74e2899948b8c18cf4ab38e1636728d23b5
Author: Jean-Philippe Andre 
Date:   Tue Jun 28 19:20:37 2016 +0900

evas: Use proper type for stringshares
---
 src/lib/evas/include/evas_private.h | 9 -
 1 file changed, 4 insertions(+), 5 deletions(-)

diff --git a/src/lib/evas/include/evas_private.h 
b/src/lib/evas/include/evas_private.h
index 394fa58..684edfc 100644
--- a/src/lib/evas/include/evas_private.h
+++ b/src/lib/evas/include/evas_private.h
@@ -1207,11 +1207,10 @@ struct _Evas_Font_Alias
 struct _Evas_Font_Description
 {
int ref;
-   /* We assume everywhere this is stringshared */
-   const char *name;
-   const char *fallbacks;
-   const char *lang;
-   const char *style;
+   Eina_Stringshare *name;
+   Eina_Stringshare *fallbacks;
+   Eina_Stringshare *lang;
+   Eina_Stringshare *style;
 
Evas_Font_Slant slant;
Evas_Font_Weight weight;

-- 




Re: [E-devel] [EGIT] [core/efl] master 01/01: evas: Fix compilation when using different build directory

2016-06-26 Thread Jean-Philippe André
fi
>
>  # Skip generation if there is no diff (or no git)
>  if ! git rev-parse 2>> /dev/null >> /dev/null ; then exit 0 ; fi
> -if git diff --quiet --exit-code -- "$DIR"
> +if git diff --quiet --exit-code -- "$OUTDIR"
>  then
>touch "$OUTPUT"
>exit 0
> @@ -24,7 +25,7 @@ fi
>  exec 1<&-
>  exec 1>"$OUTPUT"
>
> -SHADERS=$@
> +SHADERS=${@:2}
>  VERT_SHADERS_SOURCE=""
>  FRAG_SHADERS_SOURCE=""
>
> @@ -42,7 +43,7 @@ for SHD in $SHADERS ; do
>  FRAG_SHADERS_SOURCE="$FRAG_SHADERS_SOURCE"$LNAME"_glsl,\n"
>fi
>
> -  m4 "$DIR/include.shd" "$SHD" > "$SHD.tmp"
> +  m4 "$INDIR/include.shd" "$SHD" > "$SHD.tmp"
>
>OIFS="$IFS"
>IFS=`printf '\n+'`
>
> --
>
> --
> Jean-Philippe André
>
>
--
Attend Shape: An AT Tech Expo July 15-16. Meet us at AT Park in San
Francisco, CA to explore cutting-edge tech and listen to tech luminaries
present their vision of the future. This family event has something for
everyone, including kids. Get more information and register today.
http://sdm.link/attshape
___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel


[EGIT] [core/efl] master 01/01: evas object: Hide "del" event

2016-06-26 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=b48726989d5b8de0079dadd061de566514124143

commit b48726989d5b8de0079dadd061de566514124143
Author: Jean-Philippe Andre 
Date:   Fri Jun 24 17:17:20 2016 +0900

evas object: Hide "del" event

In EO world, we should stick to EO_EVENT_DEL.
---
 src/lib/elementary/elm_widget.c | 2 ++
 src/lib/evas/canvas/efl_canvas_object.eo| 2 +-
 src/lib/evas/canvas/evas_object_table.c | 2 ++
 src/lib/evas/canvas/evas_object_textblock.c | 3 +++
 4 files changed, 8 insertions(+), 1 deletion(-)

diff --git a/src/lib/elementary/elm_widget.c b/src/lib/elementary/elm_widget.c
index b670a1d..ad84720 100644
--- a/src/lib/elementary/elm_widget.c
+++ b/src/lib/elementary/elm_widget.c
@@ -6,6 +6,8 @@
 #define ELM_INTERFACE_ATSPI_COMPONENT_PROTECTED
 #define ELM_WIDGET_PROTECTED
 #define ELM_WIDGET_ITEM_PROTECTED
+#define EFL_CANVAS_OBJECT_BETA
+
 #include 
 
 #include "elm_priv.h"
diff --git a/src/lib/evas/canvas/efl_canvas_object.eo 
b/src/lib/evas/canvas/efl_canvas_object.eo
index adb66ef..1af0a78 100644
--- a/src/lib/evas/canvas/efl_canvas_object.eo
+++ b/src/lib/evas/canvas/efl_canvas_object.eo
@@ -724,7 +724,7 @@ abstract Efl.Canvas.Object (Eo.Base, Efl.Gfx, 
Efl.Gfx.Stack, Efl.Animator,
key,up @beta; [[Key Release Event ]]
focus,in; [[Focus In Event ]]
focus,out; [[Focus Out Event ]]
-   del; [[Object Being Deleted (called before Free) ]]
+   del @beta; [[Object Being Deleted (called before Free) ]]
hold; [[Events go on/off hold ]]
}
 }
diff --git a/src/lib/evas/canvas/evas_object_table.c 
b/src/lib/evas/canvas/evas_object_table.c
index b62b531..478685f 100644
--- a/src/lib/evas/canvas/evas_object_table.c
+++ b/src/lib/evas/canvas/evas_object_table.c
@@ -1,3 +1,5 @@
+#define EFL_CANVAS_OBJECT_BETA
+
 #include "evas_common_private.h"
 #include "evas_private.h"
 #include 
diff --git a/src/lib/evas/canvas/evas_object_textblock.c 
b/src/lib/evas/canvas/evas_object_textblock.c
index 85c3e98..d331bc5 100644
--- a/src/lib/evas/canvas/evas_object_textblock.c
+++ b/src/lib/evas/canvas/evas_object_textblock.c
@@ -61,6 +61,9 @@
  * @subsection textblock_layout The layout system
  * @todo write @ref textblock_layout
  */
+
+#define EFL_CANVAS_OBJECT_BETA
+
 #include "evas_common_private.h"
 #include "evas_private.h"
 

-- 




[EGIT] [core/efl] master 02/03: evas: Make shaders regen an opt-in behaviour

2016-06-27 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=89dca5ba6c4ebbe5b5b11e8e3e14f73753b443c9

commit 89dca5ba6c4ebbe5b5b11e8e3e14f73753b443c9
Author: Jean-Philippe Andre 
Date:   Mon Jun 27 16:00:50 2016 +0900

evas: Make shaders regen an opt-in behaviour

While the shaders automatic regeneration is very useful when
working on shaders, it has been the source of too many
build breaks.

So I'm making this regeneration an opt-in.

You work on shaders?
Set the env var EFL_SHD_REGEN=1
---
 src/Makefile_Evas.am | 12 
 1 file changed, 8 insertions(+), 4 deletions(-)

diff --git a/src/Makefile_Evas.am b/src/Makefile_Evas.am
index 9d45c16..118741c 100644
--- a/src/Makefile_Evas.am
+++ b/src/Makefile_Evas.am
@@ -774,8 +774,10 @@ $(NULL)
 EXTRA_DIST2 += $(EVAS_GL_SHADERS_GEN)
 
 modules/evas/engines/gl_common/shader/evas_gl_shaders.x: 
$(EVAS_GL_SHADERS_GEN) 
$(top_srcdir)/src/modules/evas/engines/gl_common/shader/gen_shaders.sh
-   @echo "  SHADERS  $@"
-   @sh 
$(top_srcdir)/src/modules/evas/engines/gl_common/shader/gen_shaders.sh
+   @if [ "x$(EFL_SHD_REGEN)" = "x1" ] ; then \
+ echo "  SHADERS  $@" ; \
+ sh 
$(top_srcdir)/src/modules/evas/engines/gl_common/shader/gen_shaders.sh ; \
+   fi
 
 modules/evas/engines/gl_common/evas_gl_shader.c: 
modules/evas/engines/gl_common/shader/evas_gl_shaders.x
 
@@ -807,8 +809,10 @@ modules/evas/engines/gl_common/shader_3d/include.shd \
 $(GL_SHADERS_3D_GEN)
 
 modules/evas/engines/gl_common/shader_3d/evas_gl_3d_shaders.x: 
$(top_srcdir)/src/modules/evas/engines/gl_common/shader_3d/gen_shaders_3d.sh 
$(GL_SHADERS_3D_GEN) 
$(top_srcdir)/src/modules/evas/engines/gl_common/shader_3d/include.shd
-   @echo "  SHADERS  $@"
-   @sh 
$(top_srcdir)/src/modules/evas/engines/gl_common/shader_3d/gen_shaders_3d.sh 
$(GL_SHADERS_3D_GEN)
+   @if [ "x$(EFL_SHD_REGEN)" = "x1" ] ; then \
+ echo "  SHADERS  $@" ; \
+ sh 
$(top_srcdir)/src/modules/evas/engines/gl_common/shader_3d/gen_shaders_3d.sh 
$(GL_SHADERS_3D_GEN) ; \
+   fi
 
 modules/evas/engines/gl_common/evas_gl_3d_shader.c: 
modules/evas/engines/gl_common/shader_3d/evas_gl_3d_shaders.x
 

-- 




[EGIT] [core/efl] master 01/03: Revert "evas: Fix compilation when using different build directory"

2016-06-27 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=4adbd32a52b928158d2bd0e2fd973178e305c3b4

commit 4adbd32a52b928158d2bd0e2fd973178e305c3b4
Author: Jean-Philippe Andre 
Date:   Mon Jun 27 15:30:47 2016 +0900

Revert "evas: Fix compilation when using different build directory"

This reverts commit 3c13ef14e3511611cabf184ff0b83c264b3e620d.

This introduced new build breaks, especially with in-tree builds.
In particular, DIR was not defined. See T3975.

I'll make the shaders regen an opt-in rather than on by default.
---
 src/Makefile_Evas.am|  4 ++--
 src/modules/evas/engines/gl_common/shader/gen_shaders.sh|  7 ---
 .../evas/engines/gl_common/shader_3d/gen_shaders_3d.sh  | 13 ++---
 3 files changed, 12 insertions(+), 12 deletions(-)

diff --git a/src/Makefile_Evas.am b/src/Makefile_Evas.am
index 4627522..9d45c16 100644
--- a/src/Makefile_Evas.am
+++ b/src/Makefile_Evas.am
@@ -775,7 +775,7 @@ EXTRA_DIST2 += $(EVAS_GL_SHADERS_GEN)
 
 modules/evas/engines/gl_common/shader/evas_gl_shaders.x: 
$(EVAS_GL_SHADERS_GEN) 
$(top_srcdir)/src/modules/evas/engines/gl_common/shader/gen_shaders.sh
@echo "  SHADERS  $@"
-   @sh 
$(top_srcdir)/src/modules/evas/engines/gl_common/shader/gen_shaders.sh 
$(top_builddir)/src/modules/evas/engines/gl_common/shader/evas_gl_shaders.x
+   @sh 
$(top_srcdir)/src/modules/evas/engines/gl_common/shader/gen_shaders.sh
 
 modules/evas/engines/gl_common/evas_gl_shader.c: 
modules/evas/engines/gl_common/shader/evas_gl_shaders.x
 
@@ -808,7 +808,7 @@ $(GL_SHADERS_3D_GEN)
 
 modules/evas/engines/gl_common/shader_3d/evas_gl_3d_shaders.x: 
$(top_srcdir)/src/modules/evas/engines/gl_common/shader_3d/gen_shaders_3d.sh 
$(GL_SHADERS_3D_GEN) 
$(top_srcdir)/src/modules/evas/engines/gl_common/shader_3d/include.shd
@echo "  SHADERS  $@"
-   @sh 
$(top_srcdir)/src/modules/evas/engines/gl_common/shader_3d/gen_shaders_3d.sh 
$(top_builddir)/src/modules/evas/engines/gl_common/shader_3d/evas_3d_shaders.x 
$(GL_SHADERS_3D_GEN)
+   @sh 
$(top_srcdir)/src/modules/evas/engines/gl_common/shader_3d/gen_shaders_3d.sh 
$(GL_SHADERS_3D_GEN)
 
 modules/evas/engines/gl_common/evas_gl_3d_shader.c: 
modules/evas/engines/gl_common/shader_3d/evas_gl_3d_shaders.x
 
diff --git a/src/modules/evas/engines/gl_common/shader/gen_shaders.sh 
b/src/modules/evas/engines/gl_common/shader/gen_shaders.sh
index 3ba7a4d..7c2fec1 100755
--- a/src/modules/evas/engines/gl_common/shader/gen_shaders.sh
+++ b/src/modules/evas/engines/gl_common/shader/gen_shaders.sh
@@ -2,7 +2,10 @@
 
 # This script will generate a C file containing all the shaders used by Evas
 
-OUTPUT=$1
+DIR=`dirname $0`
+cd $DIR/../../../../../
+
+OUTPUT="$DIR/evas_gl_shaders.x"
 
 # Skip generation during make distcheck
 if [ "${top_distdir}" != "" ] ; then exit 0; fi
@@ -18,8 +21,6 @@ then
   exit 0
 fi
 
-echo $DIR
-
 exec 1<&-
 exec 1>"$OUTPUT"
 
diff --git a/src/modules/evas/engines/gl_common/shader_3d/gen_shaders_3d.sh 
b/src/modules/evas/engines/gl_common/shader_3d/gen_shaders_3d.sh
index ffefda4..f31880f 100755
--- a/src/modules/evas/engines/gl_common/shader_3d/gen_shaders_3d.sh
+++ b/src/modules/evas/engines/gl_common/shader_3d/gen_shaders_3d.sh
@@ -2,11 +2,10 @@
 
 # This script will generate a C file containing all the shaders used by Evas_3D
 
-OUTPUT="$1"
-OUTDIR=$(dirname ${OUTPUT})
-INDIR=`dirname $0`
+DIR=`dirname $0`
+cd $DIR/../../../../../
 
-mkdir -p $OUTDIR
+OUTPUT="$DIR/evas_gl_3d_shaders.x"
 
 # Skip generation during make distcheck
 if [ "${top_distdir}" != "" ] ; then exit 0; fi
@@ -16,7 +15,7 @@ if [ -e ${OUTPUT} ] && [ ! -w ${OUTPUT} ] ; then exit 0; fi
 
 # Skip generation if there is no diff (or no git)
 if ! git rev-parse 2>> /dev/null >> /dev/null ; then exit 0 ; fi
-if git diff --quiet --exit-code -- "$OUTDIR"
+if git diff --quiet --exit-code -- "$DIR"
 then
   touch "$OUTPUT"
   exit 0
@@ -25,7 +24,7 @@ fi
 exec 1<&-
 exec 1>"$OUTPUT"
 
-SHADERS=${@:2}
+SHADERS=$@
 VERT_SHADERS_SOURCE=""
 FRAG_SHADERS_SOURCE=""
 
@@ -43,7 +42,7 @@ for SHD in $SHADERS ; do
 FRAG_SHADERS_SOURCE="$FRAG_SHADERS_SOURCE"$LNAME"_glsl,\n"
   fi
 
-  m4 "$INDIR/include.shd" "$SHD" > "$SHD.tmp"
+  m4 "$DIR/include.shd" "$SHD" > "$SHD.tmp"
 
   OIFS="$IFS"
   IFS=`printf '\n+'`

-- 




Re: [E-devel] promises...

2016-06-17 Thread Jean-Philippe André
On 17 June 2016 at 17:21, Tom Hacohen <t...@osg.samsung.com> wrote:

> On 17/06/16 03:21, Carsten Haitzler wrote:
> > On Thu, 16 Jun 2016 19:29:52 +0100 Tom Hacohen <t...@osg.samsung.com>
> said:
> >
> >> On 16/06/16 10:47, Carsten Haitzler wrote:
> >>> On Thu, 16 Jun 2016 14:28:22 +0900 Jean-Philippe André <
> j...@videolan.org>
> >>> said:
> >>>
> >>>
> >>>>>> The ON_HOLD flag, now called efl_event_processed_get/set() is a
> better
> >>>>>> approach to stop processing events.
> >>>>>
> >>>>> That is off topic, but seriously something we should consider asap if
> >>>>> we want to drop the return type of event. I have not any case in mind
> >>>>> where returning EINA_FALSE make sense. Should we drop it ?
> >>>>>
> >>>>
> >>>> I am also thinking we should drop it.
> >>>> Pretty sure the few places that return EINA_FALSE right now are
> actually
> >>>> mistakes and sources of bugs.
> >>>
> >>> i think so too. drop the return.
> >>>
> >>
> >> The return is mega useful, though I'm open to implementing it
> >> differently. The return is there so you can filter events. We currently
> >> have things like "on_hold" in input events to mark an event has been
> >> processed and should stop propagating, but the return lets you stop the
> >> callback. I guess we can change it to be "eo_event_callback_stop(obj)".
> >
> > but the thing is.. we don't want to stop the callback. well not where
> hold is
> > used. you want to still get the cb but put on hold any actions.like
> calling the
> > clicked callback. you still need the event to get the matching mouse up
> fro the
> > mouse down for example, but since you started a drag, after n move
> events the
> > mouse up (and future moves) should not be acted on.
> >
> >> Btw, it shouldn't be a bool, there are defines for the return values. I
> >> should have typedeffed the type. I'm open to changing to
> >> eo_event_callback_stop though, just let me know.
> >>
> >> Grep for EO_EVENT_STOP, it is already used by code, even code I didn't
> >> write. :)
> >
> > see above. the only use case we have to date is the above and a return
> just
> > doesn't do it. you need to have a modified event go through afterwards.
> >
> > i did the return true/false for ecore events for pass through. over the
> years i
> > have recognized this as a mistake. it's more pain than gain.
>
> Again, I don't mind changing it to eo_event_callback_stop(obj). Feels
> better for making event propagation to stop, but I do like being able to
> stop it. It is used in the EFL, I just got the name wrong,
> EO_CALLBACK_STOP. :)
> It's useful for text filtering iirc, to make it stop processing the
> filter if one has already failed. It is used and useful.
>
>
obj here would then be the Eo_Event's object?
As Cedric noted, this is not like ON_HOLD (actually called "processed"),
because we call that on the event->info.

I agree stop can be useful sometimes, but only quite rarely (in practice,
in our code).

-- 
Jean-Philippe André
--
What NetFlow Analyzer can do for you? Monitors network bandwidth and traffic
patterns at an interface-level. Reveals which users, apps, and protocols are 
consuming the most bandwidth. Provides multi-vendor support for NetFlow, 
J-Flow, sFlow and other flows. Make informed decisions using capacity planning
reports. http://sdm.link/zohomanageengine
___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel


Re: [E-devel] promises...

2016-06-15 Thread Jean-Philippe André
Hi,

On 16 June 2016 at 05:41, Cedric BAIL <cedric.b...@free.fr> wrote:

> Hello,
>
> Ok, I am giving up on this. We will make it an eo object, but not an
> eolian one as it should be a native type for any binding (It is sure
> that C++, Lua and JS will have to do a manual binding for it) as there
> is very little case were inheritance make sense on promise and
> wouldn't at the same time break binding. eina_promise_owner will
> become eo_promise and eina_promise will become eo_future (to follow
> C++ naming convention). Not to sure how to limit the interface exposed
> by a return type as we don't want the user of the API to access the
> promise API, just the future one. Double object would be annoying, but
> is likely the only solution. So if we want to be safe, we will need to
> use 2 objects per promise. One facing the user of the API and one used
> by the producer of the API. If we don't want to be safe, we can merge
> both API and just use inheritance. So returning an eo_future interface
> in the API, while in fact eo_promise function would work on it.
>
> On Mon, Jun 13, 2016 at 7:23 PM, Jean-Philippe André <j...@videolan.org>
> wrote:
> > On 14 June 2016 at 02:28, Felipe Magno de Almeida <
> > felipe.m.alme...@gmail.com> wrote:
> >> Sorry for top-posting. But let me summarize the Promise lifetime:
>


> >>
> >> Eina_Promise* p = ...;
> >> eina_promise_all(p, ...);
> >> // promise will be deleted
> >> // when callback for the then is called
> >
> > So my understanding here is that this can work because a promise can not
> > ever be synchronous.
> > In other words, eina_promise_then can never trigger the success/error
> > callback to be called synchronously, otherwise the above reference count
> > system falls apart.
> >
> > While this approach is convenient, it means that we can use an object
> > (promise) we don't hold any reference on (after first _then).
> > This is weird :)
>
> Agreed.
>

Ok




>
> > The ON_HOLD flag, now called efl_event_processed_get/set() is a better
> > approach to stop processing events.
>
> That is off topic, but seriously something we should consider asap if
> we want to drop the return type of event. I have not any case in mind
> where returning EINA_FALSE make sense. Should we drop it ?
>

I am also thinking we should drop it.
Pretty sure the few places that return EINA_FALSE right now are actually
mistakes and sources of bugs.



>
> >> >> Anyway it seems the only difference here is that a promise starts the
> >> >> action as soon as possible, while an eo object would have to
> >> explicitely be
> >> >> marked as ready (which is very similar to starting the action during
> >> >> eina_promise_then).
> >> >
> >> > No, the main difference is that the life cycle is linked to the
> >> > callbacks and that their should not be any way to bypass it. eo_del
> >> > should also be forbidden for example on a promise as only a cancel
> >> > make sense. Of course we could alias it, and make sure that cancel
> >> > don't destroy the parent. We can also override all eo event API and
> >> > make sure they do what we want, but we can't at the moment override
> >> > eo_ref and eo_unref. The alternative would be to create an Eo_Promise
> >> > which doesn't inherit from Eo_Base (Or make an Eo_Light that both
> >> > would inherit from) and would kind of make clear that it is not an Eo
> >> > object, but a promise object (Given that eo_ref and eo_unref become
> >> > virtual function).
> >> >
> >> > Also at which point do you think user are going to be confused by an
> >> > Eo object where every single function call on it has its own
> >> > documentation and doesn't behave like a normal eo object ?
> >
> > That's where we still disagree :)
> >
> > I still have trouble understanding how fundamentally different those two
> > objects are.
> > In fact I see a lot of similarities between a (conceptual) promise and
> > Efl.Part.
> >
> > From my understanding, the main difference is that a promise callback
> WILL
> > be called, be it the error or success, one of them will be, for each
> _then,
> > _race and _all that was setup. Which can be enforced with a commit
> approach:
> >
> > // same syntax as eina_promise:
> > p = promise_function(obj)
> > eo_promise_then(p, _success, _error, data) // this is a HELPER based on
> eo
> > events, implemented in Eo.Promise, steals the ref
> >
&

[EGIT] [core/efl] master 01/01: Efl: Fix a build break

2016-06-17 Thread Jean-Philippe ANDRÉ
jpeg pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=413549301fa34b93e779ce53d49c69e15ad4bdb4

commit 413549301fa34b93e779ce53d49c69e15ad4bdb4
Author: Jean-Philippe ANDRE 
Date:   Fri Jun 17 20:34:55 2016 +0900

Efl: Fix a build break

Strange doc reference has decided to break the build now.
Not sure why it worked before and not anymore...
---
 src/lib/efl/interfaces/efl_image.eo | 1 +
 1 file changed, 1 insertion(+)

diff --git a/src/lib/efl/interfaces/efl_image.eo 
b/src/lib/efl/interfaces/efl_image.eo
index 9d79e8c..a8b2337 100644
--- a/src/lib/efl/interfaces/efl_image.eo
+++ b/src/lib/efl/interfaces/efl_image.eo
@@ -1,4 +1,5 @@
 import efl_gfx_types;
+import efl_gfx_fill;
 
 enum Efl.Image.Content_Hint
 {

-- 




Re: [E-devel] Eina value optional

2016-01-26 Thread Jean-Philippe André
On 27 January 2016 at 00:03, Felipe Magno de Almeida <
felipe.m.alme...@gmail.com> wrote:

> On Tue, Jan 26, 2016 at 12:51 PM, Tom Hacohen <t...@osg.samsung.com> wrote:
> > On 26/01/16 14:42, Stefan Schmidt wrote:
> >> Hello.
>
> [snip]
>
> >> JP, Tom are you happy with Felipe's explanation? If not we need to act
> >> now as we only have 6 days left before the release and once it is in
> >> 1.17 it will stay.
> >
> > My concern was about the docs. Haven't reviewed the concept.
>
> There always were docs.
>
> https://build.enlightenment.org/job/nightly_efl_gcc_x86_64/lastSuccessfulBuild/artifact/doc/html/group__Eina__Value__Optional__Group.html
>
> It might be improved maybe with some motivation information.
> <https://lists.sourceforge.net/lists/listinfo/enlightenment-devel>
>

Yes, there are docs as to how, I was asking about why. And got my answer :)
The motivation can be documented as well, but it's not a release blocker.

Thanks,

-- 
Jean-Philippe André
--
Site24x7 APM Insight: Get Deep Visibility into Application Performance
APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month
Monitor end-to-end web transactions and take corrective actions now
Troubleshoot faster and improve end-user experience. Signup Now!
http://pubads.g.doubleclick.net/gampad/clk?id=267308311=/4140
___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel


Re: [E-devel] Scan-build (clang based static analyser) to be removed from our Jenkins

2016-01-28 Thread Jean-Philippe André
On 28 January 2016 at 19:43, Boris Faure <bo...@fau.re> wrote:

> On 16-01-28 11:31, Stefan Schmidt wrote:
> > Hello.
> >
> > After switching to git push notifications and removing the x32 builds
> > this is the next step of our QA tools consolidation.
> >
> > Scan-build is a small tool which uses the static analysis functionality
> > coming with clang. We have it running on Jenkins almost from the
> > beginning but due to the many false positives and limited functionality
> > of dealing with defects (it just generates a static html page) people
> > never really jumped on it.
> >
> > The efl build was actually disabled since end of 2014 as we experienced
> > some problems and it was never turned back on.
> >
> >
> https://build.enlightenment.org/job/nightly_elm_clang_x86_64/lastSuccessfulBuild/artifact/scan-build/build/
> >
> https://build.enlightenment.org/job/nightly_efl_clang_x86_64/lastSuccessfulBuild/artifact/scan-build/build
> >
> > If anyone wants to run this on our code it can still be done manually on
> > your local host, but I see no benefit of having it on Jenkins and
> > running every night (at least for elm).
> > If you disagree speak up now as I'm going to remove it from Jenkins next
> > week if nobody complains.
>
> Coverity is doing a good job for our needs of static analysis.
> scan-build is no longer relevant. Go ahead!
>

I agree. clang static analyzer is simple enough to run locally, but too
noisy to produce valuable stats.

-- 
Jean-Philippe André
--
Site24x7 APM Insight: Get Deep Visibility into Application Performance
APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month
Monitor end-to-end web transactions and take corrective actions now
Troubleshoot faster and improve end-user experience. Signup Now!
http://pubads.g.doubleclick.net/gampad/clk?id=267308311=/4140
___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel


Re: [E-devel] [EGIT] [core/efl] master 01/01: Eina_Value: do not mix declarations and code

2016-02-02 Thread Jean-Philippe André
ility into Application Performance
> > APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month
> > Monitor end-to-end web transactions and take corrective actions now
> > Troubleshoot faster and improve end-user experience. Signup Now!
> > http://pubads.g.doubleclick.net/gampad/clk?id=267308311=/4140
> > ___
> > enlightenment-devel mailing list
> > enlightenment-devel@lists.sourceforge.net
> > https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
> >
>
> --
> Site24x7 APM Insight: Get Deep Visibility into Application Performance
> APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month
> Monitor end-to-end web transactions and take corrective actions now
> Troubleshoot faster and improve end-user experience. Signup Now!
> http://pubads.g.doubleclick.net/gampad/clk?id=267308311=/4140
> ___
> enlightenment-devel mailing list
> enlightenment-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
>
>


-- 
Jean-Philippe André
--
Site24x7 APM Insight: Get Deep Visibility into Application Performance
APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month
Monitor end-to-end web transactions and take corrective actions now
Troubleshoot faster and improve end-user experience. Signup Now!
http://pubads.g.doubleclick.net/gampad/clk?id=267308311=/4140
___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel


Re: [E-devel] Last minute genlist fix

2016-01-31 Thread Jean-Philippe André
Hi again,

On 1 February 2016 at 13:57, Jean-Philippe André <j...@videolan.org> wrote:

> Hi,
>
> On 1 February 2016 at 06:04, Davide Andreoli <d...@gurumeditation.it>
> wrote:
>
>> Hi all,
>>
>> I was not able to speak with noone in chat in the last days, so here is a
>> last-minute-fix for Genlist/grid:
>>
>> https://phab.enlightenment.org/T3122
>>
>> Patch is really simple, the problem is just a wrong cast that make the if
>> statement always false.
>>
>> Please review and commit BEFORE the release, it is really important for
>> me,
>> or I will have to postpone my epymc release for other 3 months.
>>
>> THANKS
>>
>
> The patch itself looks good. This is definitely fixing a bad casting issue.
>
> I can't merge this in because it reveals another bug in genlist. Unrelated
> to your direct fix, but related to the items cache.
> See my comments in the ticket.
>
> Maybe we can find a solution, if we accept to delay the release...
> But you should probably first explain what was the issue on your side.
>

After more testing, and in particular testing Davide's app (epymc), I can
definitely say that the fix is good, and the new issue I see has nothing to
do with this fix. Also, it doesn't happen all the time, only sometimes.

So I pushed this patch: 2ad850e99769c6cc0eb002a497bcfb4432132fa8

-- 
Jean-Philippe André
--
Site24x7 APM Insight: Get Deep Visibility into Application Performance
APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month
Monitor end-to-end web transactions and take corrective actions now
Troubleshoot faster and improve end-user experience. Signup Now!
http://pubads.g.doubleclick.net/gampad/clk?id=267308311=/4140
___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel


Re: [E-devel] Last minute genlist fix

2016-01-31 Thread Jean-Philippe André
Hi,

On 1 February 2016 at 06:04, Davide Andreoli <d...@gurumeditation.it> wrote:

> Hi all,
>
> I was not able to speak with noone in chat in the last days, so here is a
> last-minute-fix for Genlist/grid:
>
> https://phab.enlightenment.org/T3122
>
> Patch is really simple, the problem is just a wrong cast that make the if
> statement always false.
>
> Please review and commit BEFORE the release, it is really important for me,
> or I will have to postpone my epymc release for other 3 months.
>
> THANKS
>

The patch itself looks good. This is definitely fixing a bad casting issue.

I can't merge this in because it reveals another bug in genlist. Unrelated
to your direct fix, but related to the items cache.
See my comments in the ticket.

Maybe we can find a solution, if we accept to delay the release...
But you should probably first explain what was the issue on your side.

-- 
Jean-Philippe André
--
Site24x7 APM Insight: Get Deep Visibility into Application Performance
APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month
Monitor end-to-end web transactions and take corrective actions now
Troubleshoot faster and improve end-user experience. Signup Now!
http://pubads.g.doubleclick.net/gampad/clk?id=267308311=/4140
___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel


Re: [E-devel] Porting old theme: file manager window empty

2016-02-01 Thread Jean-Philippe André
On 1 February 2016 at 18:32, Martin Dietze <mdie...@gmail.com> wrote:

> In the progress of porting two old themes, "Vulcan Retro" and
> "blingbling", to e20 I have run into another problem. While both
> themes "work" (i.e. look good most of the time, don't cause any
> trouble), there is one thing so far that does not work at all: The
> file manager window shows as an empty white space in its window.
>

A big empty white space? This sounds like a big clipper to me.
So probably some object was used as a clipper (usually a big white opaque
rectangle), and for whatever reason this clipper is not required anymore.


> After removing the old file manager theme code completely the file
> manager appears again (with the default theme, of course). Since the
> inherited theme code for the file manager (as well as file manager
> theme code from more recent themes) is quite long I don't just "see"
> what's wrong.
>
> The theme migration guide does not mention the file manager apart from
> new slots (which I cannot imagine to be the reason for this).
>
> To me it looks like there must be a rather simple and stupid reason for
> that.
>
> Maybe somebody who has ported old themes has got an idea what could be
> wrong?
>
> Cheers,
>
> Martin
>
> Just in case, both themes' source code is on my github account:
> - https://github.com/mbert/etheme-vulcan-retro-e20
> - https://github.com/mbert/etheme-blingbling-e20
>
> --
> Dr. Martin Dietze
> 1. Vorsitzender
> Deutsch-Ukrainischer Kulturverein e.V.
> http://www.deutsch-ukrainischer-kulturverein.de/


I haven't looked at the code, this is just guessing.
Good luck hunting this object!

-- 
Jean-Philippe André
--
Site24x7 APM Insight: Get Deep Visibility into Application Performance
APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month
Monitor end-to-end web transactions and take corrective actions now
Troubleshoot faster and improve end-user experience. Signup Now!
http://pubads.g.doubleclick.net/gampad/clk?id=267308311=/4140
___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel


Re: [E-devel] Porting old theme: file manager window empty

2016-02-01 Thread Jean-Philippe André
On 1 February 2016 at 20:46, Martin Dietze <mdie...@gmail.com> wrote:

> On 1 February 2016 at 11:39, Jean-Philippe André <j...@videolan.org>
> wrote:
> > I haven't looked at the code, this is just guessing.
> > Good luck hunting this object!
>
> Great, that helped. I've found and elimitated it.
>

Glad to read that!


> While there, got any hint why the old code no longer applies for the
> toolbars? They all appear like in the default theme.
> Maybe the parts containing the code in the old themes no longer apply?
> In 'blingbling' it is 'e/toolbar/default/base'. Again I could not find
> this in the migration guide (maybe I just missed that information?).
>
>
A quick check shows that the new theme indeed has nothing containing
"e/toolbar". It has "e/widgets/toolbar" and "elm/toolbar".
Either the migration guide lacks this info (please add it), or you just
missed it :)


> But anyway I'm grateful that it is at least working now, thank you again!
>
> Cheers,
>
> Martin
>
>
> --
> Dr. Martin Dietze
> 1. Vorsitzender
> Deutsch-Ukrainischer Kulturverein e.V.
> http://www.deutsch-ukrainischer-kulturverein.de/
>
>
> --
> Site24x7 APM Insight: Get Deep Visibility into Application Performance
> APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month
> Monitor end-to-end web transactions and take corrective actions now
> Troubleshoot faster and improve end-user experience. Signup Now!
> http://pubads.g.doubleclick.net/gampad/clk?id=267308311=/4140
> ___
> enlightenment-devel mailing list
> enlightenment-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
>



-- 
Jean-Philippe André
--
Site24x7 APM Insight: Get Deep Visibility into Application Performance
APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month
Monitor end-to-end web transactions and take corrective actions now
Troubleshoot faster and improve end-user experience. Signup Now!
http://pubads.g.doubleclick.net/gampad/clk?id=267308311=/4140
___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel


Re: [E-devel] [EGIT] [core/elementary] master 01/01: win: redo resize deferral to trigger during pre render

2016-01-28 Thread Jean-Philippe André
On 29 January 2016 at 08:27, Cedric BAIL <cedric.b...@free.fr> wrote:

> On Thu, Jan 28, 2016 at 3:12 PM, Stefan Schmidt <ste...@osg.samsung.com>
> wrote:
> > On 10/12/15 21:56, Mike Blumenkrantz wrote:
> >> discomfitor pushed a commit to branch master.
> >>
> >>
> http://git.enlightenment.org/core/elementary.git/commit/?id=6149fd7a0a9ef3f9495270cf1c4ab7727a30f21c
> >>
> >> commit 6149fd7a0a9ef3f9495270cf1c4ab7727a30f21c
> >> Author: Mike Blumenkrantz <zm...@osg.samsung.com>
> >> Date:   Thu Dec 10 15:53:31 2015 -0500
> >>
> >>  win: redo resize deferral to trigger during pre render
> >>
> >>  using a job results in the resize occurring after render in the
> same loop,
> >>  meaning that anything which depends on resizes to happen in a
> certain
> >>  time will not have synchronized display vs toolkit geometries
> >>
> >>  fixes all issues related to wayland window geometries
> >
> > This commit breaks the widget screenshot generation for our Elementary
> > docs. Two example from our nightly doc generation:
> >
> >
> https://build.enlightenment.org/job/nightly_elm_gcc_x86_64/lastSuccessfulBuild/artifact/doc/html/group__Button.html
> >
> https://build.enlightenment.org/job/nightly_elm_gcc_x86_64/lastSuccessfulBuild/artifact/doc/html/group__Flip.html
> >
> > As you can see the image are off or completely broken. They should
> > actually look like this (from our 1.16 docs)
> >
> > https://docs.enlightenment.org/elementary/current/group__Button.html
> > https://docs.enlightenment.org/elementary/current/group__Flip.html
> >
> > Thanks to Jean Rene Dawin for reporting it. It took me a long time to
> > git bisect'ing it down to this commit. Reverting it locally fixes the
> > problem.
> >
> > I'm open for suggestions how we fix this and still fix the problem the
> > commit originally tried to fix.
>
> Relying on render pre make sense in this patch. I am wondering how
> exactness and our doc subsystem do the screenshot. Do you have a
> pointer to it ?
>
>
make doc for elementary relies on the "shot" engine. I don't know the exact
wrt. this patch, though.

-- 
Jean-Philippe André
--
Site24x7 APM Insight: Get Deep Visibility into Application Performance
APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month
Monitor end-to-end web transactions and take corrective actions now
Troubleshoot faster and improve end-user experience. Signup Now!
http://pubads.g.doubleclick.net/gampad/clk?id=267308311=/4140
___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel


Re: [E-devel] [EGIT] [core/elementary] master 01/01: elm_widget: cleanup _elm_widget_on_focus function

2016-01-20 Thread Jean-Philippe André
On 20 January 2016 at 23:58, Cedric BAIL <cedric.b...@free.fr> wrote:

> On Jan 20, 2016 00:07, "Minkyu Kang" <mk7.k...@samsung.com> wrote:
> >
> > hermet pushed a commit to branch master.
> >
> >
>
> http://git.enlightenment.org/core/elementary.git/commit/?id=2eb95a547736af1445b0a292223ad8973ad24acb
> >
> > commit 2eb95a547736af1445b0a292223ad8973ad24acb
> > Author: Minkyu Kang <mk7.k...@samsung.com>
> > Date:   Wed Jan 20 17:06:22 2016 +0900
> >
> > elm_widget: cleanup _elm_widget_on_focus function
> >
> > Summary:
> > This patch will reduce duplicate codes and code depth for readability
> >
> > Signed-off-by: Minkyu Kang <mk7.k...@samsung.com>
> >
> > Reviewers: seoz, Hermet, cedric
> >
> > Subscribers: seoz
>
> I will let Stefan have his call here, but this commit doesn't look like a
> fix to me and does change a substantial amount of line we have no automated
> tests for.
>

It looks a lot like a simple cleanup to me. The logic looks unchanged to me.


>
> Cedric
>
> > Differential Revision: https://phab.enlightenment.org/D3574
> > ---
> >  src/lib/elm_widget.c | 36 ++--
> >  1 file changed, 14 insertions(+), 22 deletions(-)
> >
> > diff --git a/src/lib/elm_widget.c b/src/lib/elm_widget.c
> > index 97ef045..11d4ee0 100644
> > --- a/src/lib/elm_widget.c
> > +++ b/src/lib/elm_widget.c
> > @@ -5743,30 +5743,22 @@ _elm_widget_eo_base_destructor(Eo *obj,
> Elm_Widget_Smart_Data *sd EINA_UNUSED)
> >  EOLIAN static Eina_Bool
> >  _elm_widget_on_focus(Eo *obj, Elm_Widget_Smart_Data *sd, Elm_Object_Item
> *item EINA_UNUSED)
> >  {
> > -   if (elm_widget_can_focus_get(obj))
> > - {
> > -if (elm_widget_focus_get(obj))
> > -  {
> > - if (!sd->resize_obj)
> > -   evas_object_focus_set(obj, EINA_TRUE);
> > -  eo_do(obj, eo_event_callback_call
> > -   (ELM_WIDGET_EVENT_FOCUSED, NULL));
> > - if (_elm_config->atspi_mode &&
> !elm_widget_child_can_focus_get(obj))
> > -
>  elm_interface_atspi_accessible_state_changed_signal_emit(obj,
> ELM_ATSPI_STATE_FOCUSED, EINA_TRUE);
> > -  }
> > -else
> > -  {
> > - if (!sd->resize_obj)
> > -   evas_object_focus_set(obj, EINA_FALSE);
> > - eo_do(obj, eo_event_callback_call
> > -   (ELM_WIDGET_EVENT_UNFOCUSED, NULL));
> > - if (_elm_config->atspi_mode &&
> !elm_widget_child_can_focus_get(obj))
> > -
>  elm_interface_atspi_accessible_state_changed_signal_emit(obj,
> ELM_ATSPI_STATE_FOCUSED, EINA_FALSE);
> > -}
> > - }
> > -   else
> > +   Eina_Bool focused;
> > +   const Eo_Event_Description *desc;
> > +
> > +   if (!elm_widget_can_focus_get(obj))
> >   return EINA_FALSE;
> >
> > +   focused = elm_widget_focus_get(obj);
> > +   desc = focused ? ELM_WIDGET_EVENT_FOCUSED :
> ELM_WIDGET_EVENT_UNFOCUSED;
> > +
> > +   if (!sd->resize_obj)
> > + evas_object_focus_set(obj, focused);
> > +   eo_do(obj, eo_event_callback_call(desc, NULL));
> > +
> > +   if (_elm_config->atspi_mode && !elm_widget_child_can_focus_get(obj))
> > + elm_interface_atspi_accessible_state_changed_signal_emit(obj,
> ELM_ATSPI_STATE_FOCUSED, focused);
> > +
> > return EINA_TRUE;
> >  }
> >
> >
> > --
> >
> >
> >
>
> ------
> Site24x7 APM Insight: Get Deep Visibility into Application Performance
> APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month
> Monitor end-to-end web transactions and take corrective actions now
> Troubleshoot faster and improve end-user experience. Signup Now!
> http://pubads.g.doubleclick.net/gampad/clk?id=267308311=/4140
> ___
> enlightenment-devel mailing list
> enlightenment-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
>
>


-- 
Jean-Philippe André
--
Site24x7 APM Insight: Get Deep Visibility into Application Performance
APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month
Monitor end-to-end web transactions and take corrective actions now
Troubleshoot faster and improve end-user experience. Signup Now!
http://pubads.g.doubleclick.net/gampad/clk?id=267308311=/4140
___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel


Re: [E-devel] [EGIT] [core/elementary] master 01/01: elm_widget: cleanup _elm_widget_on_focus function

2016-01-21 Thread Jean-Philippe André
On 21 January 2016 at 19:27, Stefan Schmidt <ste...@osg.samsung.com> wrote:

> Hello.
>
> On 21/01/16 03:25, Jean-Philippe André wrote:
> > On 20 January 2016 at 23:58, Cedric BAIL <cedric.b...@free.fr> wrote:
> >
> >> On Jan 20, 2016 00:07, "Minkyu Kang" <mk7.k...@samsung.com> wrote:
> >>> hermet pushed a commit to branch master.
> >>>
> >>>
> >>
> http://git.enlightenment.org/core/elementary.git/commit/?id=2eb95a547736af1445b0a292223ad8973ad24acb
> >>> commit 2eb95a547736af1445b0a292223ad8973ad24acb
> >>> Author: Minkyu Kang <mk7.k...@samsung.com>
> >>> Date:   Wed Jan 20 17:06:22 2016 +0900
> >>>
> >>>  elm_widget: cleanup _elm_widget_on_focus function
> >>>
> >>>  Summary:
> >>>  This patch will reduce duplicate codes and code depth for
> readability
> >>>
> >>>  Signed-off-by: Minkyu Kang <mk7.k...@samsung.com>
> >>>
> >>>  Reviewers: seoz, Hermet, cedric
> >>>
> >>>  Subscribers: seoz
> >> I will let Stefan have his call here, but this commit doesn't look like
> a
> >> fix to me and does change a substantial amount of line we have no
> automated
> >> tests for.
> >>
> > It looks a lot like a simple cleanup to me. The logic looks unchanged to
> me.
> >
>
> IMHO the point it more about timing. We have 11 days left before 1.17
> should go out. I would prefer if people would look at the work items I
> posted and go through the bugtracker to find things that need to be
> fixed. Especially Elementary gets more and more bug reports with little
> people working on them upstream.
>
> Cleanup patches like this are indeed very welcome to remove code
> duplication and ease maintenance. But I really see no good reason why
> they could not have waited for 12 more days before they land.
>
> I looked at both patches and I can't find any logic problems with the
> re-factor either. Thus I'm not going to revert them but I'm not happy
> about the timing of these.
> <https://lists.sourceforge.net/lists/listinfo/enlightenment-devel>
>

OK. Makes sense :)

-- 
Jean-Philippe André
--
Site24x7 APM Insight: Get Deep Visibility into Application Performance
APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month
Monitor end-to-end web transactions and take corrective actions now
Troubleshoot faster and improve end-user experience. Signup Now!
http://pubads.g.doubleclick.net/gampad/clk?id=267308311=/4140
___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel


Re: [E-devel] Probie access

2016-01-21 Thread Jean-Philippe André
I'm actually just surprised he wasn't already a developer :)
+1

On 22 January 2016 at 09:15, Sung-Jin Park <input.hac...@gmail.com> wrote:

> I'd like to put +1 here, too, if I have the permission to vote. :)
> 2016. 1. 22. 오전 9:00에 "Mike Blumenkrantz" <michael.blumenkra...@gmail.com
> >님이
> 작성:
>
> > I cast 2 votes in favor of this proposal.
> >
> > On Thu, Jan 21, 2016 at 6:56 PM Christopher Michael <
> > cpmich...@osg.samsung.com> wrote:
> >
> > > I would like to Second this promotion !!
> > >
> > > +1 .. "till the cows come home" ;)
> > >
> > > Derek has been an invaluable resource while working on wayland items.
> > > Despite zmike influence ;) He's consistently provided excellent patches
> > > (use your grep log foo), and would be an Extremly valuable addition !!
> > >
> > > dh
> > >
> > >
> > > On 01/21/2016 06:50 PM, Cedric BAIL wrote:
> > > > Hello,
> > > >
> > > > I would like to promote Derek Foreman to become a probie. This would
> > > > really make life easier for development and debugging on wayland. He
> > > > is quite used to work and contribute to open source software and has
> > > > already been contributing patch to EFL. Let me know what you think of
> > > > it ?
> > > >
> > > > Thanks,
>

-- 
Jean-Philippe André
--
Site24x7 APM Insight: Get Deep Visibility into Application Performance
APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month
Monitor end-to-end web transactions and take corrective actions now
Troubleshoot faster and improve end-user experience. Signup Now!
http://pubads.g.doubleclick.net/gampad/clk?id=267308311=/4140
___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel


Re: [E-devel] [EGIT] [core/efl] master 05/05: Evas filters: Re-enable transform test case, remove dead code

2016-01-23 Thread Jean-Philippe André
On 22 January 2016 at 17:49, Stefan Schmidt <ste...@osg.samsung.com> wrote:

> Hello.
>
> On 22/01/16 07:52, Jean-Philippe ANDRÉ wrote:
> > jpeg pushed a commit to branch master.
> >
> >
> http://git.enlightenment.org/core/efl.git/commit/?id=7336b7ed9f9ea7c5f8b1e7ff46529ec8bf1845e4
> >
> > commit 7336b7ed9f9ea7c5f8b1e7ff46529ec8bf1845e4
> > Author: Jean-Philippe Andre <jp.an...@samsung.com>
> > Date:   Fri Jan 22 15:23:15 2016 +0900
> >
> >  Evas filters: Re-enable transform test case, remove dead code
> >
> >  Now that transform is fixed, this should be reenabled.
> > ---
> >   src/tests/evas/evas_test_filters.c | 23 ---
> >   1 file changed, 23 deletions(-)
> >
> > diff --git a/src/tests/evas/evas_test_filters.c
> b/src/tests/evas/evas_test_filters.c
> > index 43232e3..5301af8 100644
> > --- a/src/tests/evas/evas_test_filters.c
> > +++ b/src/tests/evas/evas_test_filters.c
> > @@ -188,16 +188,6 @@ START_TEST(evas_filter_parser)
> > "White"
> >  };
> >
> > -#if 0
> > -   // New color class defaults to black
> > -   static const char *colors_bad[] = {
> > -  "newcolor",
> > -  "ABC",
> > -  "#ZZZ",
> > -  "#-10"
> > -   };
> > -#endif
> > -
> >  for (size_t c = 0; c < sizeof(colors) / sizeof(colors[0]); c++)
> >{
> >   char buf[64];
> > @@ -205,17 +195,6 @@ START_TEST(evas_filter_parser)
> >   CHKGOOD(buf);
> >}
> >
> > -#if 0
> > -   fprintf(stderr, "Evas filters tests: start invalid cases. Ignore the
> following ERRs.\n");
> > -   for (size_t c = 0; c < sizeof(colors_bad) / sizeof(colors_bad[0]);
> c++)
> > - {
> > -char buf[64];
> > -sprintf(buf, "blend { color = '%s' }", colors_bad[c]);
> > -CHKBAAD(buf);
> > - }
> > -   fprintf(stderr, "Evas filters tests: end of invalid cases.\n");
> > -#endif
> > -
> >  // fillmodes are parsed when converting from instructions to
> commands
> >   }
> >   END_TEST
> > @@ -277,11 +256,9 @@ static struct Filter_Test_Case _test_cases[] = {
> >  { 7, 7, 7, 7, "a = buffer ({ 'rgba' }) b = buffer ({ 'rgba' })
> blend ({ dst = b, color = '#330' }) blend ({ dst = a }) displace ({ map =
> b, src = a, intensity = 7, flags = 'smooth_stretch' })", NULL },
> >
> >  /* FIXME Fix transform filter!!! FIXME */
>
> The FIXME can also get removed here as transform filters are fixed?
>

Good point :)


>
> regards
> Stefan Schmidt
>
> > -#if 0
> >  { 0, 0, 0, 40, "a = buffer ({ 'alpha' }) transform ({ a, 'vflip',
> oy = 20 }) blend ({ src = a })", NULL },
> >  { 0, 0, 40, 0, "a = buffer ({ 'alpha' }) transform ({ a, 'vflip',
> oy = -20 }) blend ({ src = a })", NULL },
> >  { 0, 0, 0, 40, "a = buffer ({ 'alpha' }) blend ({ dst = a })
> transform ({ a, 'vflip', oy = 20, src = a }) blend ({ src = a })", NULL },
> > -#endif
> >
> >  // Filter combos. TODO: Add some more tricky cases : })
> >  { 3, 5, 7, 11, "blend ({ ox = -3, oy = 11 })  blend ({ ox = 5, oy =
> -7 })", NULL },
> >
>
>
>
> ------
> Site24x7 APM Insight: Get Deep Visibility into Application Performance
> APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month
> Monitor end-to-end web transactions and take corrective actions now
> Troubleshoot faster and improve end-user experience. Signup Now!
> http://pubads.g.doubleclick.net/gampad/clk?id=267308311=/4140
> ___
> enlightenment-devel mailing list
> enlightenment-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
>



-- 
Jean-Philippe André
--
Site24x7 APM Insight: Get Deep Visibility into Application Performance
APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month
Monitor end-to-end web transactions and take corrective actions now
Troubleshoot faster and improve end-user experience. Signup Now!
http://pubads.g.doubleclick.net/gampad/clk?id=267308311=/4140
___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel


Re: [E-devel] Eo: Changes to syntax

2016-03-09 Thread Jean-Philippe André
te and your code will be
> > > wrong. If you need to correct something you've done wrong, reset the
> > > code to the previous state and run the script again on the original
> > > code. 2. The migration script is not perfect. In particular it can't
> > > deal with cases like missing {} for if/for/while content so for
> > > example,
> > >
> > > if ()
> > > return eo_add(...)
> > >
> > > would break.
> > > 3. If you are fancy and use the same variable inside eo_add and
> > > outside, for example like:
> > > parent = eo_add(CLASS, parent);
> > >
> > > your code will break. I suggest you use a temporary variable.
> > >
> > > So please be aware of that and *manually* review your changes after
> > > the script has run.
> > >
> > > If your code does have these cases, I recommend you either get rid of
> > > them, or manually migrate that code before running the script (remove
> > > the relevant eo_do).
> > >
> > >
> > >
> > > Sorry, but C++ will break until the C++ guys fix it. I'm now in the
> > > process of migrating the rest of our applications. Hopefully this
> > > will be the last disruption of this sort.
> > >
> >
> > Sorry man but the new syntax is ugly. I still don't see why this change
> was
> > needed. Please enlighten me. It reminds me the wonderful eo_do_ret
> syntax :-)
> >
> > So yes Tom I vomit on your eo_add
> >
> >
> >   BBEEEUUAH...
> >
> > %%
> > = =
> >    %%C>
> > _)' _( .' ,
> >  __/ |_/\   " *. o
> > /` \_\ \/ %`= '_  .
> >/  )   \/|  .^',*. ,
> >   /' /-   o/   - " % '_
> >  /\_/ <   = , ^ ~ .
> >  )_o|'|  .`  '
> >  ___// (_  - (\   eo_add(
> > ///-(\'   \\
>
> bwhahahahahha.


> the reason was eo add methods.
>
> obj = eo_add(..., text_set(obj, "x"), color_set(obj, 1, 2, 3, 4));
>
> because eo4 changes to pass obj into every method - that means obj has to
> be
> filled and defined with the RIGHT eo id before the extra text_set() is
> called
> because it passes it in, thus you have to pass a ptr to the eiod so it can
> be
> filled in first so it is correct for the following calls within the eo_add.
>

I know you don't like it but I can see two solutions to that:
1. a different macro for eo_add() that doesn't allow any function calls
before finalize (I believe it would be used quite often)
2. use a tls to store the currently created obj and add a macro to get it
in those inlined function calls, eg.
 obj = eo_add(CLASS, parent, do_something(eo_cur))

wrt. 1. I wonder how the bindings will even be able to create objects and
call functions before finalize?

Best regards,

-- 
Jean-Philippe André
--
Transform Data into Opportunity.
Accelerate data analysis in your applications with
Intel Data Analytics Acceleration Library.
Click to learn more.
http://pubads.g.doubleclick.net/gampad/clk?id=278785111=/4140
___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel


Re: [E-devel] Eo: Changes to syntax

2016-03-09 Thread Jean-Philippe André
> >
> > > > I created a new script that assumes the code has already been
> > > > migrated with the previous (migrate_eo.py) script. This script is
> > > > called migrate_eo_add.py and can be found at:
> > > > https://devs.enlightenment.org/~tasn/migrate_eo_add.py
> > > >
> > > > When using the script you should keep two things in mind:
> > > > 1. You are only allowed to run it *once* per source code, because
> > > > the changes to eo_add() would otherwise accumulate and your code
> > > > will be wrong. If you need to correct something you've done
> > > > wrong, reset the code to the previous state and run the script
> > > > again on the original code. 2. The migration script is not
> > > > perfect. In particular it can't deal with cases like missing {}
> > > > for if/for/while content so for example,
> > > >
> > > > if ()
> > > > return eo_add(...)
> > > >
> > > > would break.
> > > > 3. If you are fancy and use the same variable inside eo_add and
> > > > outside, for example like:
> > > > parent = eo_add(CLASS, parent);
> > > >
> > > > your code will break. I suggest you use a temporary variable.
> > > >
> > > > So please be aware of that and *manually* review your changes
> > > > after the script has run.
> > > >
> > > > If your code does have these cases, I recommend you either get
> > > > rid of them, or manually migrate that code before running the
> > > > script (remove the relevant eo_do).
> > > >
> > > >
> > > >
> > > > Sorry, but C++ will break until the C++ guys fix it. I'm now in
> > > > the process of migrating the rest of our applications. Hopefully
> > > > this will be the last disruption of this sort.
> > > >
> > >
> > > Sorry man but the new syntax is ugly. I still don't see why this
> > > change was needed. Please enlighten me. It reminds me the wonderful
> > > eo_do_ret syntax :-)
> > >
> > > So yes Tom I vomit on your eo_add
> > >
> > >
> > >   BBEEEUUAH...
> > >
> > > %%
> > > = =
> > >%%C>
> > > _)' _( .' ,
> > >  __/ |_/\   " *. o
> > > /` \_\ \/ %`= '_  .
> > >/  )   \/|  .^',*. ,
> > >   /' /-   o/   - " % '_
> > >  /\_/ <   = , ^ ~ .
> > >  )_o|'|  .`  '
> > >  ___// (_  - (\   eo_add(
> > > ///-(\'   \\
> >
> > bwhahahahahha.
> >
> > the reason was eo add methods.
> >
> > obj = eo_add(..., text_set(obj, "x"), color_set(obj, 1, 2, 3, 4));
> >
> > because eo4 changes to pass obj into every method - that means obj
> > has to be filled and defined with the RIGHT eo id before the extra
> > text_set() is called because it passes it in, thus you have to pass a
> > ptr to the eiod so it can be filled in first so it is correct for the
> > following calls within the eo_add.
>
> Why not just use some keyword for the object e.g THIS/EO_ME/whatever that
> would be replaced during preprocessing with eoid (that was defined in
> _eo_add_common)?
>

Because eoid can not be defined inside the eo_add macro.
The previous version of eo_add used a GCC construct like ({ Eo *eoid =
do_stuff; __VA_ARGS__; eoid; }) returning eoid.
But this is not standard C and so we shouldn't use this in our public
headers.

The new eo_add macro does not use the GCC construct so it's portable. But
ugly as hell.


>
> >
> > > > --
> > > > Tom.
> > > >
> > > >
> --
> > > > Transform Data into Opportunity.
> > > > Accelerate data analysis in your applications with
> > > > Intel Data Analytics Acceleration Library.
> > > > Click to learn more.
> > > > http://pubads.g.doubleclick.net/gampad/clk?id=278785111=/4140
> > > > ___
> > > > enlightenment-devel mailing list
> > > > enlightenment-devel@lists.sourceforge.net
> > > > https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
> > > >
> > >
> > >
> > >
> --
> > > Transform Data into Opportunity.
> > > Accelerate data analysis in your applications with
> > > Intel Data Analytics Acceleration Library.
> > > Click to learn more.
> > > http://pubads.g.doubleclick.net/gampad/clk?id=278785111=/4140
> > > ___
> > > enlightenment-devel mailing list
> > > enlightenment-devel@lists.sourceforge.net
> > > https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
> > >
> >
> >
>
>
>
> --
> Transform Data into Opportunity.
> Accelerate data analysis in your applications with
> Intel Data Analytics Acceleration Library.
> Click to learn more.
> http://pubads.g.doubleclick.net/gampad/clk?id=278785111=/4140
> ___
> enlightenment-devel mailing list
> enlightenment-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
>
>


-- 
Jean-Philippe André
--
Transform Data into Opportunity.
Accelerate data analysis in your applications with
Intel Data Analytics Acceleration Library.
Click to learn more.
http://pubads.g.doubleclick.net/gampad/clk?id=278785111=/4140
___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel


Re: [E-devel] Eo: Changes to syntax

2016-03-09 Thread Jean-Philippe André
Oh and I forgot, those changes add ~60 warnings in EFL with clang:

  CC   lib/evas/canvas/lib_evas_libevas_la-evas_object_line.lo
/home/jpeg/e/core/efl/src/lib/evas/canvas/evas_object_line.c:101:5:
warning: expression result unused [-Wunused-value]
   ((Eo *) ( *_obj =
_eo_add_internal_start("/home/jpeg/e/core/efl/src/lib/evas/canvas/evas_object_line.c",
101, evas_line_class_get(), e, ((Eina_Bool)0)), *_obj =
_eo_add_end(*_obj) ));


On 10 March 2016 at 15:46, Jean-Philippe André <j...@videolan.org> wrote:

>
>
> On 10 March 2016 at 15:05, Carsten Haitzler <ras...@rasterman.com> wrote:
>
>> On Thu, 10 Mar 2016 07:42:22 +0200 Daniel Zaoui <daniel.za...@samsung.com>
>> said:
>>
>> > On Wed, 09 Mar 2016 16:23:04 +
>> > Tom Hacohen <t...@osg.samsung.com> wrote:
>> >
>> > > On 03/03/16 10:22, Tom Hacohen wrote:
>> > > > On 01/03/16 09:05, Tom Hacohen wrote:
>> > > >> Hey,
>> > > >>
>> > > >> The Eo syntax is going to be changing once more, and this time, I
>> > > >> really think/hope it'll be the last time. We plan on stabilizing
>> > > >> Eo and all of the functions on top of it in the next few months,
>> > > >> so that doesn't leave us much more time to change it again. :)
>> > > >>
>> > > >> These changes will remove the need for the eo_do family of
>> > > >> functions. Functions will now look like normal C functions (which
>> > > >> they are). There are many benefits to that, and we have many cool
>> > > >> new ideas.
>> > > >>
>> > > >> For more info: https://phab.enlightenment.org/w/eo/
>> > > >>
>> > > >> I'm sending this email as an head's up, as I'll be starting to
>> > > >> work on migrating to the new Eo syntax (and implementing it)
>> > > >> today. Felipe and I have actually already started (needed to for
>> > > >> the PoC), but I plan on pushing my changes to master soon.
>> > > >>
>> > > >> If you have any issues/suggestions/comments with the proposal,
>> > > >> please let me know, either in pm, irc or just here.
>> > > >>
>> > > >
>> > > > Changes are in! I still haven't migrated eo_add to the new syntax
>> > > > (it uses a non portable gcc extension in the meanwhile), but
>> > > > otherwise everything is in. Took me *much* less time than I thought
>> > > > it would, so yay. :P
>> > > >
>> > > > I decided to push it now instead of letting it rest in my branch
>> > > > for a while because literally every hour that passed introduced
>> > > > more merge conflicts for me, so the benefits from stabilising it
>> > > > more in my branch were diminished by the new conflicts and issues
>> > > > that could arise.
>> > > >
>> > > > If you have an application that uses the Eo api, you can use my
>> > > > script https://devs.enlightenment.org/~tasn/migrate_eo.py to
>> > > > migrate your code. When using the script you should keep two things
>> > > > in mind: 1. You are only allowed to run it *once* per source code,
>> > > > because the changes to eo_add() would otherwise accumulate and your
>> > > > code will be wrong. If you need to correct something you've done
>> > > > wrong, reset the code to the previous state and run the script
>> > > > again on the original code. 2. The migration script is not perfect.
>> > > > In particular it can't deal with some corner cases like:
>> > > > eo_do(obj, a_set(1),
>> > > > /* b_set(2),
>> > > >  g_set(4), */
>> > > >   c_set(2));
>> > > > Or abominations like:
>> > > > eo_do(obj, if (a_get())
>> > > >   do_something());
>> > > >
>> > > > So please be aware of that and *manually* review your changes after
>> > > > the script has run.
>> > > >
>> > > > If your code does have these cases, I recommend you either get rid
>> > > > of them, or manually migrate that code before running the script
>> > > > (remove the relevant eo_do).
>> > > >
>> > > > Follow the wiki page mentioned in the previous email for more
>> > > > information about Eo and what else needs changing.
>> > &g

Re: [E-devel] eo_add - Request for comments

2016-03-14 Thread Jean-Philippe André
Hi,

On 14 March 2016 at 19:09, Tom Hacohen <t...@osg.samsung.com> wrote:

> On 11/03/16 15:06, Tom Hacohen wrote:
> > Hey,
> >
> > As you may have noticed I reverted the patches regarding eo_add(). The
> > reason for that is that following complaints (why didn't you say
> > anything following my proposal and *before* I did all the work?!?!) I
> > came up with a better way to do it that will let us keep the current
> > syntax except for one thing, which is what this post is about.
>

Let's say that you pushing this in woke us all up and forced you to find a
better solution :P

> If you are interested in the implementation details of this solution,
> > feel free to ask on IRC or the other thread.
> >
> > Anyhow, as part of this solution, we need to define a macro that will be
> > used inside eo_add. At the moment it's called eoid (and not a macro
> > yet), so eo_add() looks like this:
> > obj = eo_add(CLASS, parent, efl_text_set(eoid, "test"));
> >
> > I'd like to change "eoid" to something that is:
> > 1. more meaningful.
> > 2. less likely to clash.
> >
> > I was thinking (and q66 likes it too) eo_self could work.
> >
> > So the above example will become:
> > obj = eo_add(CLASS, parent, efl_text_set(eo_self, "test"));
> >
> > Do you have any ideas for a better name for this? I rather like eo_self.
> > I just really don't want to change it again, so whatever we go with now
> > will be what we end up with.
> >
> > Please let me know if you have better alternatives.
>
> Just a reminder: if I don't hear any strong objections by tomorrow, I'll
> carry on with this plan.
>

No objections but I'm not 100% sure what is the plan?
Is it to have two versions of eo_add depending on #ifdef GCC, like below?
- if not GCC, use a TLS stack and a macro eo_self returning the top value
- if GCC, use GCC construct ({ Eo *eo_self = internal_add(); ... ; eo_self;
})

If that's the plan, then I'm happy with it.
eo_self or eo_this or whatever short and meaningful enough are fine :)

-- 
Jean-Philippe André
--
Transform Data into Opportunity.
Accelerate data analysis in your applications with
Intel Data Analytics Acceleration Library.
Click to learn more.
http://pubads.g.doubleclick.net/gampad/clk?id=278785231=/4140
___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel


Re: [E-devel] [EGIT] [core/efl] master 02/02: ecore: Create Promises

2016-03-08 Thread Jean-Philippe André
On 9 March 2016 at 01:40, Felipe Magno de Almeida <
felipe.m.alme...@gmail.com> wrote:

> Hello,
>
> So, I'm top-posting because it is a overview of what we already
> discussed in IRC and
> posts some questions to EFL devs on what is best.
>
> BTW, this mail has gone 2 hours without reply because SF mailing list was
> not
> working.
>
> So, first: dlsym does suck. I will fix it by using a global variable
> in eo that ecore_init
> then sets. Removing dlsym.
>
> Second, Tom's most important critic is that Eo.h should _NOT_ know anything
> about promises or even ecore. The way I did it, the macros must know the
> Ecore_Promise type and have a different macro for each case.
>
> Tom said he would be OK with the API generating macros receiving two
> macros that could customize the way the API function is generated by
> expanding these two macros (one before and one after) which Eolian
> could use to customize Promise's use in Eolian-generated functions.
>
> I agree this is the best way and actually helps us in the future if
> we need to customize the generation some other way (maybe
> for callbacks?) and/or implement other conveniences.
>
> However, Tom still questions if Promises should be self-instantiated
> by Eolian or not.
>
> I argue that it should, because it is way more convenient and powerful.
> Eolian can register free functions for Promises (its synchronous nature
> requires it) and eliviate the user to have to do that and pass the correct
> size of the value type that the Promise is going to hold. This is
> _way_ less error-prone, and the moment you start combining promises
> and chaining them it becomes unbearable to do that by hand.
>
> Tom already reverted (I asked him to so we can have this discususion
> first) the commit. And I'll push another commit with all fixes already
> discussed and modifications with the result of this discussion.
>
> So, the other implementation points are already settled and I'll
> push the fix with them, the real question is: Should the user
> of such API functions have to instantiate promises manually
> or should we add this feature to Eolian, which already knows
> the value type, its size and how to free it, and make our code
> easier to use, specially by ourselves (think elementary)?
>

Trying to clarify the question here. Are the choices:
1. the function returning a promise will manually create a promise object,
set the destructor for the data and whatever is needed to create a promise
or 2. eolian will generate boilerplate in the .eo.c files that create a
promise, and do the above work, in which case the function only needs to
return some data that can be attached to the promise if needed

I guess the answer depends on how much work it is to create a promise
object? (disclaimer: i didn't look at the code)

Or did I misunderstand completely?


>
> Regards,
>
> On Tue, Mar 8, 2016 at 11:01 AM, Tom Hacohen  wrote:
> > I real want to keep my temper, but seriously WHAT THE FUCK?
> >
> > Why wasn't this discussed?! Mentioned? Something?
> >
> > The dlsym to call ecore functions from Eo is bad enough to revert this
> > immediately, but also the implementation in Eolian is wrong according to
> > Daniel, and not to mention, doesn't follow the rest of the Eolian
> > conventions of lower case types.
> >
> > Why didn't you consult with Daniel about Eolian and me about Eo before
> > just sneaking it in with the "ecore" prefix with nothing in the commit
> > message. We both missed it until we manually reviewed Eo jsust now.
> >
> > I don't even understand why there should be native eo support for this,
> > and why this isn't just implemented like literally everything else that
> > we have in the EFL, and the commit message doesn't do anything to
> > explain that. This is just wrong.
> >
> > Honestly, WTF.
> >
> > --
> > Tom.
> >
> >
> > On 06/03/16 20:57, Felipe Magno de Almeida wrote:
> >> felipealmeida pushed a commit to branch master.
> >>
> >>
> http://git.enlightenment.org/core/efl.git/commit/?id=f9ba80ab33e0b94dad7ec103e6d261a644f7835f
> >>
> >> commit f9ba80ab33e0b94dad7ec103e6d261a644f7835f
> >> Author: Felipe Magno de Almeida 
> >> Date:   Sun Mar 6 17:39:20 2016 -0300
> >>
> >>  ecore: Create Promises
> >>
> >>  Add a promise object that allows Eolian interface to include
> promises
> >>  as a way to have asynchronous value return and composibility.
> >>
> >>  The usage is like this in a .eo file:
> >>
> >>  class Foo {
> >> methods {
> >>bar {
> >>   params {
> >>  promise: Promise;
> >>   }
> >>}
> >> }
> >>  }
> >>
> >>  Which will create the following API interface:
> >>
> >>  void foo_bar(Ecore_Promise** promise);
> >>
> >>  and the equivalent declaration for implementation.
> >>
> >>  However, the API function will instantiate the Promise for the
> >>  user and the implementer of the 

Re: [E-devel] [EGIT] [core/efl] master 02/02: ecore: Create Promises

2016-03-08 Thread Jean-Philippe André
Hi,

On 9 March 2016 at 14:19, David Seikel <onef...@gmail.com> wrote:

> On Wed, 9 Mar 2016 13:34:48 +0900 Jean-Philippe André
> <j...@videolan.org> wrote:
>
> > Hi,
> >
> > On 9 March 2016 at 12:37, David Seikel <onef...@gmail.com> wrote:
> >
> > > On Tue, 8 Mar 2016 14:01:28 + Tom Hacohen <t...@osg.samsung.com>
> > > wrote:
> > >
> > > > I real want to keep my temper, but seriously WHAT THE FUCK?
> > > >
> > > > Why wasn't this discussed?! Mentioned? Something?
> > > >
> > > > The dlsym to call ecore functions from Eo is bad enough to revert
> > > > this immediately, but also the implementation in Eolian is wrong
> > > > according to Daniel, and not to mention, doesn't follow the rest
> > > > of the Eolian conventions of lower case types.
> > > >
> > > > Why didn't you consult with Daniel about Eolian and me about Eo
> > > > before just sneaking it in with the "ecore" prefix with nothing in
> > > > the commit message. We both missed it until we manually reviewed
> > > > Eo jsust now.
> > > >
> > > > I don't even understand why there should be native eo support for
> > > > this, and why this isn't just implemented like literally
> > > > everything else that we have in the EFL, and the commit message
> > > > doesn't do anything to explain that. This is just wrong.
> > > >
> > > > Honestly, WTF.
> > >
> > > An even deeper WTF from me, WTF is a promise?  I read the patch,
> > > couldn't figure out what they are for.  Same goes for the recently
> > > introduced bryce, WTF is that all about?
> > >
> > > Gonna need an EFL glossary if this keeps up.  lol
> > >
> >
> > Very good question indeed. There was too much IRL discussion about
> > promises, leaving the mailing list in the blind.
>
> RL discussions are not so good, we are an international team of
> developers, not all of us want to move to South Korea, or work for
> Samsung.  I'm beginning to feel there's a bit too much of that sort of
> thing going on.  Evas 3D for instance, which I'm trying to make heavy
> use of, seems to be developed in total isolation.
>

Evas 3D is another story, as it's not actively developed in Korea. You
might be the first community user of evas 3d so your feedback is most
welcome. I don't think any "core" developer is heavily involved in its
development though. It also seems to me to be developed in some kind of
isolation.

As for the rest, and the heavy work going on from now and until July (EFL
1.18), rewriting the EFL interfaces for eo and the bindings, there is a
fine balance between doing everything publicly and totally spamming the ML
as a consequence, or trying to work efficiently and informing the community
as soon as we make tangible progress.

Having started contributing to EFL since I work for Samsung, I'm not in the
best position to say that but I perfectly understand your concerns.


> Promises are a concept mainly used in javascript:
> > https://www.promisejs.org/
> >
> > Basically they allow JS to run asynchronous tasks (remember js
> > doesn't have threads) and you can define a success or a failure
> > callback. Promises can also be bundled together by waiting either for
> > the first one or for all of them to finish.
>
> In that case, I echo Toms WTF.  Sounds like something that would be
> trivial to do in a language that actually supports threads, so can't
> see much point in it for EFL.  Might be useful for the Lua side of EFL
> though, except it's easy enough to do things in C and call them from
> Lua.  I have already written a Lua wrapped in Ecore_Thread
> implementation.  Though I can't see any use for this promises concept
> in what I'm using that for.
>

Well, we are working on supporting JS. Also, Lua don't have proper threads
either, so you would have to [de]serialize data to communicate between
threads (assuming each thread is a Lua_State).

Promises might to allow us to have a single common interface for those
async jobs.
Keep in mind that with eo & eolian we want to support native languages
(C/C++) and non native languages (Lua, JS) with the same interface.

[snip]

-- 
Jean-Philippe André
--
Transform Data into Opportunity.
Accelerate data analysis in your applications with
Intel Data Analytics Acceleration Library.
Click to learn more.
http://pubads.g.doubleclick.net/gampad/clk?id=278785111=/4140
___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel


Re: [E-devel] [EGIT] [core/efl] master 02/02: ecore: Create Promises

2016-03-08 Thread Jean-Philippe André
Hi,

On 9 March 2016 at 12:37, David Seikel <onef...@gmail.com> wrote:

> On Tue, 8 Mar 2016 14:01:28 + Tom Hacohen <t...@osg.samsung.com>
> wrote:
>
> > I real want to keep my temper, but seriously WHAT THE FUCK?
> >
> > Why wasn't this discussed?! Mentioned? Something?
> >
> > The dlsym to call ecore functions from Eo is bad enough to revert
> > this immediately, but also the implementation in Eolian is wrong
> > according to Daniel, and not to mention, doesn't follow the rest of
> > the Eolian conventions of lower case types.
> >
> > Why didn't you consult with Daniel about Eolian and me about Eo
> > before just sneaking it in with the "ecore" prefix with nothing in
> > the commit message. We both missed it until we manually reviewed Eo
> > jsust now.
> >
> > I don't even understand why there should be native eo support for
> > this, and why this isn't just implemented like literally everything
> > else that we have in the EFL, and the commit message doesn't do
> > anything to explain that. This is just wrong.
> >
> > Honestly, WTF.
>
> An even deeper WTF from me, WTF is a promise?  I read the patch,
> couldn't figure out what they are for.  Same goes for the recently
> introduced bryce, WTF is that all about?
>
> Gonna need an EFL glossary if this keeps up.  lol
>

Very good question indeed. There was too much IRL discussion about
promises, leaving the mailing list in the blind.
Promises are a concept mainly used in javascript:
https://www.promisejs.org/

Basically they allow JS to run asynchronous tasks (remember js doesn't have
threads) and you can define a success or a failure callback.
Promises can also be bundled together by waiting either for the first one
or for all of them to finish.

Then again, I'm neither a JS guy nor have I ever used promises...

Bryce on the other hand, I believe is a new replacement for E's "Shelves",
but let's ask Mike :)

-- 
Jean-Philippe André
--
Transform Data into Opportunity.
Accelerate data analysis in your applications with
Intel Data Analytics Acceleration Library.
Click to learn more.
http://pubads.g.doubleclick.net/gampad/clk?id=278785111=/4140
___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel


Re: [E-devel] [EGIT] [core/efl] master 01/03: evas: Fix incorrect expression in efl_canvas_surface_wayland

2016-03-19 Thread Jean-Philippe André
Looks like a bad copy and paste from me. Thanks for the fix :)

On 16 March 2016 at 22:41, Tom Hacohen <t...@osg.samsung.com> wrote:

> Fair enough.
>
> On 16/03/16 13:38, Christopher Michael wrote:
> > Sure, that would have worked also. I just went with what was above in
> > the "constructor" functions.
> >
> > Cheers,
> > dh
> >
> >
> > On 03/16/2016 09:27 AM, Tom Hacohen wrote:
> >> Evas_Object_Protected_Data *obj = eo_data_scope_get(eo,
> EVAS_OBJECT_CLASS);
> >>
> >> Would have been fine (and encouraged). The problem was the "obj = obj =
> X".
> >>
> >> --
> >> Tom.
> >>
> >> On 16/03/16 13:25, Chris Michael wrote:
> >>> devilhorns pushed a commit to branch master.
> >>>
> >>>
> http://git.enlightenment.org/core/efl.git/commit/?id=114d010fc122a9cb1ca6a2d5f87691f13950903d
> >>>
> >>> commit 114d010fc122a9cb1ca6a2d5f87691f13950903d
> >>> Author: Chris Michael <cpmich...@osg.samsung.com>
> >>> Date:   Wed Mar 16 09:21:08 2016 -0400
> >>>
> >>>evas: Fix incorrect expression in efl_canvas_surface_wayland
> >>>
> >>>This patch fixes an issue detected by Coverity where 'obj' is
> written
> >>>twice with the same value
> >>>
> >>>CID1353365
> >>>
> >>>@fix
> >>>
> >>>Signed-off-by: Chris Michael <cpmich...@osg.samsung.com>
> >>> ---
> >>> src/lib/evas/canvas/efl_canvas_surface_wayland.c | 4 +++-
> >>> 1 file changed, 3 insertions(+), 1 deletion(-)
> >>>
> >>> diff --git a/src/lib/evas/canvas/efl_canvas_surface_wayland.c
> b/src/lib/evas/canvas/efl_canvas_surface_wayland.c
> >>> index 1798107..3b1b358 100644
> >>> --- a/src/lib/evas/canvas/efl_canvas_surface_wayland.c
> >>> +++ b/src/lib/evas/canvas/efl_canvas_surface_wayland.c
> >>> @@ -30,7 +30,9 @@ _efl_canvas_surface_wayland_eo_base_constructor(Eo
> *eo, Efl_Canvas_Surface_Wayla
> >>> EOLIAN static void
> >>> _efl_canvas_surface_wayland_eo_base_destructor(Eo *eo,
> Efl_Canvas_Surface_Wayland_Data *pd)
> >>> {
> >>> -   Evas_Object_Protected_Data *obj = obj = eo_data_scope_get(eo,
> EVAS_OBJECT_CLASS);
> >>> +   Evas_Object_Protected_Data *obj;
> >>> +
> >>> +   obj = eo_data_scope_get(eo, EVAS_OBJECT_CLASS);
> >>>
> >>>ENFN->image_native_shutdown(ENDT, EVAS_NATIVE_SURFACE_WL);
> >>>eo_data_unref(eo, pd->base);
> >>>
> >>
> >>
> >>
> --
> >> Transform Data into Opportunity.
> >> Accelerate data analysis in your applications with
> >> Intel Data Analytics Acceleration Library.
> >> Click to learn more.
> >> http://pubads.g.doubleclick.net/gampad/clk?id=278785231=/4140
> >> ___
> >> enlightenment-devel mailing list
> >> enlightenment-devel@lists.sourceforge.net
> >> https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
> >>
> >
> >
> >
> --
> > Transform Data into Opportunity.
> > Accelerate data analysis in your applications with
> > Intel Data Analytics Acceleration Library.
> > Click to learn more.
> > http://pubads.g.doubleclick.net/gampad/clk?id=278785231=/4140
> > ___
> > enlightenment-devel mailing list
> > enlightenment-devel@lists.sourceforge.net
> > https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
> >
>
>
>
> --
> Transform Data into Opportunity.
> Accelerate data analysis in your applications with
> Intel Data Analytics Acceleration Library.
> Click to learn more.
> http://pubads.g.doubleclick.net/gampad/clk?id=278785231=/4140
> ___
> enlightenment-devel mailing list
> enlightenment-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
>
>


-- 
Jean-Philippe André
--
Transform Data into Opportunity.
Accelerate data analysis in your applications with
Intel Data Analytics Acceleration Library.
Click to learn more.
http://pubads.g.doubleclick.net/gampad/clk?id=278785231=/4140
___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel


Re: [E-devel] Eo: Changes to syntax

2016-03-10 Thread Jean-Philippe André
On 11 March 2016 at 00:51, Tom Hacohen <t...@osg.samsung.com> wrote:

> On 10/03/16 12:36, Carsten Haitzler wrote:
> > On Thu, 10 Mar 2016 15:46:19 +0900 Jean-Philippe André <
> j...@videolan.org> said:
> >
> >> On 10 March 2016 at 15:05, Carsten Haitzler <ras...@rasterman.com>
> wrote:
> >>
> >>> On Thu, 10 Mar 2016 07:42:22 +0200 Daniel Zaoui <
> daniel.za...@samsung.com>
> >>> said:
> >>>
> >>>> On Wed, 09 Mar 2016 16:23:04 +
> >>>> Tom Hacohen <t...@osg.samsung.com> wrote:
> >>>>
> >>>>> On 03/03/16 10:22, Tom Hacohen wrote:
> >>>>>> On 01/03/16 09:05, Tom Hacohen wrote:
> >>>>>>> Hey,
> >>>>>>>
> >>>>>>> The Eo syntax is going to be changing once more, and this time, I
> >>>>>>> really think/hope it'll be the last time. We plan on stabilizing
> >>>>>>> Eo and all of the functions on top of it in the next few months,
> >>>>>>> so that doesn't leave us much more time to change it again. :)
> >>>>>>>
> >>>>>>> These changes will remove the need for the eo_do family of
> >>>>>>> functions. Functions will now look like normal C functions (which
> >>>>>>> they are). There are many benefits to that, and we have many cool
> >>>>>>> new ideas.
> >>>>>>>
> >>>>>>> For more info: https://phab.enlightenment.org/w/eo/
> >>>>>>>
> >>>>>>> I'm sending this email as an head's up, as I'll be starting to
> >>>>>>> work on migrating to the new Eo syntax (and implementing it)
> >>>>>>> today. Felipe and I have actually already started (needed to for
> >>>>>>> the PoC), but I plan on pushing my changes to master soon.
> >>>>>>>
> >>>>>>> If you have any issues/suggestions/comments with the proposal,
> >>>>>>> please let me know, either in pm, irc or just here.
> >>>>>>>
> >>>>>>
> >>>>>> Changes are in! I still haven't migrated eo_add to the new syntax
> >>>>>> (it uses a non portable gcc extension in the meanwhile), but
> >>>>>> otherwise everything is in. Took me *much* less time than I thought
> >>>>>> it would, so yay. :P
> >>>>>>
> >>>>>> I decided to push it now instead of letting it rest in my branch
> >>>>>> for a while because literally every hour that passed introduced
> >>>>>> more merge conflicts for me, so the benefits from stabilising it
> >>>>>> more in my branch were diminished by the new conflicts and issues
> >>>>>> that could arise.
> >>>>>>
> >>>>>> If you have an application that uses the Eo api, you can use my
> >>>>>> script https://devs.enlightenment.org/~tasn/migrate_eo.py to
> >>>>>> migrate your code. When using the script you should keep two things
> >>>>>> in mind: 1. You are only allowed to run it *once* per source code,
> >>>>>> because the changes to eo_add() would otherwise accumulate and your
> >>>>>> code will be wrong. If you need to correct something you've done
> >>>>>> wrong, reset the code to the previous state and run the script
> >>>>>> again on the original code. 2. The migration script is not perfect.
> >>>>>> In particular it can't deal with some corner cases like:
> >>>>>> eo_do(obj, a_set(1),
> >>>>>> /* b_set(2),
> >>>>>>   g_set(4), */
> >>>>>>c_set(2));
> >>>>>> Or abominations like:
> >>>>>> eo_do(obj, if (a_get())
> >>>>>>do_something());
> >>>>>>
> >>>>>> So please be aware of that and *manually* review your changes after
> >>>>>> the script has run.
> >>>>>>
> >>>>>> If your code does have these cases, I recommend you either get rid
> >>>>>> of them, or manually migrate that code before running the script
> >>>>>> (remove the relevant eo_do).
> >>>>>>
> >>>>>> Follow the wiki page men

Re: [E-devel] [EGIT] [core/efl] master 01/01: Efl: Add internal strong symbol to fix build on GCC < 5.3

2016-04-06 Thread Jean-Philippe André
Hi,

On 7 April 2016 at 14:49, Jean-Philippe ANDRÉ <j...@videolan.org> wrote:

> jpeg pushed a commit to branch master.
>
>
> http://git.enlightenment.org/core/efl.git/commit/?id=4e4b42ec036b1bda45879c1c4141b56106546373
>
> commit 4e4b42ec036b1bda45879c1c4141b56106546373
> Author: Jean-Philippe Andre <jp.an...@samsung.com>
> Date:   Thu Apr 7 14:40:10 2016 +0900
>
> Efl: Add internal strong symbol to fix build on GCC < 5.3
>
> This fixes a crash in ecore_init, calling a weak function from
> libefl that was resolved to NULL.
>
> So, here's a fun thing happening with GCC < 5.3. Since a1a506e13e2
> all EOAPI and EO class_get() functions are weak symbols. This means
> that all APIs inside libefl.so are weak.
>
> As a result, gcc linker with --as-needed skipped linking to libefl
> since not a single strong symbol from libefl was required by
> libecore. This is actually a bug in gcc linker since we do in fact
> use symbols from libefl, just weak ones.
>
> GCC 5.3 seems to be fixed, so people with GCC 5.3+ will not
> experience any build/runtime issue. The current patch is
> a workaround that bug, by artifically creating a strong symbol
> required by ecore.
>
> Other libraries than ecore might also need to call
> __efl_internal_init, if they end up not being linked to libefl.
>


This should fix the build for Ubuntu users.

For more information, refer to this thread:
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=32511



> ---
>  src/lib/ecore/ecore.c| 3 +++
>  src/lib/efl/Efl.h| 3 +++
>  src/lib/efl/interfaces/efl_interfaces_main.c | 6 ++
>  3 files changed, 12 insertions(+)
>
> diff --git a/src/lib/ecore/ecore.c b/src/lib/ecore/ecore.c
> index d7eead3..6c326a7 100644
> --- a/src/lib/ecore/ecore.c
> +++ b/src/lib/ecore/ecore.c
> @@ -210,6 +210,9 @@ ecore_init(void)
> if (++_ecore_init_count != 1)
>   return _ecore_init_count;
>
> +   /* make sure libecore is linked to libefl - workaround gcc bug */
> +   __efl_internal_init();
> +
> setlocale(LC_CTYPE, "");
> /*
>if (strcmp(nl_langinfo(CODESET), "UTF-8"))
> diff --git a/src/lib/efl/Efl.h b/src/lib/efl/Efl.h
> index 2002ebc..4cc909a 100644
> --- a/src/lib/efl/Efl.h
> +++ b/src/lib/efl/Efl.h
> @@ -119,6 +119,9 @@ typedef Efl_Gfx_Path_Command_Type Efl_Gfx_Path_Command;
>
>  #endif
>
> +/* work-around bug in gcc --as-needed link optimization */
> +EAPI void __efl_internal_init(void);
> +
>  #if defined ( __cplusplus )
>  }
>  #endif
> diff --git a/src/lib/efl/interfaces/efl_interfaces_main.c
> b/src/lib/efl/interfaces/efl_interfaces_main.c
> index 908e228..68ff6f3 100644
> --- a/src/lib/efl/interfaces/efl_interfaces_main.c
> +++ b/src/lib/efl/interfaces/efl_interfaces_main.c
> @@ -37,3 +37,9 @@ EAPI const Eo_Event_Description _EFL_GFX_PATH_CHANGED =
>  #include "interfaces/efl_animator.eo.c"
>  #include "interfaces/efl_orientation.eo.c"
>  #include "interfaces/efl_flip.eo.c"
> +
> +EAPI void
> +__efl_internal_init(void)
> +{
> +   /* nothing to do, the symbol only is required for link to work */
> +}
>
> --
>
>
>


-- 
Jean-Philippe André
--
___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel


Re: [E-devel] [EGIT] [core/efl] master 01/01: Efl: Add internal strong symbol to fix build on GCC < 5.3

2016-04-07 Thread Jean-Philippe André
On 7 April 2016 at 14:53, Jean-Philippe André <j...@videolan.org> wrote:

> Hi,
>
> On 7 April 2016 at 14:49, Jean-Philippe ANDRÉ <j...@videolan.org> wrote:
>
>> jpeg pushed a commit to branch master.
>>
>>
>> http://git.enlightenment.org/core/efl.git/commit/?id=4e4b42ec036b1bda45879c1c4141b56106546373
>>
>> commit 4e4b42ec036b1bda45879c1c4141b56106546373
>> Author: Jean-Philippe Andre <jp.an...@samsung.com>
>> Date:   Thu Apr 7 14:40:10 2016 +0900
>>
>> Efl: Add internal strong symbol to fix build on GCC < 5.3
>>
>> This fixes a crash in ecore_init, calling a weak function from
>> libefl that was resolved to NULL.
>>
>> So, here's a fun thing happening with GCC < 5.3. Since a1a506e13e2
>> all EOAPI and EO class_get() functions are weak symbols. This means
>> that all APIs inside libefl.so are weak.
>>
>> As a result, gcc linker with --as-needed skipped linking to libefl
>> since not a single strong symbol from libefl was required by
>> libecore. This is actually a bug in gcc linker since we do in fact
>> use symbols from libefl, just weak ones.
>>
>> GCC 5.3 seems to be fixed, so people with GCC 5.3+ will not
>> experience any build/runtime issue. The current patch is
>> a workaround that bug, by artifically creating a strong symbol
>> required by ecore.
>>
>> Other libraries than ecore might also need to call
>> __efl_internal_init, if they end up not being linked to libefl.
>>
>
>
> This should fix the build for Ubuntu users.
>
> For more information, refer to this thread:
> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=32511
>

Oops, this thread:
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=32219

Although it's not exactly the same situation as ours, since our weak
symbols are visible, not hidden.


>
>
>
>
>> ---
>>  src/lib/ecore/ecore.c| 3 +++
>>  src/lib/efl/Efl.h| 3 +++
>>  src/lib/efl/interfaces/efl_interfaces_main.c | 6 ++
>>  3 files changed, 12 insertions(+)
>>
>> diff --git a/src/lib/ecore/ecore.c b/src/lib/ecore/ecore.c
>> index d7eead3..6c326a7 100644
>> --- a/src/lib/ecore/ecore.c
>> +++ b/src/lib/ecore/ecore.c
>> @@ -210,6 +210,9 @@ ecore_init(void)
>> if (++_ecore_init_count != 1)
>>   return _ecore_init_count;
>>
>> +   /* make sure libecore is linked to libefl - workaround gcc bug */
>> +   __efl_internal_init();
>> +
>> setlocale(LC_CTYPE, "");
>> /*
>>if (strcmp(nl_langinfo(CODESET), "UTF-8"))
>> diff --git a/src/lib/efl/Efl.h b/src/lib/efl/Efl.h
>> index 2002ebc..4cc909a 100644
>> --- a/src/lib/efl/Efl.h
>> +++ b/src/lib/efl/Efl.h
>> @@ -119,6 +119,9 @@ typedef Efl_Gfx_Path_Command_Type
>> Efl_Gfx_Path_Command;
>>
>>  #endif
>>
>> +/* work-around bug in gcc --as-needed link optimization */
>> +EAPI void __efl_internal_init(void);
>> +
>>  #if defined ( __cplusplus )
>>  }
>>  #endif
>> diff --git a/src/lib/efl/interfaces/efl_interfaces_main.c
>> b/src/lib/efl/interfaces/efl_interfaces_main.c
>> index 908e228..68ff6f3 100644
>> --- a/src/lib/efl/interfaces/efl_interfaces_main.c
>> +++ b/src/lib/efl/interfaces/efl_interfaces_main.c
>> @@ -37,3 +37,9 @@ EAPI const Eo_Event_Description _EFL_GFX_PATH_CHANGED =
>>  #include "interfaces/efl_animator.eo.c"
>>  #include "interfaces/efl_orientation.eo.c"
>>  #include "interfaces/efl_flip.eo.c"
>> +
>> +EAPI void
>> +__efl_internal_init(void)
>> +{
>> +   /* nothing to do, the symbol only is required for link to work */
>> +}
>>
>> --
>>
>>
>>
>
>
> --
> Jean-Philippe André
>



-- 
Jean-Philippe André
--
___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel


Re: [E-devel] (: From now on all EFL code will be happy... or else!

2016-04-06 Thread Jean-Philippe André
On 7 April 2016 at 13:58, Cedric BAIL <cedric.b...@free.fr> wrote:

> On Wed, Apr 6, 2016 at 4:13 AM, Tom Hacohen <t...@osg.samsung.com> wrote:
> > On 06/04/16 11:51, Simon Lees wrote:
> >> On 04/06/2016 07:04 PM, Carsten Haitzler (The Rasterman) wrote:
> >>> On Tue, 5 Apr 2016 19:54:06 -0300 Vinícius dos Santos Oliveira
> >>> <vini.ipsma...@gmail.com> said:
> >>>> 2016-04-05 19:50 GMT-03:00 Simon Lees <sfl...@suse.de>:
> >>>>> I don't like the idea of having opening brackets without close
> brackets
> >>>>> either.
> >>>>
> >>>> This will make MANY IDEs mismatch the parens.
> >>>
> >>> i'd say thats a broken ide because its inside of a STRING quote... if
> an ide
> >>> is matching ()'s inside strings... its odd and making assumptions it
> >>> shouldn't/can't as it doesn't know the string is actually code or a
> specific
> >>> format to go handling ('s matching )'s
> >>
> >> Yes well a good ide knows that but some of the less smart ones don't
> >
> > I doubt this claim is true. All IDEs that are syntax aware should be
> > able to deal with this.
> >
> > With that being said, I don't like the syntax. I much prefer the Qt
> > syntax tbh.
>
> I do also prefer Qt syntax. Added benefit some people will be already
> use to it. Maybe we should just follow what they do there and support
> their subset.
>
> Makes sense, if our vpaths have the same meaning as Qt's.

-- 
Jean-Philippe André
--
___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel


Re: [E-devel] [EGIT] [core/efl] master 01/01: Eo tests: Also test function calls in reinit test.

2016-04-07 Thread Jean-Philippe André
On 6 April 2016 at 19:16, Tom Hacohen <t...@stosb.com> wrote:

> tasn pushed a commit to branch master.
>
>
> http://git.enlightenment.org/core/efl.git/commit/?id=c6159e042bb08dffecf60de3497126d0c60d0b68
>
> commit c6159e042bb08dffecf60de3497126d0c60d0b68
> Author: Tom Hacohen <t...@stosb.com>
> Date:   Wed Apr 6 10:16:24 2016 +0100
>
> Eo tests: Also test function calls in reinit test.
>
> Since we cache ops we also need to check function calls work
> when we reinit eo, not just class_get functions.
>
> This commit essentially verifies that
> 5284b62e930f0bef0ed3125b3a485e0599451ef8 was done correctly.
>


Thanks a lot Tom. I know I should have done this and you weren't extremely
happy about having to implement this test case yourself. So I appreciate
the effort.

Now I only hope I can go back to focus on the containers :)


> ---
>  src/tests/eo/suite/eo_test_class_simple.c | 27 ++-
>  src/tests/eo/suite/eo_test_class_simple.h |  5 +
>  src/tests/eo/suite/eo_test_init.c | 15 +++
>  3 files changed, 46 insertions(+), 1 deletion(-)
>
> diff --git a/src/tests/eo/suite/eo_test_class_simple.c
> b/src/tests/eo/suite/eo_test_class_simple.c
> index 224e80a..8566ed9 100644
> --- a/src/tests/eo/suite/eo_test_class_simple.c
> +++ b/src/tests/eo/suite/eo_test_class_simple.c
> @@ -89,7 +89,6 @@ EO_VOID_FUNC_BODY(simple_pure_virtual);
>  EO_VOID_FUNC_BODY(simple_no_implementation);
>
>  static Eo_Op_Description op_descs[] = {
> - EO_OP_FUNC_OVERRIDE(eo_dbg_info_get, _dbg_info_get),
>   EO_OP_FUNC(simple_a_set, _a_set),
>   EO_OP_FUNC(simple_a_get, _a_get),
>   EO_OP_FUNC(simple_a_print, _a_print),
> @@ -97,6 +96,7 @@ static Eo_Op_Description op_descs[] = {
>   EO_OP_FUNC(simple_recursive, _recursive),
>   EO_OP_FUNC(simple_part_get, _part_get),
>   EO_OP_FUNC(simple_pure_virtual, NULL),
> + EO_OP_FUNC_OVERRIDE(eo_dbg_info_get, _dbg_info_get),
>  };
>
>  static const Eo_Class_Description class_desc = {
> @@ -112,3 +112,28 @@ static const Eo_Class_Description class_desc = {
>
>  EO_DEFINE_CLASS(simple_class_get, _desc, EO_CLASS, NULL)
>
> +
> +static int
> +_beef_get(Eo *obj EINA_UNUSED, void *class_data EINA_UNUSED)
> +{
> +   return 0xBEEF;
> +}
> +
> +EO_FUNC_BODY_CONST(simple2_class_beef_get, int, 0);
> +
> +static Eo_Op_Description op_descs2[] = {
> + EO_OP_CLASS_FUNC(simple2_class_beef_get, _beef_get),
> +};
> +
> +static const Eo_Class_Description class_desc2 = {
> + EO_VERSION,
> + "Simple2",
> + EO_CLASS_TYPE_REGULAR,
> + EO_CLASS_DESCRIPTION_OPS(op_descs2),
> + NULL,
> + 0,
> + NULL,
> + NULL
> +};
> +
> +EO_DEFINE_CLASS(simple2_class_get, _desc2, EO_CLASS, NULL)
> diff --git a/src/tests/eo/suite/eo_test_class_simple.h
> b/src/tests/eo/suite/eo_test_class_simple.h
> index 3360ea8..32e3844 100644
> --- a/src/tests/eo/suite/eo_test_class_simple.h
> +++ b/src/tests/eo/suite/eo_test_class_simple.h
> @@ -24,4 +24,9 @@ extern const Eo_Event_Description _EV_A_CHANGED2;
>  #define SIMPLE_CLASS simple_class_get()
>  const Eo_Class *simple_class_get(void);
>
> +EAPI int simple2_class_beef_get(const Eo_Class *obj);
> +
> +#define SIMPLE2_CLASS simple2_class_get()
> +const Eo_Class *simple2_class_get(void);
> +
>  #endif
> diff --git a/src/tests/eo/suite/eo_test_init.c
> b/src/tests/eo/suite/eo_test_init.c
> index ef04d31..4a1948c 100644
> --- a/src/tests/eo/suite/eo_test_init.c
> +++ b/src/tests/eo/suite/eo_test_init.c
> @@ -5,6 +5,7 @@
>  #include 
>
>  #include "eo_suite.h"
> +#include "eo_test_class_simple.h"
>
>  START_TEST(eo_test_simple)
>  {
> @@ -17,12 +18,26 @@ END_TEST
>
>  START_TEST(eo_test_init_shutdown)
>  {
> +   Eo *obj;
> +
> fail_if(!eo_init());
> ck_assert_str_eq("Eo_Base", eo_class_name_get(EO_BASE_CLASS));
> +
> +   /* XXX-1: Essential for the next test to assign the wrong op. */
> +   obj = eo_add(SIMPLE_CLASS, NULL);
> +   simple_a_set(obj, 1);
> +   ck_assert_int_eq(1, simple_a_get(obj));
> +
> +   /* XXX-1: Essential for the next test to cache the op. */
> +   ck_assert_int_eq(0xBEEF, simple2_class_beef_get(SIMPLE2_CLASS));
> +   eo_unref(obj);
> fail_if(eo_shutdown());
>
> fail_if(!eo_init());
> ck_assert_str_eq("Eo_Base", eo_class_name_get(EO_BASE_CLASS));
> +
> +   /* XXX-1: Verify that the op was not cached. */
> +   ck_assert_int_eq(0xBEEF, simple2_class_beef_get(SIMPLE2_CLASS));
> fail_if(eo_shutdown());
>  }
>  END_TEST
>
> --
>
>
>


-- 
Jean-Philippe André
--
___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel


Re: [E-devel] Please help | Unable to clone efl.git

2016-04-07 Thread Jean-Philippe André
Hi,

On 7 April 2016 at 18:35, Durgesh Choudhary <007durgesh...@gmail.com> wrote:

> Hi Developers,  My name is Durgesh. I am from India.  I am currently using
> enlightenment and I love it. I want to contribute but I am unable to clone
> core/efl.git  after 60% cloning it show error saying
>
> error: RPC failed; curl 18 transfer closed with outstanding read data
> remaining
> fatal: The remote end hung up unexpectedly
> fatal: early EOF
> fatal: index-pack failed
>

I guess you tried with https?
Can you try with git:// protocol?

git clone git://git.enlightenment.org/core/efl.git
or:
git clone https://git.enlightenment.org/core/efl.git

-- 
Jean-Philippe André
--
___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel


Re: [E-devel] [EGIT] [core/efl] master 01/02: elm_nstate: introduce nstate widget and inherit check from it

2016-04-07 Thread Jean-Philippe André
Fixed

On 8 April 2016 at 11:19, Simon Lees <si...@simotek.net> wrote:

>
>
> On 04/07/2016 07:33 PM, Amitesh Singh wrote:
> > jpeg pushed a commit to branch master.
> >
> >
> http://git.enlightenment.org/core/efl.git/commit/?id=56ab4359981baffbbc93102b098eede1ad79e47a
> >
> > commit 56ab4359981baffbbc93102b098eede1ad79e47a
> > Author: Amitesh Singh <amitesh...@samsung.com>
> > Date:   Thu Apr 7 18:25:59 2016 +0900
> >
> > elm_nstate: introduce nstate widget and inherit check from it
> >
> > Test Plan:
> > elementary_test -to "nstate"
> >
> > @feature
> >
> > Reviewers: yashu21985, tasn, Hermet, seoz, smohanty, felipealmeida,
> JackDanielZ, jypark, woohyun, herdsman, raster, cedric, jpeg
> >
> > Subscribers: saurabhbunty, seoz
> >
>
> This broke make dist
>  "No rule to make target 'widget_preview_nstate.c', needed by 'distdir'"
>
>
> --
> _______
> enlightenment-devel mailing list
> enlightenment-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
>
>


-- 
Jean-Philippe André
--
___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel


Re: [E-devel] [EGIT] [core/elementary] master 01/01: Revert "list: set internal box as homogeneous if no separator items are present"

2016-03-19 Thread Jean-Philippe André
Hi,

On 18 March 2016 at 00:03, Mike Blumenkrantz <michael.blumenkra...@gmail.com
> wrote:

> It's been over a week with no reply and this is still broken after your
> revert. If there continues to be no compelling evidence supporting the
> revert, the patch will go back in next week.
>

Mike's patch here indeed breaks enventor's autocompletion popup menus.

I don't understand your patch Mike, why introduce a behaviour change
(become homogenous) when adding a separator? Why would a separator have
such a side effect?

Anyway, I can also reproduce the bug you mentionned (elementary_test -to
ctxpopup).
But to me it's the wrong solution to the wrong problem. Even after your
patch, other ctxpopup test cases have sizing issues ("restacking" & "user
content" show scrollers).

So, we have a bug somewhere, and it needs another solution than the one
proposed here, I think.


On Tue, Mar 8, 2016 at 2:28 PM Mike Blumenkrantz <
> michael.blumenkra...@gmail.com> wrote:
>
> > Hi,
> >
> > I am confused by this.
> >
> > Here are some screenshots of the only ctxpopup test which looks different
> > between these commits.
> > This is how it looks with your revert: http://i.imgur.com/tlIdBDU.png
> > This is how it looked before the revert: http://i.imgur.com/RrT4iXL.png
> >
> > Unless the goal is for horizontal ctxpopup to be unusable, the second
> > (pre-revert) screenshot is clearly the correct one.
> >
> > I attempted to use enventor in order to see the issue you described
> there.
> > This is how enventor looks after a first install:
> > http://i.imgur.com/RNXh4Fy.png
> > I filed https://phab.enlightenment.org/T3281 for it.
> >
> > What is the bug here???
>

Your issue is weird. It looks like your prefix was / instead of /usr.



> > On Tue, Mar 8, 2016 at 11:27 AM Hermet Park <her...@hermet.pe.kr> wrote:
> >
> >> Hey, Mike I reverted your patch.
> >> Since this broke enventor auto completion feature as well as ctxpopup
> >> example in elementary_test.
> >>
> >> We need to figure them out before applying this patch.
> >>
> >> -Original Message-
> >> From: "Hermet Park"<her...@hermet.pe.kr>
> >> To: <g...@lists.enlightenment.org>;
> >> Cc:
> >> Sent: 2016-03-08 (화) 21:00:29
> >> Subject: [EGIT] [core/elementary] master 01/01: Revert "list: set
> >> internal box as homogeneous if no separator items are present"
> >>
> >> hermet pushed a commit to branch master.
> >>
> >>
> >>
> http://git.enlightenment.org/core/elementary.git/commit/?id=89a2a7c134c8b5a9ab128c44db693c207bed55f3
> >>
> >> commit 89a2a7c134c8b5a9ab128c44db693c207bed55f3
> >> Author: Hermet Park <her...@hermet.pe.kr>
> >> Date:   Tue Mar 8 20:58:17 2016 +0900
> >>
> >> Revert "list: set internal box as homogeneous if no separator items
> >> are present"
> >>
> >> This reverts commit 9f4c43c20dfa36e7a8be18278acf4336c13574d7.
> >>
> >> I'm sorry but this causes a side effect(list sizing issue) at
> >> enventor.
> >> And I couldn't find any mis-usage in enventor side.
> >>
> >> We can't not accept this patch unless we figure the exact reason
> out.
> >> ---
> >>  src/lib/elm_list.c  3 ---
> >>  1 file changed, 3 deletions(-)
> >>
> >> diff --git a/src/lib/elm_list.c b/src/lib/elm_list.c
> >> index 78c6804..14164dc 100644
> >> --- a/src/lib/elm_list.c
> >> +++ b/src/lib/elm_list.c
> >> @@ -815,7 +815,6 @@ _items_fix(Evas_Object *obj)
> >> const char *it_plain;
> >> const char *it_compress;
> >> const char *it_compress_odd;
> >> -   Eina_Bool separators = EINA_FALSE;
> >>
> >> ELM_LIST_DATA_GET(obj, sd);
> >>
> >> @@ -851,7 +850,6 @@ _items_fix(Evas_Object *obj)
> >>   if (mw > minw[1]) minw[1] = mw;
> >>   if (mh > minh[1]) minh[1] = mh;
> >>}
> >> -separators = it->is_separator;
> >>   }
> >>
> >> if ((minw[0] != sd->minw[0])  (minw[1] != sd->minw[1])
> >> @@ -865,7 +863,6 @@ _items_fix(Evas_Object *obj)
> >>   }
> >>
> >> i = 0;
> >> -   elm_box_homogeneous_set(sd->box, !separators);
> >> EINA_LIST_FOREACH(sd->items, l, eo_it)
> >>   {
> >>  ELM_LIST_ITEM_DATA_GET(eo_it, it);
> >>
> >> --
>
>
Best regards,

-- 
Jean-Philippe André
--
Transform Data into Opportunity.
Accelerate data analysis in your applications with
Intel Data Analytics Acceleration Library.
Click to learn more.
http://pubads.g.doubleclick.net/gampad/clk?id=278785231=/4140
___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel


Re: [E-devel] [EGIT] [core/efl] master 05/07: Eo: Remove more deprecated functions.

2016-03-07 Thread Jean-Philippe André
On 7 March 2016 at 19:08, Tom Hacohen <t...@osg.samsung.com> wrote:

> On 07/03/16 04:57, Jean-Philippe André wrote:
> > Hi Tom & q66,
> >
> >
> > Is there any chance we could get rid of the 2 in Eo_Event2 as well?
> >
> > I mean this, in Eo.h:
> >
> > /** XXX: Hack until fixed in Eolian */
> > typedef struct _Eo_Event Eo_Event2;
> >
> > and its eo counterpart:
> >
> > /* XXX: Hack until Eolian is ready. */
> > type @extern Eo.Event_Cb: __builtin_event_cb;
> >
>
> It's only needed because Eolian doesn't do function pointers. We could
> get rid of it (I have an ugly way) if we really wanted, but why do you
> care? You should be using Eo_Event everywhere, the 2 is just for
> internal use.


I know


> Just so headers will be cleaner?
>

Yes :)
So I can just click on the type and then copy & paste the callback
signature.

-- 
Jean-Philippe André
--
Transform Data into Opportunity.
Accelerate data analysis in your applications with
Intel Data Analytics Acceleration Library.
Click to learn more.
http://makebettercode.com/inteldaal-eval
___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel


Re: [E-devel] [EGIT] [core/efl] master 05/07: Eo: Remove more deprecated functions.

2016-03-06 Thread Jean-Philippe André
Hi Tom & q66,


Is there any chance we could get rid of the 2 in Eo_Event2 as well?

I mean this, in Eo.h:

/** XXX: Hack until fixed in Eolian */
typedef struct _Eo_Event Eo_Event2;

and its eo counterpart:

/* XXX: Hack until Eolian is ready. */
type @extern Eo.Event_Cb: __builtin_event_cb;


Thanks,


On 4 March 2016 at 23:30, Tom Hacohen <t...@stosb.com> wrote:

> tasn pushed a commit to branch master.
>
>
> http://git.enlightenment.org/core/efl.git/commit/?id=0c03ba0a5df38ddfc92a877c47e44f449b912939
>
> commit 0c03ba0a5df38ddfc92a877c47e44f449b912939
> Author: Tom Hacohen <t...@stosb.com>
> Date:   Fri Mar 4 14:24:20 2016 +
>
> Eo: Remove more deprecated functions.
> ---
>  src/lib/eo/Eo.h | 8 
>  1 file changed, 8 deletions(-)
>
> diff --git a/src/lib/eo/Eo.h b/src/lib/eo/Eo.h
> index 57d1c12..de129fc 100644
> --- a/src/lib/eo/Eo.h
> +++ b/src/lib/eo/Eo.h
> @@ -999,14 +999,6 @@ EAPI const Eo_Event_Description
> *eo_base_legacy_only_event_description_get(const
>   * @}
>   */
>
> -/* XXX: Deprecated, here for compat, DO NOT USE */
> -EINA_DEPRECATED static inline const Eo_Event_Description*
> _EO_EV_CALLBACK_ADD(void) { return EO_BASE_EVENT_CALLBACK_ADD; }
> -EINA_DEPRECATED static inline const Eo_Event_Description*
> _EO_EV_CALLBACK_DEL(void) { return EO_BASE_EVENT_CALLBACK_DEL; }
> -EINA_DEPRECATED static inline const Eo_Event_Description*
> _EO_EV_DEL(void) { return EO_BASE_EVENT_DEL; }
> -#define EO_EV_CALLBACK_ADD _EO_EV_CALLBACK_ADD()
> -#define EO_EV_CALLBACK_DEL _EO_EV_CALLBACK_DEL()
> -#define EO_EV_DEL _EO_EV_DEL()
> -
>  /**
>   * @}
>   */
>
> --
>
> --
> Jean-Philippe André
>
>
--
Transform Data into Opportunity.
Accelerate data analysis in your applications with
Intel Data Analytics Acceleration Library.
Click to learn more.
http://makebettercode.com/inteldaal-eval
___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel


Re: [E-devel] [EGIT] [core/efl] master 01/02: eina: Add Eina_Iterator implementation for C-array

2016-03-06 Thread Jean-Philippe André
Hi Felipe

On 7 March 2016 at 05:57, Felipe Magno de Almeida <
fel...@expertisesolutions.com.br> wrote:

> felipealmeida pushed a commit to branch master.
>
>
> http://git.enlightenment.org/core/efl.git/commit/?id=d723990955289a5ca62605262f4bc4cd0aa8d25f
>
> commit d723990955289a5ca62605262f4bc4cd0aa8d25f
> Author: Felipe Magno de Almeida <fel...@expertisesolutions.com.br>
> Date:   Sun Mar 6 17:24:34 2016 -0300
>
> eina: Add Eina_Iterator implementation for C-array
>
> This iterator is convenient when you already have a C-Array and you
> need to pass this array to a function receiving an Eina_Iterator.
>
> int array[] = {1, 2, 3, 4};
> int* array2[] = {[0], [1], [2], [3], NULL};
>
> Eina_Iterator* iterator = eina_carray_iterator_new((void**)array);
>

I guess this is a typo? You meant array2 here?

Is it really necessary to have an array of pointers and NULL termination?
Can't we pass in a step value and length? Maybe that would be another type
of iterator actually?

Just wondering...



> ---
>  src/lib/eina/eina_iterator.c | 54
> 
>  src/lib/eina/eina_iterator.h | 15 
>  2 files changed, 69 insertions(+)
>
> diff --git a/src/lib/eina/eina_iterator.c b/src/lib/eina/eina_iterator.c
> index 59dc106..5d62181 100644
> --- a/src/lib/eina/eina_iterator.c
> +++ b/src/lib/eina/eina_iterator.c
> @@ -174,3 +174,57 @@ eina_iterator_unlock(Eina_Iterator *iterator)
>   return iterator->unlock(iterator);
> return EINA_TRUE;
>  }
> +
> +typedef struct _Eina_Iterator_CArray Eina_Iterator_CArray;
> +
> +struct _Eina_Iterator_CArray
> +{
> +  Eina_Iterator iterator;
> +
> +  void** array;
> +  void** current;
> +};
> +
> +static Eina_Bool
> +eina_carray_iterator_next(Eina_Iterator_CArray *it, void **data)
> +{
> +   if (!it->current || !*it->current)
> + return EINA_FALSE;
> +
> +   *data = *it->current++;
> +
> +   return EINA_TRUE;
> +}
> +
> +static void**
> +eina_carray_iterator_get_container(Eina_Iterator_CArray *it)
> +{
> +   return it->array;
> +}
> +
> +static void
> +eina_carray_iterator_free(Eina_Iterator_CArray *it)
> +{
> +  free(it);
> +}
> +
> +EAPI Eina_Iterator*
> +eina_carray_iterator_new(void** array)
> +{
> +   Eina_Iterator_CArray *it;
> +
> +   it = calloc(1, sizeof (Eina_Iterator_CArray));
> +   if (!it) return NULL;
> +
> +   EINA_MAGIC_SET(>iterator, EINA_MAGIC_ITERATOR);
> +
> +   it->array = it->current = array;
> +
> +   it->iterator.version = EINA_ITERATOR_VERSION;
> +   it->iterator.next = FUNC_ITERATOR_NEXT(eina_carray_iterator_next);
> +   it->iterator.get_container = FUNC_ITERATOR_GET_CONTAINER(
> +  eina_carray_iterator_get_container);
> +   it->iterator.free = FUNC_ITERATOR_FREE(eina_carray_iterator_free);
> +
> +   return >iterator;
> +}
> diff --git a/src/lib/eina/eina_iterator.h b/src/lib/eina/eina_iterator.h
> index 980dbfc..b379d2e 100644
> --- a/src/lib/eina/eina_iterator.h
> +++ b/src/lib/eina/eina_iterator.h
> @@ -285,6 +285,21 @@ EAPI Eina_Bool eina_iterator_lock(Eina_Iterator
> *iterator) EINA_ARG_NONNULL(1);
>  EAPI Eina_Bool eina_iterator_unlock(Eina_Iterator *iterator)
> EINA_ARG_NONNULL(1);
>
>  /**
> + * @brief Creates an Eina_Iterator that iterates through a
> + * NUL-terminated C array.
> + *
> + * @param array The NUL-terminated array
> + *
> + * You can create it like this:
> + * int array[] = {1, 2, 3, 4};
> + * int* array2[] = {[0], [1], [2], [3], NULL};
> + *
> + * Eina_Iterator* iterator = eina_carray_iterator_new((void**)array);
>

typo is here too


> + *
> + */
> +EAPI Eina_Iterator* eina_carray_iterator_new(void** array)
> EINA_ARG_NONNULL(1) EINA_WARN_UNUSED_RESULT;
> +
> +/**
>   * @def EINA_ITERATOR_FOREACH
>   * @brief Macro to iterate over all elements easily.
>   *
>
> --
>
> --
> Jean-Philippe André
>
>
--
Transform Data into Opportunity.
Accelerate data analysis in your applications with
Intel Data Analytics Acceleration Library.
Click to learn more.
http://makebettercode.com/inteldaal-eval
___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel


Re: [E-devel] [EGIT] [core/efl] master 01/01: efl - fix threadqueue spinlock destruction on openbsd - doesn't like it

2016-03-01 Thread Jean-Philippe André
Hi,


On 2 March 2016 at 10:36, Carsten Haitzler <ras...@rasterman.com> wrote:

> raster pushed a commit to branch master.
>
>
> http://git.enlightenment.org/core/efl.git/commit/?id=7920e66f29e7b2bed8f58d1768c008b199be322a
>
> commit 7920e66f29e7b2bed8f58d1768c008b199be322a
> Author: Carsten Haitzler (Rasterman) <ras...@rasterman.com>
> Date:   Wed Mar 2 10:33:40 2016 +0900
>
> efl - fix threadqueue spinlock destruction on openbsd - doesn't like it
>
> so the spinlock on the threadqueue block pool it taken on shutdownn,
> while the block pool is freed up then its is destroyed, but openbsd
> very much doesnt like this and returns an error, so release the lock
> before destroying it.
>

Well there is something fundamentally wrong with taking a lock before
destroying it.
If it's still "valid" (ie. other threads rely on it), then it shouldn't be
destroyed. Otherwise there is no need to lock.

Destroying a locking primitive when it's locked is a bad idea ("undefined
behaviour").

So I wonder why the lock was taken there in the first place during shutdown.


>
> @fix
> ---
>  src/lib/eina/eina_thread_queue.c | 1 +
>  1 file changed, 1 insertion(+)
>
> diff --git a/src/lib/eina/eina_thread_queue.c
> b/src/lib/eina/eina_thread_queue.c
> index 3a012ea..dc92db5 100644
> --- a/src/lib/eina/eina_thread_queue.c
> +++ b/src/lib/eina/eina_thread_queue.c
> @@ -171,6 +171,7 @@ _eina_thread_queue_msg_block_pool_shutdown(void)
>   _eina_thread_queue_block_pool = blknext;
>}
>   }
> +   eina_spinlock_release(&(_eina_thread_queue_block_pool_lock));
> eina_spinlock_free(&_eina_thread_queue_block_pool_lock);
>  }
>
>
> --
>
>
>


-- 
Jean-Philippe André
--
Site24x7 APM Insight: Get Deep Visibility into Application Performance
APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month
Monitor end-to-end web transactions and take corrective actions now
Troubleshoot faster and improve end-user experience. Signup Now!
http://pubads.g.doubleclick.net/gampad/clk?id=272487151=/4140
___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel


Re: [E-devel] Eo: Changes to syntax

2016-03-03 Thread Jean-Philippe André
On 3 March 2016 at 20:33, Tom Hacohen <t...@osg.samsung.com> wrote:

> On 03/03/16 10:58, Tom Hacohen wrote:
> > On 03/03/16 10:22, Tom Hacohen wrote:
> >> On 01/03/16 09:05, Tom Hacohen wrote:
> >>> Hey,
> >>>
> >>> The Eo syntax is going to be changing once more, and this time, I
> really
> >>> think/hope it'll be the last time. We plan on stabilizing Eo and all of
> >>> the functions on top of it in the next few months, so that doesn't
> leave
> >>> us much more time to change it again. :)
> >>>
> >>> These changes will remove the need for the eo_do family of functions.
> >>> Functions will now look like normal C functions (which they are). There
> >>> are many benefits to that, and we have many cool new ideas.
> >>>
> >>> For more info: https://phab.enlightenment.org/w/eo/
> >>>
> >>> I'm sending this email as an head's up, as I'll be starting to work on
> >>> migrating to the new Eo syntax (and implementing it) today. Felipe and
> I
> >>> have actually already started (needed to for the PoC), but I plan on
> >>> pushing my changes to master soon.
> >>>
> >>> If you have any issues/suggestions/comments with the proposal, please
> >>> let me know, either in pm, irc or just here.
> >>>
> >>
> >> Changes are in! I still haven't migrated eo_add to the new syntax (it
> >> uses a non portable gcc extension in the meanwhile), but otherwise
> >> everything is in. Took me *much* less time than I thought it would, so
> >> yay. :P
> >>
> >> I decided to push it now instead of letting it rest in my branch for a
> >> while because literally every hour that passed introduced more merge
> >> conflicts for me, so the benefits from stabilising it more in my branch
> >> were diminished by the new conflicts and issues that could arise.
> >>
> >> If you have an application that uses the Eo api, you can use my script
> >> https://devs.enlightenment.org/~tasn/migrate_eo.py to migrate your
> code.
> >> When using the script you should keep two things in mind:
> >> 1. You are only allowed to run it *once* per source code, because the
> >> changes to eo_add() would otherwise accumulate and your code will be
> >> wrong. If you need to correct something you've done wrong, reset the
> >> code to the previous state and run the script again on the original
> code.
> >> 2. The migration script is not perfect. In particular it can't deal with
> >> some corner cases like:
> >> eo_do(obj, a_set(1),
> >> /* b_set(2),
> >>   g_set(4), */
> >>  c_set(2));
> >> Or abominations like:
> >> eo_do(obj, if (a_get())
> >>  do_something());
> >>
> >> So please be aware of that and *manually* review your changes after the
> >> script has run.
> >>
> >> If your code does have these cases, I recommend you either get rid of
> >> them, or manually migrate that code before running the script (remove
> >> the relevant eo_do).
> >
> > Oh, one more thing about the script! There is another very important
> > "gotcha" you should be aware of.
> >
> > If you had if/for/while/whatever statements without {} (you really
> > shouldn't have those, is it's your fault to begin with), those can fail
> > in some cases (a la the infamous "goto fail") because for example:
> > if (bla)
> >  eo_do(obj, a_set(1), b_set(2));
> >
> > will be changed by the script to:
> > if (bla)
> >  a_set(obj, 1);
> >  b_set(obj, 2);
> >
> > which is obviously absolutely wrong, so please be aware of those, and
> > maybe run gcc 6 with the misleading indentation warning on. :)
>
> One more comment, if you wanna migrate an already migrated file and
> don't want it to break on eo_add, you can just edit this line in the
> script:
>  eo_do =
>
> re.compile(r'^(.*)\b(eo_add|eo_add_ref|eo_do|eo_do_ret|eo_do_super|eo_do_super_ret)\s*\(',
> re.MULTILINE)
>
> Remove eo_add and eo_add_ref like this:
>  eo_do =
> re.compile(r'^(.*)\b(eo_do|eo_do_ret|eo_do_super|eo_do_super_ret)\s*\(',
> re.MULTILINE)
>
> And you should be good to go, it'll just fix whatever remaining eo_do
> you may have.
>
> Enjoy.
>
>
Thanks a lot for all this, Tom.

If like me you had a work branch with tons of changes with eo_do, here's
what I did to get back on track:

1. git rebase -i master
This will conflict all the time... now

Re: [E-devel] [EGIT] [core/efl] master 03/03: Eolian: Mark all EO class_get() as weak

2016-04-03 Thread Jean-Philippe André
Hi Tom,

On 3 April 2016 at 19:39, Tom Hacohen <t...@stosb.com> wrote:

> Btw, this patch is incomplete. It doesn't mark the class get functions as
> weak.
> [...]
> > > >>>   Eolian: Mark all EO class_get() as weak
>

This was done in two commits, and you were replying to the commit marking
class_get as weak.
So, yes, it does.

:)

-- 
Jean-Philippe André
--
___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel


Re: [E-devel] eo_part and containers API

2016-04-27 Thread Jean-Philippe André
On 27 April 2016 at 23:44, Tom Hacohen <t...@osg.samsung.com> wrote:

> On 26/04/16 06:28, Jean-Philippe André wrote:
> > Hello,
> >
> >
> > I've just merged a series of commits dealing with the box & table APIs
> for
> > Edje.Object and Elm.Layout. Since we decided not to implement anything
> like
> > eo_part at the core eo level, I've implemented part_box and part_table
> > support using fake objects.
> >
> >
> > This code:
> >> elm_layout_table_blah(ly, "part", args);
> >
> > now becomes:
> >> efl_pack_blah(efl_content_get(ly, "part"), args);
> >
> >
> > The EO returned by efl_content_get is not a real Evas Object, it's only a
> > temporary proxy object that knows about its parent (ly) and the part name
> > it refers to ("part"). It is attached to the underlying Evas Box or Table
> > created by edje, and should live
> >
> > eo_del() is legal, just call efl_content_get() again to create a new
> handle.
> > eo_ref() is not a good idea.
> >
> >
> > Note that efl_content_get() also returns real swallowed objects if the
> > "part" is a SWALLOW.
> >
> >
> > I believe text part APIs should eventually move to the same concept, once
> > the text interface is finalized (or, well, good enough). efl_text_set()
> on
> > a Layout object (or any Widget) should set the text of the "default" part
> > (whatever that means). Other parts can be accessed by efl_content_get().
> >
> >
> > Comments? Suggestions on how to improve this?
> >
> >
>
> Proxy objects were one of the original ideas to do eo_part. After that
> we decided to do the more lightweight version I proposed and after that
> it was rejected altogether.
>
> I don't like this solution because it's essentially what everyone
> (raster?) said he didn't want to do. I prefer doing the part_* versions
> (i.e double the functions), the normal versions (passing NULL as part
> name) or maybe even an eo_part.
>

The part version means we should probably have a series of part_pack
interfaces then.
Or duplicate each and every API.

Honestly, I'm not sure which solution is best. Proxy object or part APIs.
But I believe the API looks pretty decent like this.

If we (or "people") really want the part APIs then I think we can just add
static inline / macros for C.

Anyway, remember the scope of these proxy objects: Edje BOX and TABLE.
No one uses that. Proxy objects make the API behave the same as a swallowed
Box or Table.

My biggest concern with this is the "eo_del() is legal, just call ..."
> paragraph. You need to describe the lifecycle properly and not leave it
> to chance because people will use it and you need to make sure they know
> what's allowed, what's not and what they should do. For example, it's
> not obvious to me if I get a ref out if I do content_get(). If I don't I
> risk the object being deleted underneath my feet. If I do, it becomes
> more of a PITA to deal with. Which one is it?
>

You don't get a reference. The object keeps it. There is no own().
content_get() creates an object if there is not one already, eo_del() nulls
out the reference inside the object. So another content_get() triggers a
new object creation.

The proxy object can't die under your feet as it's bound to the main
object. Unless you eo_del() the container.
It's basically the same as eo_data_scope_get().

Is this a documentation issue or a design issue?

-- 
Jean-Philippe André
--
Find and fix application performance issues faster with Applications Manager
Applications Manager provides deep performance insights into multiple tiers of
your business applications. It resolves application problems quickly and
reduces your MTTR. Get your free trial!
https://ad.doubleclick.net/ddm/clk/302982198;130105516;z
___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel


Re: [E-devel] [EGIT] [core/efl] master 03/03: docs: ector: improve docs for the abstract renderer base class

2016-04-24 Thread Jean-Philippe André
Hey Stefan,

On 22 April 2016 at 19:56, Stefan Schmidt <ste...@osg.samsung.com> wrote:

> stefan pushed a commit to branch master.
>
>
> http://git.enlightenment.org/core/efl.git/commit/?id=6e19e4f46d8e8ac9671c12228de9797accfa
>
> commit 6e19e4f46d8e8ac9671c12228de9797accfa
> Author: Stefan Schmidt <ste...@osg.samsung.com>
> Date:   Fri Apr 22 12:52:42 2016 +0200
>
> docs: ector: improve docs for the abstract renderer base class
>
> Not everything is docuement here yet. Might need some help from people
> more
> familiar with ector.
>
>
Ector is (still) an internal library. Highly subject to change, I don't
think a good stable documentation is necessary here.


-- 
Jean-Philippe André
--
Find and fix application performance issues faster with Applications Manager
Applications Manager provides deep performance insights into multiple tiers of
your business applications. It resolves application problems quickly and
reduces your MTTR. Get your free trial!
https://ad.doubleclick.net/ddm/clk/302982198;130105516;z
___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel


Re: [E-devel] eo_part and containers API

2016-04-29 Thread Jean-Philippe André
On 30 April 2016 at 02:31, Davide Andreoli <d...@gurumeditation.it> wrote:

> 2016-04-28 17:51 GMT+02:00 Tom Hacohen <t...@osg.samsung.com>:
>
> > On 28/04/16 06:25, Jean-Philippe André wrote:
> > > On 27 April 2016 at 23:44, Tom Hacohen <t...@osg.samsung.com> wrote:
> > >
> > >> On 26/04/16 06:28, Jean-Philippe André wrote:
> > >>> Hello,
> > >>>
> > >>>
> > >>> I've just merged a series of commits dealing with the box & table
> APIs
> > >> for
> > >>> Edje.Object and Elm.Layout. Since we decided not to implement
> anything
> > >> like
> > >>> eo_part at the core eo level, I've implemented part_box and
> part_table
> > >>> support using fake objects.
> > >>>
> > >>>
> > >>> This code:
> > >>>> elm_layout_table_blah(ly, "part", args);
> > >>>
> > >>> now becomes:
> > >>>> efl_pack_blah(efl_content_get(ly, "part"), args);
> > >>>
> > >>>
> > >>> The EO returned by efl_content_get is not a real Evas Object, it's
> > only a
> > >>> temporary proxy object that knows about its parent (ly) and the part
> > name
> > >>> it refers to ("part"). It is attached to the underlying Evas Box or
> > Table
> > >>> created by edje, and should live
> > >>>
> > >>> eo_del() is legal, just call efl_content_get() again to create a new
> > >> handle.
> > >>> eo_ref() is not a good idea.
> > >>>
> > >>>
> > >>> Note that efl_content_get() also returns real swallowed objects if
> the
> > >>> "part" is a SWALLOW.
> > >>>
> > >>>
> > >>> I believe text part APIs should eventually move to the same concept,
> > once
> > >>> the text interface is finalized (or, well, good enough).
> efl_text_set()
> > >> on
> > >>> a Layout object (or any Widget) should set the text of the "default"
> > part
> > >>> (whatever that means). Other parts can be accessed by
> > efl_content_get().
> > >>>
> > >>>
> > >>> Comments? Suggestions on how to improve this?
> > >>>
> > >>>
> > >>
> > >> Proxy objects were one of the original ideas to do eo_part. After that
> > >> we decided to do the more lightweight version I proposed and after
> that
> > >> it was rejected altogether.
> > >>
> > >> I don't like this solution because it's essentially what everyone
> > >> (raster?) said he didn't want to do. I prefer doing the part_*
> versions
> > >> (i.e double the functions), the normal versions (passing NULL as part
> > >> name) or maybe even an eo_part.
> > >>
> > >
> > > The part version means we should probably have a series of part_pack
> > > interfaces then.
> > > Or duplicate each and every API.
> > >
> > > Honestly, I'm not sure which solution is best. Proxy object or part
> APIs.
> > > But I believe the API looks pretty decent like this.
> >
> > I also like the part API, it's essentially the same API I suggested a
> > while back:
> >
> > efl_text_set(eo_part(obj, "bla"), "text"));
> >
> > Raster objected...
> >
> >
> I tend to agree with raster, and all this eo_part seems overenginered to my
> eyes.
> I also consider the eo_part() usage ugly and not user friendly,
> I still do not understand well what "part" is in real usage: are (for
> example) ElmList
> items considered parts? and table items? and swallowed object?
>

Parts are named items, so swallowed objects or actual edje parts (eg. an
edje box or text).


Also from the python bindings prospective this is ugly, complex to
> implement and
> for the user to use.
>
> So here is my suggestion (maybe too much simple?):
> elf_text_set(obj, text, part @nullable)
>
> so no "exotic" proxy objects, refcount issues and super simple for the
> user.
>

Yes, this is the ideal solution for bindings.


this will be the best choice for bindings as the nullable param can be
> omitted (at least in python) and the user can do:
> obj.text_set("my label")  or
> obj.text_set("my second label", "part_name")
>
> Only drawback I can see is that in C you have to pass NULL as the

<    3   4   5   6   7   8   9   10   11   12   >