[EGIT] [core/enlightenment] v-0.25.0 04/28: add forgotten header define

2022-02-07 Thread Marcel Hollerbach
raster pushed a commit to branch v-0.25.0.

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

commit cabb9aff01694d0a540912f88dc9589d4bcfd4ce
Author: Marcel Hollerbach 
Date:   Thu Jan 6 21:40:14 2022 +0100

add forgotten header define
---
 src/bin/e_client.h | 1 +
 1 file changed, 1 insertion(+)

diff --git a/src/bin/e_client.h b/src/bin/e_client.h
index af2823eb8..826cf352d 100644
--- a/src/bin/e_client.h
+++ b/src/bin/e_client.h
@@ -815,6 +815,7 @@ E_API Eina_Bool e_client_focus_track_enabled(void);
 E_API void e_client_focus_track_freeze(void);
 E_API void e_client_focus_track_thaw(void);
 E_API void e_client_refocus(void);
+E_API void e_client_revert_focus(E_Client *ec);
 E_API void e_client_focus_set_with_pointer(E_Client *ec);
 E_API void e_client_activate(E_Client *ec, Eina_Bool just_do_it);
 E_API E_Client *e_client_focused_get(void);

-- 




[EGIT] [core/enlightenment] v-0.25.0 20/28: e_client: fix more focus weirdness

2022-02-07 Thread Marcel Hollerbach
raster pushed a commit to branch v-0.25.0.

http://git.enlightenment.org/core/enlightenment.git/commit/?id=4814a63d4c8d02a6f3782fca33d28c08a96950f5

commit 4814a63d4c8d02a6f3782fca33d28c08a96950f5
Author: Marcel Hollerbach 
Date:   Fri Jan 28 18:24:51 2022 +0100

e_client: fix more focus weirdness

parent should be raised, even though it is not the modal.
---
 src/bin/e_client.c | 13 +
 1 file changed, 9 insertions(+), 4 deletions(-)

diff --git a/src/bin/e_client.c b/src/bin/e_client.c
index f3d01663b..a0314df2f 100644
--- a/src/bin/e_client.c
+++ b/src/bin/e_client.c
@@ -433,12 +433,17 @@ e_client_revert_focus(E_Client *ec)
}
   }
  }
-   else if ((ec->parent) &&
-(ec->parent->desk == desk) && (ec->parent->modal == ec))
+   else if ((ec->parent) && (ec->parent->desk == desk))
  {
-evas_object_focus_set(ec->parent->frame, 1);
+E_Client *goal_ec = NULL;
+if (ec->parent->modal != ec && ec->parent->modal) {
+  goal_ec = ec->parent->modal;
+} else {
+  goal_ec = ec->parent;
+}
+evas_object_focus_set(goal_ec->frame, 1);
 if (e_config->raise_on_revert_focus)
-  evas_object_raise(ec->parent->frame);
+  evas_object_raise(goal_ec->frame);
  }
else if (e_config->focus_revert_on_hide_or_close)
  {

-- 




[EGIT] [core/enlightenment] v-0.25.0 07/28: focus: do not revert to another client when client is unfocused

2022-02-07 Thread Marcel Hollerbach
raster pushed a commit to branch v-0.25.0.

http://git.enlightenment.org/core/enlightenment.git/commit/?id=35b8f86906072a0d28dbf38a8301ec93514da85d

commit 35b8f86906072a0d28dbf38a8301ec93514da85d
Author: Marcel Hollerbach 
Date:   Sun Jan 9 15:33:18 2022 +0100

focus: do not revert to another client when client is unfocused

This was a nice idea to fix most focus bugs at once. However, due to the
runtime of e many things can get "randomly" focused, for exmaple: volume
control on the frame, internal dialogs, config value screens when
grabbing for keys, widgets when they get created in a gadget. The list
is quite long. However, fixing all those little bugs is hard and partly
impossible as the behaviour is correct in the context of a toolkit, not
in the context of a compositor.

Long term we should split window-focus and canvas-focus from each other,
then bugs like these would not be a problem anymore.
---
 src/bin/e_comp_object.c | 7 ---
 src/bin/e_comp_x.c  | 2 +-
 src/bin/e_desk.c| 5 +++--
 src/bin/e_focus.c   | 5 +++--
 4 files changed, 11 insertions(+), 8 deletions(-)

diff --git a/src/bin/e_comp_object.c b/src/bin/e_comp_object.c
index 77720aa19..d960e4a80 100644
--- a/src/bin/e_comp_object.c
+++ b/src/bin/e_comp_object.c
@@ -1878,7 +1878,7 @@ _e_comp_intercept_focus(void *data, Evas_Object *obj, 
Eina_Bool focus)
else
  {
 if (e_client_focused_get() == ec) {
-  e_client_revert_focus(ec);
+  e_client_focused_set(NULL);
 }
  }
evas_object_focus_set(obj, focus);
@@ -2353,8 +2353,9 @@ _e_comp_smart_hide(Evas_Object *obj)
   edje_object_play_set(cw->frame_object, 0);
  }
/* ensure focus-out */
-   if (cw->ec->focused)
- evas_object_focus_set(cw->ec->frame, 0);
+   if (cw->ec->focused) {
+ e_client_revert_focus(cw->ec);
+   }
e_comp_render_queue(); //force nocomp recheck
e_comp_shape_queue();
 }
diff --git a/src/bin/e_comp_x.c b/src/bin/e_comp_x.c
index 2c742c616..8bc2c99d6 100644
--- a/src/bin/e_comp_x.c
+++ b/src/bin/e_comp_x.c
@@ -2884,7 +2884,7 @@ _e_comp_x_focus_out(void *data EINA_UNUSED, int type 
EINA_UNUSED, Ecore_X_Event_
 else if (ev->detail == ECORE_X_EVENT_DETAIL_INFERIOR)
   return ECORE_CALLBACK_PASS_ON;
  }
-   evas_object_focus_set(ec->frame, 0);
+   e_client_revert_focus(ec);
return ECORE_CALLBACK_PASS_ON;
 }
 
diff --git a/src/bin/e_desk.c b/src/bin/e_desk.c
index 0f3730541..6697e7a79 100644
--- a/src/bin/e_desk.c
+++ b/src/bin/e_desk.c
@@ -454,8 +454,9 @@ e_desk_last_focused_focus(E_Desk *desk)
   evas_object_raise(ecs->frame);
 return ecs;
  }
-   if (e_client_focused_get())
- evas_object_focus_set(e_client_focused_get()->frame, 0);
+   if (e_client_focused_get()) {
+ e_client_revert_focus(e_client_focused_get());
+   }
return NULL;
 }
 
diff --git a/src/bin/e_focus.c b/src/bin/e_focus.c
index 537e48e88..0e59b7d0a 100644
--- a/src/bin/e_focus.c
+++ b/src/bin/e_focus.c
@@ -35,8 +35,9 @@ e_focus_event_mouse_out(E_Client *ec)
  {
 if (!ec->lock_focus_in)
   {
- if (ec->focused)
-   evas_object_focus_set(ec->frame, 0);
+ if (ec->focused) {
+   e_client_revert_focus(ec);
+ }
   }
  }
E_FREE_FUNC(ec->raise_timer, ecore_timer_del);

-- 




[EGIT] [core/enlightenment] v-0.25.0 03/28: e_client: revert focus instead of setting it to NULL

2022-02-07 Thread Marcel Hollerbach
raster pushed a commit to branch v-0.25.0.

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

commit 2e99d11a1baf5601378b9c16d05793f41db708be
Author: Marcel Hollerbach 
Date:   Thu Jan 6 20:57:38 2022 +0100

e_client: revert focus instead of setting it to NULL

When closing a client a few different things can happen:
1. Client hides, this will destroy the e_client object, which will
   reverts focus to another client.
2. Client hook del, this will recover focus to the root window if no
   e_client is focused.
3. Client unfocus event, setted the focused to NULL and sets the focus 
field to 0.

when first 1 happens then 2 or 3 everything is fine. However, it seems
that sometimes first 3 happend, then 2, then 1. Which results in focus
beeing first NULL, then recovered to the root window, resulting in the
wrong things happening.
---
 src/bin/e_client.c  | 10 +-
 src/bin/e_comp_object.c |  5 +++--
 2 files changed, 8 insertions(+), 7 deletions(-)

diff --git a/src/bin/e_client.c b/src/bin/e_client.c
index 6e605a339..85f5504a7 100644
--- a/src/bin/e_client.c
+++ b/src/bin/e_client.c
@@ -400,8 +400,8 @@ _e_client_mouse_action_end(E_Client *ec)
E_FREE_FUNC(ec->cur_mouse_action, e_object_unref);
 }
 
-static void
-_e_client_revert_focus(E_Client *ec)
+E_API void
+e_client_revert_focus(E_Client *ec)
 {
E_Client *pec;
E_Desk *desk;
@@ -644,7 +644,7 @@ _e_client_del(E_Client *ec)
  evas_object_hide(ec->internal_elm_win);
 
if (ec->focused)
- _e_client_revert_focus(ec);
+ e_client_revert_focus(ec);
if (ec->frame) evas_object_focus_set(ec->frame, 0);
 
E_FREE_FUNC(ec->ping_poller, ecore_poller_del);
@@ -1560,7 +1560,7 @@ _e_client_cb_evas_hide(void *data, Evas *e EINA_UNUSED, 
Evas_Object *obj EINA_UN
if (!ec->hidden)
  {
 if (ec->focused)
-  _e_client_revert_focus(ec);
+  e_client_revert_focus(ec);
  }
ec->want_focus = ec->take_focus = 0;
 
@@ -4642,7 +4642,7 @@ e_client_iconify(E_Client *ec)
  {
 if (!ec->new_client)
   {
- _e_client_revert_focus(ec);
+ e_client_revert_focus(ec);
  evas_object_hide(ec->frame);
   }
 e_client_urgent_set(ec, ec->icccm.urgent);
diff --git a/src/bin/e_comp_object.c b/src/bin/e_comp_object.c
index 04b0bd330..77720aa19 100644
--- a/src/bin/e_comp_object.c
+++ b/src/bin/e_comp_object.c
@@ -1877,8 +1877,9 @@ _e_comp_intercept_focus(void *data, Evas_Object *obj, 
Eina_Bool focus)
  }
else
  {
-if (e_client_focused_get() == ec)
-  e_client_focused_set(NULL);
+if (e_client_focused_get() == ec) {
+  e_client_revert_focus(ec);
+}
  }
evas_object_focus_set(obj, focus);
 }

-- 




[EGIT] [core/enlightenment] v-0.25.0 09/28: focus: leave frame focus setting here

2022-02-07 Thread Marcel Hollerbach
raster pushed a commit to branch v-0.25.0.

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

commit 0e64bbfc563060598ff60bff545c6578aec91d3f
Author: Marcel Hollerbach 
Date:   Sun Jan 9 17:32:48 2022 +0100

focus: leave frame focus setting here

that might cause bugs, however, everything else might end up in a
endless recursion.
---
 src/bin/e_desk.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/bin/e_desk.c b/src/bin/e_desk.c
index 6697e7a79..6a9c3a2cf 100644
--- a/src/bin/e_desk.c
+++ b/src/bin/e_desk.c
@@ -455,7 +455,7 @@ e_desk_last_focused_focus(E_Desk *desk)
 return ecs;
  }
if (e_client_focused_get()) {
- e_client_revert_focus(e_client_focused_get());
+ evas_object_focus_set(e_client_focused_get()->frame, 0);
}
return NULL;
 }

-- 




[EGIT] [core/enlightenment] master 01/01: e_client: fix more focus weirdness

2022-01-28 Thread Marcel Hollerbach
bu5hm4n pushed a commit to branch master.

http://git.enlightenment.org/core/enlightenment.git/commit/?id=349acb214db4c86dde2e8c84c1e63586b6c01bea

commit 349acb214db4c86dde2e8c84c1e63586b6c01bea
Author: Marcel Hollerbach 
Date:   Fri Jan 28 18:24:51 2022 +0100

e_client: fix more focus weirdness

parent should be raised, even though it is not the modal.
---
 src/bin/e_client.c | 13 +
 1 file changed, 9 insertions(+), 4 deletions(-)

diff --git a/src/bin/e_client.c b/src/bin/e_client.c
index f3d01663b..a0314df2f 100644
--- a/src/bin/e_client.c
+++ b/src/bin/e_client.c
@@ -433,12 +433,17 @@ e_client_revert_focus(E_Client *ec)
}
   }
  }
-   else if ((ec->parent) &&
-(ec->parent->desk == desk) && (ec->parent->modal == ec))
+   else if ((ec->parent) && (ec->parent->desk == desk))
  {
-evas_object_focus_set(ec->parent->frame, 1);
+E_Client *goal_ec = NULL;
+if (ec->parent->modal != ec && ec->parent->modal) {
+  goal_ec = ec->parent->modal;
+} else {
+  goal_ec = ec->parent;
+}
+evas_object_focus_set(goal_ec->frame, 1);
 if (e_config->raise_on_revert_focus)
-  evas_object_raise(ec->parent->frame);
+  evas_object_raise(goal_ec->frame);
  }
else if (e_config->focus_revert_on_hide_or_close)
  {

-- 




[EGIT] [core/enlightenment] master 01/01: focus: leave frame focus setting here

2022-01-09 Thread Marcel Hollerbach
bu5hm4n pushed a commit to branch master.

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

commit f7708c6e747f0a11723802429a9bbc32434af3c7
Author: Marcel Hollerbach 
Date:   Sun Jan 9 17:32:48 2022 +0100

focus: leave frame focus setting here

that might cause bugs, however, everything else might end up in a
endless recursion.
---
 src/bin/e_desk.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/bin/e_desk.c b/src/bin/e_desk.c
index 6697e7a79..6a9c3a2cf 100644
--- a/src/bin/e_desk.c
+++ b/src/bin/e_desk.c
@@ -455,7 +455,7 @@ e_desk_last_focused_focus(E_Desk *desk)
 return ecs;
  }
if (e_client_focused_get()) {
- e_client_revert_focus(e_client_focused_get());
+ evas_object_focus_set(e_client_focused_get()->frame, 0);
}
return NULL;
 }

-- 




[EGIT] [core/enlightenment] master 01/01: focus: do not revert to another client when client is unfocused

2022-01-09 Thread Marcel Hollerbach
bu5hm4n pushed a commit to branch master.

http://git.enlightenment.org/core/enlightenment.git/commit/?id=841c8f477f47bcb21b347d62332f87adc2d6d7d8

commit 841c8f477f47bcb21b347d62332f87adc2d6d7d8
Author: Marcel Hollerbach 
Date:   Sun Jan 9 15:33:18 2022 +0100

focus: do not revert to another client when client is unfocused

This was a nice idea to fix most focus bugs at once. However, due to the
runtime of e many things can get "randomly" focused, for exmaple: volume
control on the frame, internal dialogs, config value screens when
grabbing for keys, widgets when they get created in a gadget. The list
is quite long. However, fixing all those little bugs is hard and partly
impossible as the behaviour is correct in the context of a toolkit, not
in the context of a compositor.

Long term we should split window-focus and canvas-focus from each other,
then bugs like these would not be a problem anymore.
---
 src/bin/e_comp_object.c | 7 ---
 src/bin/e_comp_x.c  | 2 +-
 src/bin/e_desk.c| 5 +++--
 src/bin/e_focus.c   | 5 +++--
 4 files changed, 11 insertions(+), 8 deletions(-)

diff --git a/src/bin/e_comp_object.c b/src/bin/e_comp_object.c
index 77720aa19..d960e4a80 100644
--- a/src/bin/e_comp_object.c
+++ b/src/bin/e_comp_object.c
@@ -1878,7 +1878,7 @@ _e_comp_intercept_focus(void *data, Evas_Object *obj, 
Eina_Bool focus)
else
  {
 if (e_client_focused_get() == ec) {
-  e_client_revert_focus(ec);
+  e_client_focused_set(NULL);
 }
  }
evas_object_focus_set(obj, focus);
@@ -2353,8 +2353,9 @@ _e_comp_smart_hide(Evas_Object *obj)
   edje_object_play_set(cw->frame_object, 0);
  }
/* ensure focus-out */
-   if (cw->ec->focused)
- evas_object_focus_set(cw->ec->frame, 0);
+   if (cw->ec->focused) {
+ e_client_revert_focus(cw->ec);
+   }
e_comp_render_queue(); //force nocomp recheck
e_comp_shape_queue();
 }
diff --git a/src/bin/e_comp_x.c b/src/bin/e_comp_x.c
index 2c742c616..8bc2c99d6 100644
--- a/src/bin/e_comp_x.c
+++ b/src/bin/e_comp_x.c
@@ -2884,7 +2884,7 @@ _e_comp_x_focus_out(void *data EINA_UNUSED, int type 
EINA_UNUSED, Ecore_X_Event_
 else if (ev->detail == ECORE_X_EVENT_DETAIL_INFERIOR)
   return ECORE_CALLBACK_PASS_ON;
  }
-   evas_object_focus_set(ec->frame, 0);
+   e_client_revert_focus(ec);
return ECORE_CALLBACK_PASS_ON;
 }
 
diff --git a/src/bin/e_desk.c b/src/bin/e_desk.c
index 0f3730541..6697e7a79 100644
--- a/src/bin/e_desk.c
+++ b/src/bin/e_desk.c
@@ -454,8 +454,9 @@ e_desk_last_focused_focus(E_Desk *desk)
   evas_object_raise(ecs->frame);
 return ecs;
  }
-   if (e_client_focused_get())
- evas_object_focus_set(e_client_focused_get()->frame, 0);
+   if (e_client_focused_get()) {
+ e_client_revert_focus(e_client_focused_get());
+   }
return NULL;
 }
 
diff --git a/src/bin/e_focus.c b/src/bin/e_focus.c
index 537e48e88..0e59b7d0a 100644
--- a/src/bin/e_focus.c
+++ b/src/bin/e_focus.c
@@ -35,8 +35,9 @@ e_focus_event_mouse_out(E_Client *ec)
  {
 if (!ec->lock_focus_in)
   {
- if (ec->focused)
-   evas_object_focus_set(ec->frame, 0);
+ if (ec->focused) {
+   e_client_revert_focus(ec);
+ }
   }
  }
E_FREE_FUNC(ec->raise_timer, ecore_timer_del);

-- 




[EGIT] [core/enlightenment] master 01/01: add forgotten header define

2022-01-06 Thread Marcel Hollerbach
bu5hm4n pushed a commit to branch master.

http://git.enlightenment.org/core/enlightenment.git/commit/?id=1f69e41daa76bcbe93129e79be40ca966600f02b

commit 1f69e41daa76bcbe93129e79be40ca966600f02b
Author: Marcel Hollerbach 
Date:   Thu Jan 6 21:40:14 2022 +0100

add forgotten header define
---
 src/bin/e_client.h | 1 +
 1 file changed, 1 insertion(+)

diff --git a/src/bin/e_client.h b/src/bin/e_client.h
index af2823eb8..826cf352d 100644
--- a/src/bin/e_client.h
+++ b/src/bin/e_client.h
@@ -815,6 +815,7 @@ E_API Eina_Bool e_client_focus_track_enabled(void);
 E_API void e_client_focus_track_freeze(void);
 E_API void e_client_focus_track_thaw(void);
 E_API void e_client_refocus(void);
+E_API void e_client_revert_focus(E_Client *ec);
 E_API void e_client_focus_set_with_pointer(E_Client *ec);
 E_API void e_client_activate(E_Client *ec, Eina_Bool just_do_it);
 E_API E_Client *e_client_focused_get(void);

-- 




[EGIT] [core/enlightenment] master 01/01: e_client: revert focus instead of setting it to NULL

2022-01-06 Thread Marcel Hollerbach
bu5hm4n pushed a commit to branch master.

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

commit 2d86d75139c40e7365e34880b0e3b56f248b0e41
Author: Marcel Hollerbach 
Date:   Thu Jan 6 20:57:38 2022 +0100

e_client: revert focus instead of setting it to NULL

When closing a client a few different things can happen:
1. Client hides, this will destroy the e_client object, which will
   reverts focus to another client.
2. Client hook del, this will recover focus to the root window if no
   e_client is focused.
3. Client unfocus event, setted the focused to NULL and sets the focus 
field to 0.

when first 1 happens then 2 or 3 everything is fine. However, it seems
that sometimes first 3 happend, then 2, then 1. Which results in focus
beeing first NULL, then recovered to the root window, resulting in the
wrong things happening.
---
 src/bin/e_client.c  | 10 +-
 src/bin/e_comp_object.c |  5 +++--
 2 files changed, 8 insertions(+), 7 deletions(-)

diff --git a/src/bin/e_client.c b/src/bin/e_client.c
index 6e605a339..85f5504a7 100644
--- a/src/bin/e_client.c
+++ b/src/bin/e_client.c
@@ -400,8 +400,8 @@ _e_client_mouse_action_end(E_Client *ec)
E_FREE_FUNC(ec->cur_mouse_action, e_object_unref);
 }
 
-static void
-_e_client_revert_focus(E_Client *ec)
+E_API void
+e_client_revert_focus(E_Client *ec)
 {
E_Client *pec;
E_Desk *desk;
@@ -644,7 +644,7 @@ _e_client_del(E_Client *ec)
  evas_object_hide(ec->internal_elm_win);
 
if (ec->focused)
- _e_client_revert_focus(ec);
+ e_client_revert_focus(ec);
if (ec->frame) evas_object_focus_set(ec->frame, 0);
 
E_FREE_FUNC(ec->ping_poller, ecore_poller_del);
@@ -1560,7 +1560,7 @@ _e_client_cb_evas_hide(void *data, Evas *e EINA_UNUSED, 
Evas_Object *obj EINA_UN
if (!ec->hidden)
  {
 if (ec->focused)
-  _e_client_revert_focus(ec);
+  e_client_revert_focus(ec);
  }
ec->want_focus = ec->take_focus = 0;
 
@@ -4642,7 +4642,7 @@ e_client_iconify(E_Client *ec)
  {
 if (!ec->new_client)
   {
- _e_client_revert_focus(ec);
+ e_client_revert_focus(ec);
  evas_object_hide(ec->frame);
   }
 e_client_urgent_set(ec, ec->icccm.urgent);
diff --git a/src/bin/e_comp_object.c b/src/bin/e_comp_object.c
index 04b0bd330..77720aa19 100644
--- a/src/bin/e_comp_object.c
+++ b/src/bin/e_comp_object.c
@@ -1877,8 +1877,9 @@ _e_comp_intercept_focus(void *data, Evas_Object *obj, 
Eina_Bool focus)
  }
else
  {
-if (e_client_focused_get() == ec)
-  e_client_focused_set(NULL);
+if (e_client_focused_get() == ec) {
+  e_client_revert_focus(ec);
+}
  }
evas_object_focus_set(obj, focus);
 }

-- 




[EGIT] [core/enlightenment] master 01/01: it should be edd not eed ... :(

2021-12-17 Thread Marcel Hollerbach
bu5hm4n pushed a commit to branch master.

http://git.enlightenment.org/core/enlightenment.git/commit/?id=1766779b1940003d9484ecd872fcb1f995e1a804

commit 1766779b1940003d9484ecd872fcb1f995e1a804
Author: Marcel Hollerbach 
Date:   Fri Dec 17 13:19:28 2021 +0100

it should be edd not eed ... :(
---
 src/modules/lokker/lokker.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/modules/lokker/lokker.c b/src/modules/lokker/lokker.c
index 67d79b77f..91ad1cda0 100644
--- a/src/modules/lokker/lokker.c
+++ b/src/modules/lokker/lokker.c
@@ -946,7 +946,7 @@ lokker_unlock(void)
 {
e_auth_fprint_end();
E_FREE_LIST(edd->elock_wnd_list, _lokker_popup_free);
-   e_pointer_type_pop(e_comp->pointer, eed, "default");
+   e_pointer_type_pop(e_comp->pointer, edd, "default");
E_FREE_LIST(edd->handlers, ecore_event_handler_del);
if (edd->move_handler) ecore_event_handler_del(edd->move_handler);
 

-- 




[EGIT] [core/enlightenment] master 01/02: do not crash when context is NULL

2021-12-17 Thread Marcel Hollerbach
bu5hm4n pushed a commit to branch master.

http://git.enlightenment.org/core/enlightenment.git/commit/?id=36eafd9a0ee18b0b780e7560f55a9b4d6821815d

commit 36eafd9a0ee18b0b780e7560f55a9b4d6821815d
Author: Marcel Hollerbach 
Date:   Sat Dec 4 18:02:54 2021 +0100

do not crash when context is NULL
---
 src/bin/e_dbusmenu.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/src/bin/e_dbusmenu.c b/src/bin/e_dbusmenu.c
index 8abcad285..f2612b567 100644
--- a/src/bin/e_dbusmenu.c
+++ b/src/bin/e_dbusmenu.c
@@ -450,12 +450,14 @@ e_dbusmenu_unload(E_DBusMenu_Ctx *ctx)
 E_API void
 e_dbusmenu_pop_request_cb_set(E_DBusMenu_Ctx *ctx, E_DBusMenu_Pop_Request_Cb 
cb)
 {
+   EINA_SAFETY_ON_NULL_RETURN(ctx);
ctx->pop_request_cb = cb;
 }
 
 E_API void
 e_dbusmenu_update_cb_set(E_DBusMenu_Ctx *ctx, E_DBusMenu_Update_Cb cb)
 {
+   EINA_SAFETY_ON_NULL_RETURN(ctx);
ctx->update_cb = cb;
 }
 

-- 




[EGIT] [core/enlightenment] master 02/02: e_pointer: improve overall

2021-12-17 Thread Marcel Hollerbach
bu5hm4n pushed a commit to branch master.

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

commit b23776416118cc96348b4cde4ce0e88a35b8ef87
Author: Marcel Hollerbach 
Date:   Sun Dec 5 17:27:06 2021 +0100

e_pointer: improve overall

do not allow a dangling pointer, and check all entities that require the
pointer object to be alive.
---
 src/bin/e_pointer.c | 25 +
 src/modules/lokker/lokker.c |  4 ++--
 2 files changed, 27 insertions(+), 2 deletions(-)

diff --git a/src/bin/e_pointer.c b/src/bin/e_pointer.c
index 22a040fb4..dd4df9b90 100644
--- a/src/bin/e_pointer.c
+++ b/src/bin/e_pointer.c
@@ -249,16 +249,27 @@ _e_pointer_cb_hot_show(void *data, Evas *evas 
EINA_UNUSED, Evas_Object *obj EINA
_hot_update(ptr);
 }
 
+static void
+_del_cb(void *data, const Efl_Event *ev EINA_UNUSED) {
+  E_Pointer *ptr = data;
+  INF("Cursor-Object (%p) of %p was removed!", ptr->o_ptr, data);
+  ptr->o_ptr = NULL;
+  return;
+}
+
 static void
 _e_pointer_pointer_canvas_init(E_Pointer *ptr, Evas *e, Evas_Object **o_ptr, 
Evas_Object **o_hot)
 {
/* create pointer object */
*o_ptr = edje_object_add(e);
 
+   efl_event_callback_add(*o_ptr, EFL_EVENT_DEL, _del_cb, ptr);
+
/* create hotspot object */
*o_hot = evas_object_rectangle_add(e);
evas_object_color_set(*o_hot, 0, 0, 0, 0);
 
+
evas_object_event_callback_add(*o_hot, EVAS_CALLBACK_MOVE,
   _e_pointer_cb_hot_move, ptr);
evas_object_event_callback_add(*o_ptr, EVAS_CALLBACK_MOVE,
@@ -622,6 +633,9 @@ e_pointer_hide(E_Pointer *ptr)
 E_API void
 e_pointer_show(E_Pointer *ptr)
 {
+   EINA_SAFETY_ON_NULL_RETURN(ptr);
+   EINA_SAFETY_ON_NULL_RETURN(ptr->o_ptr);
+
if ((!ptr->buffer_evas) && ptr->win) _e_pointer_canvas_add(ptr);
if (ptr->canvas)
  evas_object_show(ptr->o_ptr);
@@ -633,6 +647,7 @@ e_pointer_type_push(E_Pointer *ptr, void *obj, const char 
*type)
E_Pointer_Stack *stack;
 
EINA_SAFETY_ON_NULL_RETURN(ptr);
+   EINA_SAFETY_ON_NULL_RETURN(obj);
 
_e_pointer_type_set(ptr, type);
 
@@ -788,6 +803,10 @@ e_pointer_idler_before(void)
  {
 if ((!ptr->e_cursor) || (!ptr->buffer_evas)) continue;
 
+if (!ptr->o_ptr) {
+  EINA_SAFETY_ERROR("ptr->o_ptr is NULL should not be NULL!");
+}
+
 if (ptr->hot.update)
   _e_pointer_type_set(ptr, ptr->type);
 
@@ -826,6 +845,9 @@ e_pointer_object_set(E_Pointer *ptr, Evas_Object *obj, int 
x, int y)
E_Client *ec;
int px, py;
 
+   EINA_SAFETY_ON_NULL_RETURN(ptr);
+   EINA_SAFETY_ON_NULL_RETURN(ptr->o_ptr);
+
ecore_evas_cursor_get(ptr->ee, , NULL, , );
if (o)
  {
@@ -872,6 +894,9 @@ e_pointer_window_add(E_Pointer *ptr, Ecore_Window win)
 E_API void
 e_pointer_grab_set(E_Pointer *ptr, Eina_Bool grab)
 {
+   EINA_SAFETY_ON_NULL_RETURN(ptr);
+   EINA_SAFETY_ON_NULL_RETURN(ptr->o_ptr);
+
if (grab) ptr->grabcount++;
else
  {
diff --git a/src/modules/lokker/lokker.c b/src/modules/lokker/lokker.c
index 59d417002..67d79b77f 100644
--- a/src/modules/lokker/lokker.c
+++ b/src/modules/lokker/lokker.c
@@ -920,7 +920,7 @@ lokker_lock(void)
mlock(edd, sizeof(Lokker_Data));
 #endif
 
-   e_pointer_type_push(e_comp->pointer, e_comp->pointer, "default");
+   e_pointer_type_push(e_comp->pointer, edd, "default");
E_LIST_FOREACH(e_comp->zones, _lokker_popup_add);
total_zone_num = eina_list_count(e_comp->zones);
 
@@ -946,7 +946,7 @@ lokker_unlock(void)
 {
e_auth_fprint_end();
E_FREE_LIST(edd->elock_wnd_list, _lokker_popup_free);
-   e_pointer_type_pop(e_comp->pointer, e_comp->pointer, "default");
+   e_pointer_type_pop(e_comp->pointer, eed, "default");
E_FREE_LIST(edd->handlers, ecore_event_handler_del);
if (edd->move_handler) ecore_event_handler_del(edd->move_handler);
 

-- 




[EGIT] [core/enlightenment] master 01/01: e_main: shutdown e_dnd before comp

2021-11-02 Thread Marcel Hollerbach
bu5hm4n pushed a commit to branch master.

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

commit d28c105c99ddfd35f2d0c7969291e9712d7c31d5
Author: Marcel Hollerbach 
Date:   Tue Nov 2 17:43:11 2021 +0100

e_main: shutdown e_dnd before comp

otherwise we are crashing as e_comp is freed by that time.
---
 src/bin/e_main.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/bin/e_main.c b/src/bin/e_main.c
index 68ed3507a..926c68a83 100644
--- a/src/bin/e_main.c
+++ b/src/bin/e_main.c
@@ -1589,7 +1589,6 @@ _e_main_screens_init(void)
 _e_main_shutdown(101);
  }
TS("E_Dnd Init Done");
-   _e_main_shutdown_push(e_dnd_shutdown);
 #endif
 
return 1;
@@ -1601,6 +1600,7 @@ _e_main_screens_shutdown(void)
e_win_shutdown();
e_menu_shutdown();
e_shelf_shutdown();
+   e_dnd_shutdown();
e_comp_shutdown();
e_client_volume_shutdown();
e_screensaver_shutdown();

-- 




[EGIT] [core/enlightenment] master 01/01: music-control: do not crash when no config is selected

2021-11-02 Thread Marcel Hollerbach
bu5hm4n pushed a commit to branch master.

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

commit e64e7d77c62d559d74ed1954392911d5289abed0
Author: Marcel Hollerbach 
Date:   Tue Nov 2 17:10:46 2021 +0100

music-control: do not crash when no config is selected

this is a fresh config crash.
---
 src/modules/music-control/ui.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/src/modules/music-control/ui.c b/src/modules/music-control/ui.c
index 03bdf95f2..ce66173c4 100644
--- a/src/modules/music-control/ui.c
+++ b/src/modules/music-control/ui.c
@@ -149,6 +149,7 @@ _player_name_update(E_Music_Control_Instance *inst)
 {
Edje_Message_String msg;
msg.str = (char 
*)music_player_players[inst->ctxt->config->player_selected].name;
+   EINA_SAFETY_ON_NULL_RETURN(msg.str);
edje_object_message_send(inst->content_popup, EDJE_MESSAGE_STRING, 0, );
 }
 

-- 




[EGIT] [core/enlightenment] master 01/01: e_bindings: do not crash when action is not found

2021-10-17 Thread Marcel Hollerbach
bu5hm4n pushed a commit to branch master.

http://git.enlightenment.org/core/enlightenment.git/commit/?id=28b0ce28ac3085d1c18f7165e5003b73654fe3c1

commit 28b0ce28ac3085d1c18f7165e5003b73654fe3c1
Author: Marcel Hollerbach 
Date:   Sun Oct 17 10:43:06 2021 +0200

e_bindings: do not crash when action is not found
---
 src/bin/e_bindings.c | 4 
 1 file changed, 4 insertions(+)

diff --git a/src/bin/e_bindings.c b/src/bin/e_bindings.c
index f6a494069..76658fde3 100644
--- a/src/bin/e_bindings.c
+++ b/src/bin/e_bindings.c
@@ -1683,6 +1683,10 @@ e_bindings_swipe_handle(E_Binding_Context ctxt, E_Object 
*obj, double direction,
 angle_accepted(binding->direction - binding->error, 
binding->direction + binding->error, direction))
   {
  act = e_action_find(binding->action);
+ if (!act) {
+   ERR("Action %s cannot be found!", binding->action);
+   return NULL;
+ }
  act->func.go(obj, binding->params);
   }
  }

-- 




Re: [E-devel] [EGIT] [core/efl] master 01/01: eo_test_general.c: Make eo_signals tests pass on Windows

2020-11-05 Thread Marcel Hollerbach

Hi,

this looks kind of wrong to me:

1. If you speak about the nondeterministic nature of the addresses of 
the events being different: That does not matter, the order of the event 
subscriptions within the array of different events do not matter. Only 
the order of the subscriptions of the same event do matter. This is 
coming from the fact that we are only "using" the resulting order of all 
subscriptions by its history, not by its address.



2. If you speak about the fact that we rely on the same events in the 
array keeping the same order, and there is behavior in the windows qsort 
implementation that is breaking our assertions, then this needs to be 
fixed in the EFL_CALLBACKS_ARRAY_DEFINE macro, otherwise every single 
user gets the wrong behavior. Which has (exactly in this spot) caused 
apps to not even start in the past. (There was a discussion in the past 
about the fact that qsort does not have documented defined behavior for 
maintaining order of equal event, however, there is some black magic we 
could apply to get that, with rather low memory/perf impact)


Greetings,
   bu5hm4n



On 11/4/20 7:56 PM, Wander Lairson Costa wrote:

raster pushed a commit to branch master.

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

commit fc949660f70f99fe97e63de65b1b67377d16c6da
Author: Wander Lairson Costa 
Date:   Wed Nov 4 18:25:37 2020 +

 eo_test_general.c: Make eo_signals tests pass on Windows
 
 Summary:

 EFL_CALLBACKS_ARRAY_DEFINE reorders the callbacks according to
 efl_callbacks_cmp. efl_callbacks_cmp compares the address of the desc
 field, which depends on the memory layout generated by the linker.
 
 To make the test run deterministically, we define the array of callbacks

 manually.
 
 Reviewers: vtorri, felipealmeida, raster
 
 Reviewed By: raster
 
 Subscribers: cedric, #reviewers, #committers, jptiz, felipealmeida
 
 Tags: #efl
 
 Differential Revision: https://phab.enlightenment.org/D12043

---
  src/tests/eo/suite/eo_test_general.c | 25 -
  1 file changed, 20 insertions(+), 5 deletions(-)

diff --git a/src/tests/eo/suite/eo_test_general.c 
b/src/tests/eo/suite/eo_test_general.c
index ae026a27f4..7bdb0e170b 100644
--- a/src/tests/eo/suite/eo_test_general.c
+++ b/src/tests/eo/suite/eo_test_general.c
@@ -199,11 +199,26 @@ _eo_signals_cb_added_deled(void *data EINA_UNUSED, const 
Efl_Event *event)
   fail_if(callback_array->func != _eo_signals_cb_added_deled);
  }
  
-EFL_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 },
-{ EFL_EVENT_DEL, _eo_signals_efl_del_cb });
+// We don't use the EFL_CALLBACKS_ARRAY_DEFINE macro because
+// we need the callbacks be called in a specific order
+static Efl_Callback_Array_Item *
+_eo_signals_callbacks(void)
+{
+static Efl_Callback_Array_Item items[] =
+  {
+  { EV_A_CHANGED, _eo_signals_a_changed_cb },
+  { EV_A_CHANGED, _eo_signals_a_changed_cb2 },
+  { EV_A_CHANGED, _eo_signals_a_changed_never },
+  { 0, _eo_signals_efl_del_cb },
+  { 0, 0 },
+  };
+
+// On Windows, because _EFL_EVENT_DEL is a symbol exported
+// from the DLL, we can't assign from a context expression
+items[3].desc = EFL_EVENT_DEL;
+
+return items;
+}
  
  EFL_START_TEST(eo_signals)

  {




___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel


Re: [E-devel] Enlightenment Foundation Libraries 1.25 Release

2020-09-24 Thread Marcel Hollerbach

Hi,

On 9/24/20 10:20 AM, Stefan Schmidt wrote:

Hello Ross.

On 24.09.20 08:06, Ross Vandegrift wrote:

On Wed, Sep 23, 2020 at 01:10:37PM +0200, Stefan Schmidt wrote:

=== Enlightenment Foundation Libraries 1.25 Release ===


Thanks Stefan!

I'm hitting a link failure in the software_x11 engine.  Looks like 
it's missing
a -lXext.  Log of error is below.  Could be something in 8e3606698e, 
but I

probably won't have time to dig in until next week.


Very strange. I had no other reports about this and we are also 
building Debian 10.3 and Ubunutu 19.10 + 20.04 on our CI builds. Which 
are building fine.


Maybe Marcel has an idea?


Yeah, i accidently changed there something when i refactored things for 
efl-one.
I just pushed abf0e9dffe35da8fa6e20055f53786b2adbec271, it should fix it 
hopefully

(at least it restores the old state).

Greetings,
bu5hm4n


regards
Stefan Schmidt


Ross

cc  -o src/modules/evas/engines/software_x11/libsoftware_x11.so 
src/modules/evas/engines/software_x11/libsoftware_x11.so.p/evas_engine.c.o 
src/modules/evas/engines/software_x11/libsoftware_x11.so.p/evas_x_egl.c.o 
src/modules/evas/engines/software_x11/libsoftware_x11.so.p/evas_xlib_swapbuf.c.o 
src/modules/evas/engines/software_x11/libsoftware_x11.so.p/evas_xlib_outbuf.c.o 
src/modules/evas/engines/software_x11/libsoftware_x11.so.p/evas_xlib_buffer.c.o 
src/modules/evas/engines/software_x11/libsoftware_x11.so.p/evas_xlib_color.c.o 
src/modules/evas/engines/software_x11/libsoftware_x11.so.p/evas_xlib_main.c.o 
src/modules/evas/engines/software_x11/libsoftware_x11.so.p/evas_xlib_swapper.c.o 
src/modules/evas/engines/software_x11/libsoftware_x11.so.p/evas_xlib_image.c.o 
src/modules/evas/engines/software_x11/libsoftware_x11.so.p/evas_xlib_dri_image.c.o 
-Wl,--as-needed -Wl,--allow-shlib-undefined -shared -fPIC 
-Wl,--start-group -Wl,-soname,libsoftware_x11.so -g -O2 
-fdebug-prefix-map=/<  DIR>>=. -fstack-protector-strong -Wformat -Werror=format-security 
-fvisibility=hidden -O3 -Wl,-z,relro -Wl,-z,now -Wl,-z,defs 
-Wl,--as-needed src/lib/eina/libeina.so.1.25.0 
src/lib/evas/libevas.so.1.25.0 src/lib/ecore/libecore.so.1.25.0 
src/lib/eo/libeo.so.1.25.0 src/lib/efl/libefl.so.1.25.0 
src/lib/ector/libector.so.1.25.0 src/lib/emile/libemile.so.1.25.0 
src/static_libs/libunibreak/liblibunibreak.a 
src/wayland_protocol/libwayland_protocol.a 
src/lib/eet/libeet.so.1.25.0 src/lib/ecore_x/libecore_x.so.1.25.0 
src/lib/ecore_input/libecore_input.so.1.25.0 -pthread -lm -ldl 
/usr/lib/x86_64-linux-gnu/libluajit-5.1.so 
/usr/lib/x86_64-linux-gnu/libfreetype.so 
/usr/lib/x86_64-linux-gnu/libfontconfig.so 
/usr/lib/x86_64-linux-gnu/libfribidi.so 
/usr/lib/x86_64-linux-gnu/libharfbuzz.so 
/usr/lib/x86_64-linux-gnu/libwayland-client.so 
/usr/lib/x86_64-linux-gnu/libX11.so 
/usr/lib/x86_64-linux-gnu/libGLESv2.so 
/usr/lib/x86_64-linux-gnu/libEGL.so -Wl,--end-group 
'-Wl,-rpath,$ORIGIN/../../../../lib/ein
a:$ORIGIN/../../../../lib/evas:$ORIGIN/../../../../lib/eo:$ORIGIN/../../../../lib/ector:$ORIGIN/../../../../lib/efl:$ORIGIN/../../../../lib/emile:$ORIGIN/../../../../lib/eet:$ORIGIN/../../../../lib/ecore:$ORIGIN/../../../../lib/ecore_x:$ORIGIN/../../../../lib/ecore_input:$ORIGIN/../../../../lib/eeze:$ORIGIN/../../../../lib/ecore_file:$ORIGIN/../../../../lib/ecore_con:$ORIGIN/../../../../lib/eldbus' 
-Wl,-rpath-link,/<>/obj-x86_64-linux-gnu/src/lib/eina 
-Wl,-rpath-link,/<>/obj-x86_64-linux-gnu/src/lib/evas 
-Wl,-rpath-link,/<>/obj-x86_64-linux-gnu/src/lib/eo 
-Wl,-rpath-link,/<>/obj-x86_64-linux-gnu/src/lib/ector 
-Wl,-rpath-link,/<>/obj-x86_64-linux-gnu/src/lib/efl 
-Wl,-rpath-link,/<>/obj-x86_64-linux-gnu/src/lib/emile 
-Wl,-rpath-link,/<>/obj-x86_64-linux-gnu/src/lib/eet 
-Wl,-rpath-link,/<>/obj-x86_64-linux-gnu/src/lib/ecore 
-Wl,-rpath-link,/<>/obj-x86_64-linux-gnu/src/li
  b/ecore_x 
-Wl,-rpath-link,/<>/obj-x86_64-linux-gnu/src/lib/ecore_input 
-Wl,-rpath-link,/<>/obj-x86_64-linux-gnu/src/lib/eeze 
-Wl,-rpath-link,/<>/obj-x86_64-linux-gnu/src/lib/ecore_file 
-Wl,-rpath-link,/<>/obj-x86_64-linux-gnu/src/lib/ecore_con 
-Wl,-rpath-link,/<>/obj-x86_64-linux-gnu/src/lib/eldbus
/usr/bin/ld: 
src/modules/evas/engines/software_x11/libsoftware_x11.so.p/evas_xlib_buffer.c.o: 
in function `evas_software_xlib_x_output_buffer_new':
./obj-x86_64-linux-gnu/../src/modules/evas/engines/software_x11/evas_xlib_buffer.c:285: 
undefined reference to `XShmCreateImage'
/usr/bin/ld: 
./obj-x86_64-linux-gnu/../src/modules/evas/engines/software_x11/evas_xlib_buffer.c:313: 
undefined reference to `XShmAttach'
/usr/bin/ld: 
./obj-x86_64-linux-gnu/../src/modules/evas/engines/software_x11/evas_xlib_buffer.c:313: 
undefined reference to `XShmAttach'
/usr/bin/ld: 
src/modules/evas/engines/software_x11/libsoftware_x11.so.p/evas_xlib_buffer.c.o: 
in function `evas_software_xlib_x_can_do_shm':
./obj-x86_64-linux-gnu/../src/modules/evas/engines/software_x11/evas_xlib_buffer.c:235: 
undefined reference to `XShmQueryExtension'
/usr/bin/ld: 

Re: [E-devel] EFL 1.25.0 beta 1

2020-09-02 Thread Marcel Hollerbach

Hi,

On 9/1/20 9:36 PM, Romain Naour wrote:

Hello Stefan,

Le 31/08/2020 à 15:28, Stefan Schmidt a écrit :

Following our alpha release last week we are now in the beta phase, starting
with beta1. The focus is now fully on bug fixing and stabilization for the 
release.

**Fixes:**
   * ecore con - curl - fix error map to map right enum
   * eina - statgen (stat generation) - fix enable api to actually enable
   * evas - image cache - fix loading with skip head on to load changed files

**Download**
http://download.enlightenment.org/rel/libs/efl/efl-1.25.0-beta1.tar.xz
32f68cd233199318b4c3639f868101088090276deb8c92360fc28c40b987ef2d




I'm terribly sorry that i missed them before.


Can you take a look at those meson fixes made for Buildroot?

https://sourceforge.net/p/enlightenment/mailman/message/37075003/


I will fix this in a different way if its okay. As a explanation:
- 'env' will rely on the execution environment to find the correct env 
(native or not).
- using env with before "env = find_program('env', native: true) will 
hopefully tell meson which to select.


Therefore i prefer to use find_program, I fixed that in the master 
(e2a1cdfda76dd0061ef8e0ab25aee4e042304366)



https://sourceforge.net/p/enlightenment/mailman/message/37075016/
https://sourceforge.net/p/enlightenment/mailman/message/37075004/


Can you share the errors that got fixed due to these revisions?

The problem I see with them is: The second revision removes the include 
directory, that then gets added in the third one. So there is something 
fishy.
Additionally, ecore_evas_drm.c only uses dlopen for calling gl things, 
so linking with gl is not required here.


Thank you,
   bu5hm4n





Thanks!

Best regards,
Romain






___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel




___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel




___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel


Re: [E-devel] Time for efl-one

2020-05-28 Thread Marcel Hollerbach

Hi,

On 5/28/20 1:32 PM, Tom Hacohen wrote:

On 27/05/2020 12:34, Marcel Hollerbach wrote:

Hi,

after quite a big amount of work we have successfully landed this
morning a update to our build system which enables to build efl as a
single big .so instead of multiple seperated .so's. The layout is that
every single .so is merged into efl-one.so except:
- eolian: no normal app would benefit from it, and it would make our
build *a lot* more complex
- ecore_avahi: there is no real user for this within efl, in general i
dont think anyone is going to benefit from it
- efl_canvas_wl: This is also not beneficial to a standard efl application
- elua: This is only for bindings.
- ecore_drm / wayland : These are deprecated libs, not to confuse with
ecore_wl2 / ecore_drm2, which is included in efl-one
- exactness: Not useful for a normal efl app.

To build efl-one you need to pass: "-Defl-one=true" to meson. After this
is done, additionally to all the smaller libs, efl-one.so will be build.
The modules of ecore / evas etc. and all the binaries will link to
efl-one.so not to the smaller libraries. However, for compatibility
reasons, and complexity reasons, the small .so's are still build and
installed.


Great job!

Maybe instead of building small .so's we can just symlink them all to
the efl-one.so? Or would that cause symbol duplications if multiple ones
are used?


Yeah, something like that was planned in the future, or building small 
stubs without code that are just dragging in efl-one.so This way we do 
not have to worry about platforms with problems about symlinks etc.
The problem is that the parts that are outside efl-one.so are still 
linking to the smaller .so's and not to efl-one.so as that is a little 
bit harder to realize,
and I first want to ensure that we *really* have a working efl-one.so 
which totally works before investing more time into that.


The plan for getting everything on efl-one.so looks a little different 
to me:
- Maybe move ecore_wayland and ecore_drm to a deprecated folder, that is 
not handled as normal efl subproject anymore

- Move elua to lua bindings and or build it from there
- Find out what to do about ecore_avahi

After that our normal code and build structure is in a state where 
everything natively links to efl-one.so simply by calling subdir(...) in 
another directory. We then can also automatically generate the 
"declare_dependency" and "library" calls and shrink down the lib 
meson.build files even more, which should simplify everything overall 
quite a bit.


But thats for the future, first lets find out how this works out :)



If it works though we can just use the efl.so name and not have to call
it efl-one.so.



If you have an app that you want to test out with efl-one: There is now
a efl-one.pc file installed, which can be used to link to the correct
libraries, no other efl dependency is then required.


Why not just efl.pc? Did we ever ship efl.pc/was it ever used? I think
all of the API there was beta anyway.


efl.pc is sadly not beta anymore, shipped, and used.

I basically just really want to ensure that everyone understands that 
this is not yet another subproject within efl, but the overall library 
including a lot but not everything. And in the end, its just a name ... :)






 From some early profiling: this saves ~1MB of memory when running a efl
app, i have so far not tested out what impact it has on runtime
performance or first frame numbers.



Super cool!

--
Tom




___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel


Re: [E-devel] Time for efl-one

2020-05-28 Thread Marcel Hollerbach



On 5/27/20 6:30 PM, Marcel Hollerbach wrote:

Hi,

On 5/27/20 6:23 PM, Ross Vandegrift wrote:

On Wed, May 27, 2020 at 11:34:57AM +0200, Marcel Hollerbach wrote:
after quite a big amount of work we have successfully landed this 
morning a
update to our build system which enables to build efl as a single big 
.so
instead of multiple seperated .so's. The layout is that every single 
.so is

merged into efl-one.so except:
- eolian: no normal app would benefit from it, and it would make our 
build

*a lot* more complex
- ecore_avahi: there is no real user for this within efl, in general 
i dont

think anyone is going to benefit from it
- efl_canvas_wl: This is also not beneficial to a standard efl 
application


Isn't this required by E with Wayland support?  If so, it might be worth
including - assuming there aren't other downsides.


Yeah, good point actaully, that totally slipped my mind for now. I will 
see how much that adds to libefl-one.so and see what we can/need to do. 
Thanks!


Included now, thank you for pointing it out :)






- elua: This is only for bindings.
- ecore_drm / wayland : These are deprecated libs, not to confuse with
ecore_wl2 / ecore_drm2, which is included in efl-one
- exactness: Not useful for a normal efl app.

To build efl-one you need to pass: "-Defl-one=true" to meson. After 
this is
done, additionally to all the smaller libs, efl-one.so will be build. 
The
modules of ecore / evas etc. and all the binaries will link to 
efl-one.so

not to the smaller libraries. However, for compatibility reasons, and
complexity reasons, the small .so's are still build and installed.


If this works out, will this be the default at some point?  And I assume
that libefl-one will be the final name to avoid confusion with the
existing libefl?


I think we cannot say for sure if this will get the default build or not 
at this point. Right now we are more in the "try it out" stage, need to 
see how much it helps / improves the things overall, and see what 
negative things might show up.
I also do not know how many projects are out there that only use the 
stack up to ecore, or only eina / eo. For them something like this might 
be a nightmare.

And yes: the name libefl-one is taken to not be confused with libefl.

Greetings,
    bu5hm4n



Ross


___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel




___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel



___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel


Re: [E-devel] Time for efl-one

2020-05-27 Thread Marcel Hollerbach

Is that a meson or a ninja error ?
Can you post your build.ninja if the later ?

On 5/27/20 6:15 PM, Vincent Torri wrote:

Hello

meson is failing on Windows (after a pull) and without efl-one :

ERROR: Multiple producers for Ninja target
"C:_Documents_msys2_home_vincent.torri_gitroot_64_efl2_src_modules_evas_image_loaders_eet_evas_image_load_eet.c.obj".
Please rename your targets.

Vincent

On Wed, May 27, 2020 at 4:26 PM Quelrond  wrote:


Hi,

Trying to build on FreeBSD with the new option:


[1959/4907] Compiling C object 
'src/bin/elementary/aea5856@@elementary_test@sha/test_efl_gfx_vg_value_provider.c.o'
FAILED: 
src/bin/elementary/aea5856@@elementary_test@sha/test_efl_gfx_vg_value_provider.c.o
cc -Isrc/bin/elementary/aea5856@@elementary_test@sha -Isrc/bin/elementary -I../src/bin/elementary -I. -I.. 
-Isrc/lib/evil -I../src/lib/evil -Isrc/lib/eina -I../src/lib/eina -Isrc/lib/eo -I../src/lib/eo -Isrc/lib/efl 
-I../src/lib/efl -Isrc/lib/emile -I../src/lib/emile -Isrc/lib/eet -I../src/lib/eet -Isrc/lib/ecore -I../src/lib/ecore 
-Isrc/lib/eldbus -I../src/lib/eldbus -Isrc/lib/ecore_audio -I../src/lib/ecore_audio -Isrc/lib/ecore_con 
-I../src/lib/ecore_con -Isrc/lib/ecore_file -I../src/lib/ecore_file -Isrc/lib/ecore_input -I../src/lib/ecore_input 
-Isrc/lib/ecore_x -I../src/lib/ecore_x -Isrc/lib/ecore_win32 -I../src/lib/ecore_win32 -Isrc/lib/ecore_ipc 
-I../src/lib/ecore_ipc -Isrc/lib/ector -I../src/lib/ector -Isrc/lib/evas/software_generic 
-I../src/lib/evas/software_generic -I../src/modules/evas/engines/software_generic/filters -Isrc/lib/evas 
-I../src/lib/evas -Isrc/lib/evas/common -I../src/lib/evas/common -Isrc/lib/evas/include -I../src/lib/evas/include 
-Isrc/lib/evas/filters -I../src/lib/evas/filters -Isrc/lib/evas/canvas -I../src/lib/evas/canvas -Isrc/lib/efreet 
-I../src/lib/efreet -Isrc/lib/ecore_input_evas -I../src/lib/ecore_input_evas -Isrc/modules/evas/engines/buffer 
-I../src/modules/evas/engines/buffer -Isrc/lib/ecore_evas -I../src/lib/ecore_evas -Isrc/lib/ecore_imf 
-I../src/lib/ecore_imf -Isrc/lib/embryo -I../src/lib/embryo -Isrc/lib/eio -I../src/lib/eio -Isrc/lib/ecore_imf_evas 
-I../src/lib/ecore_imf_evas -Isrc/lib/edje -I../src/lib/edje -Isrc/lib/emotion -I../src/lib/emotion -Isrc/lib/ethumb 
-I../src/lib/ethumb -Isrc/lib/ethumb_client -I../src/lib/ethumb_client -Isrc/lib/elementary -I../src/lib/elementary 
-Isrc/static_libs/vg_common -I../src/static_libs/vg_common -Isrc/static_libs/buildsystem 
-I../src/static_libs/buildsystem -Isrc/lib -I../src/lib -Isrc/lib/efl/interfaces -Isrc/lib/ector/gl 
-Isrc/lib/ector/software -Isrc/lib/evas/gesture -I/usr/local/include -Xclang -fcolor-diagnostics -pipe 
-D_FILE_OFFSET_BITS=64 -fvisibility=hidden -Wall -Wpointer-arith -Wunused-parameter -Wsign-compare 
-Wno-missing-field-initializers -DHAVE_CONFIG_H=1 -D_GNU_SOURCE=1 -DEFL_BETA_API_SUPPORT=1 
-DELM_INTERNAL_API_ARGESFSDFEFC=1 -fPIC -pthread '-DPACKAGE_DATA_DIR="/usr/local/share/elementary"' 
-DNEED_RUN_IN_TREE=1 -fPIC '-Delementary_test_BIN_DIR="/usr/local/bin"' 
'-Delementary_test_LIB_DIR="/usr/local/lib"' 
'-Delementary_test_DATA_DIR="/usr/local/share/elementary"' -MD -MQ 
'src/bin/elementary/aea5856@@elementary_test@sha/test_efl_gfx_vg_value_provider.c.o' -MF 
'src/bin/elementary/aea5856@@elementary_test@sha/test_efl_gfx_vg_value_provider.c.o.d' -o 
'src/bin/elementary/aea5856@@elementary_test@sha/test_efl_gfx_vg_value_provider.c.o' -c 
../src/bin/elementary/test_efl_gfx_vg_value_provider.c
In file included from ../src/bin/elementary/test_efl_gfx_vg_value_provider.c:6:
../src/lib/elementary/elm_priv.h:161:11: fatal error: 'efl_ui_size_model.eo.h' 
file not found
# include "efl_ui_size_model.eo.h"
^~~~~~~~
1 error generated.



On 27/05/2020 11:34, Marcel Hollerbach wrote:

Hi,

after quite a big amount of work we have successfully landed this
morning a update to our build system which enables to build efl as a
single big .so instead of multiple seperated .so's. The layout is that
every single .so is merged into efl-one.so except:
- eolian: no normal app would benefit from it, and it would make our
build *a lot* more complex
- ecore_avahi: there is no real user for this within efl, in general i
dont think anyone is going to benefit from it
- efl_canvas_wl: This is also not beneficial to a standard efl
application
- elua: This is only for bindings.
- ecore_drm / wayland : These are deprecated libs, not to confuse with
ecore_wl2 / ecore_drm2, which is included in efl-one
- exactness: Not useful for a normal efl app.

To build efl-one you need to pass: "-Defl-one=true" to meson. After
this is done, additionally to all the smaller libs, efl-one.so will be
build. The modules of ecore / evas etc. and all the binaries will link
to efl-one.so not to the smaller libraries. However, for compatibility
reasons, and complexity reasons, the small .so's are still build and
installed.

If you have an app 

Re: [E-devel] Time for efl-one

2020-05-27 Thread Marcel Hollerbach

Hi,

On 5/27/20 6:23 PM, Ross Vandegrift wrote:

On Wed, May 27, 2020 at 11:34:57AM +0200, Marcel Hollerbach wrote:

after quite a big amount of work we have successfully landed this morning a
update to our build system which enables to build efl as a single big .so
instead of multiple seperated .so's. The layout is that every single .so is
merged into efl-one.so except:
- eolian: no normal app would benefit from it, and it would make our build
*a lot* more complex
- ecore_avahi: there is no real user for this within efl, in general i dont
think anyone is going to benefit from it
- efl_canvas_wl: This is also not beneficial to a standard efl application


Isn't this required by E with Wayland support?  If so, it might be worth
including - assuming there aren't other downsides.


Yeah, good point actaully, that totally slipped my mind for now. I will 
see how much that adds to libefl-one.so and see what we can/need to do. 
Thanks!





- elua: This is only for bindings.
- ecore_drm / wayland : These are deprecated libs, not to confuse with
ecore_wl2 / ecore_drm2, which is included in efl-one
- exactness: Not useful for a normal efl app.

To build efl-one you need to pass: "-Defl-one=true" to meson. After this is
done, additionally to all the smaller libs, efl-one.so will be build. The
modules of ecore / evas etc. and all the binaries will link to efl-one.so
not to the smaller libraries. However, for compatibility reasons, and
complexity reasons, the small .so's are still build and installed.


If this works out, will this be the default at some point?  And I assume
that libefl-one will be the final name to avoid confusion with the
existing libefl?


I think we cannot say for sure if this will get the default build or not 
at this point. Right now we are more in the "try it out" stage, need to 
see how much it helps / improves the things overall, and see what 
negative things might show up.
I also do not know how many projects are out there that only use the 
stack up to ecore, or only eina / eo. For them something like this might 
be a nightmare.

And yes: the name libefl-one is taken to not be confused with libefl.

Greetings,
   bu5hm4n



Ross


___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel




___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel


Re: [E-devel] Time for efl-one

2020-05-27 Thread Marcel Hollerbach

Hi,

yep, that is a missed dependency, I think i know what went wrong. Will 
merge a fix tomorrow. :)


Thank you a lot for the report,
   bu5hm4n

On 5/27/20 4:25 PM, Quelrond wrote:

Hi,

Trying to build on FreeBSD with the new option:


[1959/4907] Compiling C object 
'src/bin/elementary/aea5856@@elementary_test@sha/test_efl_gfx_vg_value_provider.c.o'
FAILED:src/bin/elementary/aea5856@@elementary_test@sha/test_efl_gfx_vg_value_provider.c.o  
cc -Isrc/bin/elementary/aea5856@@elementary_test@sha -Isrc/bin/elementary -I../src/bin/elementary -I. -I.. -Isrc/lib/evil -I../src/lib/evil -Isrc/lib/eina -I../src/lib/eina -Isrc/lib/eo -I../src/lib/eo -Isrc/lib/efl -I../src/lib/efl -Isrc/lib/emile -I../src/lib/emile -Isrc/lib/eet -I../src/lib/eet -Isrc/lib/ecore -I../src/lib/ecore -Isrc/lib/eldbus -I../src/lib/eldbus -Isrc/lib/ecore_audio -I../src/lib/ecore_audio -Isrc/lib/ecore_con -I../src/lib/ecore_con -Isrc/lib/ecore_file -I../src/lib/ecore_file -Isrc/lib/ecore_input -I../src/lib/ecore_input -Isrc/lib/ecore_x -I../src/lib/ecore_x -Isrc/lib/ecore_win32 -I../src/lib/ecore_win32 -Isrc/lib/ecore_ipc -I../src/lib/ecore_ipc -Isrc/lib/ector -I../src/lib/ector -Isrc/lib/evas/software_generic -I../src/lib/evas/software_generic -I../src/modules/evas/engines/software_generic/filters -Isrc/lib/evas -I../src/lib/evas -Isrc/lib/evas/common -I../src/lib/evas/common -Isrc/lib/evas/include -I../src/lib/evas/include -Isrc/lib/evas/filters -I../src/lib/evas/filters -Isrc/lib/evas/canvas -I../src/lib/evas/canvas -Isrc/lib/efreet -I../src/lib/efreet -Isrc/lib/ecore_input_evas -I../src/lib/ecore_input_evas -Isrc/modules/evas/engines/buffer -I../src/modules/evas/engines/buffer -Isrc/lib/ecore_evas -I../src/lib/ecore_evas -Isrc/lib/ecore_imf -I../src/lib/ecore_imf -Isrc/lib/embryo -I../src/lib/embryo -Isrc/lib/eio -I../src/lib/eio -Isrc/lib/ecore_imf_evas -I../src/lib/ecore_imf_evas -Isrc/lib/edje -I../src/lib/edje -Isrc/lib/emotion -I../src/lib/emotion -Isrc/lib/ethumb -I../src/lib/ethumb -Isrc/lib/ethumb_client -I../src/lib/ethumb_client -Isrc/lib/elementary -I../src/lib/elementary -Isrc/static_libs/vg_common -I../src/static_libs/vg_common -Isrc/static_libs/buildsystem -I../src/static_libs/buildsystem -Isrc/lib -I../src/lib -Isrc/lib/efl/interfaces -Isrc/lib/ector/gl -Isrc/lib/ector/software -Isrc/lib/evas/gesture -I/usr/local/include -Xclang -fcolor-diagnostics -pipe -D_FILE_OFFSET_BITS=64 -fvisibility=hidden -Wall -Wpointer-arith -Wunused-parameter -Wsign-compare -Wno-missing-field-initializers -DHAVE_CONFIG_H=1 -D_GNU_SOURCE=1 -DEFL_BETA_API_SUPPORT=1 -DELM_INTERNAL_API_ARGESFSDFEFC=1 -fPIC -pthread '-DPACKAGE_DATA_DIR="/usr/local/share/elementary"' -DNEED_RUN_IN_TREE=1 -fPIC '-Delementary_test_BIN_DIR="/usr/local/bin"' '-Delementary_test_LIB_DIR="/usr/local/lib"' '-Delementary_test_DATA_DIR="/usr/local/share/elementary"' -MD -MQ 'src/bin/elementary/aea5856@@elementary_test@sha/test_efl_gfx_vg_value_provider.c.o' -MF'src/bin/elementary/aea5856@@elementary_test@sha/test_efl_gfx_vg_value_provider.c.o.d' -o'src/bin/elementary/aea5856@@elementary_test@sha/test_efl_gfx_vg_value_provider.c.o' -c ../src/bin/elementary/test_efl_gfx_vg_value_provider.c

In file included from ../src/bin/elementary/test_efl_gfx_vg_value_provider.c:6:
../src/lib/elementary/elm_priv.h:161:11: fatal error: 'efl_ui_size_model.eo.h' 
file not found
# include "efl_ui_size_model.eo.h"
   ^~~~
1 error generated.



On 27/05/2020 11:34, Marcel Hollerbach wrote:

Hi,

after quite a big amount of work we have successfully landed this 
morning a update to our build system which enables to build efl as a 
single big .so instead of multiple seperated .so's. The layout is that 
every single .so is merged into efl-one.so except:
- eolian: no normal app would benefit from it, and it would make our 
build *a lot* more complex
- ecore_avahi: there is no real user for this within efl, in general i 
dont think anyone is going to benefit from it
- efl_canvas_wl: This is also not beneficial to a standard efl 
application

- elua: This is only for bindings.
- ecore_drm / wayland : These are deprecated libs, not to confuse with 
ecore_wl2 / ecore_drm2, which is included in efl-one

- exactness: Not useful for a normal efl app.

To build efl-one you need to pass: "-Defl-one=true" to meson. After 
this is done, additionally to all the smaller libs, efl-one.so will be 
build. The modules of ecore / evas etc. and all the binaries will link 
to efl-one.so not to the smaller libraries. However, for compatibility 
reasons, and complexity reasons, the small .so's are still build and 
installed.


If you have an app that you want to test out with efl-one: There is 
now a efl-one.pc file installed, which can be used to link to the 
correct libraries, no other efl dependency is then required.


From some early profiling: this saves ~1MB of memory when running a 
efl app, i have so far not tested o

[E-devel] Time for efl-one

2020-05-27 Thread Marcel Hollerbach

Hi,

after quite a big amount of work we have successfully landed this 
morning a update to our build system which enables to build efl as a 
single big .so instead of multiple seperated .so's. The layout is that 
every single .so is merged into efl-one.so except:
- eolian: no normal app would benefit from it, and it would make our 
build *a lot* more complex
- ecore_avahi: there is no real user for this within efl, in general i 
dont think anyone is going to benefit from it

- efl_canvas_wl: This is also not beneficial to a standard efl application
- elua: This is only for bindings.
- ecore_drm / wayland : These are deprecated libs, not to confuse with 
ecore_wl2 / ecore_drm2, which is included in efl-one

- exactness: Not useful for a normal efl app.

To build efl-one you need to pass: "-Defl-one=true" to meson. After this 
is done, additionally to all the smaller libs, efl-one.so will be build. 
The modules of ecore / evas etc. and all the binaries will link to 
efl-one.so not to the smaller libraries. However, for compatibility 
reasons, and complexity reasons, the small .so's are still build and 
installed.


If you have an app that you want to test out with efl-one: There is now 
a efl-one.pc file installed, which can be used to link to the correct 
libraries, no other efl dependency is then required.


From some early profiling: this saves ~1MB of memory when running a efl 
app, i have so far not tested out what impact it has on runtime 
performance or first frame numbers.


greetings,
   bu5hm4n



___
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: Fix EAPI definition by defining EFL_BUILD for each built DLL

2020-05-18 Thread Marcel Hollerbach

Hi,

I did not see this revision, as i was not getting a mail for that one.

However, 2 benchmarks are build here with EFL_BUILD=1 which seems 
absolut wrong with the description here.


Additionally, package_c_args can be used as a general "this is the 
c_args" you should use during some declaration of buildstuff.


That means, all this can simply be achived by ensuring every lib is 
build with `c_args : package_c_args`. Before each call to subdir(*lib*) 
you can add -DEFL_BUILD=1 to the package_c_args in root meson.build. And 
before the call to subdir(*bin*) you could simply declare it to the 
values they have now.


Even more, there are currently only 9 users of package_c_args in the 
binary folder, so i think just reevalulating these, and making them 
package_bin_c_args is kind of easier than this here.


The reason i am kind of against this change here is that we now do not 
have a single variable that contains the c args the package needs. 
Normally we should just concat custom things per package to that 
variable, we then have a "model" like description of the library build 
arguments and stuff like efl-one is way more easier. Parts of that 
concatination are already in the efl-one patches that are in phab.


Long story short: I dont think this is the right way of doing this.

greetings,
   bu5hm4n

On 5/18/20 10:58 AM, Vincent Torri wrote:

raster pushed a commit to branch master.

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

commit 3ade45cbc82bea1772c7ad1afb7e1ba5dd67d930
Author: Vincent Torri 
Date:   Mon May 18 09:48:17 2020 +0100

 Fix EAPI definition by defining EFL_BUILD for each built DLL
 
 Summary: EAPI must be defined to dllexport when building DLL, and to dllimport when using these DLL. To achieve this, define EFL_BUILD for each library and module, and set DLL_EXPORT unconditionally. Static library are and will be not supported
 
 Test Plan: compilation
 
 Reviewers: zmike, raster, jptiz
 
 Subscribers: cedric, #reviewers, #committers
 
 Tags: #efl
 
 Differential Revision: https://phab.enlightenment.org/D11834

---
  meson.build |  3 +--
  src/benchmarks/eina/meson.build |  2 +-
  src/benchmarks/elementary/meson.build   |  1 +
  src/edje_external/elementary/meson.build|  2 +-
  src/edje_external/emotion/meson.build   |  2 +-
  src/lib/ecore/meson.build   |  4 +++-
  src/lib/ecore_audio/meson.build |  3 +++
  src/lib/ecore_con/meson.build   |  4 +++-
  src/lib/ecore_evas/meson.build  |  2 ++
  src/lib/ecore_file/meson.build  |  2 ++
  src/lib/ecore_imf/meson.build   |  3 ++-
  src/lib/ecore_imf_evas/meson.build  |  4 +++-
  src/lib/ecore_input/meson.build |  2 ++
  src/lib/ecore_input_evas/ecore_input_evas.c |  4 ++--
  src/lib/ecore_input_evas/meson.build|  2 ++
  src/lib/ecore_ipc/meson.build   |  3 +++
  src/lib/ecore_sdl/meson.build   |  4 +++-
  src/lib/ecore_win32/meson.build |  4 +++-
  src/lib/ector/meson.build   |  3 +++
  src/lib/edje/meson.build|  4 +++-
  src/lib/eet/meson.build |  3 +++
  src/lib/efl/meson.build |  3 +++
  src/lib/efreet/meson.build  |  8 +---
  src/lib/eina/meson.build|  3 +++
  src/lib/eio/meson.build |  4 +++-
  src/lib/eldbus/meson.build  |  3 +++
  src/lib/elementary/Efl_Ui.h |  7 ---
  src/lib/elementary/meson.build  |  6 ++
  src/lib/elua/Elua.h | 16 
  src/lib/elua/cache.c|  4 ++--
  src/lib/elua/io.c   |  4 ++--
  src/lib/elua/meson.build|  4 +++-
  src/lib/embryo/embryo_main.c|  2 ++
  src/lib/embryo/embryo_private.h |  2 --
  src/lib/embryo/embryo_str.c |  2 ++
  src/lib/embryo/meson.build  |  4 +++-
  src/lib/emile/meson.build   |  3 +++
  src/lib/emotion/meson.build |  6 +++---
  src/lib/eo/meson.build  |  7 ++-
  src/lib/eolian/meson.build  |  4 +++-
  src/lib/ephysics/meson.build|  4 +++-
  src/lib/ethumb/meson.build  |  4 +++-
  src/lib/ethumb_client/meson.build   |  4 +++-
  src/lib/evas/meson.build|  5 -
  

Re: [E-devel] [EGIT] [core/efl] master 01/01: canvas clip: replace hash to cached array.

2020-04-28 Thread Marcel Hollerbach

Hi!

I totally agree with switching from eina hash to eina array.

However, i find it a bit confusing that map_clip_objects in evas is 
declared but never used. Is the usage for this planned somewhere somehow ?


Greetings,
   bu5hm4n

On 4/28/20 7:55 AM, Hermet Park wrote:

hermet pushed a commit to branch master.

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

commit 88dd66f3d15b6839a7e64a672c73e9d4a352c9aa
Author: Hermet Park 
Date:   Tue Apr 28 14:35:26 2020 +0900

 canvas clip: replace hash to cached array.
 
 Each child_map_across_mark() takes 0.026ms with eina_hash

 we can reduce the performing time by replacing the hash to array to 
0.0041ms in a device.
 
 Before Average: 0.026ms

 Mostly it takes 23 times in the scrolling. thus it takes 3%(0.48ms) in one 
frame rendering (16ms)
 
 After Average: 0.0041ms

 Mostly it takes 23 times in the scrolling. thus it takes 0.6%(0.096ms) in 
one frame rendering (16ms)
 result: map calc 5x faster than original (0.384ms improved)
 
 Thanks Subhransu for report this.
 
 @optimization

---
  src/lib/evas/canvas/evas_clip.c | 27 ++-
  src/lib/evas/canvas/evas_main.c |  3 +++
  src/lib/evas/canvas/evas_render.c   |  3 +++
  src/lib/evas/include/evas_private.h |  1 +
  4 files changed, 21 insertions(+), 13 deletions(-)

diff --git a/src/lib/evas/canvas/evas_clip.c b/src/lib/evas/canvas/evas_clip.c
index 210aa5fc7d..55ecdb2179 100644
--- a/src/lib/evas/canvas/evas_clip.c
+++ b/src/lib/evas/canvas/evas_clip.c
@@ -74,30 +74,30 @@ evas_object_recalc_clippees(Evas_Object_Protected_Data *obj)
  
  #define MAP_ACROSS 1

  static void
-evas_object_child_map_across_mark(Evas_Object *eo_obj, 
Evas_Object_Protected_Data *obj, Evas_Object *map_obj, Eina_Bool force, 
Eina_Hash *visited)
+evas_object_child_map_across_mark(Evas_Object *eo_obj, 
Evas_Object_Protected_Data *obj, Evas_Object *map_obj, Eina_Bool force, 
Eina_Array* visited)
  {
  #ifdef MAP_ACROSS
 Eina_Bool clear_visited = EINA_FALSE;
-
 if (!visited)
   {
-visited = eina_hash_pointer_new(NULL);
+visited = >layer->evas->map_clip_objects;
  clear_visited = EINA_TRUE;
   }
-   if (eina_hash_find(visited, _obj) == (void *)1) goto end;
-   else eina_hash_add(visited, _obj, (void *)1);
-
+
+   if (eina_array_find(visited, (void*) eo_obj, NULL)) goto end;
+   else eina_array_push(visited, (void*) eo_obj);
+
 if ((obj->map->cur.map_parent != map_obj) || force)
   {
  EINA_COW_WRITE_BEGIN(evas_object_map_cow, obj->map, 
Evas_Object_Map_Data, map_write)
map_write->cur.map_parent = map_obj;
  EINA_COW_WRITE_END(evas_object_map_cow, obj->map, map_write);
  
-	EINA_COW_STATE_WRITE_BEGIN(obj, state_write, cur)

- {
-   state_write->cache.clip.dirty = 1;
- }
-   EINA_COW_STATE_WRITE_END(obj, state_write, cur);
+EINA_COW_STATE_WRITE_BEGIN(obj, state_write, cur)
+  {
+ state_write->cache.clip.dirty = 1;
+  }
+EINA_COW_STATE_WRITE_END(obj, state_write, cur);
  
  evas_object_clip_recalc(obj);

  if (obj->is_smart)
@@ -125,8 +125,9 @@ evas_object_child_map_across_mark(Evas_Object *eo_obj, 
Evas_Object_Protected_Dat
 }
}
   }
-end:
-   if (clear_visited) eina_hash_free(visited);
+
+end:
+   if (clear_visited) eina_array_clean(visited);
  #endif
  }
  
diff --git a/src/lib/evas/canvas/evas_main.c b/src/lib/evas/canvas/evas_main.c

index fc53f64dc8..956e13dbcf 100644
--- a/src/lib/evas/canvas/evas_main.c
+++ b/src/lib/evas/canvas/evas_main.c
@@ -363,6 +363,8 @@ _evas_canvas_efl_object_constructor(Eo *eo_obj, 
Evas_Public_Data *e)
 EVAS_ARRAY_SET(e, glyph_unref_queue);
 EVAS_ARRAY_SET(e, texts_unref_queue);
  
+   eina_array_step_set(>map_clip_objects, sizeof(e->map_clip_objects), 64);

+
 e->active_objects.version = EINA_ARRAY_VERSION;
 eina_inarray_step_set(>active_objects,
   sizeof(Eina_Inarray),
@@ -644,6 +646,7 @@ _evas_canvas_efl_object_destructor(Eo *eo_e, 
Evas_Public_Data *e)
 eina_array_flush(>image_unref_queue);
 eina_array_flush(>glyph_unref_queue);
 eina_array_flush(>texts_unref_queue);
+   eina_array_flush(>map_clip_objects);
 eina_hash_free(e->focused_objects);
  
 SLKL(e->post_render.lock);

diff --git a/src/lib/evas/canvas/evas_render.c 
b/src/lib/evas/canvas/evas_render.c
index 4a44c5e6ea..1d47ba06af 100644
--- a/src/lib/evas/canvas/evas_render.c
+++ b/src/lib/evas/canvas/evas_render.c
@@ -4127,6 +4127,7 @@ _evas_canvas_render_idle_flush(Eo *eo_e, Evas_Public_Data 
*evas)
 OBJS_ARRAY_FLUSH(>delete_objects);
 OBJS_ARRAY_FLUSH(>obscuring_objects);
 OBJS_ARRAY_FLUSH(>temporary_objects);
+   OBJS_ARRAY_FLUSH(>map_clip_objects);
 eina_array_foreach(>clip_changes, _evas_clip_changes_free, NULL);
 

Re: [E-devel] Introduction of jefl

2020-04-22 Thread Marcel Hollerbach




On 4/21/20 7:16 PM, Carsten Haitzler (The Rasterman) wrote:

On Tue, 21 Apr 2020 16:35:08 +0200 Marcel Hollerbach  said:


Hi!

On 4/21/20 12:45 PM, Carsten Haitzler (The Rasterman) wrote:

On Tue, 21 Apr 2020 11:31:11 +0200 Marcel Hollerbach  said:


Hi,

This is a long mail, containing first an announcement and then a
suggestion.

The announcement:

The last two weeks I have been working on a project called jefl, as the
name might suggest it, these are java bindings, fully generated out of
.eo files.


java? my nemesis! my adversary... the dr. evil of languages! :)


You might now ask why I was choosing Java instead of something else.
Java was chosen because it's a language where we are not having working
bindings at all. I did not want to have any competition with any
existing project, hence I choose a language that is not there yet.
Another reason why I chose java is that we also need (and have) JNI
bindings, this is nice, because bindings for clojure, groovy or scala
can be built on that as well, with very little time invest, as the more
complex part is already done in the jni part.

For anyone who doesn't know what jni is: When writing bindings c <->
java, you need to have some "glue" that is handling the calling of your
native c code out of the java vm context, and the other way around. This
"glue-layer" is called Java Native Interface (JNI).

As of right now, you can build with jefl little applications, as a
example: https://phab.enlightenment.org/F3868538. The whole thing then
looks like
https://www.enlightenment.org/ss/display.php?image=e-5e9eb1fa897593.48620171.jpg.

I have *not* written the bindings for eina to java yet, so if you use a
API call that returns a iterator, list, array, slice, etc. You will
simply get a empty object returned, where you cannot do anything with
it. This of course will not stay like that, my primary focus was just on
the generation of java API for now.

To test this whole thing:
- Configure your EFL to install eo files (meson configure
-Dinstall-eo-files=true)

- You need EFL with the branch devs/bu5hm4n/eo_file_updates
 After the 1.24 release this whole branch will be merged to EFL.

- Install "ant" on your system

- Clone, build, and install
https://git.enlightenment.org/devs/bu5hm4n/jefl.git/

- The previous steps will have created "jefl.jar" in ./build/java which
now can be included in your IDE of choice, where you can write your jefl
app.

If you just want to have a look at the .java files, I uploaded a
snapshot of the .java files to https://phab.enlightenment.org/F3868537.

I am happy over any comment on the .java files, it has been quite some
time since I wrote java, and I might be a bit outdated to "how" you do
things these days, so any comment there is welcome :)

And now the suggestion:

Jefl is meant to be built out of the EFL tree (but maybe in a single
repository), and I think we should do that for more (if not all)
bindings, which are not required in EFL itself (like lua, for bob).
Reasons for this:

- Efl uses meson which is nice for c, however, integrating different
languages with it *into* EFL is highly complex, and we have seen for C#
that this is ending up, simply proxying a native buildtool for the
language. Which however just raises the complexity of the EFL build itself

- Due to how meson is used in EFL for bindings, the set of generated
files does not follow the structure which is recommended / required for
the language the bindings are generated for. As an example: a class
named "efl.gfx.Entity" in java must be placed in the directory
efl/gfx/Entity.java this cannot be realized with the meson stuff we have
in place, as this rule for placement is not the same for every file we
have, *and* it would require scripting to get the right position, which
makes the whole build process *again* more complex.


the code generator could generate the dummy output meson expects as well as
the java standard path.


Mhm, no, that does not work. The meson files have to be ready at
configure time, which is when we *declare* the generator, but not run it.


no no - not generate the meson files. we currently codegen bindings from eo
files. 1 eo file produces possible multiple .c/h and .hh or cs etc. files. so
when generating generate multiple outputs. some are just targets with the meson
directory tree namespace as meson wants,m but the others are a dir tree that a
java world expects and then of course wrap the jave compiler with a small
script to have it take a messon namespace style input but convert that to the
java tree format and the generated files are there waiting to build.


Then we are back at hacking something into the shape that it is somehow 
working.

Which has downsides:
 - Dependencies are going to be broken again like in .cs files right now.
 - ninja / meson does not know of the generated files, hence they 
cannot be installed
We can also again start to hack around these i

Re: [E-devel] EFL 1.24 first abi checker results (beta2)

2020-04-22 Thread Marcel Hollerbach
That is indeed a good question. And i am not sure if this just slipped 
our fingers here. We even discussed exactly that 
https://phab.enlightenment.org/D10808#203133.


Should we simply revert the changes from that revision in the legacy 
file ? Implementation wise this is not making any difference at all...


Greetings,
   bu5hm4n

On 4/22/20 8:27 AM, Jean Rene Dawin wrote:

Stefan Schmidt wrote on Wed 15/04/20 15:48:

Hello.

I hoped the alpha and beta release are getting picked up by the abi-tracker
website directly. That was not the case. Not sure why this is not the case,
but I took this as a nudge to setup abi-tracker/upstream-tracker just for
efl on my machine.

I uploaded the first results now and I would hoep everybody could have a
look and see if we have problems here for 1.24

http://www.enlightenment.org/~stefan/abi-tracker/timeline/efl/


Hi,

are the warnings like

efl_canvas_text_eo.legacy.h, libevas.so.1.23.3
- evas_object_textblock_visible_range_get ( Efl_Canvas_Text* obj, 
Efl_Text_Cursor_Cursor* start, Efl_Text_Cursor_Cursor* end )
+ evas_object_textblock_visible_range_get ( Efl_Canvas_Textblock* obj, 
Efl_Text_Cursor_Handle* start, Efl_Text_Cursor_Handle* end )

really not a problem?

If my code has this:

Efl_Canvas_Text *bla;

it compiles well with 1.23.3 but 1.24 gives

unknown type name 'Efl_Canvas_Text'

Regards,
Jean Rene


___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel




___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel


Re: [E-devel] Introduction of jefl

2020-04-21 Thread Marcel Hollerbach

Hi!

On 4/21/20 12:45 PM, Carsten Haitzler (The Rasterman) wrote:

On Tue, 21 Apr 2020 11:31:11 +0200 Marcel Hollerbach  said:


Hi,

This is a long mail, containing first an announcement and then a suggestion.

The announcement:

The last two weeks I have been working on a project called jefl, as the
name might suggest it, these are java bindings, fully generated out of
.eo files.


java? my nemesis! my adversary... the dr. evil of languages! :)


You might now ask why I was choosing Java instead of something else.
Java was chosen because it's a language where we are not having working
bindings at all. I did not want to have any competition with any
existing project, hence I choose a language that is not there yet.
Another reason why I chose java is that we also need (and have) JNI
bindings, this is nice, because bindings for clojure, groovy or scala
can be built on that as well, with very little time invest, as the more
complex part is already done in the jni part.

For anyone who doesn't know what jni is: When writing bindings c <->
java, you need to have some "glue" that is handling the calling of your
native c code out of the java vm context, and the other way around. This
"glue-layer" is called Java Native Interface (JNI).

As of right now, you can build with jefl little applications, as a
example: https://phab.enlightenment.org/F3868538. The whole thing then
looks like
https://www.enlightenment.org/ss/display.php?image=e-5e9eb1fa897593.48620171.jpg.

I have *not* written the bindings for eina to java yet, so if you use a
API call that returns a iterator, list, array, slice, etc. You will
simply get a empty object returned, where you cannot do anything with
it. This of course will not stay like that, my primary focus was just on
the generation of java API for now.

To test this whole thing:
- Configure your EFL to install eo files (meson configure
-Dinstall-eo-files=true)

- You need EFL with the branch devs/bu5hm4n/eo_file_updates
After the 1.24 release this whole branch will be merged to EFL.

- Install "ant" on your system

- Clone, build, and install
https://git.enlightenment.org/devs/bu5hm4n/jefl.git/

- The previous steps will have created "jefl.jar" in ./build/java which
now can be included in your IDE of choice, where you can write your jefl
app.

If you just want to have a look at the .java files, I uploaded a
snapshot of the .java files to https://phab.enlightenment.org/F3868537.

I am happy over any comment on the .java files, it has been quite some
time since I wrote java, and I might be a bit outdated to "how" you do
things these days, so any comment there is welcome :)

And now the suggestion:

Jefl is meant to be built out of the EFL tree (but maybe in a single
repository), and I think we should do that for more (if not all)
bindings, which are not required in EFL itself (like lua, for bob).
Reasons for this:

- Efl uses meson which is nice for c, however, integrating different
languages with it *into* EFL is highly complex, and we have seen for C#
that this is ending up, simply proxying a native buildtool for the
language. Which however just raises the complexity of the EFL build itself

- Due to how meson is used in EFL for bindings, the set of generated
files does not follow the structure which is recommended / required for
the language the bindings are generated for. As an example: a class
named "efl.gfx.Entity" in java must be placed in the directory
efl/gfx/Entity.java this cannot be realized with the meson stuff we have
in place, as this rule for placement is not the same for every file we
have, *and* it would require scripting to get the right position, which
makes the whole build process *again* more complex.


the code generator could generate the dummy output meson expects as well as the
java standard path.


Mhm, no, that does not work. The meson files have to be ready at 
configure time, which is when we *declare* the generator, but not run it.



- .eo files work in a way where we can specify a class and a struct in a
single file, in java for example, a struct is complied into a class, as
well as a class. But every class which is public, do require its own
file. We cannot detect that at configure-time in meson, hence this would
also not work.

- The problem of having these repositories bitrot is different. We could
have somewhere a .eo file, which contains all possible built-in types,
all possible structures and @by_ref calls etc.. Additionally, each
generator should escape all keywords in a language. If we have that, it
should be quite hard to break bindings from EFL itself. Additionally, to
get an overview of *what* broke bindings, we can have a travis job that
is simply pulling in all bindings repositories and building them (once a
day or so).

To give you an overview to how this works in jefl: at configure time,
meson declares the generator, the generator has 3 outputs, a .c file
(the jni stuff

Re: [E-devel] Introduction of jefl

2020-04-21 Thread Marcel Hollerbach

Hi :)

On 4/21/20 1:11 PM, Quelrond wrote:

Hi,

Thanks a lot for this work, I was searching for EFL Java binding some 
time ago :)


Now I would prefer to have Nim bindings, but I'll definitely have a 
look on your repo ;)


I suppose, that the jar could be distributed together with binary 
(compiled) EFL, so an 'average' java dev does not need to build them, 
isn't it?


Yes absolutely. However, at this point you even need to have custom 
patches to efl itself. So i don't think that for this release i can 
provide a binary and the .jar themselves. But i am definitely looking 
forward to doing that in the future :)



Best regards,

Peter


On 21/04/2020 11:31, Marcel Hollerbach wrote:

Hi,

This is a long mail, containing first an announcement and then a 
suggestion.


The announcement:

The last two weeks I have been working on a project called jefl, as 
the name might suggest it, these are java bindings, fully generated 
out of .eo files.


You might now ask why I was choosing Java instead of something else. 
Java was chosen because it's a language where we are not having 
working bindings at all. I did not want to have any competition with 
any existing project, hence I choose a language that is not there 
yet. Another reason why I chose java is that we also need (and have) 
JNI bindings, this is nice, because bindings for clojure, groovy or 
scala can be built on that as well, with very little time invest, as 
the more complex part is already done in the jni part.


For anyone who doesn't know what jni is: When writing bindings c <-> 
java, you need to have some "glue" that is handling the calling of 
your native c code out of the java vm context, and the other way 
around. This "glue-layer" is called Java Native Interface (JNI).


As of right now, you can build with jefl little applications, as a 
example: https://phab.enlightenment.org/F3868538. The whole thing 
then looks like 
https://www.enlightenment.org/ss/display.php?image=e-5e9eb1fa897593.48620171.jpg. 



I have *not* written the bindings for eina to java yet, so if you use 
a API call that returns a iterator, list, array, slice, etc. You will 
simply get a empty object returned, where you cannot do anything with 
it. This of course will not stay like that, my primary focus was just 
on the generation of java API for now.


To test this whole thing:
- Configure your EFL to install eo files (meson configure 
-Dinstall-eo-files=true)


- You need EFL with the branch devs/bu5hm4n/eo_file_updates
  After the 1.24 release this whole branch will be merged to EFL.

- Install "ant" on your system

- Clone, build, and install 
https://git.enlightenment.org/devs/bu5hm4n/jefl.git/


- The previous steps will have created "jefl.jar" in ./build/java 
which now can be included in your IDE of choice, where you can write 
your jefl app.


If you just want to have a look at the .java files, I uploaded a 
snapshot of the .java files to https://phab.enlightenment.org/F3868537.


I am happy over any comment on the .java files, it has been quite 
some time since I wrote java, and I might be a bit outdated to "how" 
you do things these days, so any comment there is welcome :)


And now the suggestion:

Jefl is meant to be built out of the EFL tree (but maybe in a single 
repository), and I think we should do that for more (if not all) 
bindings, which are not required in EFL itself (like lua, for bob). 
Reasons for this:


- Efl uses meson which is nice for c, however, integrating different 
languages with it *into* EFL is highly complex, and we have seen for 
C# that this is ending up, simply proxying a native buildtool for the 
language. Which however just raises the complexity of the EFL build 
itself


- Due to how meson is used in EFL for bindings, the set of generated 
files does not follow the structure which is recommended / required 
for the language the bindings are generated for. As an example: a 
class named "efl.gfx.Entity" in java must be placed in the directory 
efl/gfx/Entity.java this cannot be realized with the meson stuff we 
have in place, as this rule for placement is not the same for every 
file we have, *and* it would require scripting to get the right 
position, which makes the whole build process *again* more complex.


- .eo files work in a way where we can specify a class and a struct 
in a single file, in java for example, a struct is complied into a 
class, as well as a class. But every class which is public, do 
require its own file. We cannot detect that at configure-time in 
meson, hence this would also not work.


- The problem of having these repositories bitrot is different. We 
could have somewhere a .eo file, which contains all possible built-in 
types, all possible structures and @by_ref calls etc.. Additionally, 
each generator should escape all keywords in a language. If we have 
that, it should be quite hard to break bindings from EFL itself. 
Addit

[E-devel] Introduction of jefl

2020-04-21 Thread Marcel Hollerbach

Hi,

This is a long mail, containing first an announcement and then a suggestion.

The announcement:

The last two weeks I have been working on a project called jefl, as the 
name might suggest it, these are java bindings, fully generated out of 
.eo files.


You might now ask why I was choosing Java instead of something else. 
Java was chosen because it's a language where we are not having working 
bindings at all. I did not want to have any competition with any 
existing project, hence I choose a language that is not there yet. 
Another reason why I chose java is that we also need (and have) JNI 
bindings, this is nice, because bindings for clojure, groovy or scala 
can be built on that as well, with very little time invest, as the more 
complex part is already done in the jni part.


For anyone who doesn't know what jni is: When writing bindings c <-> 
java, you need to have some "glue" that is handling the calling of your 
native c code out of the java vm context, and the other way around. This 
"glue-layer" is called Java Native Interface (JNI).


As of right now, you can build with jefl little applications, as a 
example: https://phab.enlightenment.org/F3868538. The whole thing then 
looks like 
https://www.enlightenment.org/ss/display.php?image=e-5e9eb1fa897593.48620171.jpg.


I have *not* written the bindings for eina to java yet, so if you use a 
API call that returns a iterator, list, array, slice, etc. You will 
simply get a empty object returned, where you cannot do anything with 
it. This of course will not stay like that, my primary focus was just on 
the generation of java API for now.


To test this whole thing:
- Configure your EFL to install eo files (meson configure 
-Dinstall-eo-files=true)


- You need EFL with the branch devs/bu5hm4n/eo_file_updates
  After the 1.24 release this whole branch will be merged to EFL.

- Install "ant" on your system

- Clone, build, and install 
https://git.enlightenment.org/devs/bu5hm4n/jefl.git/


- The previous steps will have created "jefl.jar" in ./build/java which 
now can be included in your IDE of choice, where you can write your jefl 
app.


If you just want to have a look at the .java files, I uploaded a 
snapshot of the .java files to https://phab.enlightenment.org/F3868537.


I am happy over any comment on the .java files, it has been quite some 
time since I wrote java, and I might be a bit outdated to "how" you do 
things these days, so any comment there is welcome :)


And now the suggestion:

Jefl is meant to be built out of the EFL tree (but maybe in a single 
repository), and I think we should do that for more (if not all) 
bindings, which are not required in EFL itself (like lua, for bob). 
Reasons for this:


- Efl uses meson which is nice for c, however, integrating different 
languages with it *into* EFL is highly complex, and we have seen for C# 
that this is ending up, simply proxying a native buildtool for the 
language. Which however just raises the complexity of the EFL build itself


- Due to how meson is used in EFL for bindings, the set of generated 
files does not follow the structure which is recommended / required for 
the language the bindings are generated for. As an example: a class 
named "efl.gfx.Entity" in java must be placed in the directory 
efl/gfx/Entity.java this cannot be realized with the meson stuff we have 
in place, as this rule for placement is not the same for every file we 
have, *and* it would require scripting to get the right position, which 
makes the whole build process *again* more complex.


- .eo files work in a way where we can specify a class and a struct in a 
single file, in java for example, a struct is complied into a class, as 
well as a class. But every class which is public, do require its own 
file. We cannot detect that at configure-time in meson, hence this would 
also not work.


- The problem of having these repositories bitrot is different. We could 
have somewhere a .eo file, which contains all possible built-in types, 
all possible structures and @by_ref calls etc.. Additionally, each 
generator should escape all keywords in a language. If we have that, it 
should be quite hard to break bindings from EFL itself. Additionally, to 
get an overview of *what* broke bindings, we can have a travis job that 
is simply pulling in all bindings repositories and building them (once a 
day or so).


To give you an overview to how this works in jefl: at configure time, 
meson declares the generator, the generator has 3 outputs, a .c file 
(the jni stuff), a build.xml (the build manifest for ant), and a 
dependency file. The java files themselves are not known to meson at any 
time. Additionally, a custom target is defined which simply calls "ant" 
after the java files are generated. The files to generate .java files 
for, are loaded from the eolian directory on your system. This way we 
*never* have to worry about the placement of files in meson at all, and 
all this complexity is removed.


Re: [E-devel] [EGIT] [core/efl] master 01/01: evas: Fix dereferenceing null pointer

2020-03-04 Thread Marcel Hollerbach

Hi,

I was also looking at this piece the other day, but I was not having 
time to fix this. However, something that showed up to me:


- evas_object_intercept_init is only called in the macro 
EVAS_OBJECT_INTERCEPT_CALLBACK_DEFINE which is also getting the privat 
data, maybe we can just pass the obj pointer via params here, and safe 
the additional efl_data_scope_get call?


- additionally, i think this should use efl_data_scope_safe_get, as its 
a forward facing API, which might get a object of the wrong type, which 
would crash right away right now.


Thank you,
   bu5hm4n

On 3/4/20 8:23 PM, Christopher Michael wrote:

devilhorns pushed a commit to branch master.

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

commit 7a89b7711f5dcd1c7f177634730b64cfbc9d1c06
Author: Christopher Michael 
Date:   Wed Mar 4 14:20:47 2020 -0500

 evas: Fix dereferenceing null pointer
 
 Coverity reports a forward null here. If we do not get obj from

 efl_data_scope_get then we should return. Also fixes some formatting
 
 Fixes CID1420216

---
  src/lib/evas/canvas/evas_object_intercept.c | 8 ++--
  1 file changed, 6 insertions(+), 2 deletions(-)

diff --git a/src/lib/evas/canvas/evas_object_intercept.c 
b/src/lib/evas/canvas/evas_object_intercept.c
index fd904f7708..c4a4b44f51 100644
--- a/src/lib/evas/canvas/evas_object_intercept.c
+++ b/src/lib/evas/canvas/evas_object_intercept.c
@@ -15,8 +15,12 @@ static void evas_object_intercept_deinit(Evas_Object 
*eo_obj);
  static void
  evas_object_intercept_init(Evas_Object *eo_obj)
  {
-   Evas_Object_Protected_Data *obj = efl_data_scope_get(eo_obj, 
EFL_CANVAS_OBJECT_CLASS);
-   if (!obj || !obj->interceptors)
+   Evas_Object_Protected_Data *obj;
+
+   obj = efl_data_scope_get(eo_obj, EFL_CANVAS_OBJECT_CLASS);
+   if (!obj) return;
+
+   if (!obj->interceptors)
   obj->interceptors = calloc(1, sizeof(Evas_Intercept_Func));
  }
  




___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel


[E-devel] Memory optimizing EO

2020-02-18 Thread Marcel Hollerbach

Hi,

here a little draft of what i will work on beginning on the 10th of 
march. So until there, its time for discussion.


== Introduction ==
Eo is a OOP framework implementation. Classes are basically 
implementations of a set of interfaces / parent class / mixins. Each 
Interface / parent class / mixin, consits of a set of functions.

The API a Class provides is called the absolut set of functions of a class
Each element in the absolut set of functions has to have a 
implementation. Which has to be stored somewhere, this piece of code and 
structure is called vtable. Every entry in the vtable consits of the 
implementation of a API, and the source Class. (Which is needed for 
privat data calculation, which is another topic)


Right now, each function has a ID (fid), this id is globally unique, and 
just incremented for each and every function that gets registered to EO. 
Each vtable of a class has the space to store *all* functions that have 
been registered to the current point.
Right now this happens in a way where the function ID of each function 
is split into a upper part and a lower part (based on the bit 
representation), this then results in the dich-chain1 ID (dc1) and 
dich-chain2 ID (dc2) which are used to get to the correct slot (pseudo 
code like: vtable->dichchain1[dc1]->dichchain2[dc2]). If a class needs 
to store the function X, then dich-chain1 at space dc1 gets a allocated 
dichchain2, which consists of 0's expect in the slot dc2, there we store 
the implementation and the source.


== The problem ==
The problem with this approach is that we waste quite a lot of memory, 
esp. for widgets that do not implement a lot of API which have a close 
fid, leading to the fact that we allocate a lot of dich chain2s where 
only a few slots are really used. If you go and messure how many slots 
we allocate and how many we use we are having a mean value of round 
about 0.36, which is quite bad IMO. In total, we have 35296 slots 
allocated, and we use 16807. (This is already honoring the eo 
optimizations we have, the referenced slots are NOT added to this)


== The Idea number 1 ==
What we can do to improve this is: we change the heuristic how we 
allocate fids. We could increment for each class/interface/mixin one dc1 
counter, and for each function in this class/interface/mixin we 
increment a class/interface/mixin privat counter, which will be the dc2. 
We then combine them together to the fid via something like 
dc1*1+dc2. When a eo call then happens, we simply decompose the fid 
like we do it now, and call the two dich chains, like we do it now.
What this changes in the memory layout is that we fully use each and 
every dichchain2 that we allocate.


The downside of that method is that we get a longer dichchain1 array, 
right now with elementary_test we are having 32 pointer long dichchain1 
at max, meaning we are allocating in total 2KB over all classes we have.


With this new idea the dichchain1 will be 190 elements long meaning 70KB 
over all classes we have.
However, due to the savings in the dichchain2's we are saving round 
about 144KB of allocated data, (1 slot is 8byte). Which means we are 
still having a safe of round about 74KB.


This is something which I would implement, additional min / max 
checkings or COW on the dichchain1 are probably even saving more.


== The Idea number 2 ==
After Idea 1 is implemented, we could work on this.
Right now we are allocating one dc1 slot *per* class we have. Right now 
we have 26 mixins 90 regulars 13 abstracts and 61 Interfaces (Summing up 
to 190). Which results in the length of the dc1. To improve the 
situation we could go and say that each dc1 ID of a regular class is the 
max of all functions including those of the parent class + 1. That 
means, that fid's are not globally unique anymore, but they are still 
unique within the type they are defined.
The more interesting thing is, that all regular APIs are now in the same 
dc1 slot, which means, it is enough to allocate the size of the dc1 as 
the size of the sum of iterfaces and mixins, ending up with something 
lower than 15KB per class. Bringing us to saving 130KB of allocated data 
(compared to the state that we have right now).


Another "downside" of that approach is also that we loose the ability of 
multiclass inheritance, however, we only have one widget that uses that 
ability, and this does not work anyways, so we could just deprecate it i 
think.


Funcy side effect of this idea: if we resolve a regular API call to a 
object, the dc1[0] slot will always be the same. That means, we could 
store that pointer in parallel to the vtable pointer, saving us one 
indirection PER call resolve. (Right now we have 2).


Any ideas, thoughts about this ? I will start the work on that on the 
10.03.2020 :)


Greetings,
   bu5hm4n

PS: you can find a plot about our usage ratio in EO in the attached plot.
___
enlightenment-devel mailing list

Re: [E-devel] DND / CNP rewrite

2020-01-27 Thread Marcel Hollerbach
I found something wrong, branches are updated, maybe this fixes your 
issue as well?


On 1/26/20 10:47 PM, Carsten Haitzler (The Rasterman) wrote:

On Sun, 26 Jan 2020 13:36:04 +0100 Marcel Hollerbach  said:

just a very very very initial set of feedback.

1. warning fix:
diff --git a/src/lib/eina/eina_abstract_content.c
b/src/lib/eina/eina_abstract_content.c index fa89ee60bd..652cab4b14 100644
--- a/src/lib/eina/eina_abstract_content.c
+++ b/src/lib/eina/eina_abstract_content.c
@@ -184,7 +184,7 @@ eina_content_type_get(Eina_Content *content)
 return content->type;
  }

-EAPI const Eina_Slice
+EAPI Eina_Slice
  eina_content_data_get(Eina_Content *content)
  {
 return eina_rw_slice_slice_get(content->data);
diff --git a/src/lib/eina/eina_abstract_content.h
b/src/lib/eina/eina_abstract_content.h index b9e4723973..4eff00fbbd 100644
--- a/src/lib/eina/eina_abstract_content.h
+++ b/src/lib/eina/eina_abstract_content.h
@@ -63,7 +63,7 @@ EAPI const char* eina_content_type_get(Eina_Content *content);
   *
   * @return The path to the file. Do not free this.
   */
-EAPI const Eina_Slice eina_content_data_get(Eina_Content *content);
+EAPI Eina_Slice eina_content_data_get(Eina_Content *content);

  /**
   * Create a new content object, with the slice of data with a specific type.

2. how much is meant to work?:
How much is meant to work so far? I found copy & pasting from efl now to
something else leads to some garbage at the end of the string. 1 char it looks
like. i see the junk when pasting into terminology (which is using the current
git master implementation) and gtk2 (my mail client - sylpheed). Trying to copy
& paste from anything into the new cnp implementation results in a pair of
ERR's:
ERR<40939>:elementary ../src/lib/elementary/elm_cnp.c:36
_elm_sel_format_to_mime_type() Specified mime type is not available
ERR<40939>:elementary ../src/lib/elementary/elm_cnp.c:180
_callback_storage_error() Content cound not be received because of (null).

and .. nothing is pasted. is this expected at this stage or "that should work"?
that's as far as i've gotten so far in exploring what works so far or not...


Hi,

as i have said on EDD, i wanted to work on cnp & dnd. My current state
of work can be found in
https://git.enlightenment.org/core/efl.git/log/?h=devs/bu5hm4n/work_cnp.

The overall idea of this whole thing is to get the API into different
levels:
- Eina now has a struct (Eina_Content) that handles a data blob and a
type. This data blob can be converted to different types. This also
allows API users to add more types, and possible convertions

- Ecore_Evas now has a module API for handling cnp and dnd operations,
for more details, the documentation should help, i dont think it makes
much sense to write here every single detail. Just one thing that was
the mantra during the design of this: Every data blog is always Passed
as Eina_Content, so the type can never be split from the data, by
design. This way we should get rid of all the *ups, this was not \0
terminated* errors we had in the past. Sanity checks and smaller fixes
on content can also be implemented in the eina side.

- Ecore_X is the first (and for now only) protocol that has support in
this new thing. No multiseat support is added to this, or was meant to
be ever used. The difference here to the legacy code is not big in terms
of how we do the protocol. However, a lot of things have now been tested
for the first time, and a few bugs have been found. That means, we now
*really* get notified if someone else in the display server takes over
selection, which sadly broke a lot of the new Textbox tests, which have
been all fixed. I have tested this with chromium firefox, thunderbird
and cross efl. However, i did not test yet enlightenment or anything
around that. I would be really happy if a few people could give it a test!

- Last but not least: The elm API. The legacy API was implemented with
as much original code from 1.18 as possible, the reason i went back to
this state, was that there was a "kind of" abstraction between drop
containers drag containers and protocol operations, that was somehow
lost during the move to selection_manager. Now, this old code is back,
and just calls the new efl.ui.drag / selection API in the places where
it is needed. The Efl.Ui.Drag and Efl.Ui.Selection API has been
reworked. Listening to events implicitly turns on the listening to the
ecore evas events, this means, you do not need to explicitly register
things as "drop targets" anymore. Additionally, the API is now
structured that there is a difference between drop, drag & selection.
A DROP is a DND operation that has entered your window.
A DRAG is a DND operation that was started by your window. This way we
can ensure that it is clear when a drag or when a drop is finished.
Before there was a major confusion in the API when it comes to this.
The selection is now also defined in a way that you o

[E-devel] DND / CNP rewrite

2020-01-26 Thread Marcel Hollerbach

Hi,

as i have said on EDD, i wanted to work on cnp & dnd. My current state 
of work can be found in 
https://git.enlightenment.org/core/efl.git/log/?h=devs/bu5hm4n/work_cnp.


The overall idea of this whole thing is to get the API into different 
levels:
- Eina now has a struct (Eina_Content) that handles a data blob and a 
type. This data blob can be converted to different types. This also 
allows API users to add more types, and possible convertions


- Ecore_Evas now has a module API for handling cnp and dnd operations, 
for more details, the documentation should help, i dont think it makes 
much sense to write here every single detail. Just one thing that was 
the mantra during the design of this: Every data blog is always Passed 
as Eina_Content, so the type can never be split from the data, by 
design. This way we should get rid of all the *ups, this was not \0 
terminated* errors we had in the past. Sanity checks and smaller fixes 
on content can also be implemented in the eina side.


- Ecore_X is the first (and for now only) protocol that has support in 
this new thing. No multiseat support is added to this, or was meant to 
be ever used. The difference here to the legacy code is not big in terms 
of how we do the protocol. However, a lot of things have now been tested 
for the first time, and a few bugs have been found. That means, we now 
*really* get notified if someone else in the display server takes over 
selection, which sadly broke a lot of the new Textbox tests, which have 
been all fixed. I have tested this with chromium firefox, thunderbird 
and cross efl. However, i did not test yet enlightenment or anything 
around that. I would be really happy if a few people could give it a test!


- Last but not least: The elm API. The legacy API was implemented with 
as much original code from 1.18 as possible, the reason i went back to 
this state, was that there was a "kind of" abstraction between drop 
containers drag containers and protocol operations, that was somehow 
lost during the move to selection_manager. Now, this old code is back, 
and just calls the new efl.ui.drag / selection API in the places where 
it is needed. The Efl.Ui.Drag and Efl.Ui.Selection API has been 
reworked. Listening to events implicitly turns on the listening to the 
ecore evas events, this means, you do not need to explicitly register 
things as "drop targets" anymore. Additionally, the API is now 
structured that there is a difference between drop, drag & selection.

A DROP is a DND operation that has entered your window.
A DRAG is a DND operation that was started by your window. This way we 
can ensure that it is clear when a drag or when a drop is finished. 
Before there was a major confusion in the API when it comes to this.
The selection is now also defined in a way that you only have selection 
and the clipboard, some platforms may support the two. Others only 
support the clipboard (like wayland). However, X11 specific things like 
the secondary buffer have been dropped. Additionally, for supporting a 
wider range of usecases, the action enum have been replaced with a 
simple string.


I am not sure when i can come up with protocol implementations for 
wayland and or macos, i would be really happy if some people could help 
me with that. Additionally, i really need more help with testing, as I 
cannot imagine all the usecases we have right now out there. If you find 
any buggy behavior, feel free to write me here, of create a phab ticket, 
thank you :)


Greetings,
   bu5hm4n


___
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: Revert "ecore_wl2: Fix a memory leaking case"

2020-01-20 Thread Marcel Hollerbach

Everything that starts a wayland window.

The sequence of problems is (as described in the revision that 
introduces this):
- Module gets loaded, sets up a surface manager via 
ecore_wl2_surface_manager_add.
- Module gets unloaded, registered surface manager gets deleted via 
ecore_wl2_surface_manager_del

- Now the code continues without any loaded surface manager
- Creating a window will error out in EE
- No window can be created at all
- Every single test fails

Greetings,
   bu5hm4n

On 1/20/20 6:16 PM, Christopher Michael wrote:

On 1/20/20 11:53 AM, Marcel Hollerbach wrote:

bu5hm4n pushed a commit to branch master.

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

commit 55ec2dc89e9b38ad52c5e8b3d8ac42c8e906bba6
Author: Marcel Hollerbach
Date:   Mon Jan 20 17:51:40 2020 +0100

 Revert "ecore_wl2: Fix a memory leaking case"
 
 This reverts commit 97e71b9dc4fa73da99a890d9c39d6617e529dc94.
 
 This commit is absolutly wrong. This makes running wayland apps intree

 impossible, and also crashes tests when run in wayland mode.


Which tests were crashing with this ?? Were they Ecore_Wl2 tests ?


dh


 
 I asked multiple times in the revision for clarification, noone

 answered.
 This tricked me today for the second time, so better revert that.
---
  src/lib/ecore_wl2/ecore_wl2.c | 2 --
  1 file changed, 2 deletions(-)

diff --git a/src/lib/ecore_wl2/ecore_wl2.c b/src/lib/ecore_wl2/ecore_wl2.c
index d14b14aee5..33e06873cd 100644
--- a/src/lib/ecore_wl2/ecore_wl2.c
+++ b/src/lib/ecore_wl2/ecore_wl2.c
@@ -90,8 +90,6 @@ _ecore_wl2_surface_modules_init(void)
local_module = NULL;
return EINA_FALSE;
 }
- eina_module_free(local_module);
- local_module = NULL;
   return EINA_TRUE;
}
   }






___
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: build - experiment - turn off glib integration by default

2019-12-06 Thread Marcel Hollerbach

Hi :)

Some feedback on this experiment:
- ibus calls ecore_main_loop_glib_integrate which is now just erroring 
out, if ibus really needs glib integration (i think so) then we should 
either also disable ibus per default.

- Some people do have crashes in ibus after the disabling.

As a sidenote: we do not see this on CI, as ibus is not enabled there.

What should we do ?

On 11/27/19 5:55 PM, Carsten Haitzler wrote:

raster pushed a commit to branch master.

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

commit 59bcc3c658f1a9f11593d475d1601ed209763a08
Author: Carsten Haitzler (Rasterman) 
Date:   Sun Nov 24 11:32:34 2019 +

 build - experiment - turn off glib integration by default
 
 i wany to see if this breaks anything for regular efl use on regular

 platforms... one way to figure it out is disable it by default and
 see...xs
---
  meson_options.txt | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/meson_options.txt b/meson_options.txt
index 41f5059f8d..784bdf9a27 100644
--- a/meson_options.txt
+++ b/meson_options.txt
@@ -109,7 +109,7 @@ option('crypto',
  
  option('glib',

type : 'boolean',
-  value : true,
+  value : false,
description : 'Main loop integration for glib in efl'
  )
  




___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel


[EGIT] [core/efl] master 02/02: here comes a new example

2019-11-28 Thread Marcel Hollerbach
bu5hm4n pushed a commit to branch master.

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

commit 74b4b354f534c5d44514f4c5969259920be43719
Author: Marcel Hollerbach 
Date:   Wed Sep 18 21:47:08 2019 +0200

here comes a new example

Reviewed-by: Cedric BAIL 
Differential Revision: https://phab.enlightenment.org/D10733
---
 .../elementary/efl_ui_grid_view_example_1.c| 477 +
 src/examples/elementary/meson.build|   3 +-
 2 files changed, 479 insertions(+), 1 deletion(-)

diff --git a/src/examples/elementary/efl_ui_grid_view_example_1.c 
b/src/examples/elementary/efl_ui_grid_view_example_1.c
new file mode 100644
index 00..8ccf560f09
--- /dev/null
+++ b/src/examples/elementary/efl_ui_grid_view_example_1.c
@@ -0,0 +1,477 @@
+// gcc -o efl_ui_grid_view_example_1 efl_ui_grid_view_example_1.c `pkg-config 
--cflags --libs elementary`
+
+#define EFL_BETA_API_SUPPORT 1
+
+#include 
+#include 
+#include 
+#include "efl_ui_grid_view.eo.h"
+
+
+static Efl_Model*
+_make_model(Evas_Object *win)
+{
+   Eina_Value vtext;
+   Efl_Generic_Model *model, *child;
+
+   model = efl_add(EFL_GENERIC_MODEL_CLASS, win);
+   eina_value_setup(, EINA_VALUE_TYPE_STRING);
+
+#define IC(x) \
+child = efl_model_child_add(model); \
+eina_value_set(, x); \
+efl_model_property_set(child, "title", );
+
+   IC("user-home")
+   IC("user-bookmarks")
+   IC("user-desktop")
+   IC("user-trash")
+   IC("folder")
+   IC("folder-drag-accept")
+   IC("folder-remote")
+   IC("folder-open")
+   IC("folder-home")
+   IC("folder-download")
+   IC("folder-recent")
+   IC("folder-documents")
+   IC("folder-pictures")
+   IC("folder-music")
+   IC("folder-videos")
+   IC("folder-visiting")
+   IC("network-server")
+   IC("network-workgroup")
+   IC("start-here")
+   IC("emblem-default")
+   IC("emblem-documents")
+   IC("emblem-downloads")
+   IC("emblem-favorite")
+   IC("emblem-important")
+   IC("emblem-mail")
+   IC("emblem-photos")
+   IC("emblem-readonly")
+   IC("emblem-shared")
+   IC("emblem-symbolic-link")
+   IC("emblem-unreadable")
+   IC("emblem-system")
+   IC("emblem-synchronized")
+   IC("emblem-synchronizing")
+   IC("address-book-new")
+   IC("application-exit")
+   IC("appointment-new")
+   IC("call-start")
+   IC("call-stop")
+   IC("contact-new")
+   IC("document-open")
+   IC("document-open-recent")
+   IC("document-page-setup")
+   IC("document-properties")
+   IC("document-save")
+   IC("document-save-as")
+   IC("document-send")
+   IC("document-close")
+   IC("document-new")
+   IC("document-print")
+   IC("document-print-preview")
+   IC("document-revert")
+   IC("document-export")
+   IC("document-import")
+   IC("edit-clear")
+   IC("edit-copy")
+   IC("edit-cut")
+   IC("edit-delete")
+   IC("edit-find")
+   IC("edit-find-replace")
+   IC("edit-paste")
+   IC("edit-redo")
+   IC("edit-undo")
+   IC("edit-select-all")
+   IC("folder-copy")
+   IC("folder-move")
+   IC("folder-new")
+   IC("format-indent-less")
+   IC("format-indent-more")
+   IC("format-justify-center")
+   IC("format-justify-fill")
+   IC("format-justify-left")
+   IC("format-justify-right")
+   IC("format-text-direction-ltr")
+   IC("format-text-direction-rtl")
+   IC("format-text-bold")
+   IC("format-text-italic")
+   IC("format-text-underline")
+   IC("format-text-strikethrough")
+   IC("go-home")
+   IC("go-bottom")
+   IC("go-down")
+   IC("go-first")
+   IC("go-jump")
+   IC("go-last")
+   IC("go-next")
+   IC("go-previous")
+   IC("go-top")
+   IC("go-up")
+   IC("insert-image")
+   IC("insert-link")
+   IC("insert-object")
+   IC("insert-text")
+   IC("list-add")
+   IC("list-remove")
+   IC("mail-forward")
+   IC("mail-mark-important")
+   IC("mail-mark-junk")
+   IC("mail-mark-notjunk")
+   IC("mail-mark-read")
+   IC("mail-mark-unread")
+   IC("mail-message-new")
+   IC("mail-reply-all")
+   

[EGIT] [core/efl] master 05/08: efl_ui_spotlight_manager_*: remove size and position events

2019-11-27 Thread Marcel Hollerbach
bu5hm4n pushed a commit to branch master.

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

commit 3ad70802c6485d4707e9b824314186c5a7a647bb
Author: Marcel Hollerbach 
Date:   Wed Nov 20 16:58:27 2019 +0100

efl_ui_spotlight_manager_*: remove size and position events

there is no need to listen to them, they are already listent to by the
container, and new sizes are told via the size property.

Reviewed-by: Mike Blumenkrantz 
Differential Revision: https://phab.enlightenment.org/D10704
---
 src/lib/elementary/efl_ui_spotlight_manager_plain.c  | 20 
 src/lib/elementary/efl_ui_spotlight_manager_scroll.c | 16 
 src/lib/elementary/efl_ui_spotlight_manager_stack.c  | 18 --
 3 files changed, 54 deletions(-)

diff --git a/src/lib/elementary/efl_ui_spotlight_manager_plain.c 
b/src/lib/elementary/efl_ui_spotlight_manager_plain.c
index 49ca251c6a..83aab8fcce 100644
--- a/src/lib/elementary/efl_ui_spotlight_manager_plain.c
+++ b/src/lib/elementary/efl_ui_spotlight_manager_plain.c
@@ -39,23 +39,6 @@ _geom_sync(Eo *obj EINA_UNUSED, 
Efl_Ui_Spotlight_Manager_Plain_Data *pd)
efl_gfx_entity_geometry_set(entity, goal);
 }
 
-static void
-_resize_cb(void *data, const Efl_Event *ev EINA_UNUSED)
-{
-   _geom_sync(data, efl_data_scope_get(data, MY_CLASS));
-}
-
-static void
-_move_cb(void *data, const Efl_Event *ev EINA_UNUSED)
-{
-   _geom_sync(data, efl_data_scope_get(data, MY_CLASS));
-}
-
-EFL_CALLBACKS_ARRAY_DEFINE(group_callback,
-  {EFL_GFX_ENTITY_EVENT_SIZE_CHANGED, _resize_cb},
-  {EFL_GFX_ENTITY_EVENT_POSITION_CHANGED, _move_cb},
-)
-
 EOLIAN static void
 _efl_ui_spotlight_manager_plain_efl_ui_spotlight_manager_bind(Eo *obj, 
Efl_Ui_Spotlight_Manager_Plain_Data *pd, Efl_Ui_Spotlight_Container *spotlight)
 {
@@ -64,7 +47,6 @@ 
_efl_ui_spotlight_manager_plain_efl_ui_spotlight_manager_bind(Eo *obj, Efl_Ui_Sp
 Efl_Ui_Widget *index;
 
 pd->container = spotlight;
-efl_event_callback_array_add(pd->container, group_callback(), obj);
 
 for (int i = 0; i < efl_content_count(spotlight) ; ++i) {
Efl_Gfx_Entity *elem = efl_pack_content_get(spotlight, i);
@@ -144,8 +126,6 @@ _efl_ui_spotlight_manager_plain_efl_object_destructor(Eo 
*obj, Efl_Ui_Spotlight_
 {
efl_destructor(efl_super(obj, MY_CLASS));
 
-   efl_event_callback_array_del(pd->container, group_callback(), obj);
-
for (int i = 0; i < efl_content_count(pd->container); ++i)
  {
 Efl_Gfx_Stack *elem = efl_pack_content_get(pd->container, i);
diff --git a/src/lib/elementary/efl_ui_spotlight_manager_scroll.c 
b/src/lib/elementary/efl_ui_spotlight_manager_scroll.c
index d6e1dbad21..18486763ad 100644
--- a/src/lib/elementary/efl_ui_spotlight_manager_scroll.c
+++ b/src/lib/elementary/efl_ui_spotlight_manager_scroll.c
@@ -76,18 +76,6 @@ _apply_box_properties(Eo *obj, 
Efl_Ui_Spotlight_Manager_Scroll_Data *pd)
_propagate_progress(obj, current_pos);
 }
 
-static void
-_resize_cb(void *data, const Efl_Event *ev EINA_UNUSED)
-{
-   _apply_box_properties(data, efl_data_scope_get(data, 
EFL_UI_SPOTLIGHT_MANAGER_SCROLL_CLASS));
-}
-
-static void
-_move_cb(void *data, const Efl_Event *ev EINA_UNUSED)
-{
-   _apply_box_properties(data, efl_data_scope_get(data, 
EFL_UI_SPOTLIGHT_MANAGER_SCROLL_CLASS));
-}
-
 static void
 _mouse_down_cb(void *data,
const Efl_Event *event)
@@ -174,8 +162,6 @@ 
_efl_ui_spotlight_manager_scroll_efl_ui_spotlight_manager_bind(Eo *obj, Efl_Ui_S
if (spotlight)
  {
 pd->container = spotlight;
-efl_event_callback_add(pd->container, 
EFL_GFX_ENTITY_EVENT_SIZE_CHANGED, _resize_cb, obj);
-efl_event_callback_add(pd->container, 
EFL_GFX_ENTITY_EVENT_POSITION_CHANGED, _move_cb, obj);
 
 pd->foreclip = efl_add(EFL_CANVAS_RECTANGLE_CLASS,
evas_object_evas_get(pd->container));
@@ -325,8 +311,6 @@ 
_efl_ui_spotlight_manager_scroll_efl_ui_spotlight_manager_animated_transition_ge
 EOLIAN static void
 _efl_ui_spotlight_manager_scroll_efl_object_invalidate(Eo *obj, 
Efl_Ui_Spotlight_Manager_Scroll_Data *pd EINA_UNUSED)
 {
-   efl_event_callback_del(pd->container, EFL_GFX_ENTITY_EVENT_SIZE_CHANGED, 
_resize_cb, obj);
-   efl_event_callback_del(pd->container, 
EFL_GFX_ENTITY_EVENT_POSITION_CHANGED, _move_cb, obj);
efl_event_callback_array_del(efl_content_get(efl_part(pd->container, 
"efl.event")), mouse_listeners(), obj);
efl_del(pd->backclip);
efl_del(pd->foreclip);
diff --git a/src/lib/elementary/efl_ui_spotlight_manager_stack.c 
b/src/lib/elementary/efl_ui_spotlight_manager_stack.c
index 42e80d7b0b..b7f04937c4 100644
--- a/src/lib/elementary/efl_ui_spotlight_manager_stack.c
+++ b/src/lib/elementary/efl_ui_spotlight_manager_stack.c
@@ -32,18 +32,6 @@ _geom_sync(Eo *obj EINA_UNUSED, 
Efl_Ui_Spotlight_Manager_Stack_Data *pd)

[EGIT] [core/efl] master 01/08: Revert "gesture_manager: Changed function param to reduce internal function calls."

2019-11-27 Thread Marcel Hollerbach
bu5hm4n pushed a commit to branch master.

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

commit 3838112294d91efd121eade232e071eb3325d9e1
Author: Marcel Hollerbach 
Date:   Wed Nov 27 11:45:46 2019 +0100

Revert "gesture_manager: Changed function param to reduce internal function 
calls."

This has still open review comments, lets solve them, and *then* land
it.

This reverts commit 2f41f867ae992c58690e8fcad60672daa8744708.
---
 src/lib/evas/canvas/evas_callbacks.c  | 16 +---
 src/lib/evas/canvas/evas_main.c   |  1 -
 src/lib/evas/gesture/efl_canvas_gesture_manager.c |  9 ++---
 src/lib/evas/gesture/efl_canvas_gesture_touch.c   |  9 ++---
 src/lib/evas/gesture/efl_canvas_gesture_touch.eo  |  5 -
 src/lib/evas/include/evas_private.h   |  4 ++--
 6 files changed, 27 insertions(+), 17 deletions(-)

diff --git a/src/lib/evas/canvas/evas_callbacks.c 
b/src/lib/evas/canvas/evas_callbacks.c
index d9aac154f8..d19ce686da 100644
--- a/src/lib/evas/canvas/evas_callbacks.c
+++ b/src/lib/evas/canvas/evas_callbacks.c
@@ -393,7 +393,7 @@ evas_object_event_callback_call(Evas_Object *eo_obj, 
Evas_Object_Protected_Data
 type == EVAS_CALLBACK_MULTI_DOWN ||
 type == EVAS_CALLBACK_MOUSE_UP ||
 type == EVAS_CALLBACK_MULTI_UP)
- _efl_canvas_gesture_manager_filter_event(e->gmd, eo_obj, event_info);
+ _efl_canvas_gesture_manager_filter_event(e->gesture_manager, eo_obj, 
event_info);
 
if (obj->is_smart)
  _evas_object_smart_callback_call_internal(eo_obj, efl_event_desc);
@@ -817,12 +817,17 @@ void
 evas_object_callbacks_event_catcher_add(Eo *eo_obj EINA_UNUSED, 
Evas_Object_Protected_Data *obj, const Efl_Callback_Array_Item *array)
 {
Evas_Callback_Type type = EVAS_CALLBACK_LAST;
+   void *gd = NULL;
int i;
 
for (i = 0; array[i].desc != NULL; i++)
  {
 if (obj->layer && obj->layer->evas && 
obj->layer->evas->gesture_manager)
-  _efl_canvas_gesture_manager_callback_add_hook(obj->layer->evas->gmd, 
obj->object, array[i].desc);
+  {
+ if (!gd) gd = 
_efl_canvas_gesture_manager_private_data_get(obj->layer->evas->gesture_manager);
+
+ _efl_canvas_gesture_manager_callback_add_hook(gd, obj->object, 
array[i].desc);
+  }
 
 if (array[i].desc == EFL_CANVAS_OBJECT_EVENT_ANIMATOR_TICK)
   {
@@ -850,6 +855,7 @@ evas_object_callbacks_event_catcher_add(Eo *eo_obj 
EINA_UNUSED, Evas_Object_Prot
 void
 evas_object_callbacks_event_catcher_del(Eo *eo_obj EINA_UNUSED, 
Evas_Object_Protected_Data *obj, const Efl_Callback_Array_Item *array)
 {
+   void *gd = NULL;
int i;
 
if (!obj->layer ||
@@ -859,7 +865,11 @@ evas_object_callbacks_event_catcher_del(Eo *eo_obj 
EINA_UNUSED, Evas_Object_Prot
for (i = 0; array[i].desc != NULL; i++)
  {
 if (obj->layer->evas->gesture_manager)
-  _efl_canvas_gesture_manager_callback_del_hook(obj->layer->evas->gmd, 
obj->object, array[i].desc);
+  {
+ if (!gd) gd = 
_efl_canvas_gesture_manager_private_data_get(obj->layer->evas->gesture_manager);
+
+ _efl_canvas_gesture_manager_callback_del_hook(gd, obj->object, 
array[i].desc);
+  }
 
 if (array[i].desc == EFL_CANVAS_OBJECT_EVENT_ANIMATOR_TICK)
   {
diff --git a/src/lib/evas/canvas/evas_main.c b/src/lib/evas/canvas/evas_main.c
index 86a7881473..6d4c07c95e 100644
--- a/src/lib/evas/canvas/evas_main.c
+++ b/src/lib/evas/canvas/evas_main.c
@@ -312,7 +312,6 @@ _evas_canvas_efl_object_constructor(Eo *eo_obj, 
Evas_Public_Data *e)
eina_clist_init(>calc_done);
 
efl_wref_add(efl_add(EFL_CANVAS_GESTURE_MANAGER_CLASS, eo_obj), 
>gesture_manager);
-   e->gmd = efl_data_scope_get(e->gesture_manager, 
EFL_CANVAS_GESTURE_MANAGER_CLASS);
 
 #define EVAS_ARRAY_SET(E, Array) \
eina_array_step_set(>Array, sizeof (E->Array), \
diff --git a/src/lib/evas/gesture/efl_canvas_gesture_manager.c 
b/src/lib/evas/gesture/efl_canvas_gesture_manager.c
index d5103186e1..2d821b5770 100644
--- a/src/lib/evas/gesture/efl_canvas_gesture_manager.c
+++ b/src/lib/evas/gesture/efl_canvas_gesture_manager.c
@@ -153,17 +153,19 @@ _efl_canvas_gesture_manager_callback_del_hook(void *data, 
Eo *target, const Efl_
 }
 
 void
-_efl_canvas_gesture_manager_filter_event(void *data, Eo *target, void *event)
+_efl_canvas_gesture_manager_filter_event(Eo *obj, Eo *target, void *event)
 {
-   Efl_Canvas_Gesture_Manager_Data *pd = data;
Eina_List *l, *gesture_context;
+   Efl_Canvas_Gesture_Manager_Data *pd;
const Efl_Event_Description *gesture_type;
Efl_Canvas_Gesture_Recognizer *recognizer;
Efl_Canvas_Gesture *gesture;
Efl_Canvas_Gesture_Recognizer_Result recog_result;
Efl_Canvas_Gesture_Recognizer

[EGIT] [core/efl] master 07/08: theme: rename pager to spotlight

2019-11-27 Thread Marcel Hollerbach
bu5hm4n pushed a commit to branch master.

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

commit ebf8d0cf300f751613c43fb7b7262aaac61a2600
Author: Marcel Hollerbach 
Date:   Wed Nov 20 17:05:10 2019 +0100

theme: rename pager to spotlight

that mirrors the name of the widget.

Reviewed-by: Mike Blumenkrantz 
Differential Revision: https://phab.enlightenment.org/D10706
---
 data/elementary/themes/default.edc  | 2 +-
 data/elementary/themes/edc/efl/{pager.edc => spotlight.edc} | 4 ++--
 src/lib/elementary/efl_page_indicator_icon.c| 2 +-
 src/lib/elementary/efl_ui_spotlight_container.c | 2 +-
 src/lib/elementary/efl_ui_spotlight_indicator_icon.c| 2 +-
 5 files changed, 6 insertions(+), 6 deletions(-)

diff --git a/data/elementary/themes/default.edc 
b/data/elementary/themes/default.edc
index cc29760931..315a5e7ca3 100644
--- a/data/elementary/themes/default.edc
+++ b/data/elementary/themes/default.edc
@@ -203,7 +203,7 @@ collections {
 #include "edc/efl/textpath.edc"
 #include "edc/efl/win.edc"
 #include "edc/efl/uiclock.edc"
-#include "edc/efl/pager.edc"
+#include "edc/efl/spotlight.edc"
 #include "edc/efl/tab_pager.edc"
 #include "edc/efl/tab_bar.edc"
 #include "edc/efl/tab_page.edc"
diff --git a/data/elementary/themes/edc/efl/pager.edc 
b/data/elementary/themes/edc/efl/spotlight.edc
similarity index 89%
rename from data/elementary/themes/edc/efl/pager.edc
rename to data/elementary/themes/edc/efl/spotlight.edc
index f56abdc8fe..802be68847 100644
--- a/data/elementary/themes/edc/efl/pager.edc
+++ b/data/elementary/themes/edc/efl/spotlight.edc
@@ -1,4 +1,4 @@
-group { "efl/pager"; data.item: "version" "123";
+group { "efl/spotlight"; data.item: "version" "123";
parts {
   swallow { "efl.indicator";
  scale;
@@ -17,7 +17,7 @@ group { "efl/pager"; data.item: "version" "123";
}
 }
 
-group { "efl/pager/indicator"; data.item: "version" "123";
+group { "efl/spotlight/indicator"; data.item: "version" "123";
images {
   image: "ring_white_middle.png" COMP;
}
diff --git a/src/lib/elementary/efl_page_indicator_icon.c 
b/src/lib/elementary/efl_page_indicator_icon.c
index 4a13db3d05..fadd3dae4d 100644
--- a/src/lib/elementary/efl_page_indicator_icon.c
+++ b/src/lib/elementary/efl_page_indicator_icon.c
@@ -57,7 +57,7 @@ _efl_page_indicator_icon_pack(Eo *obj,
 
item = efl_add(EFL_CANVAS_LAYOUT_CLASS, spd->idbox);
elm_widget_theme_object_set(spd->idbox, item,
-   "pager", "indicator", "default");
+   "spotlight", "indicator", "default");
efl_gfx_hint_align_set(item, 0.5, 0.5);
efl_gfx_hint_weight_set(item, 0, 0);
efl_gfx_hint_fill_set(item, 0, 0);
diff --git a/src/lib/elementary/efl_ui_spotlight_container.c 
b/src/lib/elementary/efl_ui_spotlight_container.c
index a715d7f04e..6eed4363d3 100644
--- a/src/lib/elementary/efl_ui_spotlight_container.c
+++ b/src/lib/elementary/efl_ui_spotlight_container.c
@@ -178,7 +178,7 @@ _efl_ui_spotlight_container_efl_object_constructor(Eo *obj,
ELM_WIDGET_DATA_GET_OR_RETURN(obj, wd, NULL);
 
if (!elm_widget_theme_klass_get(obj))
- elm_widget_theme_klass_set(obj, "pager");
+ elm_widget_theme_klass_set(obj, "spotlight");
 
obj = efl_constructor(efl_super(obj, MY_CLASS));
 
diff --git a/src/lib/elementary/efl_ui_spotlight_indicator_icon.c 
b/src/lib/elementary/efl_ui_spotlight_indicator_icon.c
index c7bc2a31de..6437710494 100644
--- a/src/lib/elementary/efl_ui_spotlight_indicator_icon.c
+++ b/src/lib/elementary/efl_ui_spotlight_indicator_icon.c
@@ -28,7 +28,7 @@ _add_item(Eo *obj EINA_UNUSED, 
Efl_Ui_Spotlight_Indicator_Icon_Data *pd)
 
item = efl_add(EFL_CANVAS_LAYOUT_CLASS, pd->indicator);
elm_widget_theme_object_set(pd->indicator, item,
-   "pager", "indicator", "default");
+   "spotlight", "indicator", "default");
efl_gfx_hint_align_set(item, 0.5, 0.5);
efl_gfx_hint_weight_set(item, 0, 0);
efl_gfx_hint_fill_set(item, 0, 0);

-- 




[EGIT] [core/efl] master 08/08: remove unused code file

2019-11-27 Thread Marcel Hollerbach
bu5hm4n pushed a commit to branch master.

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

commit dd941fe4f80c93b65e2a1d11c7577a61b20ef047
Author: Marcel Hollerbach 
Date:   Wed Nov 20 17:06:58 2019 +0100

remove unused code file

Reviewed-by: Mike Blumenkrantz 
Differential Revision: https://phab.enlightenment.org/D10707
---
 src/lib/elementary/efl_page_indicator_icon.c | 191 ---
 1 file changed, 191 deletions(-)

diff --git a/src/lib/elementary/efl_page_indicator_icon.c 
b/src/lib/elementary/efl_page_indicator_icon.c
deleted file mode 100644
index fadd3dae4d..00
--- a/src/lib/elementary/efl_page_indicator_icon.c
+++ /dev/null
@@ -1,191 +0,0 @@
-#ifdef HAVE_CONFIG_H
-# include "elementary_config.h"
-#endif
-
-#include 
-#include "elm_priv.h"
-
-#include "efl_page_indicator_icon.h"
-#include "efl_page_indicator.h"
-#include "efl_ui_widget_pager.h"
-
-#define MY_CLASS EFL_PAGE_INDICATOR_ICON_CLASS
-
-
-
-EOLIAN static void
-_efl_page_indicator_icon_update(Eo *obj,
-Efl_Page_Indicator_Icon_Data *pd,
-double pos)
-{
-   EFL_PAGE_INDICATOR_DATA_GET(obj, spd);
-   double delta = fabs(pos);
-
-   if (pd->curr)
- {
-eina_value_set(pd->v, 0.0);
-efl_layout_signal_message_send(pd->curr, 1, *(pd->v));
-if (pd->adj) efl_layout_signal_message_send(pd->adj, 1, *(pd->v));
- }
-
-   efl_page_indicator_update(efl_super(obj, MY_CLASS), pos);
-
-   pd->curr = eina_list_nth(pd->items, spd->curr_idx);
-   eina_value_set(pd->v, (1.0 - delta));
-   efl_layout_signal_message_send(pd->curr, 1, *(pd->v));
-
-   if (pos < 0)
- pd->adj = eina_list_nth(pd->items, (spd->curr_idx - 1 + spd->cnt) % 
spd->cnt);
-   else if (pos > 0)
- pd->adj = eina_list_nth(pd->items, (spd->curr_idx + 1 + spd->cnt) % 
spd->cnt);
-   else pd->adj = NULL;
-
-   if (pd->adj)
- {
-eina_value_set(pd->v, delta);
-efl_layout_signal_message_send(pd->adj, 1, *(pd->v));
- }
-}
-
-EOLIAN static void
-_efl_page_indicator_icon_pack(Eo *obj,
-  Efl_Page_Indicator_Icon_Data *pd,
-  int index)
-{
-   EFL_PAGE_INDICATOR_DATA_GET(obj, spd);
-   Eo *item, *existing;
-
-   item = efl_add(EFL_CANVAS_LAYOUT_CLASS, spd->idbox);
-   elm_widget_theme_object_set(spd->idbox, item,
-   "spotlight", "indicator", "default");
-   efl_gfx_hint_align_set(item, 0.5, 0.5);
-   efl_gfx_hint_weight_set(item, 0, 0);
-   efl_gfx_hint_fill_set(item, 0, 0);
-
-   if (index == spd->cnt)
- {
-pd->items = eina_list_append(pd->items, item);
-efl_pack_end(spd->idbox, item);
- }
-   else
- {
-existing = eina_list_nth(pd->items, index);
-pd->items = eina_list_prepend_relative(pd->items, item, existing);
-efl_pack_before(spd->idbox, item, existing);
- }
-
-   efl_page_indicator_pack(efl_super(obj, MY_CLASS), index);
-
-   if (!pd->curr)
- {
-pd->curr = eina_list_nth(pd->items, spd->curr_idx);
-eina_value_set(pd->v, 1.0);
-efl_layout_signal_message_send(pd->curr, 1, *(pd->v));
- }
-}
-
-EOLIAN static void
-_efl_page_indicator_icon_unpack(Eo *obj,
-Efl_Page_Indicator_Icon_Data *pd,
-int index)
-{
-   EFL_PAGE_INDICATOR_DATA_GET(obj, spd);
-   Eo *item;
-
-   item = eina_list_nth(pd->items, index);
-   pd->items = eina_list_remove(pd->items, item);
-   efl_pack_unpack(spd->idbox, item);
-   efl_del(item);
-
-   if (index == spd->curr_idx) pd->curr = NULL;
-
-   efl_page_indicator_unpack(efl_super(obj, MY_CLASS), index);
-
-   if ((pd->curr == NULL) && (spd->curr_idx != -1))
- {
-pd->curr = eina_list_nth(pd->items, spd->curr_idx);
-eina_value_set(pd->v, 1.0);
-efl_layout_signal_message_send(pd->curr, 1, *(pd->v));
- }
-}
-
-EOLIAN static void
-_efl_page_indicator_icon_unpack_all(Eo *obj,
-Efl_Page_Indicator_Icon_Data *pd)
-{
-   Eo *item;
-
-   EINA_LIST_FREE(pd->items, item)
- {
-efl_del(item);
- }
-
-   pd->curr = NULL;
-
-   efl_page_indicator_unpack_all(efl_super(obj, MY_CLASS));
-}
-
-EOLIAN static void
-_efl_page_indicator_icon_efl_page_indicator_bind(Eo *obj,
- Efl_Page_Indicator_Icon_Data 
*pd,
- Eo *pager,
- Efl_Canvas_Group *idbox)
-{
-   EFL_PAGE_INDICATOR_DATA_GET(obj, spd);
-   Eo *item;
-   int i, page;
-
-   if (spd-&

[EGIT] [core/efl] master 06/08: theme: remove unused parts

2019-11-27 Thread Marcel Hollerbach
bu5hm4n pushed a commit to branch master.

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

commit 14c9d43f98b7bfaa07bd037c6aea9cc3bf3bc8da
Author: Marcel Hollerbach 
Date:   Wed Nov 20 17:02:37 2019 +0100

theme: remove unused parts

they seem totally useless, no idea why they are there.

Reviewed-by: Mike Blumenkrantz 
Differential Revision: https://phab.enlightenment.org/D10705
---
 data/elementary/themes/edc/efl/pager.edc | 10 --
 1 file changed, 10 deletions(-)

diff --git a/data/elementary/themes/edc/efl/pager.edc 
b/data/elementary/themes/edc/efl/pager.edc
index b4a3dbecdb..f56abdc8fe 100644
--- a/data/elementary/themes/edc/efl/pager.edc
+++ b/data/elementary/themes/edc/efl/pager.edc
@@ -1,15 +1,5 @@
 group { "efl/pager"; data.item: "version" "123";
parts {
-  spacer { "base";
- scale;
- desc { "default";
- }
-  }
-  swallow { "efl.background";
- scale;
- desc { "default";
- }
-  }
   swallow { "efl.indicator";
  scale;
  desc { "default";

-- 




[EGIT] [core/efl] master 02/08: efl_ui_spotligt: make it possible to freeze animations

2019-11-27 Thread Marcel Hollerbach
bu5hm4n pushed a commit to branch master.

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

commit 5932520f0320d9344b2d4fa61640af0ed7540169
Author: Marcel Hollerbach 
Date:   Wed Nov 20 16:16:22 2019 +0100

efl_ui_spotligt: make it possible to freeze animations

this new API makes it possible to stop animations beeing executed in the
spotlight manager. (The logic in the spotlight managers itself are
already implemented).
The animation will also be frozen during construction time of the
spotlight.

Reviewed-by: Mike Blumenkrantz 
Differential Revision: https://phab.enlightenment.org/D10701
---
 src/lib/elementary/efl_ui_spotlight_container.c  | 31 +++--
 src/lib/elementary/efl_ui_spotlight_container.eo |  6 
 src/tests/elementary/efl_ui_test_spotlight.c | 35 ++--
 3 files changed, 67 insertions(+), 5 deletions(-)

diff --git a/src/lib/elementary/efl_ui_spotlight_container.c 
b/src/lib/elementary/efl_ui_spotlight_container.c
index f725f4830c..993438c200 100644
--- a/src/lib/elementary/efl_ui_spotlight_container.c
+++ b/src/lib/elementary/efl_ui_spotlight_container.c
@@ -33,6 +33,8 @@ typedef struct _Efl_Ui_Spotlight_Container_Data
Eina_Bool fill_width: 1;
Eina_Bool fill_height: 1;
Eina_Bool prevent_transition_interaction : 1;
+   Eina_Bool animation_enabled_internal : 1;
+   Eina_Bool animation_enabled : 1;
 } Efl_Ui_Spotlight_Container_Data;
 
 #define MY_CLASS EFL_UI_SPOTLIGHT_CONTAINER_CLASS
@@ -186,6 +188,7 @@ _efl_ui_spotlight_container_efl_object_constructor(Eo *obj,
elm_widget_theme_style_get(obj)) == 
EFL_UI_THEME_APPLY_ERROR_GENERIC)
  CRI("Failed to set layout!");
 
+   pd->animation_enabled = EINA_TRUE;
pd->position = -1;
pd->curr.page = NULL;
pd->curr.pos = 0.0;
@@ -214,13 +217,19 @@ _efl_ui_spotlight_container_efl_object_constructor(Eo 
*obj,
return obj;
 }
 
+static void
+_animated_transition_manager_eval(Eo *obj EINA_UNUSED, 
Efl_Ui_Spotlight_Container_Data *pd)
+{
+   efl_ui_spotlight_manager_animated_transition_set(pd->transition, 
pd->animation_enabled_internal && pd->animation_enabled);
+}
+
 EOLIAN static Efl_Object*
-_efl_ui_spotlight_container_efl_object_finalize(Eo *obj, 
Efl_Ui_Spotlight_Container_Data *pd EINA_UNUSED)
+_efl_ui_spotlight_container_efl_object_finalize(Eo *obj, 
Efl_Ui_Spotlight_Container_Data *pd)
 {
Efl_Ui_Spotlight_Manager *manager;
 
obj = efl_finalize(efl_super(obj, MY_CLASS));
-
+   pd->animation_enabled_internal = EINA_TRUE;
manager = efl_ui_spotlight_manager_get(obj);
//set a view manager in case nothing is here
if (!manager)
@@ -229,7 +238,8 @@ _efl_ui_spotlight_container_efl_object_finalize(Eo *obj, 
Efl_Ui_Spotlight_Contai
  }
else
  {
-efl_ui_spotlight_manager_animated_transition_set(manager, EINA_TRUE);
+
+_animated_transition_manager_eval(obj, pd);
  }
 
return obj;
@@ -619,6 +629,7 @@ _efl_ui_spotlight_container_spotlight_manager_set(Eo *obj, 
Efl_Ui_Spotlight_Cont
 //the api indicates that the caller passes ownership to this function, 
so we need to unref here
 efl_unref(pd->transition);
 //disable animation when not finalized yet, this help reducing the 
overhead of scheduling a animation that will not be displayed
+_animated_transition_manager_eval(obj, pd);
 efl_ui_spotlight_manager_animated_transition_set(pd->transition, 
efl_finalized_get(obj));
 efl_ui_spotlight_manager_bind(pd->transition, obj,
   pd->page_root);
@@ -738,5 +749,19 @@ _efl_ui_spotlight_container_pop(Eo *obj, 
Efl_Ui_Spotlight_Container_Data *pd, Ei
return transition_done;
 }
 
+EOLIAN static void
+_efl_ui_spotlight_container_animated_transition_set(Eo *obj, 
Efl_Ui_Spotlight_Container_Data *pd, Eina_Bool enable)
+{
+   pd->animation_enabled = enable;
+   _animated_transition_manager_eval(obj, pd);
+}
+
+EOLIAN static Eina_Bool
+_efl_ui_spotlight_container_animated_transition_get(const Eo *obj EINA_UNUSED, 
Efl_Ui_Spotlight_Container_Data *pd)
+{
+   return pd->animation_enabled;
+}
+
+
 
 #include "efl_ui_spotlight_container.eo.c"
diff --git a/src/lib/elementary/efl_ui_spotlight_container.eo 
b/src/lib/elementary/efl_ui_spotlight_container.eo
index fcd0bc30a3..16928d7d56 100644
--- a/src/lib/elementary/efl_ui_spotlight_container.eo
+++ b/src/lib/elementary/efl_ui_spotlight_container.eo
@@ -65,6 +65,12 @@ class @beta Efl.Ui.Spotlight.Container extends 
Efl.Ui.Layout_Base implements Efl
  (-1, -1) means that all available space 
inside the container can be used.]]
  }
   }
+  @property animated_transition {
+ [[When this flag is $true the transitions caused by @.push, @.pop or 
@.active_element are animated (if the @.spotlight_manager su

[EGIT] [core/efl] master 04/08: elm_test: make spotlight test check boxes work again

2019-11-27 Thread Marcel Hollerbach
bu5hm4n pushed a commit to branch master.

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

commit 6399ae4a84a697f30a684fe2fc39d91d548f194c
Author: Marcel Hollerbach 
Date:   Wed Nov 20 16:54:08 2019 +0100

elm_test: make spotlight test check boxes work again

when we refactored check boxes, cases that used unified events on legacy
obejcts broke, which is okay. So the usage needed fixing.

Reviewed-by: Mike Blumenkrantz 
Differential Revision: https://phab.enlightenment.org/D10703
---
 src/bin/elementary/test_ui_spotlight.c | 14 ++
 1 file changed, 6 insertions(+), 8 deletions(-)

diff --git a/src/bin/elementary/test_ui_spotlight.c 
b/src/bin/elementary/test_ui_spotlight.c
index fe095ab879..48736fe7db 100644
--- a/src/bin/elementary/test_ui_spotlight.c
+++ b/src/bin/elementary/test_ui_spotlight.c
@@ -230,10 +230,10 @@ height_slider_cb(void *data, const Efl_Event *ev)
 }
 
 static void
-width_check_cb(void *data, const Efl_Event *ev)
+width_check_cb(void *data, Evas_Object *obj, void *event_info EINA_UNUSED)
 {
Size_Params *params = data;
-   Eina_Bool ck = elm_check_selected_get(ev->object);
+   Eina_Bool ck = elm_check_selected_get(obj);
int w, h;
 
elm_object_disabled_set(params->slider, ck);
@@ -250,10 +250,10 @@ width_check_cb(void *data, const Efl_Event *ev)
 }
 
 static void
-height_check_cb(void *data, const Efl_Event *ev)
+height_check_cb(void *data, Evas_Object *obj, void *event_info EINA_UNUSED)
 {
Size_Params *params = data;
-   Eina_Bool ck = elm_check_selected_get(ev->object);
+   Eina_Bool ck = elm_check_selected_get(obj);
int w, h;
 
elm_object_disabled_set(params->slider, ck);
@@ -456,8 +456,7 @@ spotlight_size(void *data,
size_params->spotlight = params->spotlight;
size_params->params = params;
 
-   efl_event_callback_add(ck, EFL_UI_EVENT_SELECTED_CHANGED, width_check_cb,
-  size_params);
+   evas_object_smart_callback_add(ck, "changed", width_check_cb, size_params);
efl_event_callback_add(ck, EFL_EVENT_DEL, check_del_cb, size_params);
 
if (params->wfill)
@@ -497,8 +496,7 @@ spotlight_size(void *data,
size_params->spotlight = params->spotlight;
size_params->params = params;
 
-   efl_event_callback_add(ck, EFL_UI_EVENT_SELECTED_CHANGED, height_check_cb,
-  size_params);
+   evas_object_smart_callback_add(ck, "changed", height_check_cb, size_params);
efl_event_callback_add(ck, EFL_EVENT_DEL, check_del_cb, size_params);
 
if (params->hfill)

-- 




[EGIT] [core/efl] master 03/08: efl_ui_spotlight_manager: remove the group object

2019-11-27 Thread Marcel Hollerbach
bu5hm4n pushed a commit to branch master.

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

commit 58a2fa931bf5cfa3093c0b9210c1a7ab60fc4e50
Author: Marcel Hollerbach 
Date:   Wed Nov 20 16:45:45 2019 +0100

efl_ui_spotlight_manager: remove the group object

i do not know why its there, it caused a bug in the past (in regards of
clippers and visibility). Now we can get rid of it completly, the state
of it is always compatible to the one of the widget itself, s ...

Reviewed-by: Mike Blumenkrantz 
Differential Revision: https://phab.enlightenment.org/D10702
---
 data/elementary/themes/edc/efl/pager.edc   |  5 
 src/lib/elementary/efl_ui_spotlight_container.c| 12 --
 src/lib/elementary/efl_ui_spotlight_manager.eo |  3 ---
 .../elementary/efl_ui_spotlight_manager_plain.c| 13 ---
 .../elementary/efl_ui_spotlight_manager_scroll.c   | 27 +++---
 .../elementary/efl_ui_spotlight_manager_stack.c| 16 ++---
 6 files changed, 29 insertions(+), 47 deletions(-)

diff --git a/data/elementary/themes/edc/efl/pager.edc 
b/data/elementary/themes/edc/efl/pager.edc
index 6f45c3680c..b4a3dbecdb 100644
--- a/data/elementary/themes/edc/efl/pager.edc
+++ b/data/elementary/themes/edc/efl/pager.edc
@@ -10,11 +10,6 @@ group { "efl/pager"; data.item: "version" "123";
  desc { "default";
  }
   }
-  swallow { "efl.page_root";
- scale;
- desc { "default";
- }
-  }
   swallow { "efl.indicator";
  scale;
  desc { "default";
diff --git a/src/lib/elementary/efl_ui_spotlight_container.c 
b/src/lib/elementary/efl_ui_spotlight_container.c
index 993438c200..a715d7f04e 100644
--- a/src/lib/elementary/efl_ui_spotlight_container.c
+++ b/src/lib/elementary/efl_ui_spotlight_container.c
@@ -9,7 +9,7 @@
 typedef struct _Efl_Ui_Spotlight_Container_Data
 {
Eina_List *content_list;
-   Eo *page_root, *event;
+   Eo *event;
struct {
   Eina_Size2D sz;
} page_spec;
@@ -203,10 +203,7 @@ _efl_ui_spotlight_container_efl_object_constructor(Eo *obj,
 
elm_widget_can_focus_set(obj, EINA_FALSE);
 
-   pd->page_root = efl_add(EFL_CANVAS_GROUP_CLASS, evas_object_evas_get(obj));
-   efl_content_set(efl_part(obj, "efl.page_root"), pd->page_root);
-
-   efl_event_callback_add(pd->page_root, EFL_GFX_ENTITY_EVENT_SIZE_CHANGED, 
_resize_cb, pd);
+   efl_event_callback_add(obj, EFL_GFX_ENTITY_EVENT_SIZE_CHANGED, _resize_cb, 
pd);
 
pd->event = efl_add(EFL_CANVAS_RECTANGLE_CLASS,
evas_object_evas_get(obj));
@@ -616,7 +613,7 @@ _efl_ui_spotlight_container_spotlight_manager_set(Eo *obj, 
Efl_Ui_Spotlight_Cont
 
if (pd->transition)
  {
-efl_ui_spotlight_manager_bind(pd->transition, NULL, NULL);
+efl_ui_spotlight_manager_bind(pd->transition, NULL);
 efl_del(pd->transition);
  }
 
@@ -631,8 +628,7 @@ _efl_ui_spotlight_container_spotlight_manager_set(Eo *obj, 
Efl_Ui_Spotlight_Cont
 //disable animation when not finalized yet, this help reducing the 
overhead of scheduling a animation that will not be displayed
 _animated_transition_manager_eval(obj, pd);
 efl_ui_spotlight_manager_animated_transition_set(pd->transition, 
efl_finalized_get(obj));
-efl_ui_spotlight_manager_bind(pd->transition, obj,
-  pd->page_root);
+efl_ui_spotlight_manager_bind(pd->transition, obj);
 efl_ui_spotlight_manager_size_set(pd->transition, pd->page_spec.sz);
 efl_event_callback_add(pd->transition, 
EFL_UI_SPOTLIGHT_MANAGER_EVENT_POS_UPDATE, _pos_updated, obj);
  }
diff --git a/src/lib/elementary/efl_ui_spotlight_manager.eo 
b/src/lib/elementary/efl_ui_spotlight_manager.eo
index ddb1ac1041..6de4898a94 100644
--- a/src/lib/elementary/efl_ui_spotlight_manager.eo
+++ b/src/lib/elementary/efl_ui_spotlight_manager.eo
@@ -18,9 +18,6 @@ abstract @beta Efl.Ui.Spotlight.Manager extends Efl.Object {
   ]]
   params {
 spotlight : Efl.Ui.Spotlight.Container; [[The container to bind the 
manager to.]]
-group : Efl.Canvas.Group; [[The graphical group where the views should 
be added with
-@Efl.Canvas.Group.group_member_add and 
removed with
-@Efl.Canvas.Group.group_member_remove.]]
   }
 }
 content_add @pure_virtual  {
diff --git a/src/lib/elementary/efl_ui_spotlight_manager_plain.c 
b/src/lib/elementary/efl_ui_spotlight_manager_plain.c
index 50371ed3fc..49ca251c6a 100644
--- a/src/lib/elementary/efl_ui_spotlight_manager_plain.c
+++ b/src/lib/elementary/efl_ui_spotlight_manager_plain.c
@@ -8,7 +8,6 @@
 
 typedef struct {
Efl_Ui_Spotlight_Container * container;
-   Efl_Gfx_Entity *group;
Eina_Size2

[EGIT] [core/efl] master 01/01: efl_ui_multi_selectable: clean this up

2019-11-25 Thread Marcel Hollerbach
bu5hm4n pushed a commit to branch master.

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

commit f7868fd28cfc2a941601cd11e4598abf77e17c6c
Author: Marcel Hollerbach 
Date:   Wed Nov 20 12:36:02 2019 +

efl_ui_multi_selectable: clean this up

this commit merges common functions from efl_ui_multi_selectable and
efl_ui_multi_selectable_async. Additionally, the two different aspects
of accessing the elements in a multi_selectable widget (numerical or
object based) are now abstracted into interfaces called range_numeric and
range_object. numeric APIs are also prefixed with id's, so its possible
for one widget to implement both (if there will ever be the demand to do
that in future).

The main reason for this split is:
- there is no good common path between mvvm based multi_selectable and
object based multi_Selectable, so there is no way that both sides would
benefit, without the other one suffering.
- If we find later on the demand to implement both on one widget, we now
can fully do that
- Common API is available for both types, so its less API and less
confusion for the API user.

ref T7871
ref T8265

Reviewed-by: Cedric BAIL 
Differential Revision: https://phab.enlightenment.org/D10675
---
 src/bin/elementary/test_ui_collection.c|  6 +-
 .../elementary/efl_ui_collection_view_example_1.c  |  2 +-
 src/examples/elementary/efl_ui_list_example_1.c|  4 +-
 .../elementary/efl_ui_list_view_example_3.c|  4 +-
 src/lib/elementary/Efl_Ui.h|  3 +-
 src/lib/elementary/efl_ui_collection.c |  6 +-
 src/lib/elementary/efl_ui_collection.eo| 10 +--
 src/lib/elementary/efl_ui_collection_view.c|  4 +-
 src/lib/elementary/efl_ui_collection_view.eo   |  6 +-
 src/lib/elementary/efl_ui_grid.eo  |  2 +-
 src/lib/elementary/efl_ui_grid_view.eo |  4 +-
 src/lib/elementary/efl_ui_item.c   |  3 +-
 src/lib/elementary/efl_ui_list.eo  |  2 +-
 src/lib/elementary/efl_ui_list_view.eo |  4 +-
 src/lib/elementary/efl_ui_multi_selectable.eo  | 34 +-
 .../elementary/efl_ui_multi_selectable_async.eo| 63 --
 .../efl_ui_multi_selectable_index_range.eo | 53 
 .../efl_ui_multi_selectable_object_range.eo| 46 ++
 src/lib/elementary/efl_ui_select_model.c   | 24 +++
 src/lib/elementary/efl_ui_select_model.eo  | 16 ++---
 src/lib/elementary/meson.build |  3 +-
 src/tests/elementary/efl_ui_test_select_model.c|  4 +-
 .../elementary/spec/efl_test_multi_selectable.c| 74 +++---
 23 files changed, 192 insertions(+), 185 deletions(-)

diff --git a/src/bin/elementary/test_ui_collection.c 
b/src/bin/elementary/test_ui_collection.c
index 2f74809d29..2397e14211 100644
--- a/src/bin/elementary/test_ui_collection.c
+++ b/src/bin/elementary/test_ui_collection.c
@@ -8,13 +8,13 @@
 static void
 _all_select(void *data, const Efl_Event *ev EINA_UNUSED)
 {
-   efl_ui_selectable_all_select(data);
+   efl_ui_multi_selectable_all_select(data);
 }
 
 static void
 _all_unselect(void *data, const Efl_Event *ev EINA_UNUSED)
 {
-   efl_ui_selectable_all_unselect(data);
+   efl_ui_multi_selectable_all_unselect(data);
 }
 
 static void
@@ -168,7 +168,7 @@ _select_value_cb(void *data, const Efl_Event *ev)
 {
Efl_Ui_Collection *c = data;
 
-   efl_ui_selectable_select_mode_set(c, 
efl_ui_radio_group_selected_value_get(ev->object));
+   efl_ui_multi_selectable_select_mode_set(c, 
efl_ui_radio_group_selected_value_get(ev->object));
 }
 
 void create_item_container_ui(const Efl_Class *collection_class, const 
Efl_Class *item, const char *name)
diff --git a/src/examples/elementary/efl_ui_collection_view_example_1.c 
b/src/examples/elementary/efl_ui_collection_view_example_1.c
index 72960651fb..3255b17d4d 100644
--- a/src/examples/elementary/efl_ui_collection_view_example_1.c
+++ b/src/examples/elementary/efl_ui_collection_view_example_1.c
@@ -96,7 +96,7 @@ efl_main(void *data EINA_UNUSED, const Efl_Event *ev)
li = efl_add(EFL_UI_COLLECTION_VIEW_CLASS, win,
 efl_ui_collection_view_position_manager_set(efl_added, 
position_manager),
 efl_ui_view_model_set(efl_added, model),
-efl_ui_multi_selectable_async_select_mode_set(efl_added, mode),
+efl_ui_multi_selectable_select_mode_set(efl_added, mode),
 efl_ui_collection_view_factory_set(efl_added, factory));
 
efl_content_set(win, li);
diff --git a/src/examples/elementary/efl_ui_list_example_1.c 
b/src/examples/elementary/efl_ui_list_example_1.c
index ac4976a3c1..edf6d5dd4b 100644
--- a/src/examples/elementary/efl_ui_list_example_1.c
+++ b/src/examples/elementary/efl_ui_list_example_1.c
@@ -37,7

[EGIT] [core/efl] master 01/01: efl_canvas_object_animation: fix possible invalid pointer

2019-11-21 Thread Marcel Hollerbach
bu5hm4n pushed a commit to branch master.

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

commit 17ba8515f1c9534ebd47a71adda71db2eff6799a
Author: Marcel Hollerbach 
Date:   Thu Nov 21 18:41:08 2019 +0100

efl_canvas_object_animation: fix possible invalid pointer

now if one of the event handlers calls animation_stop in a callback to
EFL_CANVAS_OBJECT_ANIMATION_EVENT_ANIMATION_PROGRESS_UPDATED, then
pd->in will be freeed. Which means, in the next event handler the
address taken by >in->progress might be invalid, leading to a crash.

With this commit this is a address on the stack, which should fix this.
---
 src/lib/evas/canvas/efl_canvas_object_animation.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/src/lib/evas/canvas/efl_canvas_object_animation.c 
b/src/lib/evas/canvas/efl_canvas_object_animation.c
index 9028677953..5663833a26 100644
--- a/src/lib/evas/canvas/efl_canvas_object_animation.c
+++ b/src/lib/evas/canvas/efl_canvas_object_animation.c
@@ -59,7 +59,8 @@ _animator_cb(void *data, const Efl_Event *ev EINA_UNUSED)
efl_gfx_mapping_reset(obj);
efl_animation_apply(pd->in->animation, pd->in->progress, obj);
 
-   efl_event_callback_call(obj, 
EFL_CANVAS_OBJECT_ANIMATION_EVENT_ANIMATION_PROGRESS_UPDATED, 
>in->progress);
+   double progress = pd->in->progress;
+   efl_event_callback_call(obj, 
EFL_CANVAS_OBJECT_ANIMATION_EVENT_ANIMATION_PROGRESS_UPDATED, );
 
//Check if animation stopped in animation_progress,updated callback.
if (!pd->in) return;

-- 




[EGIT] [core/efl] master 01/01: efl_canvas_object_animation: make this all more safe

2019-11-21 Thread Marcel Hollerbach
xartigas pushed a commit to branch master.

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

commit eeff991076aa39f336557c72b4914576dcb76449
Author: Marcel Hollerbach 
Date:   Thu Nov 21 12:22:41 2019 +0100

efl_canvas_object_animation: make this all more safe

Summary:
when a callback is called, the in pointer might be free'ed, we should be
more carefull with that.

fix CID1407682

Reviewers: segfaultxavi

Reviewed By: segfaultxavi

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D10713
---
 src/lib/evas/canvas/efl_canvas_object_animation.c | 7 ++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/src/lib/evas/canvas/efl_canvas_object_animation.c 
b/src/lib/evas/canvas/efl_canvas_object_animation.c
index 67dec4a080..9028677953 100644
--- a/src/lib/evas/canvas/efl_canvas_object_animation.c
+++ b/src/lib/evas/canvas/efl_canvas_object_animation.c
@@ -106,6 +106,7 @@ static Eina_Value
 _start_fcb(Eo *o, void *data EINA_UNUSED, const Eina_Value v)
 {
Efl_Canvas_Object_Animation_Data *pd = efl_data_scope_safe_get(o, MY_CLASS);
+   EINA_SAFETY_ON_NULL_RETURN_VAL(pd, EINA_VALUE_EMPTY);
if (!pd->in) return v; //animation was stopped before anything started
_start(o, pd, pd->in->start_pos);
return v;
@@ -169,6 +170,8 @@ _efl_canvas_object_animation_animation_start(Eo *obj, 
Efl_Canvas_Object_Animatio
in->speed = speed;
in->start_pos = start_pos;
efl_event_callback_call(obj, 
EFL_CANVAS_OBJECT_ANIMATION_EVENT_ANIMATION_CHANGED, in->animation);
+   //You should not rely on in beeing available after calling the above event.
+   in = NULL;
 
if (efl_animation_start_delay_get(animation) > 0.0)
  {
@@ -193,7 +196,9 @@ _efl_canvas_object_animation_animation_stop(Eo *obj, 
Efl_Canvas_Object_Animation
 
efl_event_callback_call(obj, 
EFL_CANVAS_OBJECT_ANIMATION_EVENT_ANIMATION_CHANGED, pd->in->animation);
 
-   free(pd->in);
+   //this could be NULL if some weird callstack calls stop again while the 
above event is executed
+   if (pd->in)
+ free(pd->in);
pd->in = NULL;
 }
 

-- 




[EGIT] [core/efl] master 01/01: eo: there is no need to count callbacks here

2019-11-20 Thread Marcel Hollerbach
bu5hm4n pushed a commit to branch master.

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

commit 14b6f23cb39b08ca14fb5407de5cc5a8ae7dde6d
Author: Marcel Hollerbach 
Date:   Sun Nov 17 12:09:23 2019 +0100

eo: there is no need to count callbacks here

we are going to add this description anyways, no need to count here
again. I think this is not really making anything really faster, its
more keeping things consistance.

Reviewed-by: Cedric BAIL 
Differential Revision: https://phab.enlightenment.org/D10689
---
 src/lib/eo/eo_base_class.c | 13 -
 1 file changed, 4 insertions(+), 9 deletions(-)

diff --git a/src/lib/eo/eo_base_class.c b/src/lib/eo/eo_base_class.c
index 382beaa8d8..66e6032830 100644
--- a/src/lib/eo/eo_base_class.c
+++ b/src/lib/eo/eo_base_class.c
@@ -1270,15 +1270,10 @@ _special_event_count_inc(Eo *obj_id, Efl_Object_Data 
*pd, const Efl_Callback_Arr
else if (it->desc == EFL_EVENT_NOREF && !pd->event_cb_EFL_EVENT_NOREF)
  {
 update_hash = EINA_FALSE;
-
-if (efl_event_callback_count(obj_id, EFL_EVENT_NOREF) > 0)
-  {
- EO_OBJ_POINTER_RETURN(obj_id, obj);
- obj->noref_event = EINA_TRUE;
- EO_OBJ_DONE(obj_id);
-
- pd->event_cb_EFL_EVENT_NOREF = EINA_TRUE;
-  }
+EO_OBJ_POINTER_RETURN(obj_id, obj);
+obj->noref_event = EINA_TRUE;
+EO_OBJ_DONE(obj_id);
+pd->event_cb_EFL_EVENT_NOREF = EINA_TRUE;
  }
else if (it->desc == EFL_EVENT_OWNERSHIP_SHARED || it->desc == 
EFL_EVENT_OWNERSHIP_UNIQUE)
  {

-- 




[EGIT] [core/efl] master 02/06: introduce efl_canvas_object_animation

2019-11-20 Thread Marcel Hollerbach
bu5hm4n pushed a commit to branch master.

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

commit fa93893548858b83055e95c9e334f3d5875958be
Author: Marcel Hollerbach 
Date:   Thu Nov 7 11:24:21 2019 +0100

introduce efl_canvas_object_animation

this brings the animation to the canvas object. All the controls of the
animation now do now require a player object anymore, you can just use
the API that is directly on the Efl.Canvas.Object object.

wip animation player replacement

Differential Revision: https://phab.enlightenment.org/D10615
---
 src/examples/evas/efl-canvas-animation.c   | 179 +++
 src/examples/evas/meson.build  |   1 +
 src/lib/evas/Evas_Eo.h |   2 +-
 src/lib/evas/canvas/efl_canvas_object.eo   |   2 +-
 src/lib/evas/canvas/efl_canvas_object_animation.c  | 197 +
 src/lib/evas/canvas/efl_canvas_object_animation.eo |  60 +++
 src/lib/evas/canvas/meson.build|   2 +
 src/tests/evas/evas_test_object.c  | 158 +
 8 files changed, 599 insertions(+), 2 deletions(-)

diff --git a/src/examples/evas/efl-canvas-animation.c 
b/src/examples/evas/efl-canvas-animation.c
new file mode 100644
index 00..2cc2355956
--- /dev/null
+++ b/src/examples/evas/efl-canvas-animation.c
@@ -0,0 +1,179 @@
+/**
+ * Example of animation in efl canvas
+ *
+ * You'll need at least one engine built for it (excluding the buffer
+ * one). See stdout/stderr for output.
+ *
+ */
+
+#ifdef HAVE_CONFIG_H
+#include "config.h"
+#endif
+
+#include 
+#include 
+
+#include 
+#include 
+#include 
+
+#define WIDTH  (640)
+#define HEIGHT (480)
+
+struct example_data
+{
+   Ecore_Evas  *ee;
+   Evas*evas;
+   Evas_Object *bg, *scale;
+   double current_speed;
+};
+
+static struct example_data d;
+
+static Evas_Object * /* new rectangle to be put in the box */
+_new_rectangle_add(Evas *e)
+{
+   Efl_Canvas_Rectangle *rect = efl_add(EFL_CANVAS_RECTANGLE_CLASS, e);
+
+   efl_gfx_entity_size_set(rect, EINA_SIZE2D(10, 10));
+   efl_gfx_color_set(rect, 0, 255, 0, 255);
+   efl_gfx_entity_visible_set(rect, EINA_TRUE);
+
+   return rect;
+}
+
+/* use the following commands to interact with this example - 'h' is
+ * the key for help */
+static void
+_on_keydown(void *data EINA_UNUSED, const Efl_Event *ev)
+{
+   if (strcmp(efl_input_key_sym_get(ev->info) , "r") == 0)
+ {
+Efl_Canvas_Animation *animation = 
efl_canvas_object_animation_get(d.scale);
+double current_pos = efl_canvas_object_animation_progress_get(d.scale);
+d.current_speed *= -1;
+efl_canvas_object_animation_start(d.scale, animation, d.current_speed, 
1.0 - current_pos);
+ }
+   if (strcmp(efl_input_key_sym_get(ev->info), "p") == 0)
+ {
+efl_canvas_object_animation_pause_set(d.scale, 
!efl_canvas_object_animation_pause_get(d.scale));
+ }
+}
+
+static void
+_on_delete(Ecore_Evas *ee EINA_UNUSED)
+{
+   ecore_main_loop_quit();
+}
+
+static void /* adjust canvas' contents on resizes */
+_canvas_resize_cb(Ecore_Evas *ee)
+{
+   int w, h;
+
+   ecore_evas_geometry_get(ee, NULL, NULL, , );
+
+   efl_gfx_entity_geometry_set(d.bg, EINA_RECT(0, 0, w, h));
+}
+
+static void
+print_help(void)
+{
+   printf("evas-animation example\n Press r to reverse the animation of the 
red rect.\n Press p to pause the animation of the red rect.\n");
+}
+
+int
+main(void)
+{
+   if (!ecore_evas_init())
+ return EXIT_FAILURE;
+
+   /* this will give you a window with an Evas canvas under the first
+* engine available */
+   d.ee = ecore_evas_new(NULL, 0, 0, WIDTH, HEIGHT, NULL);
+   if (!d.ee)
+ goto panic;
+
+   print_help();
+
+   ecore_evas_name_class_set(d.ee, "Evas Animation example", "Evas Animation 
Example");
+   ecore_evas_callback_delete_request_set(d.ee, _on_delete);
+   ecore_evas_callback_resize_set(d.ee, _canvas_resize_cb);
+   ecore_evas_show(d.ee);
+
+   d.evas = ecore_evas_get(d.ee);
+
+   d.bg = _new_rectangle_add(d.evas);
+   efl_gfx_color_set(d.bg, 255, 255, 255, 255);
+   efl_gfx_entity_visible_set(d.bg, EINA_TRUE);
+   efl_canvas_object_key_focus_set(d.bg, EINA_TRUE);
+   efl_event_callback_add(d.bg, EFL_EVENT_KEY_DOWN, _on_keydown, NULL);
+
+   _canvas_resize_cb(d.ee);
+
+   Evas_Object *scale_rect = _new_rectangle_add(d.evas);
+   efl_gfx_entity_geometry_set(scale_rect, EINA_RECT(50, 50, 50, 50));
+   efl_canvas_object_animation_start(scale_rect,
+efl_new(EFL_CANVAS_ANIMATION_SCALE_CLASS,
+  efl_animation_scale_set(efl_added, EINA_VECTOR2(1.0, 1.0), 
EINA_VECTOR2(3.0, 3.0), scale_rect, EINA_VECTOR2(0.5, 0.5)),
+  efl_animation_start_delay_set(efl_added, 5.0),
+  efl_animation_duration_set(efl_added, 2.0),
+  efl_animation_repeat_count_set(efl_added, EFL_ANIMATION_REPEAT_INFINITE)
+),

[EGIT] [core/efl] master 06/06: remove efl_canvas_animation_player

2019-11-20 Thread Marcel Hollerbach
bu5hm4n pushed a commit to branch master.

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

commit aef56b169e2588ee450e13b5f163c19bd65a330f
Author: Marcel Hollerbach 
Date:   Thu Nov 14 12:54:31 2019 +0100

remove efl_canvas_animation_player

this now all migrated to Efl.Canvas.Object.Animation

Reviewed-by: Cedric BAIL 
Differential Revision: https://phab.enlightenment.org/D10667
---
 src/lib/evas/Efl_Canvas.h  |   1 -
 src/lib/evas/Evas_Eo.h |   1 -
 src/lib/evas/canvas/efl_canvas_animation.eo|   5 +-
 src/lib/evas/canvas/efl_canvas_animation_player.c  | 444 -
 src/lib/evas/canvas/efl_canvas_animation_player.eo |  62 ---
 .../canvas/efl_canvas_animation_player_private.h   |  53 ---
 src/lib/evas/canvas/meson.build|   2 -
 7 files changed, 2 insertions(+), 566 deletions(-)

diff --git a/src/lib/evas/Efl_Canvas.h b/src/lib/evas/Efl_Canvas.h
index 82659a38e7..cf0db0c2f4 100644
--- a/src/lib/evas/Efl_Canvas.h
+++ b/src/lib/evas/Efl_Canvas.h
@@ -69,7 +69,6 @@ extern "C" {
 #include 
 #include 
 #include 
-#include 
 #include 
 #include 
 #include 
diff --git a/src/lib/evas/Evas_Eo.h b/src/lib/evas/Evas_Eo.h
index 13ecde563a..5f8d0b45bc 100644
--- a/src/lib/evas/Evas_Eo.h
+++ b/src/lib/evas/Evas_Eo.h
@@ -232,7 +232,6 @@ struct _Efl_Canvas_Object_Animation_Event
 #include "canvas/efl_canvas_animation_group.eo.h"
 #include "canvas/efl_canvas_animation_group_parallel.eo.h"
 #include "canvas/efl_canvas_animation_group_sequential.eo.h"
-#include "canvas/efl_canvas_animation_player.eo.h"
 #include "canvas/efl_canvas_event_grabber.eo.h"
 
  /**
diff --git a/src/lib/evas/canvas/efl_canvas_animation.eo 
b/src/lib/evas/canvas/efl_canvas_animation.eo
index f8c371c0c9..3640cd2234 100644
--- a/src/lib/evas/canvas/efl_canvas_animation.eo
+++ b/src/lib/evas/canvas/efl_canvas_animation.eo
@@ -1,5 +1,4 @@
 import efl_canvas_animation_types;
-parse efl_canvas_animation_player;
 
 class @beta Efl.Canvas.Animation extends Efl.Object implements Efl.Playable
 {
@@ -16,7 +15,7 @@ class @beta Efl.Canvas.Animation extends Efl.Object 
implements Efl.Playable
  removed. This means that if the animation does not end in the object's 
initial state there will be a noticeable
  sudden jump.
  To avoid this, animations must finish in the same state as they begin, or 
the object's state must be
- matched to the animation's ending state once the animation finishes 
(using the @[Efl.Canvas.Animation_Player.ended]
+ matched to the animation's ending state once the animation finishes 
(using the @[Efl.Canvas.Object_Animation.animation,changed]
  event).
]]
c_prefix: efl_animation;
@@ -99,7 +98,7 @@ class @beta Efl.Canvas.Animation extends Efl.Object 
implements Efl.Playable
   }
   animation_apply {
  [[Overwrite this method to implement your own animation subclasses.
- 
+
This is used for example by @Efl.Canvas.Animation_Translate or 
@Efl.Canvas.Animation_Scale.
 
Subclasses should call their parent's @.animation_apply to get the 
adjusted $progress value
diff --git a/src/lib/evas/canvas/efl_canvas_animation_player.c 
b/src/lib/evas/canvas/efl_canvas_animation_player.c
deleted file mode 100644
index e8b57cb5b9..00
--- a/src/lib/evas/canvas/efl_canvas_animation_player.c
+++ /dev/null
@@ -1,444 +0,0 @@
-#include "efl_canvas_animation_player_private.h"
-
-static void
-_target_del_cb(void *data, const Efl_Event *event EINA_UNUSED)
-{
-   Efl_Canvas_Animation_Player_Data *pd = data;
-   pd->target = NULL;
-}
-
-EOLIAN static void
-_efl_canvas_animation_player_target_set(Eo *eo_obj EINA_UNUSED,
- Efl_Canvas_Animation_Player_Data *pd,
- Efl_Canvas_Object *target)
-{
-   if (pd->target == target)
- return;
-
-   if (pd->target)
- efl_event_callback_del(pd->target, EFL_EVENT_DEL, _target_del_cb, pd);
-
-   efl_event_callback_add(target, EFL_EVENT_DEL, _target_del_cb, pd);
-
-   pd->target = target;
-}
-
-EOLIAN static Efl_Canvas_Object *
-_efl_canvas_animation_player_target_get(const Eo *eo_obj EINA_UNUSED, 
Efl_Canvas_Animation_Player_Data *pd)
-{
-   return pd->target;
-}
-
-EOLIAN static void
-_efl_canvas_animation_player_auto_del_set(Eo *eo_obj EINA_UNUSED,
-   Efl_Canvas_Animation_Player_Data *pd,
-   Eina_Bool auto_del)
-{
-   pd->auto_del = auto_del;
-}
-
-EOLIAN static Eina_Bool
-_efl_canvas_animation_player_auto_del_get(const Eo *eo_obj EINA_UNUSED,
-   Efl_Canvas_Animation_Player_Data *pd)
-{
-   return pd->auto_del;
-}
-
-EOLIAN static void
-_efl_canvas_animation_player_anima

[EGIT] [core/efl] master 03/06: elementary: move away from normal player to the new animation mixin

2019-11-20 Thread Marcel Hollerbach
bu5hm4n pushed a commit to branch master.

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

commit 0792d042e5db4827fb5f50bdf3fcbff11ccd8b2c
Author: Marcel Hollerbach 
Date:   Sun Nov 10 19:10:02 2019 +0100

elementary: move away from normal player to the new animation mixin

the mixin can handle the same things as the player. Additionally, the
usage of the mixin simplifies the animation usage alot.

Reviewed-by: Cedric BAIL 
Differential Revision: https://phab.enlightenment.org/D10636
---
 src/bin/elementary/test_efl_anim_alpha.c   | 45 ++--
 src/bin/elementary/test_efl_anim_group_parallel.c  | 48 ++---
 .../elementary/test_efl_anim_group_sequential.c| 47 ++---
 src/bin/elementary/test_efl_anim_interpolator.c| 82 +-
 src/bin/elementary/test_efl_anim_pause.c   | 68 +++---
 src/bin/elementary/test_efl_anim_repeat.c  | 74 +--
 src/bin/elementary/test_efl_anim_rotate.c  | 73 +++
 src/bin/elementary/test_efl_anim_scale.c   | 72 +++
 src/bin/elementary/test_efl_anim_start_delay.c | 55 +++
 src/bin/elementary/test_efl_anim_translate.c   | 57 +++
 10 files changed, 259 insertions(+), 362 deletions(-)

diff --git a/src/bin/elementary/test_efl_anim_alpha.c 
b/src/bin/elementary/test_efl_anim_alpha.c
index d75733f8c8..b364319279 100644
--- a/src/bin/elementary/test_efl_anim_alpha.c
+++ b/src/bin/elementary/test_efl_anim_alpha.c
@@ -7,31 +7,38 @@ typedef struct _App_Data
 {
Efl_Canvas_Animation*show_anim;
Efl_Canvas_Animation*hide_anim;
-   Efl_Canvas_Animation_Player *anim_obj;
+   Elm_Button  *button;
 
Eina_Bool is_btn_visible;
 } App_Data;
 
 static void
-_anim_started_cb(void *data EINA_UNUSED, const Efl_Event *event EINA_UNUSED)
+_anim_changed_cb(void *data EINA_UNUSED, const Efl_Event *event EINA_UNUSED)
 {
-   printf("Animation has been started!\n");
-}
+   Eo *anim = event->info;
 
-static void
-_anim_ended_cb(void *data EINA_UNUSED, const Efl_Event *event EINA_UNUSED)
-{
-   printf("Animation has been ended!\n");
+   if (anim)
+ {
+printf("Animation has been started!\n");
+ }
+   else
+ {
+printf("Animation has been ended!\n");
+ }
 }
 
 static void
 _anim_running_cb(void *data EINA_UNUSED, const Efl_Event *event)
 {
-   Efl_Canvas_Animation_Player_Event_Running *event_running = event->info;
-   double progress = event_running->progress;
-   printf("Animation is running! Current progress(%lf)\n", progress);
+   double *progress = event->info;
+   printf("Animation is running! Current progress(%lf)\n", *progress);
 }
 
+EFL_CALLBACKS_ARRAY_DEFINE(animation_stats_cb,
+  {EFL_CANVAS_OBJECT_ANIMATION_EVENT_ANIMATION_CHANGED, _anim_changed_cb },
+  {EFL_CANVAS_OBJECT_ANIMATION_EVENT_ANIMATION_PROGRESS_UPDATED, 
_anim_running_cb },
+)
+
 static void
 _btn_clicked_cb(void *data, Evas_Object *obj, void *event_info EINA_UNUSED)
 {
@@ -42,18 +49,17 @@ _btn_clicked_cb(void *data, Evas_Object *obj, void 
*event_info EINA_UNUSED)
if (ad->is_btn_visible)
  {
 //Create Animation Object from Animation
-efl_animation_player_animation_set(ad->anim_obj, ad->show_anim);
+efl_canvas_object_animation_start(ad->button, ad->show_anim, 1.0, 0.0);
 efl_text_set(obj, "Start Alpha Animation from 1.0 to 0.0");
  }
else
  {
 //Create Animation Object from Animation
-efl_animation_player_animation_set(ad->anim_obj, ad->hide_anim);
+efl_canvas_object_animation_start(ad->button, ad->hide_anim, 1.0, 0.0);
 efl_text_set(obj, "Start Alpha Animation from 0.0 to 1.0");
  }
 
//Let Animation Object start animation
-   efl_player_playing_set(ad->anim_obj, EINA_TRUE);
 }
 
 static void
@@ -81,6 +87,7 @@ test_efl_anim_alpha(void *data EINA_UNUSED, Evas_Object *obj 
EINA_UNUSED, void *
evas_object_resize(btn, 200, 200);
evas_object_move(btn, 100, 50);
evas_object_show(btn);
+   efl_event_callback_array_add(btn, animation_stats_cb(), ad);
 
//Show Animation
Efl_Canvas_Animation *show_anim = efl_add(EFL_CANVAS_ANIMATION_ALPHA_CLASS, 
win);
@@ -97,16 +104,8 @@ test_efl_anim_alpha(void *data EINA_UNUSED, Evas_Object 
*obj EINA_UNUSED, void *
//Initialize App Data
ad->show_anim = show_anim;
ad->hide_anim = hide_anim;
-   ad->anim_obj = efl_add(EFL_CANVAS_ANIMATION_PLAYER_CLASS, win,
-  efl_animation_player_target_set(efl_added, btn));
-
-   //Register callback called when animation starts
-   efl_event_callback_add(ad->anim_obj, EFL_ANIMATION_PLAYER_EVENT_STARTED, 
_anim_started_cb, NULL);
-   //Register callback called when animatio

[EGIT] [core/efl] master 04/06: efl_ui_spotlight_manager stack: move away from player object

2019-11-20 Thread Marcel Hollerbach
bu5hm4n pushed a commit to branch master.

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

commit d4c004ab5db3bb97ee05a3bb0f8c4d70a26a3c60
Author: Marcel Hollerbach 
Date:   Sun Nov 10 20:00:50 2019 +0100

efl_ui_spotlight_manager stack: move away from player object

with this commit we move from using the player object to using the mixin
that was introduced a few commits before. The new mixin is way easier to
use here, we safe a lot of code, we also only need 1 object instead of
4. (And overall, everything just gets so much more easier).

Reviewed-by: Cedric BAIL 
Differential Revision: https://phab.enlightenment.org/D10637
---
 .../elementary/efl_ui_spotlight_manager_stack.c| 156 ++---
 1 file changed, 40 insertions(+), 116 deletions(-)

diff --git a/src/lib/elementary/efl_ui_spotlight_manager_stack.c 
b/src/lib/elementary/efl_ui_spotlight_manager_stack.c
index 16e721560f..3696eb991e 100644
--- a/src/lib/elementary/efl_ui_spotlight_manager_stack.c
+++ b/src/lib/elementary/efl_ui_spotlight_manager_stack.c
@@ -9,9 +9,9 @@
 typedef struct {
Efl_Ui_Spotlight_Container * container;
Efl_Gfx_Entity *group;
-   Efl_Canvas_Animation_Player *hide, *show;
-   int from, to;
-   Efl_Gfx_Entity *content;
+   Efl_Canvas_Animation_Player *alpha_anim;
+   Efl_Gfx_Entity *content[2];
+   int ids[2]; //only used when in animation
Eina_Size2D page_size;
Eina_Bool animation;
 } Efl_Ui_Spotlight_Manager_Stack_Data;
@@ -21,29 +21,16 @@ typedef struct {
 static void
 _geom_sync(Eo *obj EINA_UNUSED, Efl_Ui_Spotlight_Manager_Stack_Data *pd)
 {
-   Eina_Array *array = eina_array_new(2);
Eina_Rect group_pos = efl_gfx_entity_geometry_get(pd->group);
-   if (efl_player_playing_get(pd->hide))
- {
-//we are currently in animation, sync the geometry of the targets
-eina_array_push(array, efl_animation_player_target_get(pd->hide));
-eina_array_push(array, efl_animation_player_target_get(pd->show));
- }
-   else
- {
-//we only have our content right now, or nothing
-eina_array_push(array, pd->content);
- }
Eina_Rect goal = EINA_RECT_EMPTY();
goal.size = pd->page_size;
goal.y = (group_pos.y + group_pos.h/2)-pd->page_size.h/2;
goal.x = (group_pos.x + group_pos.w/2)-pd->page_size.w/2;
-   while (eina_array_count(array) > 0)
+   for (int i = 0; i < 2; ++i)
  {
-Efl_Gfx_Entity *subobj = eina_array_pop(array);
-efl_gfx_entity_geometry_set(subobj, goal);
+if (pd->content[i])
+  efl_gfx_entity_geometry_set(pd->content[i], goal);
  }
-   eina_array_free(array);
 }
 
 static void
@@ -66,85 +53,36 @@ _running_cb(void *data, const Efl_Event *ev EINA_UNUSED)
 
EINA_SAFETY_ON_NULL_RETURN(pd);
//calculate absolut position, multiply pos with 2.0 because duration is 
only 0.5)
-   absolut_position = pd->from + (pd->to - 
pd->from)*(efl_player_playback_position_get(pd->show)*2.0);
+   absolut_position = pd->ids[0] + (pd->ids[1] - 
pd->ids[0])*(efl_canvas_object_animation_progress_get(ev->object));
efl_event_callback_call(data, EFL_UI_SPOTLIGHT_MANAGER_EVENT_POS_UPDATE, 
_position);
 }
 
 static void
-_anim_started_cb(void *data EINA_UNUSED, const Efl_Event *event)
+_hide_object_cb(void *data, const Efl_Event *ev)
 {
-   Efl_Canvas_Object *content;
-
-   content = efl_animation_player_target_get(event->object);
-   efl_gfx_entity_visible_set(content, EINA_TRUE);
-}
-
-static void
-_hide_anim_ended_cb(void *data, const Efl_Event *event EINA_UNUSED)
-{
-   Efl_Ui_Spotlight_Manager_Stack_Data *pd = efl_data_scope_safe_get(data, 
MY_CLASS);
-   Efl_Canvas_Object *content;
-
-   EINA_SAFETY_ON_NULL_RETURN(pd);
-   content = efl_animation_player_target_get(pd->hide);
-   efl_gfx_entity_visible_set(content, EINA_FALSE);
-}
-
-static void
-_show_anim_ended_cb(void *data, const Efl_Event *event EINA_UNUSED)
-{
-   Efl_Ui_Spotlight_Manager_Stack_Data *pd = efl_data_scope_safe_get(data, 
MY_CLASS);
-   Efl_Canvas_Object *content;
-
-   EINA_SAFETY_ON_NULL_RETURN(pd);
-   content = efl_animation_player_target_get(pd->show);
-   efl_gfx_entity_visible_set(content, EINA_TRUE);
-   pd->content = content;
+   if (!ev->info)
+ {
+efl_gfx_entity_visible_set(ev->object, EINA_FALSE);
+efl_event_callback_del(ev->object, ev->desc, _hide_object_cb, data);
+efl_event_callback_del(ev->object, 
EFL_CANVAS_OBJECT_ANIMATION_EVENT_ANIMATION_PROGRESS_UPDATED, _running_cb, 
data);
+ }
 }
 
-EFL_CALLBACKS_ARRAY_DEFINE(_anim_show_event_cb,
-  {EFL_ANIMATION_PLAYER_EVENT_RUNNING, _running_cb},
-  {EFL_ANIMATION_PLAYER_EVENT_STARTED, _anim_started_cb},
-  {EFL_ANIMATION_PLAYER_EVENT_ENDED, _show_anim_ended_cb},
-)
-
-EFL_CALLBACKS_ARRAY_DEFINE(_anim_hide_event_cb,
-  {EFL_ANIMATION_PLAYER_EVENT_STARTED, _anim_started_cb

[EGIT] [core/efl] master 05/06: evas: migrate the vg json example

2019-11-20 Thread Marcel Hollerbach
bu5hm4n pushed a commit to branch master.

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

commit 80e58dd79ad98267d2069a62661e6ae4db6bf11f
Author: Marcel Hollerbach 
Date:   Mon Nov 18 11:44:15 2019 +0900

evas: migrate the vg json example

Summary:
i was not able to run the example before this commit, nor after this
commit. However, i had to migrate this, as i want to remove the player
object.
Depends on D10637

Reviewers: Hermet

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Reviewed-by: Hermet Park 
Differential Revision: https://phab.enlightenment.org/D10666
---
 src/examples/evas/evas-vg-json.c | 12 
 1 file changed, 4 insertions(+), 8 deletions(-)

diff --git a/src/examples/evas/evas-vg-json.c b/src/examples/evas/evas-vg-json.c
index 248dcb1054..cf0519f6f3 100644
--- a/src/examples/evas/evas-vg-json.c
+++ b/src/examples/evas/evas-vg-json.c
@@ -35,10 +35,9 @@
 static Eo *gvg[5];
 
 static void
-running_cb(void *data EINA_UNUSED, const Efl_Event *event)
+_running_cb(void *data EINA_UNUSED, const Efl_Event *event)
 {
-   Efl_Canvas_Animation_Player_Event_Running *event_running = event->info;
-   double progress = event_running->progress;
+   double progress = *((double*)event->info);
 
int i;
for (i = 0; i < 5; i++)
@@ -120,11 +119,8 @@ main(void)
//Play custom animation
Eo *anim = efl_add(EFL_CANVAS_ANIMATION_CLASS, evas);
efl_animation_duration_set(anim, 
efl_gfx_frame_controller_frame_duration_get(vg, 0, 0));
-
-   Eo *player = efl_add(EFL_CANVAS_ANIMATION_PLAYER_CLASS, evas);
-   efl_animation_player_animation_set(player, anim);
-   efl_event_callback_add(player, EFL_ANIMATION_PLAYER_EVENT_RUNNING, 
running_cb, NULL);
-   efl_player_playing_set(player, EINA_TRUE);
+   efl_event_callback_add(vg, 
EFL_CANVAS_OBJECT_ANIMATION_EVENT_ANIMATION_PROGRESS_UPDATED, _running_cb, 
NULL);
+   efl_canvas_object_animation_start(vg, anim, 1.0, 0.0);
 
ecore_main_loop_begin();
ecore_evas_shutdown();

-- 




[EGIT] [core/efl] master 01/01: evas: migrate the vg json example

2019-11-17 Thread Marcel Hollerbach
hermet pushed a commit to branch master.

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

commit a1f1cd6dd67de8eac0e302d47ce2aebf44aead16
Author: Marcel Hollerbach 
Date:   Mon Nov 18 11:44:15 2019 +0900

evas: migrate the vg json example

Summary:
i was not able to run the example before this commit, nor after this
commit. However, i had to migrate this, as i want to remove the player
object.
Depends on D10637

Reviewers: Hermet

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D10666
---
 src/examples/evas/evas-vg-json.c | 12 
 1 file changed, 4 insertions(+), 8 deletions(-)

diff --git a/src/examples/evas/evas-vg-json.c b/src/examples/evas/evas-vg-json.c
index 248dcb1054..cf0519f6f3 100644
--- a/src/examples/evas/evas-vg-json.c
+++ b/src/examples/evas/evas-vg-json.c
@@ -35,10 +35,9 @@
 static Eo *gvg[5];
 
 static void
-running_cb(void *data EINA_UNUSED, const Efl_Event *event)
+_running_cb(void *data EINA_UNUSED, const Efl_Event *event)
 {
-   Efl_Canvas_Animation_Player_Event_Running *event_running = event->info;
-   double progress = event_running->progress;
+   double progress = *((double*)event->info);
 
int i;
for (i = 0; i < 5; i++)
@@ -120,11 +119,8 @@ main(void)
//Play custom animation
Eo *anim = efl_add(EFL_CANVAS_ANIMATION_CLASS, evas);
efl_animation_duration_set(anim, 
efl_gfx_frame_controller_frame_duration_get(vg, 0, 0));
-
-   Eo *player = efl_add(EFL_CANVAS_ANIMATION_PLAYER_CLASS, evas);
-   efl_animation_player_animation_set(player, anim);
-   efl_event_callback_add(player, EFL_ANIMATION_PLAYER_EVENT_RUNNING, 
running_cb, NULL);
-   efl_player_playing_set(player, EINA_TRUE);
+   efl_event_callback_add(vg, 
EFL_CANVAS_OBJECT_ANIMATION_EVENT_ANIMATION_PROGRESS_UPDATED, _running_cb, 
NULL);
+   efl_canvas_object_animation_start(vg, anim, 1.0, 0.0);
 
ecore_main_loop_begin();
ecore_evas_shutdown();

-- 




[EGIT] [core/efl] master 01/02: elm: apply the same fix we needed in entry to other scrollable widgets

2019-11-11 Thread Marcel Hollerbach
bu5hm4n pushed a commit to branch master.

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

commit 4c8a764b49bab346bccbcac3c411df94448ff042
Author: Marcel Hollerbach 
Date:   Thu Nov 7 23:00:36 2019 +0100

elm: apply the same fix we needed in entry to other scrollable widgets

this here is the same effect as in my previous commit:
When re retheme a object, we need to reset the signals, otherwise there
would be wrongly displayed scrollbars.

This fixes wrong scrollbars in enlightenment.

Differential Revision: https://phab.enlightenment.org/D10628
---
 src/lib/elementary/elm_gengrid.c  | 1 +
 src/lib/elementary/elm_genlist.c  | 1 +
 src/lib/elementary/elm_list.c | 3 ++-
 src/lib/elementary/elm_map.c  | 3 +--
 src/lib/elementary/elm_panel.c| 1 +
 src/lib/elementary/elm_scroller.c | 1 +
 src/lib/elementary/elm_toolbar.c  | 1 +
 7 files changed, 8 insertions(+), 3 deletions(-)

diff --git a/src/lib/elementary/elm_gengrid.c b/src/lib/elementary/elm_gengrid.c
index f30dfe6b3a..36206fd375 100644
--- a/src/lib/elementary/elm_gengrid.c
+++ b/src/lib/elementary/elm_gengrid.c
@@ -3623,6 +3623,7 @@ _elm_gengrid_efl_ui_widget_theme_apply(Eo *obj, 
Elm_Gengrid_Data *sd EINA_UNUSED
int_ret = efl_ui_widget_theme_apply(efl_super(obj, MY_CLASS));
if (int_ret == EFL_UI_THEME_APPLY_ERROR_GENERIC) return int_ret;
 
+   elm_interface_scrollable_reset_signals(obj);
_mirrored_set(obj, efl_ui_mirrored_get(obj));
 
return int_ret;
diff --git a/src/lib/elementary/elm_genlist.c b/src/lib/elementary/elm_genlist.c
index 9f2fb8e4a0..65bc5182b5 100644
--- a/src/lib/elementary/elm_genlist.c
+++ b/src/lib/elementary/elm_genlist.c
@@ -3562,6 +3562,7 @@ _elm_genlist_efl_ui_widget_theme_apply(Eo *obj, 
Elm_Genlist_Data *sd)
int_ret = efl_ui_widget_theme_apply(efl_super(obj, MY_CLASS));
if (int_ret == EFL_UI_THEME_APPLY_ERROR_GENERIC) return int_ret;
 
+   elm_interface_scrollable_reset_signals(obj);
e = evas_object_evas_get(obj);
evas_event_freeze(e);
_mirrored_set(obj, efl_ui_mirrored_get(obj));
diff --git a/src/lib/elementary/elm_list.c b/src/lib/elementary/elm_list.c
index 04831372c5..7414bd2559 100644
--- a/src/lib/elementary/elm_list.c
+++ b/src/lib/elementary/elm_list.c
@@ -1139,6 +1139,8 @@ _elm_list_efl_ui_widget_theme_apply(Eo *obj, 
Elm_List_Data *sd)
int_ret = efl_ui_widget_theme_apply(efl_super(obj, MY_CLASS));
if (int_ret == EFL_UI_THEME_APPLY_ERROR_GENERIC) return int_ret;
 
+   elm_interface_scrollable_reset_signals(obj);
+
_mirrored_set(obj, efl_ui_mirrored_get(obj));
 
EINA_LIST_FOREACH(sd->items, n, eo_it)
@@ -1150,7 +1152,6 @@ _elm_list_efl_ui_widget_theme_apply(Eo *obj, 
Elm_List_Data *sd)
  }
 
_items_fix(obj);
-
elm_layout_sizing_eval(obj);
 
return int_ret;
diff --git a/src/lib/elementary/elm_map.c b/src/lib/elementary/elm_map.c
index 4549f7cb1f..6a37e59cb2 100644
--- a/src/lib/elementary/elm_map.c
+++ b/src/lib/elementary/elm_map.c
@@ -4002,10 +4002,9 @@ _elm_map_efl_ui_widget_theme_apply(Eo *obj, Elm_Map_Data 
*sd EINA_UNUSED)
int_ret = efl_ui_widget_theme_apply(efl_super(obj, MY_CLASS));
if (int_ret == EFL_UI_THEME_APPLY_ERROR_GENERIC) return int_ret;
 
-
elm_widget_theme_object_set
   (obj, wd->resize_obj, "map", "base", elm_widget_style_get(obj));
-
+   elm_interface_scrollable_reset_signals(obj);
_sizing_eval(obj);
 
return int_ret;
diff --git a/src/lib/elementary/elm_panel.c b/src/lib/elementary/elm_panel.c
index 1468d810c5..97f4267b2b 100644
--- a/src/lib/elementary/elm_panel.c
+++ b/src/lib/elementary/elm_panel.c
@@ -223,6 +223,7 @@ _elm_panel_efl_ui_widget_theme_apply(Eo *obj, 
Elm_Panel_Data *sd)
int_ret = efl_ui_widget_theme_apply(efl_super(obj, MY_CLASS));
if (int_ret == EFL_UI_THEME_APPLY_ERROR_GENERIC) return int_ret;
 
+   elm_interface_scrollable_reset_signals(obj);
_mirrored_set(obj, efl_ui_mirrored_get(obj));
 
if (sd->scrollable)
diff --git a/src/lib/elementary/elm_scroller.c 
b/src/lib/elementary/elm_scroller.c
index 5f47874b90..8d20030a91 100644
--- a/src/lib/elementary/elm_scroller.c
+++ b/src/lib/elementary/elm_scroller.c
@@ -406,6 +406,7 @@ _elm_scroller_efl_ui_widget_theme_apply(Eo *obj, 
Elm_Scroller_Data *sd EINA_UNUS
int_ret = efl_ui_widget_theme_apply(efl_super(obj, MY_CLASS));
if (int_ret == EFL_UI_THEME_APPLY_ERROR_GENERIC) return int_ret;
 
+   elm_interface_scrollable_reset_signals(obj);
_mirrored_set(obj, efl_ui_mirrored_get(obj));
 
elm_layout_sizing_eval(obj);
diff --git a/src/lib/elementary/elm_toolbar.c b/src/lib/elementary/elm_toolbar.c
index 273fb25f1b..d6763cebb6 100644
--- a/src/lib/elementary/elm_toolbar.c
+++ b/src/lib/elementary/elm_toolbar.c
@@ -1511,6 +1511,7 @@ _elm_toolbar_efl_ui_widget_theme_apply(Eo *obj, 
Elm_Toolbar_Data *sd)
elm_widget_theme_object_set
  (obj, wd->resize_obj, "toolbar&quo

[EGIT] [core/efl] master 01/01: efl_canvas_animation: correctly handle double signness

2019-11-11 Thread Marcel Hollerbach
xartigas pushed a commit to branch master.

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

commit 6b1de6a4ac4afac779d873f292757c943331540d
Author: Marcel Hollerbach 
Date:   Mon Nov 11 10:14:42 2019 +0100

efl_canvas_animation: correctly handle double signness

Summary:
start_delay and duration both have to be > 0.0 otherwise there should be
an error. This also adds the neccessary checks, to ensure that.

For now this is only added to the normal evas test suite, maybe we eed
to refactor these efl_* API tests into theire own test suite. However,
not for now.

Reviewers: segfaultxavi

Reviewed By: segfaultxavi

Subscribers: segfaultxavi, cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D10617
---
 src/lib/evas/canvas/efl_canvas_animation.c |  3 ++-
 src/tests/evas/efl_canvas_animation.c  | 40 ++
 src/tests/evas/evas_suite.c|  1 +
 src/tests/evas/evas_suite.h|  1 +
 src/tests/evas/meson.build |  1 +
 5 files changed, 45 insertions(+), 1 deletion(-)

diff --git a/src/lib/evas/canvas/efl_canvas_animation.c 
b/src/lib/evas/canvas/efl_canvas_animation.c
index 119384b5eb..33ffa035ac 100644
--- a/src/lib/evas/canvas/efl_canvas_animation.c
+++ b/src/lib/evas/canvas/efl_canvas_animation.c
@@ -7,6 +7,7 @@ _efl_canvas_animation_duration_set(Eo *eo_obj EINA_UNUSED,
 Efl_Canvas_Animation_Data *pd,
 double sec)
 {
+   EINA_SAFETY_ON_FALSE_RETURN(sec > 0.0);
pd->duration = sec;
 }
 
@@ -69,7 +70,7 @@ _efl_canvas_animation_start_delay_set(Eo *eo_obj EINA_UNUSED,
Efl_Canvas_Animation_Data *pd,
double sec)
 {
-   EINA_SAFETY_ON_FALSE_RETURN(sec < 0.0);
+   EINA_SAFETY_ON_FALSE_RETURN(sec >= 0.0);
 
pd->start_delay_time = sec;
 }
diff --git a/src/tests/evas/efl_canvas_animation.c 
b/src/tests/evas/efl_canvas_animation.c
new file mode 100644
index 00..cef036341c
--- /dev/null
+++ b/src/tests/evas/efl_canvas_animation.c
@@ -0,0 +1,40 @@
+#ifdef HAVE_CONFIG_H
+# include "config.h"
+#endif
+
+#include 
+
+#include 
+
+#include "evas_suite.h"
+#include "evas_tests_helpers.h"
+
+EFL_START_TEST(efl_canvas_animation_negative_double_checking)
+{
+   Efl_Canvas_Animation *animation = efl_new(EFL_CANVAS_ANIMATION_CLASS);
+
+   efl_animation_duration_set(animation, 1.0);
+   ck_assert_int_eq(efl_animation_duration_get(animation), 1.0);
+   efl_animation_duration_set(animation, 3.0);
+   ck_assert_int_eq(efl_animation_duration_get(animation), 3.0);
+   EXPECT_ERROR_START;
+   efl_animation_duration_set(animation, -1.0);
+   ck_assert_int_eq(efl_animation_duration_get(animation), 3.0);
+   EXPECT_ERROR_END;
+
+   efl_animation_start_delay_set(animation, 1.0);
+   ck_assert(EINA_DBL_EQ(efl_animation_start_delay_get(animation), 1.0));
+   efl_animation_start_delay_set(animation, 0.0);
+   ck_assert(EINA_DBL_EQ(efl_animation_start_delay_get(animation), 0.0));
+   EXPECT_ERROR_START;
+   efl_animation_start_delay_set(animation, -1.0);
+   ck_assert_int_eq(efl_animation_start_delay_get(animation), 0.0);
+   EXPECT_ERROR_END;
+
+}
+EFL_END_TEST
+
+void efl_test_canvas_animation(TCase *tc)
+{
+   tcase_add_test(tc, efl_canvas_animation_negative_double_checking);
+}
diff --git a/src/tests/evas/evas_suite.c b/src/tests/evas/evas_suite.c
index 5e3d0d5571..eded3ae08f 100644
--- a/src/tests/evas/evas_suite.c
+++ b/src/tests/evas/evas_suite.c
@@ -29,6 +29,7 @@ static const Efl_Test_Case etc[] = {
   { "Object Smart", evas_test_object_smart },
   { "Matrix", evas_test_matrix },
   { "Events", evas_test_events },
+  { "Efl Canvas Animation", efl_test_canvas_animation },
   { NULL, NULL }
 };
 
diff --git a/src/tests/evas/evas_suite.h b/src/tests/evas/evas_suite.h
index 6fee2236d0..90a7ac0860 100644
--- a/src/tests/evas/evas_suite.h
+++ b/src/tests/evas/evas_suite.h
@@ -23,5 +23,6 @@ void evas_test_evasgl(TCase *tc);
 void evas_test_object_smart(TCase *tc);
 void evas_test_matrix(TCase *tc);
 void evas_test_events(TCase *tc);
+void efl_test_canvas_animation(TCase *tc);
 
 #endif /* _EVAS_SUITE_H */
diff --git a/src/tests/evas/meson.build b/src/tests/evas/meson.build
index 62d744a5db..0e92eba83e 100644
--- a/src/tests/evas/meson.build
+++ b/src/tests/evas/meson.build
@@ -21,6 +21,7 @@ evas_suite_src = [
   'efl_test_canvas.c',
   'efl_test_canvas2.c',
   'efl_test_canvas3.c',
+  'efl_canvas_animation.c',
 ]
 
 evas_suite = executable('evas_suite',

-- 




[EGIT] [core/efl] master 05/05: elm_entry: fix wrong displayed scrollbars

2019-11-07 Thread Marcel Hollerbach
bu5hm4n pushed a commit to branch master.

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

commit 01bf9a34d667466417b807a1187b2bc4ba6fa87f
Author: Marcel Hollerbach 
Date:   Thu Nov 7 21:45:02 2019 +0100

elm_entry: fix wrong displayed scrollbars

the scrolbars have been displayed wrongly before. Reason for this is
that the theme displays the bars per default, the code however works
with hidden by default. This was worked arround before with the fact
that we are explicitly hiding the vbar/hbar before.
The reason this previous code was not working proberly is that entry
decided to retheme a object that was already set to the interface
scrollable object. Which means, it was not detected by the code. With
the newly introduced reset function you can tell the interface, that you
have changed the group, signals will be emitted accordingly.

Reviewed-by: Cedric BAIL 
Differential Revision: https://phab.enlightenment.org/D10622
---
 src/lib/elementary/elm_entry.c |  1 +
 src/lib/elementary/elm_interface_scrollable.c  | 20 
 src/lib/elementary/elm_interface_scrollable.eo |  3 +++
 3 files changed, 20 insertions(+), 4 deletions(-)

diff --git a/src/lib/elementary/elm_entry.c b/src/lib/elementary/elm_entry.c
index 4cbf725cfb..737be8141b 100644
--- a/src/lib/elementary/elm_entry.c
+++ b/src/lib/elementary/elm_entry.c
@@ -1003,6 +1003,7 @@ _elm_entry_efl_ui_widget_theme_apply(Eo *obj, 
Elm_Entry_Data *sd)
   elm_widget_theme_object_set
   (obj, sd->scr_edje, "scroller", "entry", style);
 
+elm_interface_scrollable_reset_signals(obj);
 _elm_entry_background_switch(sd->entry_edje, sd->scr_edje);
 
 str = edje_object_data_get(sd->scr_edje, "focus_highlight");
diff --git a/src/lib/elementary/elm_interface_scrollable.c 
b/src/lib/elementary/elm_interface_scrollable.c
index 8a2c390f9f..7130efbd94 100644
--- a/src/lib/elementary/elm_interface_scrollable.c
+++ b/src/lib/elementary/elm_interface_scrollable.c
@@ -4027,6 +4027,21 @@ _scroll_event_object_detach(Evas_Object *obj)
  _elm_scroll_mouse_move_event_cb, sid);
 }
 
+EOLIAN static void
+_elm_interface_scrollable_reset_signals(Eo *obj EINA_UNUSED, 
Elm_Scrollable_Smart_Interface_Data *sid)
+{
+   sid->go_up = sid->go_down = sid->go_right = sid->go_left = EINA_FALSE;
+
+   edje_object_signal_emit(sid->edje_obj, "elm,action,hide,up", "elm");
+   edje_object_signal_emit(sid->edje_obj, "elm,action,hide,down", "elm");
+   edje_object_signal_emit(sid->edje_obj, "elm,action,hide,right", "elm");
+   edje_object_signal_emit(sid->edje_obj, "elm,action,hide,left", "elm");
+   edje_object_signal_emit(sid->edje_obj, "elm,action,hide,vbar", "elm");
+   edje_object_signal_emit(sid->edje_obj, "elm,action,hide,hbar", "elm");
+
+   _elm_scroll_scroll_bar_visibility_adjust(sid);
+}
+
 EOLIAN static void
 _elm_interface_scrollable_objects_set(Eo *obj, 
Elm_Scrollable_Smart_Interface_Data *sid, Evas_Object *edje_object, Evas_Object 
*hit_rectangle)
 {
@@ -4039,10 +4054,7 @@ _elm_interface_scrollable_objects_set(Eo *obj, 
Elm_Scrollable_Smart_Interface_Da
 
sid->edje_obj = edje_object;
 
-   edje_object_signal_emit(sid->edje_obj, "elm,action,hide,up", "elm");
-   edje_object_signal_emit(sid->edje_obj, "elm,action,hide,down", "elm");
-   edje_object_signal_emit(sid->edje_obj, "elm,action,hide,right", "elm");
-   edje_object_signal_emit(sid->edje_obj, "elm,action,hide,left", "elm");
+   elm_interface_scrollable_reset_signals(obj);
 
if (sid->event_rect)
  _scroll_event_object_detach(obj);
diff --git a/src/lib/elementary/elm_interface_scrollable.eo 
b/src/lib/elementary/elm_interface_scrollable.eo
index cec1536c10..2c911b8091 100644
--- a/src/lib/elementary/elm_interface_scrollable.eo
+++ b/src/lib/elementary/elm_interface_scrollable.eo
@@ -647,6 +647,9 @@ mixin @beta Elm.Interface_Scrollable requires Efl.Ui.Widget 
extends Efl.Ui.Focus
 enable: bool; [[True to enable looping.]]
  }
   }
+  reset_signals {
+[[Call this if you have changed the group of the object passed to 
@.objects]]
+  }
}
implements {
   class.constructor;

-- 




[EGIT] [core/efl] master 01/01: efl_canvas_animation: improve generally

2019-11-04 Thread Marcel Hollerbach
xartigas pushed a commit to branch master.

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

commit 56d541fbdb1cdc980dcdee644be24d52255af3fb
Author: Marcel Hollerbach 
Date:   Mon Nov 4 13:44:29 2019 +0100

efl_canvas_animation: improve generally

Summary:
to be taken over by doccop
Depends on D10559

Reviewers: Jaehyun_Cho, bu5hm4n

Reviewed By: bu5hm4n

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D10560
---
 src/lib/evas/canvas/efl_canvas_animation.eo | 65 -
 1 file changed, 45 insertions(+), 20 deletions(-)

diff --git a/src/lib/evas/canvas/efl_canvas_animation.eo 
b/src/lib/evas/canvas/efl_canvas_animation.eo
index a64047820f..987220bf4d 100644
--- a/src/lib/evas/canvas/efl_canvas_animation.eo
+++ b/src/lib/evas/canvas/efl_canvas_animation.eo
@@ -2,75 +2,100 @@ import efl_canvas_animation_types;
 
 class @beta Efl.Canvas.Animation extends Efl.Object implements Efl.Playable
 {
-   [[Efl animation class]]
+   [[Base class to be used by classes implementing specific canvas animations.
+
+ A canvas animation modifies the properties of a @Efl.Canvas.Object like
+ @Efl.Gfx.Entity.position, @Efl.Gfx.Entity.scale or 
@Efl.Gfx.Mapping.rotate, for example.
+ The value of the changed properties moves smoothly as the provided 
progress value
+ evolves from $[0] to $[1].
+
+ For example implementations see @Efl.Canvas.Animation_Translate or 
@Efl.Canvas.Animation_Scale.
+   ]]
c_prefix: efl_animation;
methods {
   @property final_state_keep {
- [[Keep final state property]]
+ [[If $true the last mapping state the animation applies will be kept.
+   Otherwise all the @Efl.Gfx.Mapping properties will be reset when 
the animation ends.]]
  set {
  }
  get {
  }
  values {
-keep: bool; [[$true to keep final state, $false otherwise.]]
+keep: bool; [[$true to keep the final state.]]
  }
   }
   @property duration {
- [[Duration property]]
+ [[The duration of a single animation "run".
+   The @Efl.Playable.length implementation will return this duration 
adjusted by @.repeat_mode and
+   @.repeat_count.
+ ]]
  set {
  }
  get {
  }
  values {
-sec: double; [[Duration value.]]
+sec: double; [[Duration in seconds.]]
  }
   }
   @property repeat_mode {
- [[Repeat mode property]]
+ [[What to do when the animation finishes.
+ ]]
  set {
  }
  get {
  }
  values {
-mode: Efl.Canvas.Animation_Repeat_Mode; [[Repeat mode.]]
+mode: 
Efl.Canvas.Animation_Repeat_Mode(Efl.Canvas.Animation_Repeat_Mode.restart); 
[[Repeat mode.]]
  }
   }
   @property repeat_count {
- [[Repeat count property]]
- set {
- }
- get {
- }
+ [[How many times to repeat an animation once it finishes.
+   $[0] means that the animation only plays once (it is not repeated) 
and is the default value.
+   $[-1] means that the animation is repeated forever.
+ ]]
  values {
-count: int; [[Repeat count. -1 repeats animation infinitely.]]
+count: int(0); [[Repeat count.]]
  }
   }
   @property start_delay {
- [[Start delay property]]
+ [[The time that passes since the animation is started and the first 
real change to the object is applied.
+ ]]
  set {
  }
  get {
  }
  values {
-sec: double; [[Delay time, in seconds, from when the animation 
starts until the animation is animated.]]
+sec: double; [[Delay time in seconds.]]
  }
   }
   @property interpolator {
- [[Interpolator property]]
+ [[Optional mapping function.
+
+   Animations are based on a timer that moves linearly from 0 to 1. 
This $interpolator
+   method is applied before the timer is passed to the animation, to 
achieve effects
+   like acceleration or deceleration, for example.
+ ]]
  set {
  }
  get {
  }
  values {
-interpolator: Efl.Interpolator; [[Interpolator which indicates 
interpolation function.]]
+interpolator: Efl.Interpolator; [[Mapping function. By default it 
is $NULL (linear mapping).]]
  }
   }
   animation_apply {
+ [[Overwrite this method to implement your own animation subclasses.
+ 
+   This is used for example by @Efl.Canvas.Animation_Translate or 
@Efl.Canvas.Animation_Scale.
+
+   Subclasses should call their parent's @.animation_ap

[EGIT] [core/efl] master 02/05: efl_canvas_animation: be more explicit with errors

2019-11-04 Thread Marcel Hollerbach
xartigas pushed a commit to branch master.

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

commit 92a4fab5d79f69dfea118f65f494bb014117b4f2
Author: Marcel Hollerbach 
Date:   Wed Oct 30 15:30:09 2019 +0100

efl_canvas_animation: be more explicit with errors

Summary:
with this commit invalid values are not accepted silently anymore. But
rather a error will be raised.
Depends on D10350

Reviewers: segfaultxavi, Jaehyun_Cho

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Maniphest Tasks: T8288

Differential Revision: https://phab.enlightenment.org/D10558
---
 src/lib/evas/canvas/efl_canvas_animation.c | 10 --
 src/lib/evas/canvas/efl_canvas_animation_types.eot |  3 ++-
 2 files changed, 6 insertions(+), 7 deletions(-)

diff --git a/src/lib/evas/canvas/efl_canvas_animation.c 
b/src/lib/evas/canvas/efl_canvas_animation.c
index b8c7c99861..119384b5eb 100644
--- a/src/lib/evas/canvas/efl_canvas_animation.c
+++ b/src/lib/evas/canvas/efl_canvas_animation.c
@@ -38,9 +38,8 @@ _efl_canvas_animation_repeat_mode_set(Eo *eo_obj EINA_UNUSED,
Efl_Canvas_Animation_Data *pd,
Efl_Canvas_Animation_Repeat_Mode mode)
 {
-   if ((mode == EFL_CANVAS_ANIMATION_REPEAT_MODE_RESTART) ||
-   (mode == EFL_CANVAS_ANIMATION_REPEAT_MODE_REVERSE))
- pd->repeat_mode = mode;
+   EINA_SAFETY_ON_FALSE_RETURN(mode >= 0 && mode < 
EFL_CANVAS_ANIMATION_REPEAT_MODE_LAST);
+   pd->repeat_mode = mode;
 }
 
 EOLIAN static Efl_Canvas_Animation_Repeat_Mode
@@ -54,8 +53,7 @@ _efl_canvas_animation_repeat_count_set(Eo *eo_obj EINA_UNUSED,
 Efl_Canvas_Animation_Data *pd,
 int count)
 {
-   //EFL_ANIMATION_REPEAT_INFINITE repeats animation infinitely
-   if ((count < 0) && (count != EFL_ANIMATION_REPEAT_INFINITE)) return;
+   EINA_SAFETY_ON_FALSE_RETURN(count >= EFL_ANIMATION_REPEAT_INFINITE);
 
pd->repeat_count = count;
 }
@@ -71,7 +69,7 @@ _efl_canvas_animation_start_delay_set(Eo *eo_obj EINA_UNUSED,
Efl_Canvas_Animation_Data *pd,
double sec)
 {
-   if (sec < 0.0) return;
+   EINA_SAFETY_ON_FALSE_RETURN(sec < 0.0);
 
pd->start_delay_time = sec;
 }
diff --git a/src/lib/evas/canvas/efl_canvas_animation_types.eot 
b/src/lib/evas/canvas/efl_canvas_animation_types.eot
index 23e89aef0d..cfdda2d490 100644
--- a/src/lib/evas/canvas/efl_canvas_animation_types.eot
+++ b/src/lib/evas/canvas/efl_canvas_animation_types.eot
@@ -8,5 +8,6 @@ enum @beta Efl.Canvas.Animation_Repeat_Mode
[[Animation repeat mode]]
 
restart = 0, [[Restart animation when the animation ends.]]
-   reverse  [[Reverse animation when the animation ends.]]
+   reverse = 1, [[Reverse animation when the animation ends.]]
+   last
 }

-- 




[EGIT] [core/efl] master 01/05: efl_canvas_animation_rotate: adjust API

2019-11-04 Thread Marcel Hollerbach
xartigas pushed a commit to branch master.

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

commit f47b9277453edb1a3b4b68171d99f5b841e52e19
Author: Marcel Hollerbach 
Date:   Wed Oct 30 15:29:59 2019 +0100

efl_canvas_animation_rotate: adjust API

Summary:
in task T8288 we concluded that a few APIs need to be adjusted in order
to stabelize animation classes at some point. This also adds a new macro
to eina in order to create EINA_VECTOR2 values more easily.

ref T8288

Reviewers: Jaehyun_Cho, segfaultxavi, zmike

Reviewed By: zmike

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Maniphest Tasks: T8288

Differential Revision: https://phab.enlightenment.org/D10350
---
 src/bin/elementary/test_efl_anim_group_parallel.c  |  4 +-
 .../elementary/test_efl_anim_group_sequential.c|  4 +-
 src/bin/elementary/test_efl_anim_rotate.c  | 12 +++---
 src/lib/eina/eina_vector.h |  1 +
 src/lib/evas/canvas/efl_canvas_animation_rotate.c  | 44 --
 src/lib/evas/canvas/efl_canvas_animation_rotate.eo |  8 +---
 .../canvas/efl_canvas_animation_rotate_private.h   |  9 +
 7 files changed, 31 insertions(+), 51 deletions(-)

diff --git a/src/bin/elementary/test_efl_anim_group_parallel.c 
b/src/bin/elementary/test_efl_anim_group_parallel.c
index 6283e2262f..ec4c3eabea 100644
--- a/src/bin/elementary/test_efl_anim_group_parallel.c
+++ b/src/bin/elementary/test_efl_anim_group_parallel.c
@@ -90,7 +90,7 @@ test_efl_anim_group_parallel(void *data EINA_UNUSED, 
Evas_Object *obj EINA_UNUSE
 
//Rotate from 45 to 0 degrees Animation
Efl_Canvas_Animation *ccw_45_degrees_anim = 
efl_add(EFL_CANVAS_ANIMATION_ROTATE_CLASS, win);
-   efl_animation_rotate_set(ccw_45_degrees_anim, 45.0, 0.0, NULL, 0.5, 0.5);
+   efl_animation_rotate_set(ccw_45_degrees_anim, 45.0, 0.0, NULL, 
EINA_VECTOR2(0.5, 0.5));
 
//Scale Animation to zoom out
Efl_Canvas_Animation *scale_half_anim = 
efl_add(EFL_CANVAS_ANIMATION_SCALE_CLASS, win);
@@ -113,7 +113,7 @@ test_efl_anim_group_parallel(void *data EINA_UNUSED, 
Evas_Object *obj EINA_UNUSE
 
//Rotate from 0 to 45 degrees Animation
Efl_Canvas_Animation *cw_45_degrees_anim = 
efl_add(EFL_CANVAS_ANIMATION_ROTATE_CLASS, win);
-   efl_animation_rotate_set(cw_45_degrees_anim, 0.0, 45.0, NULL, 0.5, 0.5);
+   efl_animation_rotate_set(cw_45_degrees_anim, 0.0, 45.0, NULL, 
EINA_VECTOR2(0.5, 0.5));
 
//Scale Animation to zoom in
Efl_Canvas_Animation *scale_double_anim = 
efl_add(EFL_CANVAS_ANIMATION_SCALE_CLASS, win);
diff --git a/src/bin/elementary/test_efl_anim_group_sequential.c 
b/src/bin/elementary/test_efl_anim_group_sequential.c
index 3488149af0..2d09354675 100644
--- a/src/bin/elementary/test_efl_anim_group_sequential.c
+++ b/src/bin/elementary/test_efl_anim_group_sequential.c
@@ -86,7 +86,7 @@ test_efl_anim_group_sequential(void *data EINA_UNUSED, 
Evas_Object *obj EINA_UNU
/* Animations to hide button */
//Rotate from 0 to 45 degrees Animation
Efl_Canvas_Animation *cw_45_degrees_anim = 
efl_add(EFL_CANVAS_ANIMATION_ROTATE_CLASS, win);
-   efl_animation_rotate_set(cw_45_degrees_anim, 0.0, 45.0, NULL, 0.5, 0.5);
+   efl_animation_rotate_set(cw_45_degrees_anim, 0.0, 45.0, NULL, 
EINA_VECTOR2(0.5, 0.5));
 
//Scale Animation to zoom in
Efl_Canvas_Animation *scale_double_anim = 
efl_add(EFL_CANVAS_ANIMATION_SCALE_CLASS, win);
@@ -120,7 +120,7 @@ test_efl_anim_group_sequential(void *data EINA_UNUSED, 
Evas_Object *obj EINA_UNU
 
//Rotate from 45 to 0 degrees Animation
Efl_Canvas_Animation *ccw_45_degrees_anim = 
efl_add(EFL_CANVAS_ANIMATION_ROTATE_CLASS, win);
-   efl_animation_rotate_set(ccw_45_degrees_anim, 45.0, 0.0, NULL, 0.5, 0.5);
+   efl_animation_rotate_set(ccw_45_degrees_anim, 45.0, 0.0, NULL, 
EINA_VECTOR2(0.5, 0.5));
efl_animation_duration_set(ccw_45_degrees_anim, 1.0);
 
//Show Sequential Group Animation
diff --git a/src/bin/elementary/test_efl_anim_rotate.c 
b/src/bin/elementary/test_efl_anim_rotate.c
index 10df8caf89..ea8b94af68 100644
--- a/src/bin/elementary/test_efl_anim_rotate.c
+++ b/src/bin/elementary/test_efl_anim_rotate.c
@@ -84,13 +84,13 @@ test_efl_anim_rotate(void *data EINA_UNUSED, Evas_Object 
*obj EINA_UNUSED, void
 
//Rotate from 0 to 45 degrees Animation
Efl_Canvas_Animation *cw_45_degrees_anim = 
efl_add(EFL_CANVAS_ANIMATION_ROTATE_CLASS, win);
-   efl_animation_rotate_set(cw_45_degrees_anim, 0.0, 45.0,NULL, 0.5, 0.5);
+   efl_animation_rotate_set(cw_45_degrees_anim, 0.0, 45.0, NULL, 
EINA_VECTOR2(0.5, 0.5));
efl_animation_duration_set(cw_45_degrees_anim, 1.0);
efl_animation_final_state_keep_set(cw_45_degrees_anim, EINA_TRUE);
 
//Rotate from 45 to 0 degrees Animation
Efl_Canvas_Animation *ccw_45_degrees_anim = 
efl_add(EFL_CANVAS_ANIMATION_ROTATE_CLASS, win);
-   efl_animation_rotate_set(ccw_45_degrees_anim

[EGIT] [core/efl] master 03/05: efl_canvas_animation_scale: move from 2 doubles to vectors

2019-11-04 Thread Marcel Hollerbach
xartigas pushed a commit to branch master.

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

commit e2a011f56b48d7894e710fca5a46a4bfe87ecd1f
Author: Marcel Hollerbach 
Date:   Wed Oct 30 15:30:18 2019 +0100

efl_canvas_animation_scale: move from 2 doubles to vectors

Summary:
with this the passing of positions is getting more easy. Additionally,
Reading the API call gets easier, as parameters are semantically
grouped.
Depends on D10558

Reviewers: segfaultxavi, Jaehyun_Cho

Reviewed By: segfaultxavi

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Maniphest Tasks: T8288

Differential Revision: https://phab.enlightenment.org/D10559
---
 src/bin/elementary/test_efl_anim_group_parallel.c  |   4 +-
 .../elementary/test_efl_anim_group_sequential.c|   4 +-
 src/bin/elementary/test_efl_anim_scale.c   |  12 +-
 src/lib/evas/canvas/efl_canvas_animation_scale.c   | 134 +++--
 src/lib/evas/canvas/efl_canvas_animation_scale.eo  |  20 +--
 .../canvas/efl_canvas_animation_scale_private.h|  18 +--
 6 files changed, 64 insertions(+), 128 deletions(-)

diff --git a/src/bin/elementary/test_efl_anim_group_parallel.c 
b/src/bin/elementary/test_efl_anim_group_parallel.c
index ec4c3eabea..262286a6fb 100644
--- a/src/bin/elementary/test_efl_anim_group_parallel.c
+++ b/src/bin/elementary/test_efl_anim_group_parallel.c
@@ -94,7 +94,7 @@ test_efl_anim_group_parallel(void *data EINA_UNUSED, 
Evas_Object *obj EINA_UNUSE
 
//Scale Animation to zoom out
Efl_Canvas_Animation *scale_half_anim = 
efl_add(EFL_CANVAS_ANIMATION_SCALE_CLASS, win);
-   efl_animation_scale_set(scale_half_anim, 2.0, 2.0, 1.0, 1.0, NULL, 0.5, 
0.5);
+   efl_animation_scale_set(scale_half_anim, EINA_VECTOR2(2.0, 2.0), 
EINA_VECTOR2(1.0, 1.0), NULL, EINA_VECTOR2(0.5, 0.5));
 
//Show Parallel Group Animation
Efl_Canvas_Animation *parallel_show_anim = 
efl_add(EFL_CANVAS_ANIMATION_GROUP_PARALLEL_CLASS, win);
@@ -117,7 +117,7 @@ test_efl_anim_group_parallel(void *data EINA_UNUSED, 
Evas_Object *obj EINA_UNUSE
 
//Scale Animation to zoom in
Efl_Canvas_Animation *scale_double_anim = 
efl_add(EFL_CANVAS_ANIMATION_SCALE_CLASS, win);
-   efl_animation_scale_set(scale_double_anim, 1.0, 1.0, 2.0, 2.0, NULL, 0.5, 
0.5);
+   efl_animation_scale_set(scale_double_anim, EINA_VECTOR2(1.0, 1.0), 
EINA_VECTOR2(2.0, 2.0), NULL, EINA_VECTOR2(0.5, 0.5));
 
//Hide Parallel Group Animation
Efl_Canvas_Animation *parallel_hide_anim = 
efl_add(EFL_CANVAS_ANIMATION_GROUP_PARALLEL_CLASS, win);
diff --git a/src/bin/elementary/test_efl_anim_group_sequential.c 
b/src/bin/elementary/test_efl_anim_group_sequential.c
index 2d09354675..4beefb2f55 100644
--- a/src/bin/elementary/test_efl_anim_group_sequential.c
+++ b/src/bin/elementary/test_efl_anim_group_sequential.c
@@ -90,7 +90,7 @@ test_efl_anim_group_sequential(void *data EINA_UNUSED, 
Evas_Object *obj EINA_UNU
 
//Scale Animation to zoom in
Efl_Canvas_Animation *scale_double_anim = 
efl_add(EFL_CANVAS_ANIMATION_SCALE_CLASS, win);
-   efl_animation_scale_set(scale_double_anim, 1.0, 1.0, 2.0, 2.0, NULL, 0.5, 
0.5);
+   efl_animation_scale_set(scale_double_anim, EINA_VECTOR2(1.0, 1.0), 
EINA_VECTOR2(2.0, 2.0), NULL, EINA_VECTOR2(0.5, 0.5));
 
//Hide Animation
Efl_Canvas_Animation *hide_anim = efl_add(EFL_CANVAS_ANIMATION_ALPHA_CLASS, 
win);
@@ -115,7 +115,7 @@ test_efl_anim_group_sequential(void *data EINA_UNUSED, 
Evas_Object *obj EINA_UNU
 
//Scale Animation to zoom out
Efl_Canvas_Animation *scale_half_anim = 
efl_add(EFL_CANVAS_ANIMATION_SCALE_CLASS, win);
-   efl_animation_scale_set(scale_half_anim, 2.0, 2.0, 1.0, 1.0, NULL, 0.5, 
0.5);
+   efl_animation_scale_set(scale_half_anim, EINA_VECTOR2(2.0, 2.0), 
EINA_VECTOR2(1.0, 1.0), NULL, EINA_VECTOR2(0.5, 0.5));
efl_animation_duration_set(scale_half_anim, 1.0);
 
//Rotate from 45 to 0 degrees Animation
diff --git a/src/bin/elementary/test_efl_anim_scale.c 
b/src/bin/elementary/test_efl_anim_scale.c
index 5e5f9abc58..d3812dec67 100644
--- a/src/bin/elementary/test_efl_anim_scale.c
+++ b/src/bin/elementary/test_efl_anim_scale.c
@@ -84,13 +84,13 @@ test_efl_anim_scale(void *data EINA_UNUSED, Evas_Object 
*obj EINA_UNUSED, void *
 
//Scale Animation to zoom in
Efl_Canvas_Animation *scale_double_anim = 
efl_add(EFL_CANVAS_ANIMATION_SCALE_CLASS, win);
-   efl_animation_scale_set(scale_double_anim, 1.0, 1.0, 2.0, 2.0, NULL, 0.5, 
0.5);
+   efl_animation_scale_set(scale_double_anim, EINA_VECTOR2(1.0, 1.0), 
EINA_VECTOR2(2.0, 2.0), NULL, EINA_VECTOR2(0.5, 0.5));
efl_animation_duration_set(scale_double_anim, 1.0);
efl_animation_final_state_keep_set(scale_double_anim, EINA_TRUE);
 
//Scale Animation to zoom out
Efl_Canvas_Animation *scale_half_anim = 
efl_add(EFL_CANVAS_ANIMATION_SCALE_CLASS, win);
-   efl_animation_scale_set(scale_half_anim, 2.0, 2.0, 1.0

[EGIT] [core/efl] master 04/05: efl_canvas_animation_translate: move from x to container types

2019-11-04 Thread Marcel Hollerbach
xartigas pushed a commit to branch master.

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

commit a1a77f5590a27ba6bb70ce9d2f5343f3cddc96dc
Author: Marcel Hollerbach 
Date:   Wed Oct 30 15:30:20 2019 +0100

efl_canvas_animation_translate: move from x to container types

Summary:
this now uses Eina.Position2D so its easier to pass arround other
positions.

ref T8288
Depends on D10559

Reviewers: segfaultxavi

Reviewed By: segfaultxavi

Subscribers: segfaultxavi, cedric, #reviewers, #committers

Tags: #efl

Maniphest Tasks: T8288

Differential Revision: https://phab.enlightenment.org/D10562
---
 src/bin/elementary/test_efl_anim_interpolator.c|  2 +-
 src/bin/elementary/test_efl_anim_translate.c   |  8 +--
 .../evas/canvas/efl_canvas_animation_translate.c   | 75 +++---
 .../evas/canvas/efl_canvas_animation_translate.eo  | 12 ++--
 .../efl_canvas_animation_translate_private.h   | 10 +--
 5 files changed, 35 insertions(+), 72 deletions(-)

diff --git a/src/bin/elementary/test_efl_anim_interpolator.c 
b/src/bin/elementary/test_efl_anim_interpolator.c
index be177d7ed4..9a6522f6d7 100644
--- a/src/bin/elementary/test_efl_anim_interpolator.c
+++ b/src/bin/elementary/test_efl_anim_interpolator.c
@@ -199,7 +199,7 @@ test_efl_anim_interpolator(void *data EINA_UNUSED, 
Evas_Object *obj EINA_UNUSED,
 
 Efl_Canvas_Animation *anim =
   efl_add(EFL_CANVAS_ANIMATION_TRANSLATE_CLASS, win);
-efl_animation_translate_set(anim, 0, 0, (WIN_W - BTN_W), 0);
+efl_animation_translate_set(anim, EINA_POSITION2D(0, 0), 
EINA_POSITION2D((WIN_W - BTN_W), 0));
 efl_animation_duration_set(anim, 2.0);
 efl_animation_final_state_keep_set(anim, EINA_FALSE);
 
diff --git a/src/bin/elementary/test_efl_anim_translate.c 
b/src/bin/elementary/test_efl_anim_translate.c
index 9f30cc3b63..5bbf1b22e7 100644
--- a/src/bin/elementary/test_efl_anim_translate.c
+++ b/src/bin/elementary/test_efl_anim_translate.c
@@ -84,13 +84,13 @@ test_efl_anim_translate(void *data EINA_UNUSED, Evas_Object 
*obj EINA_UNUSED, vo
 
//Translate Animation to right bottom relatively
Efl_Canvas_Animation *translate_rb_anim = 
efl_add(EFL_CANVAS_ANIMATION_TRANSLATE_CLASS, win);
-   efl_animation_translate_set(translate_rb_anim, 0, 0, 100, 100);
+   efl_animation_translate_set(translate_rb_anim, EINA_POSITION2D(0, 0), 
EINA_POSITION2D(100, 100));
efl_animation_duration_set(translate_rb_anim, 1.0);
efl_animation_final_state_keep_set(translate_rb_anim, EINA_TRUE);
 
//Translate Animation to left top relatively
Efl_Canvas_Animation *translate_lt_anim = 
efl_add(EFL_CANVAS_ANIMATION_TRANSLATE_CLASS, win);
-   efl_animation_translate_set(translate_lt_anim, 100, 100, 0, 0);
+   efl_animation_translate_set(translate_lt_anim, EINA_POSITION2D(100, 100), 
EINA_POSITION2D(0, 0));
efl_animation_duration_set(translate_lt_anim, 1.0);
efl_animation_final_state_keep_set(translate_lt_anim, EINA_TRUE);
 
@@ -150,13 +150,13 @@ test_efl_anim_translate_absolute(void *data EINA_UNUSED, 
Evas_Object *obj EINA_U
 
//Translate Animation to right bottom absolutely
Efl_Canvas_Animation *translate_rb_anim = 
efl_add(EFL_CANVAS_ANIMATION_TRANSLATE_CLASS, win);
-   efl_animation_translate_absolute_set(translate_rb_anim, 0, 0, 100, 100);
+   efl_animation_translate_absolute_set(translate_rb_anim, EINA_POSITION2D(0, 
0), EINA_POSITION2D(100, 100));
efl_animation_duration_set(translate_rb_anim, 1.0);
efl_animation_final_state_keep_set(translate_rb_anim, EINA_TRUE);
 
//Translate Animation to left top absolutely
Efl_Canvas_Animation *translate_lt_anim = 
efl_add(EFL_CANVAS_ANIMATION_TRANSLATE_CLASS, win);
-   efl_animation_translate_absolute_set(translate_lt_anim, 100, 100, 0, 0);
+   efl_animation_translate_absolute_set(translate_lt_anim, 
EINA_POSITION2D(100, 100), EINA_POSITION2D(0, 0));
efl_animation_duration_set(translate_lt_anim, 1.0);
efl_animation_final_state_keep_set(translate_lt_anim, EINA_TRUE);
 
diff --git a/src/lib/evas/canvas/efl_canvas_animation_translate.c 
b/src/lib/evas/canvas/efl_canvas_animation_translate.c
index 39a052cf26..1a98daa60d 100644
--- a/src/lib/evas/canvas/efl_canvas_animation_translate.c
+++ b/src/lib/evas/canvas/efl_canvas_animation_translate.c
@@ -11,16 +11,12 @@ typedef struct __Translate_Property_Double
 EOLIAN static void
 _efl_canvas_animation_translate_translate_set(Eo *eo_obj EINA_UNUSED,
Efl_Canvas_Animation_Translate_Data *pd,
-   Evas_Coord from_x,
-   Evas_Coord from_y,
-   Evas_Coord to_x,
-   Evas_Coord to_y)
+   Eina_Position2D from

[EGIT] [core/efl] master 01/01: eo_base_class: move shift init to the first call

2019-10-31 Thread Marcel Hollerbach
zmike pushed a commit to branch master.

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

commit 1a621c9109796d3d5df79d6549a40b69408b9c6d
Author: Marcel Hollerbach 
Date:   Thu Oct 31 12:48:27 2019 -0400

eo_base_class: move shift init to the first call

Summary:
this cannot be evalulated in compile time, so this must be evalulated in
runtime, at the first call.

This should fix OSX build.

Co-authored-by: Cedric Bail 

Reviewers: zmike, cedric, raster

Reviewed By: zmike

Subscribers: #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D10582
---
 src/lib/eo/eo_base_class.c | 7 ++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/src/lib/eo/eo_base_class.c b/src/lib/eo/eo_base_class.c
index 39da0e8538..43068c7f19 100644
--- a/src/lib/eo/eo_base_class.c
+++ b/src/lib/eo/eo_base_class.c
@@ -1230,7 +1230,12 @@ _efl_pending_future_new(void)
 static inline unsigned char
 _pointer_hash(const uintptr_t val)
 {
-   static const unsigned char shift = (unsigned char) log2(1 + sizeof 
(Efl_Event_Description));
+   static unsigned char shift = 0;
+
+   /* Sadly LLVM doesn't have log2 in its compile time optimization. So
+  we can not use static const here for portability sake. */
+   if (EINA_UNLIKELY((!shift)))
+ shift = (unsigned char) log2(1 + sizeof (Efl_Event_Description));
 #ifdef EFL64
return (unsigned char)(((val) >> shift) & 0x3F);
 #else

-- 




[EGIT] [core/efl] master 01/01: meson: add embryo as a dep of edje

2019-10-29 Thread Marcel Hollerbach
bu5hm4n pushed a commit to branch master.

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

commit 7b59fec40e364c43573cdfd0f914cb5b31009fbd
Author: Marcel Hollerbach 
Date:   Tue Oct 29 17:52:07 2019 +0100

meson: add embryo as a dep of edje

if you want to build a edje theme without building all of efl, you can
do that now. Before embryo was missing and no scripts could be compiled.
Now this is possible and works.
---
 src/bin/edje/meson.build | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/bin/edje/meson.build b/src/bin/edje/meson.build
index f33193d655..0fff2cd6dc 100644
--- a/src/bin/edje/meson.build
+++ b/src/bin/edje/meson.build
@@ -42,7 +42,7 @@ else
 env = find_program('env', native: true)
 edje_cc_exe = [env, 'EFL_RUN_IN_TREE=1', edje_cc.full_path()]
   endif
-  edje_depends = [edje_cc, epp, evas_engine_buffer_mod]
+  edje_depends = [edje_cc, epp, evas_engine_buffer_mod, embryo_cc]
 endif
 
 edje_decc_src = [

-- 




[EGIT] [core/efl] master 01/01: meson: redo evas building

2019-10-29 Thread Marcel Hollerbach
zmike pushed a commit to branch master.

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

commit 28f630ba418719c36ea679541acc97c59cf5183c
Author: Marcel Hollerbach 
Date:   Tue Oct 29 12:54:55 2019 -0400

meson: redo evas building

Summary:
before recent times we had to support static and shared building based
on the options of the user, which forced us to complicate our build with
the evas_goal hack. the evas_goal hack more or less was the idea of
"faking" the evas build in the evas directory, finish all the .eo
generation there, then build the modules and make all the static files
ready. Then build everything in evas_goal.

Now, that we just build everything the same always, we can simply build
it in the evas way (removing the evas_goal hack FINALLY), as the same 
modules
are build statically and shared.
This also gives us the possibility to build the shared image loaders
*again* the the modules directory, which unbreaks peoples build scripts
who packaged loader files seperatly.

Reviewers: zmike, raster, cedric, stefan_schmidt

Reviewed By: zmike

Subscribers: #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D10548
---
 meson.build |  10 +-
 src/lib/evas/file/evas_module.c |  25 +---
 src/lib/evas/meson.build| 166 +++---
 src/lib/evas_goal/empty.c   |   0
 src/lib/evas_goal/meson.build   | 179 
 src/modules/evas/image_loaders/meson.build  |  23 +++
 src/modules/evas/image_savers/meson.build   |  23 +++
 src/modules/evas/meson.build|   4 +-
 src/modules/evas/model_loaders/meson.build  |  17 +--
 src/modules/evas/model_savers/meson.build   |  17 +--
 src/modules/evas/vg_loaders/meson.build |  27 +---
 src/modules/evas/vg_savers/meson.build  |  18 +--
 src/static_libs/buildsystem/buildsystem_meson.c |   4 +
 13 files changed, 210 insertions(+), 303 deletions(-)

diff --git a/meson.build b/meson.build
index 4de9757946..702e38390b 100644
--- a/meson.build
+++ b/meson.build
@@ -249,13 +249,6 @@ ecore_evas_wayland_engine_include_dir = []
 
 evas_static_list = []
 
-evas_lib = ['evas'   ,[], false,  true, false, 
false,  true,  true, ['eina', 'efl', 'eo'], ['vg_common', 'libunibreak']]
-evas_img_modules = ['evas'   ,[],  true, false, false, 
false, false, false, ['eina', 'efl', 'eo'], ['vg_common', 'libunibreak']]
-evas_engines = [join_paths('evas', 'engines'),[],  true, false, false, 
false, false, false, [], []]
-evas_goal =['evas_goal'  ,[], false,  true, false, 
false, false, false, ['eina', 'efl', 'eo'], []]
-
-evas_settings = [ evas_lib, evas_img_modules, evas_goal, evas_engines ]
-
 subprojects = [
 # name  |   option  | mod  | lib  | bin  | bench | 
tests | examples | pkg-config options | name of static libs
 ['evil' ,[], false,  true, false, false, 
false, false, [], []],
@@ -284,7 +277,8 @@ subprojects = [
 ['ector',[], false,  true, false, false,  
true, false, ['eina', 'efl'], ['draw', 'triangulator', 'freetype']],
 ['elput',['drm']   , false,  true, false, false,  
true, false, ['eina', 'eldbus'], []],
 ['ecore_drm2'   ,['drm']   , false,  true, false, false, 
false, false, ['ecore'], ['libdrm']],
-['ecore_cocoa'  ,['cocoa'] , false,  true, false, false, 
false, false, ['eina'], []]] + evas_settings +[
+['ecore_cocoa'  ,['cocoa'] , false,  true, false, false, 
false, false, ['eina'], []],
+['evas' ,[],  true,  true, false, false,  
true,  true, ['eina', 'efl', 'eo'], ['vg_common', 'libunibreak']],
 ['ecore_input_evas' ,[], false,  true, false, false, 
false, false, ['eina', 'evas'], []],
 ['ecore_evas'   ,[],  true,  true,  true, false, 
false, false, ['evas', 'ector'], []],
 ['ecore_imf',[],  true,  true, false, false, 
false, false, ['eina'], []],
diff --git a/src/lib/evas/file/evas_module.c b/src/lib/evas/file/evas_module.c
index b651ad544a..a1e8b623af 100644
--- a/src/lib/evas/file/evas_module.c
+++ b/src/lib/evas/file/evas_module.c
@@ -599,27 +599,12 @@ evas_module_find_type(Evas_Module_Type type, const char 
*name)
   {
  if (run_in_tree == 1)
{
-  // special cases due to compleixty of meson build and
-  // putting these in odd places in the tree - do special
-  // name lookups for build in tree module lookups
-  if (type == EVAS_MODULE_TYPE_IM

[EGIT] [core/efl] master 02/02: spec-suite: verify correct widget-hiding behaviour.

2019-10-28 Thread Marcel Hollerbach
zmike pushed a commit to branch master.

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

commit df653267b37e906b94aa3b826c93ba60999426b1
Author: Marcel Hollerbach 
Date:   Mon Oct 28 12:40:27 2019 -0400

spec-suite: verify correct widget-hiding behaviour.

Summary:
These checks are ensuring that when we are hiding a widget, that
everything inside these widgets are also hidden correctly. Due to
clipper or due to visibility flag.

Depends on D10468

Reviewers: zmike

Reviewed By: zmike

Subscribers: zmike, segfaultxavi, cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D10474
---
 src/tests/elementary/spec/efl_test_basics.c | 67 +
 1 file changed, 67 insertions(+)

diff --git a/src/tests/elementary/spec/efl_test_basics.c 
b/src/tests/elementary/spec/efl_test_basics.c
index 047e07d1d8..f9cf4afd69 100644
--- a/src/tests/elementary/spec/efl_test_basics.c
+++ b/src/tests/elementary/spec/efl_test_basics.c
@@ -118,9 +118,76 @@ EFL_START_TEST(no_err_on_shutdown)
 }
 EFL_END_TEST
 
+static Eina_Bool
+is_this_visible(Eo *obj)
+{
+   Eina_Size2D sz;
+
+   if (!efl_gfx_entity_visible_get(obj))
+ return EINA_FALSE;
+
+   sz = efl_gfx_entity_size_get(obj);
+   if ((!sz.w) || (!sz.h)) return EINA_FALSE;
+
+   for (Eo *clipper = efl_canvas_object_clipper_get(obj); clipper ; clipper = 
efl_canvas_object_clipper_get(clipper))
+ {
+int r,g,b,a;
+
+efl_gfx_color_get(clipper, , , , );
+
+if (!efl_gfx_entity_visible_get(clipper)) return EINA_FALSE;
+
+if (r == 0 && g == 0 && b == 0) return EINA_FALSE;
+if (a == 0) return EINA_FALSE;
+sz = efl_gfx_entity_size_get(clipper);
+if ((!sz.w) || (!sz.h)) return EINA_FALSE;
+ }
+   return EINA_TRUE;
+}
+
+EFL_START_TEST(correct_visibility_setting)
+{
+   Eo *checker = NULL;
+
+   if (efl_isa(widget, EFL_UI_FLIP_CLASS)) return; //FIXME Flip needs more 
work for this. However, flip should be redone as a spotlight manager, When this 
is done, we can add these classes to the check here.
+
+   efl_gfx_entity_size_set(widget, EINA_SIZE2D(200, 200));
+   efl_gfx_hint_size_min_set(widget, EINA_SIZE2D(200, 200));
+   efl_gfx_entity_visible_set(widget, EINA_TRUE);
+   checker = create_test_widget();
+   efl_gfx_hint_size_min_set(checker, EINA_SIZE2D(100, 100));
+
+   if (efl_isa(widget, EFL_PACK_INTERFACE))
+ {
+ efl_pack(widget, checker);
+ }
+   else if (efl_isa(widget, EFL_CONTENT_INTERFACE))
+ {
+efl_content_set(widget, checker);
+ }
+   else
+ return;
+
+   get_me_to_those_events(widget);
+
+   if (checker)
+ ck_assert_int_eq(is_this_visible(checker), EINA_TRUE);
+
+   efl_gfx_entity_visible_set(widget, EINA_FALSE);
+   get_me_to_those_events(widget);
+   if (checker)
+ ck_assert_int_eq(is_this_visible(checker), EINA_FALSE);
+
+   efl_gfx_entity_visible_set(widget, EINA_TRUE);
+   get_me_to_those_events(widget);
+   if (checker)
+ ck_assert_int_eq(is_this_visible(checker), EINA_TRUE);
+}
+EFL_END_TEST
 void
 efl_ui_widget_behavior_test(TCase *tc)
 {
tcase_add_test(tc, no_leaking_canvas_object);
tcase_add_test(tc, no_err_on_shutdown);
+   tcase_add_test(tc, correct_visibility_setting);
 }

-- 




[EGIT] [core/efl] master 01/02: efl_ui_spotlight_manager: apply vis changes to subobj

2019-10-28 Thread Marcel Hollerbach
zmike pushed a commit to branch master.

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

commit ea07d5f7da5399615139c42a05b2d9aa6bebaf50
Author: Marcel Hollerbach 
Date:   Mon Oct 28 12:40:17 2019 -0400

efl_ui_spotlight_manager: apply vis changes to subobj

Summary:
when the sportlight is hidden, the state should be applied to the
backclip and foreclip, in order to hide the subobjects correctly.

This fixes dangling showing widgets.

Reviewers: Jaehyun_Cho, zmike, segfaultxavi

Reviewed By: zmike

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D10468
---
 src/lib/elementary/efl_ui_spotlight_manager_plain.c  | 6 +++---
 src/lib/elementary/efl_ui_spotlight_manager_scroll.c | 2 ++
 src/lib/elementary/efl_ui_spotlight_manager_stack.c  | 6 +++---
 3 files changed, 8 insertions(+), 6 deletions(-)

diff --git a/src/lib/elementary/efl_ui_spotlight_manager_plain.c 
b/src/lib/elementary/efl_ui_spotlight_manager_plain.c
index ec7c3a2782..f7d81335d6 100644
--- a/src/lib/elementary/efl_ui_spotlight_manager_plain.c
+++ b/src/lib/elementary/efl_ui_spotlight_manager_plain.c
@@ -71,7 +71,7 @@ 
_efl_ui_spotlight_manager_plain_efl_ui_spotlight_manager_bind(Eo *obj, Efl_Ui_Sp
 
 for (int i = 0; i < efl_content_count(spotlight) ; ++i) {
Efl_Gfx_Entity *elem = efl_pack_content_get(spotlight, i);
-   efl_canvas_group_member_add(pd->group, elem);
+   efl_canvas_group_member_add(pd->container, elem);
efl_gfx_entity_visible_set(elem, EINA_FALSE);
 }
 index = efl_ui_spotlight_active_element_get(spotlight);
@@ -102,7 +102,7 @@ _content_changed(Eo *obj, 
Efl_Ui_Spotlight_Manager_Plain_Data *pd)
 EOLIAN static void
 _efl_ui_spotlight_manager_plain_efl_ui_spotlight_manager_content_add(Eo *obj, 
Efl_Ui_Spotlight_Manager_Plain_Data *pd, Efl_Gfx_Entity *subobj, int index 
EINA_UNUSED)
 {
-   efl_canvas_group_member_add(pd->group, subobj);
+   efl_canvas_group_member_add(pd->container, subobj);
efl_gfx_entity_visible_set(subobj, EINA_FALSE);
_content_changed(obj, pd);
 }
@@ -110,7 +110,7 @@ 
_efl_ui_spotlight_manager_plain_efl_ui_spotlight_manager_content_add(Eo *obj, Ef
 EOLIAN static void
 _efl_ui_spotlight_manager_plain_efl_ui_spotlight_manager_content_del(Eo *obj, 
Efl_Ui_Spotlight_Manager_Plain_Data *pd, Efl_Gfx_Entity *subobj, int index 
EINA_UNUSED)
 {
-   efl_canvas_group_member_remove(pd->group, subobj);
+   efl_canvas_group_member_remove(pd->container, subobj);
_content_changed(obj, pd);
 }
 EOLIAN static void
diff --git a/src/lib/elementary/efl_ui_spotlight_manager_scroll.c 
b/src/lib/elementary/efl_ui_spotlight_manager_scroll.c
index e7179a259d..1728c269d1 100644
--- a/src/lib/elementary/efl_ui_spotlight_manager_scroll.c
+++ b/src/lib/elementary/efl_ui_spotlight_manager_scroll.c
@@ -181,11 +181,13 @@ 
_efl_ui_spotlight_manager_scroll_efl_ui_spotlight_manager_bind(Eo *obj, Efl_Ui_S
 pd->foreclip = efl_add(EFL_CANVAS_RECTANGLE_CLASS,
evas_object_evas_get(group));
 evas_object_static_clip_set(pd->foreclip, EINA_TRUE);
+efl_canvas_group_member_add(spotlight, pd->foreclip);
 
 pd->backclip = efl_add(EFL_CANVAS_RECTANGLE_CLASS,
evas_object_evas_get(group));
 evas_object_static_clip_set(pd->backclip, EINA_TRUE);
 efl_gfx_entity_visible_set(pd->backclip, EINA_FALSE);
+efl_canvas_group_member_add(spotlight, pd->backclip);
 
 for (int i = 0; i < efl_content_count(spotlight) ; ++i) {
Efl_Gfx_Entity *elem = efl_pack_content_get(spotlight, i);
diff --git a/src/lib/elementary/efl_ui_spotlight_manager_stack.c 
b/src/lib/elementary/efl_ui_spotlight_manager_stack.c
index e93c82080f..811a686194 100644
--- a/src/lib/elementary/efl_ui_spotlight_manager_stack.c
+++ b/src/lib/elementary/efl_ui_spotlight_manager_stack.c
@@ -148,7 +148,7 @@ 
_efl_ui_spotlight_manager_stack_efl_ui_spotlight_manager_bind(Eo *obj, Efl_Ui_Sp
 
 for (int i = 0; i < efl_content_count(spotlight) ; ++i) {
Efl_Gfx_Entity *elem = efl_pack_content_get(spotlight, i);
-   efl_canvas_group_member_add(pd->group, elem);
+   efl_canvas_group_member_add(pd->container, elem);
efl_gfx_entity_visible_set(elem, EINA_FALSE);
 }
 if (efl_ui_spotlight_active_element_get(spotlight))
@@ -163,14 +163,14 @@ 
_efl_ui_spotlight_manager_stack_efl_ui_spotlight_manager_bind(Eo *obj, Efl_Ui_Sp
 EOLIAN static void
 _efl_ui_spotlight_manager_stack_efl_ui_spotlight_manager_content_add(Eo *obj 
EINA_UNUSED, Efl_Ui_Spotlight_Manager_Stack_Data *pd, Efl_Gfx_Entity *subobj, 
int index EINA_UNUSED)
 {
-   efl_canvas_group_member_add(pd->group, subobj);
+   efl_canvas_group_member_add(pd->container

[EGIT] [core/efl] master 02/04: elm_interface_scrollable: correctly handle bouncing

2019-10-25 Thread Marcel Hollerbach
zmike pushed a commit to branch master.

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

commit 72525c77da8aab2a426628545a76eb344964d42a
Author: Marcel Hollerbach 
Date:   Fri Oct 25 14:04:46 2019 -0400

elm_interface_scrollable: correctly handle bouncing

Summary:
if bounding is enabled, those values can get smaller and bigger than the
max value.

ref T4918

Depends on D9906

Reviewers: zmike

Reviewed By: zmike

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Maniphest Tasks: T4918

Differential Revision: https://phab.enlightenment.org/D9907
---
 src/lib/elementary/elm_interface_scrollable.c | 8 
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/src/lib/elementary/elm_interface_scrollable.c 
b/src/lib/elementary/elm_interface_scrollable.c
index 4defc707b4..05616e4cb6 100644
--- a/src/lib/elementary/elm_interface_scrollable.c
+++ b/src/lib/elementary/elm_interface_scrollable.c
@@ -479,10 +479,10 @@ 
_elm_direction_arrows_eval(Elm_Scrollable_Smart_Interface_Data *sid)
elm_obj_pan_pos_min_get(sid->pan_obj, , );
elm_obj_pan_pos_get(sid->pan_obj, , );
 
-   if (x == minx) go_left = EINA_FALSE;
-   if (x == (mx + minx)) go_right = EINA_FALSE;
-   if (y == miny) go_up = EINA_FALSE;
-   if (y == (my + miny)) go_down = EINA_FALSE;
+   if (x <= minx) go_left = EINA_FALSE;
+   if (x >= (mx + minx)) go_right = EINA_FALSE;
+   if (y <= miny) go_up = EINA_FALSE;
+   if (y >= (my + miny)) go_down = EINA_FALSE;
if (go_left != sid->go_left)
  {
 if (go_left)

-- 




[EGIT] [core/efl] master 01/04: theme: redo scroller theme of elm

2019-10-25 Thread Marcel Hollerbach
zmike pushed a commit to branch master.

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

commit a23b5452492c1af5fee07ec5d5ff376a8f264d3a
Author: Marcel Hollerbach 
Date:   Fri Oct 25 14:04:39 2019 -0400

theme: redo scroller theme of elm

Summary:
this was a little bit weird. There was a script that did what we already
do in C and pass it on via signals, however, there was also somewhere a
bug in this script, the arrow was not getting enabled, even if the
position is not completly max and not completly min, the problem here
was that the numbers that are passed to edje are not 100% correct (I
think they got somehwere on the way casted to an int).

With this commit we just use the signals from c in the theme and replace
the theme, this should also make everything a bit easier on the
mainloop, as a single movement of the scroller does not schedule 10
timers anymore.

ref T4918

Reviewers: zmike, eagleeye, woohyun

Reviewed By: zmike

Subscribers: zmike, cedric, #reviewers, #committers

Tags: #efl

Maniphest Tasks: T4918

Differential Revision: https://phab.enlightenment.org/D9906
---
 data/elementary/themes/edc/elm/scroller.edc | 177 
 1 file changed, 50 insertions(+), 127 deletions(-)

diff --git a/data/elementary/themes/edc/elm/scroller.edc 
b/data/elementary/themes/edc/elm/scroller.edc
index 091cfb1b23..71a050df29 100644
--- a/data/elementary/themes/edc/elm/scroller.edc
+++ b/data/elementary/themes/edc/elm/scroller.edc
@@ -34,91 +34,9 @@ group { name: "elm/scroller/base/default";
images.image: "sym_left_dark_normal.png" COMP;
images.image: "sym_right_dark_normal.png" COMP;
 
-
data.item: "focus_highlight" "on";
 
-   script {
-  public loop_x, loop_y;
-  public action_on_pos_vbar(val) {
- new x, y , w, h, x1, y1 , w1, h1;
-
- get_geometry(PART:"y_vbar_up", x,y,w, h);
- get_geometry(PART:"y_vbar_up_mapper", x1,y1,w1, h1);
-
- if(((y1 <= y) && (y <= (y1 + h1))) && (0 == get_int(loop_y)))
- {
-set_state(PART:"arrow1_vbar", "hidden", 0.0);
-set_state(PART:"sb_vbar_a1", "hidden", 0.0);
- }
- else
- {
-set_state(PART:"arrow1_vbar", "default", 0.0);
-set_state(PART:"sb_vbar_a1", "default", 0.0);
- }
-
- get_geometry(PART:"y_vbar_down", x,y,w, h);
- get_geometry(PART:"y_vbar_down_mapper", x1,y1,w1, h1);
-
- if(((y1 <= (y + h)) && ((y+ h) <= (y1 + h1))) && (0 == 
get_int(loop_y)))
- {
-set_state(PART:"arrow2_vbar", "hidden", 0.0);
-set_state(PART:"sb_vbar_a2", "hidden", 0.0);
- }
- else
- {
-set_state(PART:"arrow2_vbar", "default", 0.0);
-set_state(PART:"sb_vbar_a2", "default", 0.0);
- }
-
- if(val < 10)
-timer(0.1,"action_on_pos_vbar", val+1);
-  }
-
-  public action_on_pos_hbar(val) {
- new x, y , w, h, x1, y1 , w1, h1;
-
- get_geometry(PART:"x_hbar_left", x,y,w, h);
- get_geometry(PART:"x_hbar_left_mapper", x1,y1,w1, h1);
-
- if(((x1 <= x) && (x <= (x1 + w1))) && (0 == get_int(loop_x)))
- {
-set_state(PART:"arrow1_hbar", "hidden", 0.0);
-set_state(PART:"sb_hbar_a1", "hidden", 0.0);
- }
- else
- {
-set_state(PART:"arrow1_hbar", "default", 0.0);
-set_state(PART:"sb_hbar_a1", "default", 0.0);
- }
-
- get_geometry(PART:"x_hbar_right", x,y,w, h);
- get_geometry(PART:"x_hbar_right_mapper", x1,y1,w1, h1);
-
- if(((x1 <= (x + w)) && ((x + w) <= (x1 + w1))) && (0 == 
get_int(loop_x)))
- {
-set_state(PART:"arrow2_hbar", "hidden", 0.0);
-set_state(PART:"sb_hbar_a2", "hidden", 0.0);
- }
- else
- {
-set_state(PART:"arrow2_hbar", "default", 0.0);
-set_state(PART:"sb_hbar_a2", "default", 0.0);
- }
-
- if(val < 10)
-timer(0.1,"action_on_pos_hbar", val+1);
-  }
-   }
-
parts {
-  program {
- signal: "load"; source: "";
- script {
-emit("reload", "elm");
-acti

[EGIT] [core/efl] master 03/04: elm_interface_scrollable: correctly emit the signals always

2019-10-25 Thread Marcel Hollerbach
zmike pushed a commit to branch master.

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

commit ace64dafea1317da1ec3dff6ad8c8184bec50845
Author: Marcel Hollerbach 
Date:   Fri Oct 25 14:04:54 2019 -0400

elm_interface_scrollable: correctly emit the signals always

Summary:
our default theme defaults to show everything, the code here assumes
that everything is hidden by default, this fixes all this.

fix T4918

Depends on D9907

Reviewers: zmike

Reviewed By: zmike

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Maniphest Tasks: T4918

Differential Revision: https://phab.enlightenment.org/D9908
---
 src/lib/elementary/elm_interface_scrollable.c | 29 ++-
 1 file changed, 19 insertions(+), 10 deletions(-)

diff --git a/src/lib/elementary/elm_interface_scrollable.c 
b/src/lib/elementary/elm_interface_scrollable.c
index 05616e4cb6..d57c778570 100644
--- a/src/lib/elementary/elm_interface_scrollable.c
+++ b/src/lib/elementary/elm_interface_scrollable.c
@@ -467,7 +467,7 @@ _elm_scroll_smooth_debug_shutdown(void)
 }
 
 static void
-_elm_direction_arrows_eval(Elm_Scrollable_Smart_Interface_Data *sid)
+_elm_direction_arrows_eval(Elm_Scrollable_Smart_Interface_Data *sid, Eina_Bool 
rely_on_cache)
 {
Eina_Bool go_left = EINA_TRUE, go_right = EINA_TRUE;
Eina_Bool go_up = EINA_TRUE, go_down = EINA_TRUE;
@@ -483,7 +483,8 @@ 
_elm_direction_arrows_eval(Elm_Scrollable_Smart_Interface_Data *sid)
if (x >= (mx + minx)) go_right = EINA_FALSE;
if (y <= miny) go_up = EINA_FALSE;
if (y >= (my + miny)) go_down = EINA_FALSE;
-   if (go_left != sid->go_left)
+
+   if (!rely_on_cache || go_left != sid->go_left)
  {
 if (go_left)
   edje_object_signal_emit(sid->edje_obj, "elm,action,show,left", 
"elm");
@@ -491,7 +492,7 @@ 
_elm_direction_arrows_eval(Elm_Scrollable_Smart_Interface_Data *sid)
   edje_object_signal_emit(sid->edje_obj, "elm,action,hide,left", 
"elm");
 sid->go_left = go_left;
  }
-   if (go_right != sid->go_right)
+   if (!rely_on_cache || go_right != sid->go_right)
  {
 if (go_right)
   edje_object_signal_emit(sid->edje_obj, "elm,action,show,right", 
"elm");
@@ -499,7 +500,7 @@ 
_elm_direction_arrows_eval(Elm_Scrollable_Smart_Interface_Data *sid)
   edje_object_signal_emit(sid->edje_obj, "elm,action,hide,right", 
"elm");
 sid->go_right= go_right;
  }
-   if (go_up != sid->go_up)
+   if (!rely_on_cache ||go_up != sid->go_up)
  {
 if (go_up)
   edje_object_signal_emit(sid->edje_obj, "elm,action,show,up", "elm");
@@ -507,7 +508,7 @@ 
_elm_direction_arrows_eval(Elm_Scrollable_Smart_Interface_Data *sid)
   edje_object_signal_emit(sid->edje_obj, "elm,action,hide,up", "elm");
 sid->go_up = go_up;
  }
-   if (go_down != sid->go_down)
+   if (!rely_on_cache ||go_down != sid->go_down)
  {
 if (go_down)
   edje_object_signal_emit(sid->edje_obj, "elm,action,show,down", 
"elm");
@@ -587,6 +588,7 @@ 
_elm_scroll_scroll_bar_h_visibility_apply(Elm_Scrollable_Smart_Interface_Data *s
  edje_object_signal_emit(sid->edje_obj, "elm,action,hide,hbar", "elm");
edje_object_message_signal_process(sid->edje_obj);
_elm_scroll_scroll_bar_size_adjust(sid);
+   _elm_direction_arrows_eval(sid, EINA_FALSE);
if (sid->cb_func.content_min_limit)
  sid->cb_func.content_min_limit(sid->obj, sid->min_w, sid->min_h);
 }
@@ -608,6 +610,7 @@ 
_elm_scroll_scroll_bar_v_visibility_apply(Elm_Scrollable_Smart_Interface_Data *s
(sid->edje_obj, "elm,action,hide,vbar", "elm");
edje_object_message_signal_process(sid->edje_obj);
_elm_scroll_scroll_bar_size_adjust(sid);
+   _elm_direction_arrows_eval(sid, EINA_FALSE);
if (sid->cb_func.content_min_limit)
  sid->cb_func.content_min_limit(sid->obj, sid->min_w, sid->min_h);
 }
@@ -681,7 +684,7 @@ _elm_scroll_scroll_bar_h_visibility_adjust(
 
if (scroll_h_vis_change) _elm_scroll_scroll_bar_h_visibility_apply(sid);
 
-   _elm_direction_arrows_eval(sid);
+   _elm_direction_arrows_eval(sid, EINA_TRUE);
return scroll_h_vis_change;
 }
 
@@ -753,7 +756,7 @@ _elm_scroll_scroll_bar_v_visibility_adjust(
  }
if (scroll_v_vis_change) _elm_scroll_scroll_bar_v_visibility_apply(sid);
 
-   _elm_direction_arrows_eval(sid);
+   _elm_direction_arrows_eval(sid, EINA_TRUE);
return scroll_v_vis_change;
 }
 
@@ -1105,6 +1108,7 @@ 
_elm_scroll_policy_signal_emit(Elm_Scrollable_Smart_Interface_Data *sid)
(sid->edje_obj, "elm,action,show_no

[EGIT] [core/efl] master 04/04: elm_interface_scrollable: correctly honor looping over

2019-10-25 Thread Marcel Hollerbach
zmike pushed a commit to branch master.

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

commit a380a4275ac47f134c51b6a99efab7ce3931489a
Author: Marcel Hollerbach 
Date:   Fri Oct 25 14:05:00 2019 -0400

elm_interface_scrollable: correctly honor looping over

Summary:
when looping is enabled, we need to ensure that the correct arrows are
enabled.

ref D9906

Depends on D9908

Reviewers: zmike

Reviewed By: zmike

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9917
---
 src/lib/elementary/elm_interface_scrollable.c | 12 
 1 file changed, 12 insertions(+)

diff --git a/src/lib/elementary/elm_interface_scrollable.c 
b/src/lib/elementary/elm_interface_scrollable.c
index d57c778570..8a2c390f9f 100644
--- a/src/lib/elementary/elm_interface_scrollable.c
+++ b/src/lib/elementary/elm_interface_scrollable.c
@@ -484,6 +484,18 @@ 
_elm_direction_arrows_eval(Elm_Scrollable_Smart_Interface_Data *sid, Eina_Bool r
if (y <= miny) go_up = EINA_FALSE;
if (y >= (my + miny)) go_down = EINA_FALSE;
 
+   if (sid->loop_v)
+ {
+go_up = EINA_TRUE;
+go_down = EINA_TRUE;
+ }
+
+   if (sid->loop_h)
+ {
+go_right = EINA_TRUE;
+go_left = EINA_TRUE;
+ }
+
if (!rely_on_cache || go_left != sid->go_left)
  {
 if (go_left)

-- 




Re: [E-devel] Eolian property setters with return values

2019-10-21 Thread Marcel Hollerbach

On 10/21/19 5:37 PM, Tom Hacohen wrote:

I agree it's most of them, though it's not all of them. IIRC there are
some that indicate "nothing happened", at least in textblock. It
shouldn't be too hard to fix these though.

Maybe in general we need a way to mark a return/parameter as an error
indicator? It's just a half-baked thought, though maybe worth exploring.


Maybe some internal "error_flag" type from eolian, which can be 
translated to a Exception in the languages supporting them, or to a 
simple Eina_Bool in case of C ?
It can only be returned (so exceptions do work). This would also not 
mean a API/ABI break to C.




--
Tom

On 21/10/2019 17:49, Xavi Artigas wrote:

Hi people,

We are encountering a problem when matching EO properties to C# properties,
since the C# ones cannot have a return value.

We mostly use return values in EO property setters to indicate error
conditions and this is pretty easily matched to C# by throwing an
exception. We just need to know WHEN a returned bool from a setter really
means ERROR and when it is not.
Currently, all property setters in our tree returning a bool use it to
indicate an error, so it is just a matter of we all agreeing that in the
future this will always be the case (and documenting it).
If we agree on this, then the C# bindings can start throwing exceptions on
setters returning FALSE (there's a patch ready, but I cannot access it
right now).

If nobody has anything against it, I'll land this patch in a week (October
28th).

Thanks!
Xavi

___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel




___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel




___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel


[EGIT] [core/efl] master 02/05: efl_canvas_animation_player: fix double free

2019-10-11 Thread Marcel Hollerbach
zmike pushed a commit to branch master.

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

commit dd093de23cb0d0eb9b3de5513ef9881b2566efca
Author: Marcel Hollerbach 
Date:   Fri Oct 11 09:42:14 2019 -0400

efl_canvas_animation_player: fix double free

Summary:
when we are returning 0 in a animation callback, the animator will be
deleted.

This fixes a crash in tab_pager.
Depends on D10306

Reviewers: segfaultxavi

Reviewed By: segfaultxavi

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D10307
---
 src/lib/evas/canvas/efl_canvas_animation_player.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/src/lib/evas/canvas/efl_canvas_animation_player.c 
b/src/lib/evas/canvas/efl_canvas_animation_player.c
index 5e2d4046a0..e8b57cb5b9 100644
--- a/src/lib/evas/canvas/efl_canvas_animation_player.c
+++ b/src/lib/evas/canvas/efl_canvas_animation_player.c
@@ -149,6 +149,7 @@ _animator_cb(void *data)
  }
efl_player_playing_set(eo_obj, EINA_FALSE);
 
+   pd->animator = NULL;
return ECORE_CALLBACK_CANCEL;
 }
 

-- 




[EGIT] [core/efl] master 04/05: efl_ui_focus_object: do not emit focus_geometry_changed when not needed

2019-10-11 Thread Marcel Hollerbach
zmike pushed a commit to branch master.

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

commit b7432f690f86a8c38374b813d3ca497476dbd3b6
Author: Marcel Hollerbach 
Date:   Fri Oct 11 09:42:34 2019 -0400

efl_ui_focus_object: do not emit focus_geometry_changed when not needed

Summary:
this is emitted a lot of times, which costs time. Most of the time they
are however not needed. With this commit, these events are not emitted
anymore.

ref T8321

Reviewers: zmike, cedric

Reviewed By: zmike, cedric

Subscribers: #reviewers, #committers

Tags: #efl

Maniphest Tasks: T8321

Differential Revision: https://phab.enlightenment.org/D10348
---
 src/lib/elementary/efl_ui_focus_object.c | 49 
 1 file changed, 49 insertions(+)

diff --git a/src/lib/elementary/efl_ui_focus_object.c 
b/src/lib/elementary/efl_ui_focus_object.c
index 92f857897d..3c02b8c177 100644
--- a/src/lib/elementary/efl_ui_focus_object.c
+++ b/src/lib/elementary/efl_ui_focus_object.c
@@ -7,10 +7,13 @@
 #include 
 #include "elm_priv.h"
 
+#define MY_CLASS EFL_UI_FOCUS_OBJECT_MIXIN
+
 typedef struct {
   Eina_Bool old_focus;
   Eina_Bool ongoing_prepare_call;
   Eina_Bool child_focus;
+  Eina_Bool focus_geom_changed;
 } Efl_Ui_Focus_Object_Data;
 
 EOLIAN static void
@@ -65,5 +68,51 @@ _efl_ui_focus_object_child_focus_get(const Eo *obj 
EINA_UNUSED, Efl_Ui_Focus_Obj
 }
 
 
+EOLIAN static Eina_Bool
+_efl_ui_focus_object_efl_object_event_callback_priority_add(Eo *obj, 
Efl_Ui_Focus_Object_Data *pd,
+const Efl_Event_Description *desc,
+Efl_Callback_Priority priority,
+Efl_Event_Cb func,
+const void *user_data)
+{
+  if (desc == EFL_UI_FOCUS_OBJECT_EVENT_FOCUS_GEOMETRY_CHANGED)
+{
+   pd->focus_geom_changed = EINA_TRUE;
+}
+
+  return efl_event_callback_priority_add(efl_super(obj, MY_CLASS), desc, 
priority, func, user_data);
+}
+
+EOLIAN static Eina_Bool
+_efl_ui_focus_object_efl_object_event_callback_array_priority_add(Eo *obj, 
Efl_Ui_Focus_Object_Data *pd,
+  const Efl_Callback_Array_Item 
*array,
+  Efl_Callback_Priority priority,
+  const void *user_data)
+{
+   for (int i = 0; array[i].desc; ++i)
+ {
+if (array[i].desc == EFL_UI_FOCUS_OBJECT_EVENT_FOCUS_GEOMETRY_CHANGED)
+  {
+ pd->focus_geom_changed = EINA_TRUE;
+  }
+ }
+   return efl_event_callback_array_priority_add(efl_super(obj, MY_CLASS), 
array, priority, user_data);
+}
+
+
+EOLIAN static Eina_Bool
+_efl_ui_focus_object_efl_object_event_callback_call(Eo *obj, 
Efl_Ui_Focus_Object_Data *pd,
+const Efl_Event_Description *desc,
+void *event_info)
+{
+   if (desc == EFL_UI_FOCUS_OBJECT_EVENT_FOCUS_GEOMETRY_CHANGED && 
!pd->focus_geom_changed)
+ return EINA_TRUE;
+   return efl_event_callback_call(efl_super(obj, MY_CLASS), desc, event_info);
+}
+
+#define EFL_UI_FOCUS_OBJECT_EXTRA_OPS \
+   EFL_OBJECT_OP_FUNC(efl_event_callback_priority_add, 
_efl_ui_focus_object_efl_object_event_callback_priority_add), \
+   EFL_OBJECT_OP_FUNC(efl_event_callback_array_priority_add, 
_efl_ui_focus_object_efl_object_event_callback_array_priority_add), \
+   EFL_OBJECT_OP_FUNC(efl_event_callback_call, 
_efl_ui_focus_object_efl_object_event_callback_call) \
 
 #include "efl_ui_focus_object.eo.c"

-- 




[EGIT] [core/efl] master 03/03: introduce script that generates widget hirachy

2019-10-09 Thread Marcel Hollerbach
bu5hm4n pushed a commit to branch master.

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

commit 14a6611f2316814c54d6000b53669d0b35c716f9
Author: Marcel Hollerbach 
Date:   Thu Sep 5 15:51:05 2019 +0200

introduce script that generates widget hirachy

this scripts generates a .svg with a hirachy like:

https://phab.enlightenment.org/file/data/jtiilbekufvfa77taf5y/PHID-FILE-5iwtamur4qxtktrcwh77/widget_hirachy.png

blue means something is stable, red means, something is beta.

This script requires ete3 to be installed. You can install it via with
pip with: `pip install ete3`

Reviewed-by: Mike Blumenkrantz 
Differential Revision: https://phab.enlightenment.org/D9850
---
 generate_widget_header.py | 99 +++
 1 file changed, 99 insertions(+)

diff --git a/generate_widget_header.py b/generate_widget_header.py
new file mode 100755
index 00..d4a323400f
--- /dev/null
+++ b/generate_widget_header.py
@@ -0,0 +1,99 @@
+#!/usr/bin/python3
+import sys
+import os
+from ete3 import Tree, TreeStyle, AttrFace, CircleFace, faces, NodeStyle
+import argparse
+
+parser = argparse.ArgumentParser(description='Create a image showing all 
widgets')
+parser.add_argument('sourcedir', metavar='sourcedir', help='the path where to 
find efls source')
+
+G = parser.parse_args()
+sys.path.insert(0, os.path.join(G.sourcedir, 'src', 'scripts', 'pyolian'))
+
+import eolian
+from eolian import Eolian_Type_Type
+from eolian import Eolian_Type_Builtin_Type
+
+SCAN_FOLDER = os.path.join(G.sourcedir, 'src', 'lib')
+
+eolian_db = eolian.Eolian_State()
+
+if not eolian_db.directory_add(SCAN_FOLDER):
+  raise(RuntimeError('Eolian, failed to scan source directory'))
+
+# Parse all known eo files
+if not eolian_db.all_eot_files_parse():
+  raise(RuntimeError('Eolian, failed to parse all EOT files'))
+
+if not eolian_db.all_eo_files_parse():
+  raise(RuntimeError('Eolian, failed to parse all EO files'))
+
+widget = eolian_db.class_by_name_get("Efl.Ui.Widget")
+assert(widget)
+
+def is_widget(obj, rd = 0):
+  if obj == widget:
+return rd
+  elif obj.parent != None:
+return is_widget(obj.parent, rd + 1)
+  return -1
+
+list_of_widgets = []
+
+for kl in eolian_db.classes:
+  widget_depth = is_widget(kl)
+  if widget_depth != -1:
+insert = {
+  'depth' : widget_depth,
+  'name' : kl.name,
+  'eolian_obj' : kl,
+  'beta' : kl.is_beta,
+}
+list_of_widgets.append(insert)
+
+def layout(node):
+# Add node name to laef nodes
+N = AttrFace("name", fsize=9, fgcolor="black")
+faces.add_face_to_node(N, node, 0)
+
+
+class Widget_Tree():
+  def __init__(self, name, parent, is_beta):
+self.name = name
+self.children = []
+if parent != None:
+  self.parent = parent
+  parent.children.append(self)
+  self.tree_node = parent.tree_node.add_child(None, self.name, 1)
+else:
+  self.tree_node = Tree(name = self.name).add_child(None, 'Efl.Ui.Widget', 
1)
+nstyle = NodeStyle()
+if is_beta:
+  nstyle["fgcolor"] = "red"
+else:
+  nstyle["fgcolor"] = "blue"
+self.tree_node.set_style(nstyle)
+
+  def dump(self, prev):
+print(prev + self.name)
+self.children.sort(key = lambda x:x.name)
+for c in self.children:
+  c.dump(prev + " ")
+
+sorted_widgets = sorted(list_of_widgets, key=lambda x: x['depth'])
+widget_tree = {}
+
+for widget in sorted_widgets:
+  if widget['depth'] == 0:
+widget_tree[widget['name']] = Widget_Tree(widget['name'], None, 
widget['beta'])
+  else:
+widget_tree[widget['name']] = Widget_Tree(widget['name'], 
widget_tree[widget['eolian_obj'].parent.name], widget['beta'])
+
+ts = TreeStyle()
+ts.layout_fn = layout
+ts.show_leaf_name = False
+ts.show_scale = False
+
+print("Created widget-overview.svg in $CWD")
+
+widget_tree['Efl.Ui.Widget'].tree_node.render("widget-overview.svg", 
units="mm", tree_style=ts)

-- 




[EGIT] [core/efl] master 02/09: efl_ui_datepicker: no need to delete the manager here

2019-10-07 Thread Marcel Hollerbach
zmike pushed a commit to branch master.

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

commit d52e77dcb7de133e951c37c1d010399d0308fb06
Author: Marcel Hollerbach 
Date:   Mon Oct 7 09:38:05 2019 -0400

efl_ui_datepicker: no need to delete the manager here

Summary:
it is already picked up when datetime is invalidated, due to the correct
parent beeing set.

Reviewers: zmike

Reviewed By: zmike

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D10291
---
 src/lib/elementary/efl_ui_datepicker.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/src/lib/elementary/efl_ui_datepicker.c 
b/src/lib/elementary/efl_ui_datepicker.c
index 8a6ee63985..c52c43437f 100644
--- a/src/lib/elementary/efl_ui_datepicker.c
+++ b/src/lib/elementary/efl_ui_datepicker.c
@@ -247,9 +247,8 @@ _efl_ui_datepicker_efl_object_constructor(Eo *obj, 
Efl_Ui_Datepicker_Data *pd)
 }
 
 EOLIAN static void
-_efl_ui_datepicker_efl_object_destructor(Eo *obj, Efl_Ui_Datepicker_Data *pd)
+_efl_ui_datepicker_efl_object_destructor(Eo *obj, Efl_Ui_Datepicker_Data *pd 
EINA_UNUSED)
 {
-   efl_del(pd->dt_manager);
efl_destructor(efl_super(obj, MY_CLASS));
 }
 

-- 




[EGIT] [core/efl] master 03/09: efl_ui_spec: introduce tests that ensure we are not leaking objects

2019-10-07 Thread Marcel Hollerbach
zmike pushed a commit to branch master.

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

commit b0ac1ec85f7290da7f8af7ddff30b3b501325ace
Author: Marcel Hollerbach 
Date:   Mon Oct 7 09:38:12 2019 -0400

efl_ui_spec: introduce tests that ensure we are not leaking objects

Summary:
with those two tests we are checking two things:
- Check that there is no left out canvas object after the widget is
invalidated but not deleted. For now this only deals with canvas
objects.
- Additionally this also ensures that ref;del;unref as well as simple
del is never ever going to end up in a error, even with children beeing
added.

This pretty much mirrors the tests for legacy in
0d48cb46d45184608afa298f0f719e35688f , except that these tests do
not check for evas parent contsruction vs. real widget parent
construction. Which is intendet, as none-legacy widgets do error out
when a not widget object is passed as parent.
Depends on D10291

Reviewers: zmike

Reviewed By: zmike

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D10292
---
 src/tests/elementary/spec/efl_test_basics.c   | 126 ++
 src/tests/elementary/spec/efl_ui_spec_suite.h |   1 +
 src/tests/elementary/spec/meson.build |   1 +
 3 files changed, 128 insertions(+)

diff --git a/src/tests/elementary/spec/efl_test_basics.c 
b/src/tests/elementary/spec/efl_test_basics.c
new file mode 100644
index 00..047e07d1d8
--- /dev/null
+++ b/src/tests/elementary/spec/efl_test_basics.c
@@ -0,0 +1,126 @@
+#ifdef HAVE_CONFIG_H
+# include "elementary_config.h"
+#endif
+
+#include 
+#include "efl_ui_spec_suite.h"
+#include "suite_helpers.h"
+
+/* spec-meta-start
+  {"test-interface":"Efl.Ui.Widget",
+   "test-widgets": [
+ "Efl.Ui.Image",
+ "Efl.Ui.Image_Zoomable",
+ "Efl.Ui.Box",
+ "Efl.Ui.Clock",
+ "Efl.Ui.Layout",
+ "Efl.Ui.List_View",
+ "Efl.Ui.Tab_Bar",
+ "Efl.Ui.Tags",
+ "Efl.Ui.Panel",
+ "Efl.Ui.Scroller",
+ "Efl.Ui.Slider",
+ "Efl.Ui.Calendar",
+ "Efl.Ui.Check",
+ "Efl.Ui.Panes",
+ "Efl.Ui.Grid",
+ "Efl.Ui.List",
+ "Efl.Ui.Spin",
+ "Efl.Ui.Spin_Button",
+ "Efl.Ui.Spotlight.Container",
+ "Efl.Ui.Popup",
+ "Efl.Ui.Alert_Popup",
+ "Efl.Ui.Slider_Interval",
+ "Efl.Ui.Frame",
+ "Efl.Ui.Progressbar",
+ "Efl.Ui.Video",
+ "Efl.Ui.Navigation_Layout",
+ "Efl.Ui.Bg",
+ "Efl.Ui.Datepicker",
+ "Efl.Ui.Grid_Default_Item",
+ "Efl.Ui.List_Default_Item",
+ "Efl.Ui.List_Placeholder_Item",
+ "Efl.Ui.Tab_Page",
+ "Efl.Ui.Timepicker",
+ "Efl.Ui.Navigation_Bar",
+ "Efl.Ui.Relative_Layout",
+ "Efl.Ui.Animation_View",
+ "Efl.Ui.Table",
+ "Efl.Ui.Flip"
+ ],
+   "custom-mapping" : {
+  "Efl.Ui.Grid" : "EFL_UI_GRID_DEFAULT_ITEM_CLASS",
+  "Efl.Ui.List" : "EFL_UI_LIST_DEFAULT_ITEM_CLASS",
+  "Efl.Ui.Tab_Bar" : "EFL_UI_TAB_BAR_DEFAULT_ITEM_CLASS"
+}
+   }
+
+   spec-meta-end */
+
+EFL_START_TEST(no_leaking_canvas_object)
+{
+   Eina_List *not_invalidate = NULL;
+   Eina_Iterator *iter = eo_objects_iterator_new();
+   Eo *obj;
+
+   EINA_ITERATOR_FOREACH(iter, obj)
+ {
+if (!efl_alive_get(obj)) continue;
+if (!efl_isa(obj, EFL_CANVAS_OBJECT_CLASS)) continue;
+
+not_invalidate = eina_list_append(not_invalidate, obj);
+ }
+   eina_iterator_free(iter);
+
+   //now try to will those widgets
+   if (efl_isa(widget, EFL_PACK_LINEAR_INTERFACE))
+ {
+for (int i = 0; i < 30; ++i)
+  {
+ Efl_Ui_Widget *w = create_test_widget();
+ efl_pack_end(widget, w);
+  }
+ }
+   else if (efl_isa(widget, EFL_CONTENT_INTERFACE))
+ {
+efl_content_set(widget, create_test_widget());
+ }
+   else if (efl_isa(widget, EFL_TEXT_INTERFACE))
+ {
+efl_text_set(widget, "Test Things!");
+ }
+   //now reference things, and delete the widget ag

[EGIT] [core/efl] master 05/09: efl_test_multi_selectable: ensure consistant state across mode switch

2019-10-07 Thread Marcel Hollerbach
zmike pushed a commit to branch master.

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

commit 427a93c47fb6f84766952d56b80393f096d441c3
Author: Marcel Hollerbach 
Date:   Mon Oct 7 09:38:25 2019 -0400

efl_test_multi_selectable: ensure consistant state across mode switch

Summary:
When we are in multi, and switch back to single or none, we should
ensure that the state is corrently. Same applies to single -> none.

Reviewers: segfaultxavi, zmike

Reviewed By: zmike

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D10277
---
 .../elementary/spec/efl_test_multi_selectable.c| 52 ++
 1 file changed, 52 insertions(+)

diff --git a/src/tests/elementary/spec/efl_test_multi_selectable.c 
b/src/tests/elementary/spec/efl_test_multi_selectable.c
index 8f05ba1467..edd445ac5f 100644
--- a/src/tests/elementary/spec/efl_test_multi_selectable.c
+++ b/src/tests/elementary/spec/efl_test_multi_selectable.c
@@ -236,6 +236,55 @@ EFL_START_TEST(range_select2)
 }
 EFL_END_TEST
 
+EFL_START_TEST(change_mode_from_multi_to_single)
+{
+   int sel = 0;
+
+   efl_ui_selectable_select_mode_set(widget, EFL_UI_SELECT_MODE_MULTI);
+   efl_ui_selectable_all_select(widget);
+   efl_ui_selectable_select_mode_set(widget, EFL_UI_SELECT_MODE_SINGLE);
+   for (int i = 0; i < efl_content_count(widget); ++i)
+ {
+if (efl_ui_selectable_selected_get(efl_pack_content_get(widget, i)))
+  sel ++;
+ }
+   ck_assert_int_eq(sel, 1);
+}
+EFL_END_TEST
+
+
+EFL_START_TEST(change_mode_from_multi_to_none)
+{
+   int sel = 0;
+
+   efl_ui_selectable_select_mode_set(widget, EFL_UI_SELECT_MODE_MULTI);
+   efl_ui_selectable_all_select(widget);
+   efl_ui_selectable_select_mode_set(widget, EFL_UI_SELECT_MODE_NONE);
+   for (int i = 0; i < efl_content_count(widget); ++i)
+ {
+if (efl_ui_selectable_selected_get(efl_pack_content_get(widget, i)))
+  sel ++;
+ }
+   ck_assert_int_eq(sel, 0);
+}
+EFL_END_TEST
+
+EFL_START_TEST(change_mode_from_single_to_none)
+{
+   int sel = 0;
+
+   efl_ui_selectable_select_mode_set(widget, EFL_UI_SELECT_MODE_SINGLE);
+   efl_ui_selectable_all_select(widget);
+   efl_ui_selectable_select_mode_set(widget, EFL_UI_SELECT_MODE_NONE);
+   for (int i = 0; i < efl_content_count(widget); ++i)
+ {
+if (efl_ui_selectable_selected_get(efl_pack_content_get(widget, i)))
+  sel ++;
+ }
+   ck_assert_int_eq(sel, 0);
+}
+EFL_END_TEST
+
 void
 efl_ui_multi_selectable_behavior_test(TCase *tc)
 {
@@ -250,5 +299,8 @@ efl_ui_multi_selectable_behavior_test(TCase *tc)
tcase_add_test(tc, range_unselect2);
tcase_add_test(tc, range_select);
tcase_add_test(tc, range_select2);
+   tcase_add_test(tc, change_mode_from_multi_to_single);
+   tcase_add_test(tc, change_mode_from_multi_to_none);
+   tcase_add_test(tc, change_mode_from_single_to_none);
efl_ui_single_selectable_behavior_test(tc);
 }

-- 




[EGIT] [website/www-content] master 01/01: try to get rid of NOCACHE

2019-10-04 Thread Marcel Hollerbach
bu5hm4n pushed a commit to branch master.

http://git.enlightenment.org/website/www-content.git/commit/?id=2f6163e133e40448544e470e4d6cd3b9491dafb6

commit 2f6163e133e40448544e470e4d6cd3b9491dafb6
Author: Marcel Hollerbach 
Date:   Fri Oct 4 14:22:27 2019 +0200

try to get rid of NOCACHE
---
 pages/about-edi.md.txt | 1 -
 1 file changed, 1 deletion(-)

diff --git a/pages/about-edi.md.txt b/pages/about-edi.md.txt
index 21b2f5477..adf56e0df 100644
--- a/pages/about-edi.md.txt
+++ b/pages/about-edi.md.txt
@@ -1,6 +1,5 @@
 ---
 ~~Title: About Edi~~
-~~NOCACHE~~
 ---
 
 # Edi (The Enlightenment IDE) # 

-- 




[EGIT] [core/efl] efl-1.23 03/06: meson: pass correct PACKAGE_DATA_DIR

2019-10-04 Thread Marcel Hollerbach
stefan pushed a commit to branch efl-1.23.

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

commit 8d1e3661ec5ce6c176efc62d0cb5778a3b6c75b9
Author: Marcel Hollerbach 
Date:   Wed Oct 2 19:03:58 2019 +0200

meson: pass correct PACKAGE_DATA_DIR

Summary:
PACKAGE_DATA_DIR was set to the build dir instead to the elementary
specific data dir.

ref T8304

Reviewers: segfaultxavi

Reviewed By: segfaultxavi

Subscribers: segfaultxavi, cedric, #reviewers, #committers

Tags: #efl

Maniphest Tasks: T8304

Differential Revision: https://phab.enlightenment.org/D10275
---
 doc/meson.build | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/doc/meson.build b/doc/meson.build
index 068554f87b..5598b18ba3 100644
--- a/doc/meson.build
+++ b/doc/meson.build
@@ -133,7 +133,7 @@ foreach widget_preview : widget_previews
   dependencies: elementary,
   build_by_default: false,
   c_args : [
-'-DPACKAGE_DATA_DIR="'+meson.current_build_dir()+'"',
+'-DPACKAGE_DATA_DIR="'+join_paths(meson.source_root(), 'data', 
'elementary')+'"',
 '-DTESTS_BUILD_DIR="'+meson.current_build_dir()+'"',
 '-DTESTS_SRC_DIR="'+meson.current_source_dir()+'"',
 '-DDOCW_DIR="'+meson.current_build_dir()+'"']

-- 




Re: [E-devel] [EGIT] [core/efl] master 01/01: Pyolian gendoc: unbreak after recent eolian changes

2019-10-03 Thread Marcel Hollerbach
   This is super cool, thank you!

   Am 03.10.2019 20:19 schrieb Davide Andreoli :

 davemds pushed a commit to branch master.
 http://git.enlightenment.org/core/efl.git/commit/?id=b12f07e52bf5d16
 595cc3ef120ecdc8c203437fc
 commit b12f07e52bf5d16595cc3ef120ecdc8c203437fc
 Author: Dave Andreoli 
 Date:   Thu Oct 3 20:18:54 2019 +0200
 Pyolian gendoc: unbreak after recent eolian changes

 shiny new generated documentation can be seen at:
 www.gurumeditation.it/dokuwiki_efl/
 ---
 src/scripts/gendoc/doc_enum.template|  2 +-
 src/scripts/gendoc/doc_macros.include   |  4 ++--
 src/scripts/gendoc/gendoc.py| 20
 +++-
 src/scripts/pyolian/eolian.py   |  2 +-
 src/scripts/pyolian/generator.py|  2 +-
 src/scripts/pyolian/test_gen_class.template |  3 +--
 src/scripts/pyolian/test_gen_namespace.template |  2 +-
 7 files changed, 18 insertions(+), 17 deletions(-)
 diff --git a/src/scripts/gendoc/doc_enum.template
 b/src/scripts/gendoc/doc_enum.template
 index bdbb37a527..f7a11ee6c4 100644
 --- a/src/scripts/gendoc/doc_enum.template
 +++ b/src/scripts/gendoc/doc_enum.template
 @@ -33,7 +33,7 @@ enum {
 
 typedef enum {
 
 -${field.c_name}$ = ${field.value.serialize}$,
 +${field.c_constant}$ = ${field.value.serialize}$,
 
 } ${enum.name.replace('.', '_')}$;
 
 diff --git a/src/scripts/gendoc/doc_macros.include
 b/src/scripts/gendoc/doc_macros.include
 index 64b5311e5a..507693179a 100644
 --- a/src/scripts/gendoc/doc_macros.include
 +++ b/src/scripts/gendoc/doc_macros.include
 @@ -178,8 +178,8 @@ interface#!
 #!  FUNC_SCOPE(func)
 ##
 #!##
 
 
 -   
 - ''class method'' #!
 +   
 + ''static method'' #!
 
 

 diff --git a/src/scripts/gendoc/gendoc.py
 b/src/scripts/gendoc/gendoc.py
 index 2ebaa605d4..bee5161f0b 100755
 --- a/src/scripts/gendoc/gendoc.py
 +++ b/src/scripts/gendoc/gendoc.py
 @@ -41,7 +41,7 @@ _choices = ['start', 'classes', 'enums',
 'structs', 'aliases']
 parser.add_argument('--step', '-s', metavar='STEP', default=None,
  choices=_choices,
  help='A single step to run (default to all), '
 - 'valid choices: '+ ', '.join(_choices))
 + 'valid choices: ' + ', '.join(_choices))
 args = parser.parse_args()
 @@ -64,6 +64,8 @@ if not eolian_db.all_eo_files_parse():
 def cleanup_db():
  global eolian_db
  del eolian_db
 +
 +
 atexit.register(cleanup_db)
 @@ -72,14 +74,14 @@ def page_path_for_object(obj):
  path = ['data', 'pages', 'develop', 'api']
  for ns in obj.namespaces:
  path.append(ns.lower())
 -output_file = obj.short_name.lower() + '.txt'
 -return os.path.join(args.root_path, *path, output_file)
 +output_filename = obj.short_name.lower() + '.txt'
 +return os.path.join(args.root_path, *path, output_filename)
 # render a (temporary) page for analizying the namespaces hierarchy
 t = Template('namespaces.template')
 -nspaces = [ ns for ns in eolian_db.all_namespaces
 -if ns.name.startswith(args.namespace) ]
 +nspaces = [ns for ns in eolian_db.all_namespaces
 +   if ns.name.startswith(args.namespace)]
 tot_classes = tot_regulars = tot_abstracts = tot_mixins = tot_ifaces
 = 0
 tot_enums = tot_structs = tot_aliases = 0
 @@ -113,7 +115,7 @@ totals = [
 root_ns = eolian_db.namespace_get_by_name(args.namespace)
 -output_file =
 os.path.join(args.root_path,'data','pages','develop','api','namespac
 es.txt')
 +output_file = os.path.join(args.root_path, 'data', 'pages',
 'develop', 'api', 'namespaces.txt')
 t.render(output_file, args.verbose, root_ns=root_ns, totals=totals)
 @@ -121,10 +123,10 @@ t.render(output_file, args.verbose,
 root_ns=root_ns, totals=totals)
 if args.step in ('start', None):
  t = Template('doc_start.template')
 -nspaces = [ ns for ns in eolian_db.all_namespaces
 -if ns.name.startswith(args.namespace) ]
 +nspaces = [ns for ns in eolian_db.all_namespaces
 +   if ns.name.startswith(args.namespace)]
 -output_file =
 os.path.join(args.root_path,'data','pages','develop','api','start.tx
 t')
 +output_file = os.path.join(args.root_path, 'data', 'pages',
 'develop', 'api', 'start.txt')
  t.render(output_file, args.verbose, nspaces=nspaces)
 diff --git a/src/scripts/pyolian/eolian.py
 

[EGIT] [website/www] master 01/01: pagetitle: remove action.php

2019-10-03 Thread Marcel Hollerbach
bu5hm4n pushed a commit to branch master.

http://git.enlightenment.org/website/www.git/commit/?id=c8cab04139f93b35525ce4f8ffd00069ac473a26

commit c8cab04139f93b35525ce4f8ffd00069ac473a26
Author: Marcel Hollerbach 
Date:   Thu Oct 3 17:47:29 2019 +0200

pagetitle: remove action.php

this file has some logic in it that causes caches to be invalidated and
purged. With this commit things are quite fast.
---
 public_html/lib/plugins/pagetitle/action.php | 142 ---
 1 file changed, 142 deletions(-)

diff --git a/public_html/lib/plugins/pagetitle/action.php 
b/public_html/lib/plugins/pagetitle/action.php
deleted file mode 100644
index 9c00b388..
--- a/public_html/lib/plugins/pagetitle/action.php
+++ /dev/null
@@ -1,142 +0,0 @@
-http://www.gnu.org/licenses/gpl.html)
- * @author Satoshi Sahara 
- */
-
-if(!defined('DOKU_INC')) die();
-
-class action_plugin_pagetitle extends DokuWiki_Action_Plugin {
-
-/**
- * register the event handlers
- */
-function register(Doku_Event_Handler $controller) {
-  //$controller->register_hook('DOKUWIKI_STARTED', 'BEFORE', $this, 
'deleteObsoletedSingleClass');
-$controller->register_hook('INDEXER_VERSION_GET', 'BEFORE', $this, 
'_indexer_version');
-$controller->register_hook('INDEXER_PAGE_ADD', 'BEFORE', $this, 
'_indexer_pagetitle');
-$controller->register_hook('PARSER_METADATA_RENDER', 'AFTER', $this, 
'_parser_render');
-$controller->register_hook('PARSER_CACHE_USE', 'BEFORE', $this, 
'_prepare_cache');
-}
-
-/**
- * Delete syntax.php which is obsoleted since multi-components syntax 
structure
- */
-function deleteObsoletedSingleClass(Doku_Event $event) {
-$legacyFile = dirname(__FILE__).'/syntax.php';
-if (file_exists($legacyFile)) { unlink($legacyFile); }
-}
-
-
-/**
- * INDEXER_VERSION_GET
- * Set a version string to the metadata index so that
- * the index will be re-created when the version increased
- */
-function _indexer_version(Doku_Event $event, $param) {
-$event->data['plgin_pagetitle'] = '1.'.$this->getConf('usePersistent');
-}
-
-/**
- * INDEXER_PAGE_ADD
- * Add id of the page to metadata index, relevant pages should be found
- * in data/index/plugin_pagetitle_w.idx file
- */
-function _indexer_pagetitle(Doku_Event $event, $param) {
-$id = p_get_metadata($event->data['page'], 'plugin pagetitle');
-if ($id) {
-$event->data['metadata']['plugin_pagetitle'] = $id;
-}
-}
-
-
-/**
- * PAESER_METADATA_RENDER
- * Use this event to update/reflesh metadata they may have set elseware.
- * The page metadata is passed including both the current and persistent 
arrays.
- */
-function _parser_render(Doku_Event $event, $param) {
-global $ID;
-
-/*
- * The PageTitle plugin will overwrite "title" metadata of the page
- * with "pagetitle" specified in page source. The page must be rendered
- * first in xhtml mode to get pagetitle and to stote it on metadata
- * storage.
- 
- * Each metadata storage (.meta file) may be expired or refleshed by
- * DokuWiki or any plugins at elsewhere in any stage. For example,
- * metadata will be expired when main config modified. DokuWiki will 
set
- * again title metadata through calls p_get_first_heading() depending 
on
- * $conf['useheading"] setting.
- *
- * Since page text is not changed, instruction and xhtml cache files 
are
- * used to set title metadata, there is no chance to handle/render page
- * source to get pagetitle and to overwite title metadata.
- * Therfore, the value of "title" metadata will remain wrong with that
- * pagetitle plugin intended.
- *
- * For the purpose to trigger PageTitle plugin's renderer, we 
tentatively
- * set $ID as "title" to tell DokuWiki caching mechanism so that old
- * cache need to be purged and metadata must be rebuild again.
- */
-
-$meta   =& $event->data['current'];
-$persistent =& $event->data['persistent'];
-
-// check metadata index whether pagetitle had used in the wiki page
-$pages = idx_get_indexer()->getPages('plugin_pagetitle');
-$pageTitled = in_array($ID, $pages);
-
-if (!$pageTitled) return;
-
-// check whether page has rendered by pagetitle plugin
-if (!isset($meta['plugin']['pagetitle'])) {
-// tentatively assign full id as page title, just to distinguish
-// with normal setting noNS($ID) and to purge .meta file later
-$meta['title'] = $ID;
-}
-
-// unnecessary persistent metadata should be removed in syntax 
component,
-//

Re: [E-devel] RFC: Text interface + advice regarding interface splitting

2019-10-03 Thread Marcel Hollerbach



On 10/1/19 10:09 AM, Tom Hacohen wrote:

Hey,

Sorry for the delay, and thanks for your feedback! Comments are inline.

Just one thing though, while you provided a lot of very valuable
comments, you haven't solved my issue with splitting interfaces, which
is the main thing blocking my work ("the advice"). Any comments on that?



On 27/09/2019 15:22, Marcel Hollerbach wrote:

Hi,

after a long read:


Sorry, there's a lot there. :)


- efl2_text_attribute_factory:
     - Why having a struct here as handle, i fear that bindings will have
a very hard time with this, where you actually pass in a struct to the
remove method, and this one is dead after it.


What's your suggested alternative? Anyhow, why would bindings have a
hard time? Structs have associated free functions and ref/unref, no? I'm
happy with an alternative, but I'd need a lightweight handle for this.


Lets say you have a situation in a binded language where you have stored 
a reference to this struct in a variable, someone else frees it. What is 
now happening when you access this variable in the binded language ? How 
can the binded language protect against that while keeping the idea of 
having it as a lightweight handle. (The problem is basically classic use 
after free, with 2 people having a ref to the struct).


For normal eo objects this is solved by invalidate etc. etc. If we now 
start to use structs like this, we also need a solution to that problem 
for the binded languages, which basically invalidates the argument of 
them beeing leightweight handles.


My suggested alternative is just making them a normal eo object, OR 
making it not a struct pointer you return but rather some unique ID, 
which does not have the problem of unprotected accessing (Definitly the 
more leightweight option.)





     - Its also not clear to me how explicit remove plays well with unref.


Remove: removes it from the text object. This means the handle is still
alive, just disassociated from the text object so it doesn't affect it
anymore.

Unref: reduces the refcount in case you reffed it before. Used for when
you kept your own copies.


Okay, and a handle that is not assosiated with a text object is just 
waiting for complete deletion ?





     - the `insert` method should return a owned struct handle ? Or is
the user never really owning any of the structs there ?


It's not owned. If you want to use it, you need to immediately ref it
after it's returned from there. It's done this way so you can safely
ignore the return value when you don't want it, but also use it when you do.


Oh okay, that was not clear to me.




- efl2_text_font_properties / style_properties: (I have criticized the
names before, i like the new names.) However, hard to comment more, as i
do not know much about text property stuff itself.


No worries, these ones are actually less of a problem for me.


- efl2_text_wrap_properties: Can you document what impact ellipsis and
wrap do have ?


As in: you have questions, or just commenting about the lack of docs?


As in: I do not understand what the different properties do result in.


- efl2_text_markup:
     - I am not entirely sure how item_factory works here. Is the
item_factory knowing to which Efl2.Text_Markup they belong ? If so,
shoudnt that be expressed somehow ?


Not sure I understand your question.


If each item_factory belongs to exactly one Efl2.Text_Markup object.
Then the factory should probebly be owned by the Efl2.Text_Markup object 
in order to support correct destruction etc.





- efl2_text_item_factory:
     - Again, why having a struct here, same as above applies to this.


Same answer as before. :)


see above ... :P




- efl2_text_raw_editable:
     - Where does this object belong ? We normally only have objects in
efl.canvas / ui / layout. But not in efl. itself.


Happy to rename it, though dunno what to. It's somewhere between canvas
and ui. It's above canvas as it handles input and deals with X, but
below UI because it doesn't have a theme.


Sounds like a thing for efl.layout ?




     - Is it doing undo/redo or only emitting the events ?


At the moment just events, but Ali is going to fix this.


- efl2_ui_text:
     - Why are here cnp related events ? Isnt that just a normal
insertion / copy operation ? The cut and copy operation could be on a
object that handles cnp, the paste operation as well, paired with a
changed,user event?


Fair comment, need to re-evaluate that.



General notes:
- you used a lot of ptr(...), you cannot use them when you remove @beta
from the file. These files should not use ptr, nor void_ptr.


I know. :(
I created my branch before there was an alternative (very recently), and
haven't updated anything yet.


- You have a few places where you have explicitly x,y,w,h (x,y) in your
API, can you replace them with rect (position) handles from eina, that
would make it more aligned with the rest of efl.



Could you please provide an example?


I think you re

[EGIT] [core/efl] master 01/01: meson: pass correct PACKAGE_DATA_DIR

2019-10-02 Thread Marcel Hollerbach
xartigas pushed a commit to branch master.

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

commit 914135a6db9fd199c8cd69501fc7102a39a97921
Author: Marcel Hollerbach 
Date:   Wed Oct 2 19:03:58 2019 +0200

meson: pass correct PACKAGE_DATA_DIR

Summary:
PACKAGE_DATA_DIR was set to the build dir instead to the elementary
specific data dir.

ref T8304

Reviewers: segfaultxavi

Reviewed By: segfaultxavi

Subscribers: segfaultxavi, cedric, #reviewers, #committers

Tags: #efl

Maniphest Tasks: T8304

Differential Revision: https://phab.enlightenment.org/D10275
---
 doc/meson.build | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/doc/meson.build b/doc/meson.build
index 068554f87b..5598b18ba3 100644
--- a/doc/meson.build
+++ b/doc/meson.build
@@ -133,7 +133,7 @@ foreach widget_preview : widget_previews
   dependencies: elementary,
   build_by_default: false,
   c_args : [
-'-DPACKAGE_DATA_DIR="'+meson.current_build_dir()+'"',
+'-DPACKAGE_DATA_DIR="'+join_paths(meson.source_root(), 'data', 
'elementary')+'"',
 '-DTESTS_BUILD_DIR="'+meson.current_build_dir()+'"',
 '-DTESTS_SRC_DIR="'+meson.current_source_dir()+'"',
 '-DDOCW_DIR="'+meson.current_build_dir()+'"']

-- 




[EGIT] [core/efl] master 01/01: elm: add basics test to create a destroy *every* widget with errors

2019-10-02 Thread Marcel Hollerbach
xartigas pushed a commit to branch master.

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

commit 0d48cb46d45184608afa298f0f719e35688f
Author: Marcel Hollerbach 
Date:   Wed Oct 2 17:05:36 2019 +0200

elm: add basics test to create a destroy *every* widget with errors

Summary:
this simply creates packs, resizes, and destroys every single widget
that we have in legacy elm.

This i made to ensure that there are no mistakes in the construction
chain. Additionally, a second test case checks that creation with none
elm parents is erroring but not failing, this seems weird, but we have
provided that in the past, so we should continue providing this.

Reviewers: zmike, segfaultxavi

Reviewed By: zmike, segfaultxavi

Subscribers: segfaultxavi, cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D10088
---
 src/tests/elementary/elm_suite.c  |   1 +
 src/tests/elementary/elm_suite.h  |   1 +
 src/tests/elementary/elm_test_widget_basics.c | 137 ++
 src/tests/elementary/meson.build  |   3 +-
 4 files changed, 141 insertions(+), 1 deletion(-)

diff --git a/src/tests/elementary/elm_suite.c b/src/tests/elementary/elm_suite.c
index 87fac6e4e1..d6aa4636e8 100644
--- a/src/tests/elementary/elm_suite.c
+++ b/src/tests/elementary/elm_suite.c
@@ -86,6 +86,7 @@ static const Efl_Test_Case etc[] = {
   { "elm_code_widget_selection", elm_code_test_widget_selection },
   { "elm_code_widget_undo", elm_code_test_widget_undo },
   { "elm_widget_focus", elm_test_widget_focus},
+  { "elm_widget_basics", elm_test_widget_basics},
   { NULL, NULL }
 };
 
diff --git a/src/tests/elementary/elm_suite.h b/src/tests/elementary/elm_suite.h
index ba76b29615..67f5d0d5c4 100644
--- a/src/tests/elementary/elm_suite.h
+++ b/src/tests/elementary/elm_suite.h
@@ -84,6 +84,7 @@ void elm_test_slideshow(TCase *tc);
 void elm_test_spinner(TCase *tc);
 void elm_test_plug(TCase *tc);
 void elm_test_widget_focus(TCase *tc);
+void elm_test_widget_basics(TCase *tc);
 
 void elm_code_file_test_load(TCase *tc);
 void elm_code_file_test_memory(TCase *tc);
diff --git a/src/tests/elementary/elm_test_widget_basics.c 
b/src/tests/elementary/elm_test_widget_basics.c
new file mode 100644
index 00..12f439d0b3
--- /dev/null
+++ b/src/tests/elementary/elm_test_widget_basics.c
@@ -0,0 +1,137 @@
+#ifdef HAVE_CONFIG_H
+# include "elementary_config.h"
+#endif
+
+#include 
+#include "elm_suite.h"
+
+typedef struct _Simple_Test_Widget
+{
+   Evas_Object* (*constructor)(Evas_Object *win);
+   const char *name;
+} Simple_Test_Widget;
+
+
+static const Simple_Test_Widget simple_widgets[] = {
+  {elm_flip_add, "flip"},
+  {elm_frame_add, "frame"},
+  {elm_player_add, "player"},
+  {elm_video_add, "video"},
+  {elm_ctxpopup_add, "ctxpopup"},
+  {elm_fileselector_add, "fileselector"},
+  {elm_hoversel_add, "hoversel"},
+  {elm_multibuttonentry_add, "multibuttonentry"},
+  {elm_naviframe_add, "naviframe"},
+  {elm_popup_add, "popup"},
+  {elm_actionslider_add, "actionslider"},
+  {elm_bg_add, "bg"},
+  {elm_box_add, "box"},
+  {elm_bubble_add, "bubble"},
+  {elm_calendar_add, "calendar"},
+  {elm_button_add, "button"},
+  {elm_check_add, "check"},
+  {elm_clock_add, "clock"},
+  {elm_colorselector_add, "colorselector"},
+  {elm_conformant_add, "conformant"},
+  {elm_dayselector_add, "dayselector"},
+  {elm_entry_add, "entry"},
+  {elm_flipselector_add, "flipselector"},
+  {elm_gengrid_add, "gengrid"},
+  {elm_genlist_add, "genlist"},
+  {elm_grid_add, "grid"},
+  {elm_hover_add, "hover"},
+  {elm_icon_add, "icon"},
+  {elm_image_add, "image"},
+  {elm_index_add, "index"},
+  {elm_label_add, "label"},
+  {elm_layout_add, "layout"},
+  {elm_list_add, "list"},
+  {elm_map_add, "map"},
+  {elm_mapbuf_add, "mapbuf"},
+  {elm_menu_add, "menu"},
+  {elm_notify_add, "notify"},
+  {elm_panel_add, "panel"},
+  {elm_panes_add, "panes"},
+  {elm_photo_add, "photo"},
+  {elm_photocam_add, "photocam"},
+  {elm_plug_add, "plug"},
+  {elm_prefs_add, "prefs"},
+  {elm_progressbar_add, "progressbar"},
+  {elm_radio_add, "radio"},
+  {elm_route_add, "route"},
+  {elm_separator_add, "seperator"},
+  {elm_slider_add, "slider"},
+  {elm_slideshow_add, "slideshow"},
+  {elm_spinner_add, "spinner"},
+  

[EGIT] [core/efl] master 01/01: meson: support mono bindings building without cxx

2019-10-01 Thread Marcel Hollerbach
lauromoura pushed a commit to branch master.

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

commit cc4aa8ccaa055ef81714c8e63bdee582c4c94284
Author: Marcel Hollerbach 
Date:   Tue Oct 1 09:57:04 2019 -0300

meson: support mono bindings building without cxx

Summary:
the mono bindings do depend partitially on the cxx bindings, eina_cxx
and eolian_cxx are needed, nothing more. With this commit you can build
mono without cxx.

fixes T8292

Reviewers: lauromoura

Reviewed By: lauromoura

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Maniphest Tasks: T8292

Differential Revision: https://phab.enlightenment.org/D10264
---
 meson.build  | 11 +--
 src/bindings/meson.build | 20 
 2 files changed, 21 insertions(+), 10 deletions(-)

diff --git a/meson.build b/meson.build
index f7afdfb11a..55270cda23 100644
--- a/meson.build
+++ b/meson.build
@@ -440,16 +440,7 @@ if sys_windows == false
   subdir(join_paths('src', 'generic', 'emotion'))
 endif
 subdir('cmakeconfig')
-
-bindings = get_option('bindings')
-bindings_order = ['luajit', 'cxx', 'mono']
-
-foreach binding : bindings_order
-  if bindings.contains(binding)
-subdir(join_paths('src', 'bindings', binding))
-  endif
-endforeach
-
+subdir(join_paths('src', 'bindings'))
 subdir(join_paths('src', 'edje_external'))
 subdir(join_paths('data'))
 
diff --git a/src/bindings/meson.build b/src/bindings/meson.build
new file mode 100644
index 00..e6a59d1559
--- /dev/null
+++ b/src/bindings/meson.build
@@ -0,0 +1,20 @@
+
+bindings = get_option('bindings')
+bindings_order = ['luajit', 'cxx', 'mono']
+
+if (bindings.contains('cxx') == false and bindings.contains('mono'))
+  subdirs = ['eina_cxx', 'eolian_cxx']
+  subdir(join_paths('cxx', 'eina_cxx'))
+  inc_dir = []
+  subdir(join_paths('cxx', 'eolian_cxx'))
+  eolian_cxx = declare_dependency(
+include_directories: inc_dir,
+dependencies : eolian
+  )
+endif
+
+foreach binding : bindings_order
+  if bindings.contains(binding)
+subdir(join_paths( binding))
+  endif
+endforeach

-- 




[EGIT] [core/efl] master 01/01: docs: do not crash gengrid widget preview

2019-10-01 Thread Marcel Hollerbach
stefan pushed a commit to branch master.

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

commit d10f0ee3b92433cec6e01f47448ba25db82d6ac4
Author: Marcel Hollerbach 
Date:   Tue Oct 1 11:27:58 2019 +0200

docs: do not crash gengrid widget preview

item class is not initialized to 0. This can crash gengrid later on.

Reviewed-by: Stefan Schmidt 
Differential Revision: https://phab.enlightenment.org/D10261
---
 doc/widgets/widget_preview_gengrid.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/doc/widgets/widget_preview_gengrid.c 
b/doc/widgets/widget_preview_gengrid.c
index 14f00b30ba..fd8c4e0372 100644
--- a/doc/widgets/widget_preview_gengrid.c
+++ b/doc/widgets/widget_preview_gengrid.c
@@ -38,7 +38,7 @@ evas_object_size_hint_weight_set(gengrid, EVAS_HINT_EXPAND, 
EVAS_HINT_EXPAND);
 elm_win_resize_object_add(win, gengrid);
 evas_object_show(gengrid);
 
-Elm_Gengrid_Item_Class gic;
+Elm_Gengrid_Item_Class gic = { 0 };
 gic.item_style = "default";
 gic.func.text_get = _grid_text_get;
 gic.func.content_get = _grid_content_get;

-- 




[EGIT] [core/efl] master 01/01: efl_canvas_animation_player: improve docs

2019-09-30 Thread Marcel Hollerbach
xartigas pushed a commit to branch master.

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

commit f324e9fc1155489444e775461fa8db7ebc300c42
Author: Marcel Hollerbach 
Date:   Mon Sep 30 17:03:01 2019 +0200

efl_canvas_animation_player: improve docs

Reviewers: segfaultxavi

Reviewed By: segfaultxavi

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D10250
---
 src/lib/evas/canvas/efl_canvas_animation_player.eo | 26 +-
 1 file changed, 16 insertions(+), 10 deletions(-)

diff --git a/src/lib/evas/canvas/efl_canvas_animation_player.eo 
b/src/lib/evas/canvas/efl_canvas_animation_player.eo
index 361dfcbad5..9a391cb874 100644
--- a/src/lib/evas/canvas/efl_canvas_animation_player.eo
+++ b/src/lib/evas/canvas/efl_canvas_animation_player.eo
@@ -1,13 +1,19 @@
 class @beta Efl.Canvas.Animation_Player extends Efl.Object implements 
Efl.Player, Efl.Playable
 {
-   [[Efl animation object class]]
+   [[Player object for playing canvas animations.
+
+ This player object can be used to play animations on a @.target canvas 
object.
+ The type of animation depends on the @.animation object.
+   ]]
c_prefix: efl_animation_player;
methods {
   @property animation {
- set {}
- get {}
+ [[The animation to play.
+
+   This animation object will be used to change the visual state of 
the @.target object.
+ ]]
  values {
-animation: Efl.Canvas.Animation;
+animation: Efl.Canvas.Animation; [[An already-configured animation 
object.]]
  }
   }
   @property auto_del {
@@ -22,13 +28,13 @@ class @beta Efl.Canvas.Animation_Player extends Efl.Object 
implements Efl.Player
  }
   }
   @property target {
- [[Target object property]]
- set {
- }
- get {
- }
+ [[The canvas object to apply the effects of the @.animation object on.
+
+   The @.animation object can change several properties of the $target.
+   You should ensure that nothing else is trying to change them too.
+ ]]
  values {
-target: Efl.Canvas.Object; [[Target object which is applied 
animation.]]
+target: Efl.Canvas.Object; [[Canvas object to animate.]]
  }
   }
}

-- 




[EGIT] [core/efl] master 04/06: elm_code_widget: initialize these vars correctly

2019-09-30 Thread Marcel Hollerbach
stefan pushed a commit to branch master.

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

commit 9bc9eff716a4fde5514bf4a9225a25a9dd11e2d0
Author: Marcel Hollerbach 
Date:   Fri Sep 27 16:32:25 2019 +0200

elm_code_widget: initialize these vars correctly

otherwise we are setting a cursor from time to time at a uninitialized
position. Which causes disappeared cursors

Reviewed-by: Stefan Schmidt 
Differential Revision: https://phab.enlightenment.org/D10224
---
 src/lib/elementary/elm_code_widget.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/lib/elementary/elm_code_widget.c 
b/src/lib/elementary/elm_code_widget.c
index 17ee786791..7979a4d28a 100644
--- a/src/lib/elementary/elm_code_widget.c
+++ b/src/lib/elementary/elm_code_widget.c
@@ -311,7 +311,7 @@ _elm_code_widget_fill_whitespace(Elm_Code_Widget *widget, 
Eina_Unicode character
 static void
 _elm_code_widget_cursor_update(Elm_Code_Widget *widget, Elm_Code_Widget_Data 
*pd)
 {
-   Evas_Coord cx, cy, cw, ch;
+   Evas_Coord cx = 0, cy = 0, cw = 0, ch = 0;
 
elm_code_widget_geometry_for_position_get(widget, pd->cursor_line, 
pd->cursor_col, , , , );
 

-- 




[EGIT] [core/efl] master 05/06: elm_code_widget: when the position is updated, set new geom to cursor

2019-09-30 Thread Marcel Hollerbach
stefan pushed a commit to branch master.

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

commit 8de8f059c94f1edc718d59a5fa53bfec26c7c31d
Author: Marcel Hollerbach 
Date:   Fri Sep 27 16:33:35 2019 +0200

elm_code_widget: when the position is updated, set new geom to cursor

in order to do that, we need to ensure that the internal box is
calculated, otherwise the position is still not updated correctly.
This fixes wrong cursor positions in edi.

fixes T8214

Reviewed-by: Stefan Schmidt 
Differential Revision: https://phab.enlightenment.org/D10225
---
 src/lib/elementary/elm_code_widget.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/src/lib/elementary/elm_code_widget.c 
b/src/lib/elementary/elm_code_widget.c
index 7979a4d28a..30c87327a6 100644
--- a/src/lib/elementary/elm_code_widget.c
+++ b/src/lib/elementary/elm_code_widget.c
@@ -542,6 +542,8 @@ _elm_code_widget_refresh(Elm_Code_Widget *widget, 
Elm_Code_Line *line)
  return ;
 
_elm_code_widget_fill_update(widget, first_row, last_row, line);
+   if (pd->editable)
+ _elm_code_widget_cursor_update(widget, pd);
 }
 
 static void
@@ -798,6 +800,7 @@ _elm_code_widget_geometry_for_position_get(Elm_Code_Widget 
*widget, Elm_Code_Wid
gutter = efl_ui_code_widget_text_left_gutter_width_get(widget);
 
grid = eina_list_nth(pd->grids, row - 1);
+   evas_object_smart_calculate(pd->gridbox);
evas_object_geometry_get(grid, x, y, NULL, NULL);
 
if (x)

-- 




[EGIT] [core/efl] master 01/06: test_code: do not create a background by hand

2019-09-30 Thread Marcel Hollerbach
stefan pushed a commit to branch master.

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

commit 93d77015c4b0220ec9490e0855eef0e2f9eb4dc3
Author: Marcel Hollerbach 
Date:   Fri Sep 27 16:31:47 2019 +0200

test_code: do not create a background by hand

the background here was wrong, it hasnt resizable hints, which means
that the whole object cannot be resized.

Reviewed-by: Stefan Schmidt 
Differential Revision: https://phab.enlightenment.org/D10223
---
 src/bin/elementary/test_code.c | 8 ++--
 1 file changed, 2 insertions(+), 6 deletions(-)

diff --git a/src/bin/elementary/test_code.c b/src/bin/elementary/test_code.c
index 076ef6d27d..ca26ca6cd6 100644
--- a/src/bin/elementary/test_code.c
+++ b/src/bin/elementary/test_code.c
@@ -6,16 +6,12 @@
 
 static Evas_Object *_test_code_win_create(const char *id, const char *name)
 {
-   Evas_Object *win, *bg;
+   Evas_Object *win;
 
-   win = elm_win_add(NULL, id, ELM_WIN_BASIC);
+   win = elm_win_util_standard_add(id, name);
elm_win_title_set(win, name);
elm_win_autodel_set(win, EINA_TRUE);
 
-   bg = elm_bg_add(win);
-   elm_win_resize_object_add(win, bg);
-   evas_object_show(bg);
-
evas_object_resize(win, 360 * elm_config_scale_get(), 220 * 
elm_config_scale_get());
return win;
 }

-- 




[EGIT] [core/efl] master 01/01: elm_*: make scrolling correct again

2019-09-28 Thread Marcel Hollerbach
bu5hm4n pushed a commit to branch master.

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

commit a864d62ecfeb09177cc4f4d311351477879e229e
Author: Marcel Hollerbach 
Date:   Sat Sep 28 18:02:56 2019 +0200

elm_*: make scrolling correct again

in revision D9859 the scroll events have been renamed. However this also
renamed the legacy widgets, which also renamed the evas smart events,
which is a bug. With this commit we are back to plain old
evas_smart_callback_call calls, as these just take the string, and do
not need the bypassing through the eo events.

This fixes:
- elm_test gengrid,toolbar,panel (the events are now shown correctly
again)
- scrolling in elm_code_widget
- elm_map in a touchscreen

Reviewed-by: Mike Blumenkrantz 
Differential Revision: https://phab.enlightenment.org/D10240
---
 src/lib/elementary/elm_entry.c|  3 +--
 src/lib/elementary/elm_gengrid.c  | 10 +-
 src/lib/elementary/elm_genlist.c  | 10 +-
 src/lib/elementary/elm_map.c  | 15 +--
 src/lib/elementary/elm_panel.c|  3 +--
 src/lib/elementary/elm_scroller.c | 16 ++--
 src/lib/elementary/elm_toolbar.c  | 10 +-
 7 files changed, 28 insertions(+), 39 deletions(-)

diff --git a/src/lib/elementary/elm_entry.c b/src/lib/elementary/elm_entry.c
index 28fcd55542..4cbf725cfb 100644
--- a/src/lib/elementary/elm_entry.c
+++ b/src/lib/elementary/elm_entry.c
@@ -5149,8 +5149,7 @@ _scroll_cb(Evas_Object *obj, void *data EINA_UNUSED)
 {
ELM_ENTRY_DATA_GET(obj, sd);
/* here we need to emit the signal that the elm_scroller would have done */
-   efl_event_callback_legacy_call
- (obj, EFL_UI_EVENT_SCROLL_CHANGED, NULL);
+   evas_object_smart_callback_call(obj, "scroll", NULL);
 
if (sd->have_selection)
  _update_selection_handler(obj);
diff --git a/src/lib/elementary/elm_gengrid.c b/src/lib/elementary/elm_gengrid.c
index 39e6c2a0b3..a162fb7c6c 100644
--- a/src/lib/elementary/elm_gengrid.c
+++ b/src/lib/elementary/elm_gengrid.c
@@ -3714,28 +3714,28 @@ static void
 _scroll_animate_start_cb(Evas_Object *obj,
  void *data EINA_UNUSED)
 {
-   efl_event_callback_legacy_call(obj, EFL_UI_EVENT_SCROLL_ANIM_STARTED, NULL);
+   evas_object_smart_callback_call(obj, "anim,start", NULL);
 }
 
 static void
 _scroll_animate_stop_cb(Evas_Object *obj,
 void *data EINA_UNUSED)
 {
-   efl_event_callback_legacy_call(obj, EFL_UI_EVENT_SCROLL_ANIM_FINISHED, 
NULL);
+   evas_object_smart_callback_call(obj, "anim,stop", NULL);
 }
 
 static void
 _scroll_drag_start_cb(Evas_Object *obj,
   void *data EINA_UNUSED)
 {
-   efl_event_callback_legacy_call(obj, EFL_UI_EVENT_SCROLL_DRAG_STARTED, NULL);
+   evas_object_smart_callback_call(obj, "drag,start", NULL);
 }
 
 static void
 _scroll_drag_stop_cb(Evas_Object *obj,
  void *data EINA_UNUSED)
 {
-   efl_event_callback_legacy_call(obj, EFL_UI_EVENT_SCROLL_DRAG_FINISHED, 
NULL);
+   evas_object_smart_callback_call(obj, "drag,stop", NULL);
 }
 
 static void
@@ -3777,7 +3777,7 @@ static void
 _scroll_cb(Evas_Object *obj,
void *data EINA_UNUSED)
 {
-   efl_event_callback_legacy_call(obj, EFL_UI_EVENT_SCROLL_CHANGED, NULL);
+   evas_object_smart_callback_call(obj, "changed", NULL);
 }
 
 static int
diff --git a/src/lib/elementary/elm_genlist.c b/src/lib/elementary/elm_genlist.c
index 09dd0df73d..1c0864e2e7 100644
--- a/src/lib/elementary/elm_genlist.c
+++ b/src/lib/elementary/elm_genlist.c
@@ -5541,35 +5541,35 @@ static void
 _scroll_animate_start_cb(Evas_Object *obj,
  void *data EINA_UNUSED)
 {
-   efl_event_callback_legacy_call(obj, EFL_UI_EVENT_SCROLL_ANIM_STARTED, NULL);
+   evas_object_smart_callback_call(obj, "anim,start", NULL);
 }
 
 static void
 _scroll_animate_stop_cb(Evas_Object *obj,
 void *data EINA_UNUSED)
 {
-   efl_event_callback_legacy_call(obj, EFL_UI_EVENT_SCROLL_ANIM_FINISHED, 
NULL);
+   evas_object_smart_callback_call(obj, "anim,stop", NULL);
 }
 
 static void
 _scroll_drag_start_cb(Evas_Object *obj,
   void *data EINA_UNUSED)
 {
-   efl_event_callback_legacy_call(obj, EFL_UI_EVENT_SCROLL_DRAG_STARTED, NULL);
+   evas_object_smart_callback_call(obj, "drag,start", NULL);
 }
 
 static void
 _scroll_cb(Evas_Object *obj,
void *data EINA_UNUSED)
 {
-   efl_event_callback_legacy_call(obj, EFL_UI_EVENT_SCROLL_CHANGED, NULL);
+   evas_object_smart_callback_call(obj, "changed", NULL);
 }
 
 static void
 _scroll_drag_stop_cb(Evas_Object *obj,
  void *data EINA_UNUSED)
 {
-   efl_event_callback_legacy_call(obj, EFL_UI_EVENT_SCROLL_DRAG_FINISHED, 
NULL);
+   evas_object_smart_callback_call(obj, "drag,stop", NULL);
 }
 
 static 

Re: [E-devel] RFC: Text interface + advice regarding interface splitting

2019-09-27 Thread Marcel Hollerbach

Hi,

after a long read:
- efl2_text_attribute_factory:
- Why having a struct here as handle, i fear that bindings will 
have a very hard time with this, where you actually pass in a struct to 
the remove method, and this one is dead after it.

- Its also not clear to me how explicit remove plays well with unref.
- the `insert` method should return a owned struct handle ? Or is 
the user never really owning any of the structs there ?
- efl2_text_font_properties / style_properties: (I have criticized the 
names before, i like the new names.) However, hard to comment more, as i 
do not know much about text property stuff itself.
- efl2_text_wrap_properties: Can you document what impact ellipsis and 
wrap do have ?

- efl2_text_markup:
- I am not entirely sure how item_factory works here. Is the 
item_factory knowing to which Efl2.Text_Markup they belong ? If so, 
shoudnt that be expressed somehow ?

- efl2_text_item_factory:
- Again, why having a struct here, same as above applies to this.
- efl2_text_raw_editable:
- Where does this object belong ? We normally only have objects in 
efl.canvas / ui / layout. But not in efl. itself.

- Is it doing undo/redo or only emitting the events ?
- efl2_ui_text:
- Why are here cnp related events ? Isnt that just a normal 
insertion / copy operation ? The cut and copy operation could be on a 
object that handles cnp, the paste operation as well, paired with a 
changed,user event?


General notes:
- you used a lot of ptr(...), you cannot use them when you remove @beta 
from the file. These files should not use ptr, nor void_ptr.
- You have a few places where you have explicitly x,y,w,h (x,y) in your 
API, can you replace them with rect (position) handles from eina, that 
would make it more aligned with the rest of efl.


Greetings,
   bu5hm4n

On 9/19/19 4:15 PM, Tom Hacohen wrote:

Hey,

As most of you (at least the IRC lurkers) know, I've been recently
working on the text interfaces. Trying to clean them up and stabilise them.
The discussion and work has been covered on phab at:
https://phab.enlightenment.org/T8151

And the new (suggested) interfaces are all the files starting with
"efl2_" in my branch:
https://git.enlightenment.org/core/efl.git/tree/?h=devs/tasn/ifaces

I'd love to get your feedback and let me know if there's anything I've
missed. All feedback is welcomed, including bike shedding.
Some interfaces still have massive FIXMEs at the top, so obviously read
those before replying to avoid repeating what we already know.


As for the advice I mentioned in the title: due to composite object
regressions as described in T8184, I'm forced to break up the classes
into interfaces. As discussed at length in the ticket, these interfaces
would have to be very specific to the classes and not really reusable
("cursor_new" is quite specific, obviously).

I can either just do as I said in the ticket, and for every class do a
big interface, so Efl.Canvas.Text -> Efl.Canvas.Text +
Efl.Canvas.Text_Interface. This is one way. It's obviously very ugly.
The other way is to split to a lot of smaller, probably 1/2 property
interfaces, which is also ugly and quite inefficient (classes/interfaces
are not free).

I'd love to get your input, to what interfaces would you split up these
two classes:
1.
https://git.enlightenment.org/core/efl.git/tree/src/lib/evas/canvas/efl2_canvas_text.eo?h=devs/tasn/ifaces
2.
https://git.enlightenment.org/core/efl.git/tree/src/lib/elementary/efl2_text_raw_editable.eo?h=devs/tasn/ifaces


Thanks a lot for your help and feedback!

--
Tom


___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel




___
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel


[EGIT] [core/efl] master 01/01: efl: mark selectable stable

2019-09-26 Thread Marcel Hollerbach
xartigas pushed a commit to branch master.

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

commit 8197fee189457aba01ae35dea5451731be003065
Author: Marcel Hollerbach 
Date:   Thu Sep 26 12:49:20 2019 +0200

efl: mark selectable stable

Summary:
fixes T7871
fixes T7852

This also works arround a eolian issue where composites do not mark the
inherited API from the composites as implemented.

Reviewers: SanghyeonLee, cedric, segfaultxavi, zmike

Reviewed By: segfaultxavi

Subscribers: SanghyeonLee, cedric

Tags: #efl

Maniphest Tasks: T7871, T7852

Differential Revision: https://phab.enlightenment.org/D10184
---
 src/lib/elementary/efl_ui_collection_view.eo   | 4 +---
 src/lib/elementary/efl_ui_selectable.eo| 2 +-
 src/lib/elementary/efl_ui_single_selectable.eo | 2 +-
 3 files changed, 3 insertions(+), 5 deletions(-)

diff --git a/src/lib/elementary/efl_ui_collection_view.eo 
b/src/lib/elementary/efl_ui_collection_view.eo
index 9278cd04c7..4bbbf97922 100644
--- a/src/lib/elementary/efl_ui_collection_view.eo
+++ b/src/lib/elementary/efl_ui_collection_view.eo
@@ -1,11 +1,9 @@
 class Efl.Ui.Collection_View extends Efl.Ui.Layout_Base implements
 Efl.Ui.Layout_Orientable,
-Efl.Ui.Selectable,
-Efl.Ui.Multi_Selectable_Async,
 Efl.Ui.Focus.Manager_Sub,
 Efl.Ui.Widget_Focus_Manager,
 Efl.Ui.Item_Clickable
-composites Efl.Ui.Scrollable, Efl.Ui.Scrollbar, 
Efl.Ui.Multi_Selectable_Async
+composites Efl.Ui.Scrollable, Efl.Ui.Scrollbar, 
Efl.Ui.Multi_Selectable_Async, Efl.Ui.Single_Selectable
 {
[[This widget displays a list of items in an arrangement controlled by an 
external @.position_manager
  object. By using different @.position_manager objects this widget can 
show unidimensional lists or
diff --git a/src/lib/elementary/efl_ui_selectable.eo 
b/src/lib/elementary/efl_ui_selectable.eo
index 553d12e90a..fe9468e594 100644
--- a/src/lib/elementary/efl_ui_selectable.eo
+++ b/src/lib/elementary/efl_ui_selectable.eo
@@ -1,4 +1,4 @@
-interface @beta Efl.Ui.Selectable {
+interface Efl.Ui.Selectable {
   [[Selectable interface for UI objects
 
 An object implementing this interface can be selected.
diff --git a/src/lib/elementary/efl_ui_single_selectable.eo 
b/src/lib/elementary/efl_ui_single_selectable.eo
index 457bf6cc5d..9d96d607d0 100644
--- a/src/lib/elementary/efl_ui_single_selectable.eo
+++ b/src/lib/elementary/efl_ui_single_selectable.eo
@@ -1,4 +1,4 @@
-interface @beta Efl.Ui.Single_Selectable {
+interface Efl.Ui.Single_Selectable {
[[Interface for getting access to a single selected item in the implementor.
 
  The implementor is free to allow a specific number of selectables being 
selected or not.

-- 




[EGIT] [core/efl] master 01/01: efl_ui_*selectable: unify these APIs with the same c_prefix

2019-09-26 Thread Marcel Hollerbach
sanghyeonlee pushed a commit to branch master.

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

commit 1df17abba575f70b1f26fb50b972a1c8f37d2d27
Author: Marcel Hollerbach 
Date:   Thu Sep 26 18:16:24 2019 +0900

efl_ui_*selectable: unify these APIs with the same c_prefix

Summary:
with this commit that api for single and multi selectable shares the
same prefix, which makes sense in c as we do not really differ between
those two types there anyway.

ref T7871

Reviewers: SanghyeonLee, segfaultxavi

Reviewed By: segfaultxavi

Subscribers: segfaultxavi, cedric, #reviewers, #committers

Tags: #efl

Maniphest Tasks: T7871

Differential Revision: https://phab.enlightenment.org/D10183
---
 src/bin/elementary/test_part_bg.c  |  6 +-
 src/bin/elementary/test_ui_collection.c|  6 +-
 src/bin/elementary/test_ui_collection_view.c   |  4 +-
 src/bin/elementary/test_ui_radio.c |  6 +-
 src/examples/elementary/efl_ui_list_example_1.c|  8 +-
 .../elementary/efl_ui_list_view_example_3.c|  4 +-
 src/lib/elementary/efl_ui_collection.c |  4 +-
 src/lib/elementary/efl_ui_collection_view.c|  6 +-
 src/lib/elementary/efl_ui_item.c   |  4 +-
 src/lib/elementary/efl_ui_multi_selectable.eo  |  2 +-
 src/lib/elementary/efl_ui_radio_box.c  |  2 +-
 src/lib/elementary/efl_ui_radio_group_impl.c   |  2 +-
 src/lib/elementary/efl_ui_select_model.c   |  2 +-
 src/lib/elementary/efl_ui_single_selectable.eo |  1 +
 src/lib/elementary/efl_ui_tab_bar.c|  2 +-
 src/lib/elementary/efl_ui_tab_pager.c  |  2 +-
 src/tests/elementary/efl_ui_test_radio_group.c | 28 +++
 .../elementary/spec/efl_test_multi_selectable.c| 98 +++---
 .../elementary/spec/efl_test_single_selectable.c   | 14 ++--
 19 files changed, 101 insertions(+), 100 deletions(-)

diff --git a/src/bin/elementary/test_part_bg.c 
b/src/bin/elementary/test_part_bg.c
index da50aae206..3f3c9db14a 100644
--- a/src/bin/elementary/test_part_bg.c
+++ b/src/bin/elementary/test_part_bg.c
@@ -15,7 +15,7 @@ _reset_cb(void *data, const Efl_Event *ev EINA_UNUSED)
Efl_Ui_Radio_Group *radio = data;
Evas_Object *target;
 
-   radio = efl_ui_single_selectable_last_selected_get(radio);
+   radio = efl_ui_selectable_last_selected_get(radio);
target = evas_object_data_get(radio, "data");
 
efl_gfx_color_set(efl_part(target, "background"), 0, 0, 0, 0);
@@ -29,7 +29,7 @@ _color_cb(void *data, const Efl_Event *ev EINA_UNUSED)
Evas_Object *target;
static Eina_Bool i;
 
-   radio = efl_ui_single_selectable_last_selected_get(radio);
+   radio = efl_ui_selectable_last_selected_get(radio);
target = evas_object_data_get(radio, "data");
i ^= EINA_TRUE;
efl_gfx_color_set(efl_part(target, "background"), (i) ? 255 : 0, (i) ? 0 : 
255, 0, 255);
@@ -43,7 +43,7 @@ _scale_type_cb(void *data, const Efl_Event *ev EINA_UNUSED)
Efl_Gfx_Image_Scale_Method type;
char buf[PATH_MAX];
 
-   radio = efl_ui_single_selectable_last_selected_get(radio);
+   radio = efl_ui_selectable_last_selected_get(radio);
target = evas_object_data_get(radio, "data");
 
snprintf(buf, sizeof(buf), "%s/images/plant_01.jpg", 
elm_app_data_dir_get());
diff --git a/src/bin/elementary/test_ui_collection.c 
b/src/bin/elementary/test_ui_collection.c
index f407a6988a..3d1b34e3cd 100644
--- a/src/bin/elementary/test_ui_collection.c
+++ b/src/bin/elementary/test_ui_collection.c
@@ -7,13 +7,13 @@
 static void
 _all_select(void *data, const Efl_Event *ev EINA_UNUSED)
 {
-   efl_ui_all_select(data);
+   efl_ui_selectable_all_select(data);
 }
 
 static void
 _all_unselect(void *data, const Efl_Event *ev EINA_UNUSED)
 {
-   efl_ui_all_unselect(data);
+   efl_ui_selectable_all_unselect(data);
 }
 
 static void
@@ -167,7 +167,7 @@ _select_value_cb(void *data, const Efl_Event *ev)
 {
Efl_Ui_Collection *c = data;
 
-   efl_ui_select_mode_set(c, 
efl_ui_radio_group_selected_value_get(ev->object));
+   efl_ui_selectable_select_mode_set(c, 
efl_ui_radio_group_selected_value_get(ev->object));
 }
 
 void create_item_container_ui(const Efl_Class *collection_class, const 
Efl_Class *item, const char *name)
diff --git a/src/bin/elementary/test_ui_collection_view.c 
b/src/bin/elementary/test_ui_collection_view.c
index 4a3f2f7b7c..ba34d320b5 100644
--- a/src/bin/elementary/test_ui_collection_view.c
+++ b/src/bin/elementary/test_ui_collection_view.c
@@ -46,7 +46,7 @@ _item_constructing(void *data EINA_UNUSED, const Efl_Event 
*ev)
 static void
 _item_select(void *data, const Efl_Event *ev)
 {
-   Efl_Ui_Widget *w = efl_ui_single_selectable_last_selected_get(ev->object);
+   Efl_Ui_Widget *w = efl_ui_selectable_last_selected_get(ev->object);
Efl_Mode

[EGIT] [core/efl] master 01/01: Revert "elm: add basics test to create a destroy *every* widget with errors"

2019-09-25 Thread Marcel Hollerbach
bu5hm4n pushed a commit to branch master.

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

commit 6592fefcdd3c3d59b0619d1c1ce3a5d5dd7fadef
Author: Marcel Hollerbach 
Date:   Wed Sep 25 21:46:54 2019 +0200

Revert "elm: add basics test to create a destroy *every* widget with errors"

This reverts commit 10cdb070180e0f1e62d5b8e5d5164a19fbc51548.

this does not pass on ci ... o.O
---
 src/tests/elementary/elm_suite.c  |   1 -
 src/tests/elementary/elm_suite.h  |   1 -
 src/tests/elementary/elm_test_widget_basics.c | 137 --
 src/tests/elementary/meson.build  |   3 +-
 4 files changed, 1 insertion(+), 141 deletions(-)

diff --git a/src/tests/elementary/elm_suite.c b/src/tests/elementary/elm_suite.c
index d6aa4636e8..87fac6e4e1 100644
--- a/src/tests/elementary/elm_suite.c
+++ b/src/tests/elementary/elm_suite.c
@@ -86,7 +86,6 @@ static const Efl_Test_Case etc[] = {
   { "elm_code_widget_selection", elm_code_test_widget_selection },
   { "elm_code_widget_undo", elm_code_test_widget_undo },
   { "elm_widget_focus", elm_test_widget_focus},
-  { "elm_widget_basics", elm_test_widget_basics},
   { NULL, NULL }
 };
 
diff --git a/src/tests/elementary/elm_suite.h b/src/tests/elementary/elm_suite.h
index 67f5d0d5c4..ba76b29615 100644
--- a/src/tests/elementary/elm_suite.h
+++ b/src/tests/elementary/elm_suite.h
@@ -84,7 +84,6 @@ void elm_test_slideshow(TCase *tc);
 void elm_test_spinner(TCase *tc);
 void elm_test_plug(TCase *tc);
 void elm_test_widget_focus(TCase *tc);
-void elm_test_widget_basics(TCase *tc);
 
 void elm_code_file_test_load(TCase *tc);
 void elm_code_file_test_memory(TCase *tc);
diff --git a/src/tests/elementary/elm_test_widget_basics.c 
b/src/tests/elementary/elm_test_widget_basics.c
deleted file mode 100644
index e66a9ac149..00
--- a/src/tests/elementary/elm_test_widget_basics.c
+++ /dev/null
@@ -1,137 +0,0 @@
-#ifdef HAVE_CONFIG_H
-# include "elementary_config.h"
-#endif
-
-#include 
-#include "elm_suite.h"
-
-typedef struct _Simple_Test_Widget
-{
-   Evas_Object* (*constructor)(Evas_Object *win);
-   const char *name;
-} Simple_Test_Widget;
-
-
-static const Simple_Test_Widget simple_widgets[] = {
-  {elm_flip_add, "flip"},
-  {elm_frame_add, "frame"},
-  {elm_player_add, "player"},
-  {elm_video_add, "video"},
-  {elm_ctxpopup_add, "ctxpopup"},
-  {elm_fileselector_add, "fileselector"},
-  {elm_hoversel_add, "hoversel"},
-  {elm_multibuttonentry_add, "multibuttonentry"},
-  {elm_naviframe_add, "naviframe"},
-  {elm_popup_add, "popup"},
-  {elm_actionslider_add, "actionslider"},
-  {elm_bg_add, "bg"},
-  {elm_box_add, "box"},
-  {elm_bubble_add, "bubble"},
-  {elm_calendar_add, "calendar"},
-  {elm_button_add, "button"},
-  {elm_check_add, "check"},
-  {elm_clock_add, "clock"},
-  {elm_colorselector_add, "colorselector"},
-  {elm_conformant_add, "conformant"},
-  {elm_dayselector_add, "dayselector"},
-  {elm_entry_add, "entry"},
-  {elm_flipselector_add, "flipselector"},
-  {elm_gengrid_add, "gengrid"},
-  {elm_genlist_add, "genlist"},
-  {elm_glview_add, "glview"},
-  {elm_grid_add, "grid"},
-  {elm_hover_add, "hover"},
-  {elm_icon_add, "icon"},
-  {elm_image_add, "image"},
-  {elm_index_add, "index"},
-  {elm_label_add, "label"},
-  {elm_layout_add, "layout"},
-  {elm_list_add, "list"},
-  {elm_map_add, "map"},
-  {elm_mapbuf_add, "mapbuf"},
-  {elm_menu_add, "menu"},
-  {elm_notify_add, "notify"},
-  {elm_panel_add, "panel"},
-  {elm_panes_add, "panes"},
-  {elm_photo_add, "photo"},
-  {elm_photocam_add, "photocam"},
-  {elm_plug_add, "plug"},
-  {elm_prefs_add, "prefs"},
-  {elm_progressbar_add, "progressbar"},
-  {elm_radio_add, "radio"},
-  {elm_route_add, "route"},
-  {elm_separator_add, "seperator"},
-  {elm_slider_add, "slider"},
-  {elm_slideshow_add, "slideshow"},
-  {elm_spinner_add, "spinner"},
-  {elm_table_add, "table"},
-  {elm_textpath_add, "textpath"},
-  {elm_toolbar_add, "toolbar"},
-  {elm_web_add, "web"},
-  {elm_diskselector_add, "diskselector"},
-  {elm_datetime_add, "datetime"},
-  //{elm_combobox_add, "button"}, This is a beta widget which was never public 
and is written in a few ways that break basic assertions of widgets base class
-  //{elm_thumb_add, "button"}, This dies because of a 

[EGIT] [core/efl] master 01/02: elm: add basics test to create a destroy *every* widget with errors

2019-09-25 Thread Marcel Hollerbach
bu5hm4n pushed a commit to branch master.

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

commit 10cdb070180e0f1e62d5b8e5d5164a19fbc51548
Author: Marcel Hollerbach 
Date:   Mon Sep 23 20:43:47 2019 +0200

elm: add basics test to create a destroy *every* widget with errors

this simply creates packs, resizes, and destroys every single widget
that we have in legacy elm.

This i made to ensure that there are no mistakes in the construction
chain. Additionally, a second test case checks that creation with none
elm parents is erroring but not failing, this seems weird, but we have
provided that in the past, so we should continue providing this.

Differential Revision: https://phab.enlightenment.org/D10088
---
 src/tests/elementary/elm_suite.c  |   1 +
 src/tests/elementary/elm_suite.h  |   1 +
 src/tests/elementary/elm_test_widget_basics.c | 137 ++
 src/tests/elementary/meson.build  |   3 +-
 4 files changed, 141 insertions(+), 1 deletion(-)

diff --git a/src/tests/elementary/elm_suite.c b/src/tests/elementary/elm_suite.c
index 87fac6e4e1..d6aa4636e8 100644
--- a/src/tests/elementary/elm_suite.c
+++ b/src/tests/elementary/elm_suite.c
@@ -86,6 +86,7 @@ static const Efl_Test_Case etc[] = {
   { "elm_code_widget_selection", elm_code_test_widget_selection },
   { "elm_code_widget_undo", elm_code_test_widget_undo },
   { "elm_widget_focus", elm_test_widget_focus},
+  { "elm_widget_basics", elm_test_widget_basics},
   { NULL, NULL }
 };
 
diff --git a/src/tests/elementary/elm_suite.h b/src/tests/elementary/elm_suite.h
index ba76b29615..67f5d0d5c4 100644
--- a/src/tests/elementary/elm_suite.h
+++ b/src/tests/elementary/elm_suite.h
@@ -84,6 +84,7 @@ void elm_test_slideshow(TCase *tc);
 void elm_test_spinner(TCase *tc);
 void elm_test_plug(TCase *tc);
 void elm_test_widget_focus(TCase *tc);
+void elm_test_widget_basics(TCase *tc);
 
 void elm_code_file_test_load(TCase *tc);
 void elm_code_file_test_memory(TCase *tc);
diff --git a/src/tests/elementary/elm_test_widget_basics.c 
b/src/tests/elementary/elm_test_widget_basics.c
new file mode 100644
index 00..e66a9ac149
--- /dev/null
+++ b/src/tests/elementary/elm_test_widget_basics.c
@@ -0,0 +1,137 @@
+#ifdef HAVE_CONFIG_H
+# include "elementary_config.h"
+#endif
+
+#include 
+#include "elm_suite.h"
+
+typedef struct _Simple_Test_Widget
+{
+   Evas_Object* (*constructor)(Evas_Object *win);
+   const char *name;
+} Simple_Test_Widget;
+
+
+static const Simple_Test_Widget simple_widgets[] = {
+  {elm_flip_add, "flip"},
+  {elm_frame_add, "frame"},
+  {elm_player_add, "player"},
+  {elm_video_add, "video"},
+  {elm_ctxpopup_add, "ctxpopup"},
+  {elm_fileselector_add, "fileselector"},
+  {elm_hoversel_add, "hoversel"},
+  {elm_multibuttonentry_add, "multibuttonentry"},
+  {elm_naviframe_add, "naviframe"},
+  {elm_popup_add, "popup"},
+  {elm_actionslider_add, "actionslider"},
+  {elm_bg_add, "bg"},
+  {elm_box_add, "box"},
+  {elm_bubble_add, "bubble"},
+  {elm_calendar_add, "calendar"},
+  {elm_button_add, "button"},
+  {elm_check_add, "check"},
+  {elm_clock_add, "clock"},
+  {elm_colorselector_add, "colorselector"},
+  {elm_conformant_add, "conformant"},
+  {elm_dayselector_add, "dayselector"},
+  {elm_entry_add, "entry"},
+  {elm_flipselector_add, "flipselector"},
+  {elm_gengrid_add, "gengrid"},
+  {elm_genlist_add, "genlist"},
+  {elm_glview_add, "glview"},
+  {elm_grid_add, "grid"},
+  {elm_hover_add, "hover"},
+  {elm_icon_add, "icon"},
+  {elm_image_add, "image"},
+  {elm_index_add, "index"},
+  {elm_label_add, "label"},
+  {elm_layout_add, "layout"},
+  {elm_list_add, "list"},
+  {elm_map_add, "map"},
+  {elm_mapbuf_add, "mapbuf"},
+  {elm_menu_add, "menu"},
+  {elm_notify_add, "notify"},
+  {elm_panel_add, "panel"},
+  {elm_panes_add, "panes"},
+  {elm_photo_add, "photo"},
+  {elm_photocam_add, "photocam"},
+  {elm_plug_add, "plug"},
+  {elm_prefs_add, "prefs"},
+  {elm_progressbar_add, "progressbar"},
+  {elm_radio_add, "radio"},
+  {elm_route_add, "route"},
+  {elm_separator_add, "seperator"},
+  {elm_slider_add, "slider"},
+  {elm_slideshow_add, "slideshow"},
+  {elm_spinner_add, "spinner"},
+  {elm_table_add, "table"},
+  {elm_textpath_add, "textpath"},
+  {elm_toolbar_add, "toolbar"},
+  {elm

  1   2   3   4   5   6   7   8   9   10   >