[EGIT] [core/efl] master 01/01: eina: Fix magic check for eina_promise_owner_buffer_get
felipealmeida pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=1c269cf24a03aee2b1a0a09f58802157dee60183 commit 1c269cf24a03aee2b1a0a09f58802157dee60183 Author: Felipe Magno de AlmeidaDate: Fri Jun 3 21:53:29 2016 -0300 eina: Fix magic check for eina_promise_owner_buffer_get --- src/lib/eina/eina_promise.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/lib/eina/eina_promise.c b/src/lib/eina/eina_promise.c index e4adccd..e6e3a14 100644 --- a/src/lib/eina/eina_promise.c +++ b/src/lib/eina/eina_promise.c @@ -990,7 +990,7 @@ EAPI void * eina_promise_owner_buffer_get(Eina_Promise_Owner* promise) { _EINA_PROMISE_NULL_CHECK(promise, NULL); - EINA_MAGIC_CHECK_PROMISE(promise); + EINA_MAGIC_CHECK_PROMISE_OWNER(promise); return promise->buffer_get(promise); } --
[EGIT] [core/efl] master 01/01: eina: Fix EINA_MAGIC and eina_promise_then NULL check
felipealmeida pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=2e4765bc886e222f5f5d01a3a6ca6437ff10f7de commit 2e4765bc886e222f5f5d01a3a6ca6437ff10f7de Author: Felipe Magno de AlmeidaDate: Fri Jun 3 21:42:23 2016 -0300 eina: Fix EINA_MAGIC and eina_promise_then NULL check --- src/lib/eina/eina_promise.c | 16 ++-- 1 file changed, 14 insertions(+), 2 deletions(-) diff --git a/src/lib/eina/eina_promise.c b/src/lib/eina/eina_promise.c index 8a207f7..e4adccd 100644 --- a/src/lib/eina/eina_promise.c +++ b/src/lib/eina/eina_promise.c @@ -538,6 +538,8 @@ eina_promise_value_add(int value_size) p->promise.vtable.unref = EINA_FUNC_PROMISE_UNREF(_eina_promise_unref); p->promise.vtable.value_size_get = EINA_FUNC_PROMISE_VALUE_SIZE_GET(_eina_promise_value_size_get); p->promise.vtable.buffer_get = EINA_FUNC_PROMISE_BUFFER_GET(_eina_promise_buffer_get); + EINA_MAGIC_SET(>promise.vtable, EINA_MAGIC_PROMISE); + p->promise.has_finished = p->promise.has_errored = p->promise.is_cancelled = p->promise.is_manual_then = p->promise.is_pointer = EINA_FALSE; p->promise.is_first_then = EINA_TRUE; @@ -560,6 +562,7 @@ eina_promise_value_add(int value_size) p->owner_vtable.cancelled_is = EINA_FUNC_PROMISE_OWNER_CANCELLED_IS(_eina_promise_owner_cancelled_is); p->owner_vtable.progress = EINA_FUNC_PROMISE_OWNER_PROGRESS(_eina_promise_owner_progress); p->owner_vtable.progress_notify = EINA_FUNC_PROMISE_OWNER_PROGRESS_NOTIFY(_eina_promise_owner_progress_notify); + EINA_MAGIC_SET(>owner_vtable, EINA_MAGIC_PROMISE_OWNER); return >owner_vtable; } @@ -581,6 +584,8 @@ eina_promise_add() p->promise.vtable.unref = EINA_FUNC_PROMISE_UNREF(_eina_promise_unref); p->promise.vtable.value_size_get = EINA_FUNC_PROMISE_VALUE_SIZE_GET(_eina_promise_value_size_get); p->promise.vtable.buffer_get = EINA_FUNC_PROMISE_BUFFER_GET(_eina_promise_buffer_get); + EINA_MAGIC_SET(>promise.vtable, EINA_MAGIC_PROMISE); + p->promise.has_finished = p->promise.has_errored = p->promise.is_cancelled = p->promise.is_manual_then = EINA_FALSE; p->promise.is_first_then = p->promise.is_pointer = EINA_TRUE; @@ -603,7 +608,8 @@ eina_promise_add() p->owner_vtable.cancelled_is = EINA_FUNC_PROMISE_OWNER_CANCELLED_IS(_eina_promise_owner_cancelled_is); p->owner_vtable.progress = EINA_FUNC_PROMISE_OWNER_PROGRESS(_eina_promise_owner_progress); p->owner_vtable.progress_notify = EINA_FUNC_PROMISE_OWNER_PROGRESS_NOTIFY(_eina_promise_owner_progress_notify); - + EINA_MAGIC_SET(>owner_vtable, EINA_MAGIC_PROMISE_OWNER); + return >owner_vtable; } @@ -881,7 +887,13 @@ eina_promise_then(Eina_Promise* promise, Eina_Promise_Cb callback, { if(!promise) { -error_cb(data, EINA_ERROR_PROMISE_NULL); +if(!error_cb) + { +ERR("eina_promise_the with NULL promise and no error callback."); +eina_error_set(EINA_ERROR_PROMISE_NULL); + } +else + error_cb(data, EINA_ERROR_PROMISE_NULL); return; } else --
Re: [E-devel] Next release
With Mike's health problems as well, it's sounding like the entire thing (EFL and Enlightenment) might need to just slow down for a bit. On Fri, 3 Jun 2016 16:24:55 -0700 Cedric BAILwrote: > Hello, > > I just would like to start a thread regarding what is still pending > for next release and what we should do about it. First let's start > with what is not ready : > - Most of the elementary widgets have not been renamed correctly to be > in efl.ui namespace. > - Edje and Elm.Layout have not been refactorized and properly > inherited from each other. > - Text interface is not there (this impact also entry, label and > edje). > - Genlist is also not there. > - All eo object still needs a proper cleanup and use of own(). > - Uri manager is not there. > - Color/Color_Class is not there. > - Efl photocam is not there. > - Efl video is not there. > - Efl.Ui.Window is not there. > - Efl.Ui.Focus cleanup is not there. > > Sone of the above have patch in review process that may land before > Monday morning, but I prefer to just give the current status as I may > not have time this weekend as I am moving. Also most of the API that > have landed so far have not been tested in any real application and we > don't really if they do fit their purpose (making life easier). My SledjHamr project is one of the real applications that would be using a lot of the Ecore_Con, Elm, Eo, Evas_3D, and threading stuff. It's still not fully working right, but at least builds and doesn't crash anymore. Some of the current bugs might be related to the focus and genlist stuff not being there. Video is due to be added to this project later (I want to hook up video to the terrain heightfield, so people can create earthquakes). My new Conky experiments will use Lua and Edje stuff, and might eventually use whatever EFL has for hardware monitoring these days. That will need the color and text stuff, so that's on hold for now. > It is obvious to me, and I am pretty to sure to everyone involved in > the development of 1.18 that we can not do an alpha while some of the > biggest change are not there yet. Now the question is should we delay > the alpha ? Or should we make the alpha a technical preview followed > by an alpha later on ? Should we just move on and delay the above > change for 1.19, in which case all the new API need to remain BETA. > Also if we do delay, how much longer is needed for a release ? Isn't > it going to drag on ? > > Oh and did I miss anything in the above list ? I tired to compile EFL yesterday, had issues with Lua and EIO. The Lua issue is likely a problem at my end, but the EIO issue looked like a problem at your end. I might poke at that more later today. -- A big old stinking pile of genius that no one wants coz there are too many silver coated monkeys in the world. signature.asc Description: PGP signature -- What NetFlow Analyzer can do for you? Monitors network bandwidth and traffic patterns at an interface-level. Reveals which users, apps, and protocols are consuming the most bandwidth. Provides multi-vendor support for NetFlow, J-Flow, sFlow and other flows. Make informed decisions using capacity planning reports. https://ad.doubleclick.net/ddm/clk/305295220;132659582;e___ enlightenment-devel mailing list enlightenment-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
[EGIT] [core/efl] master 01/08: ecore: remove Ecore_Animator Eo object.
cedric pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=5cc16b1c295045b5c4126f9fbe7db0dc8e1d05c4 commit 5cc16b1c295045b5c4126f9fbe7db0dc8e1d05c4 Author: Cedric BAILDate: Fri Jun 3 15:44:40 2016 -0700 ecore: remove Ecore_Animator Eo object. This is only a legacy API. --- src/Makefile_Ecore.am | 1 - src/lib/ecore/Ecore_Common.h | 3 - src/lib/ecore/Ecore_Eo.h | 12 --- src/lib/ecore/Ecore_Legacy.h | 4 +- src/lib/ecore/ecore_anim.c| 149 +- src/lib/ecore/ecore_animator.eo | 42 -- src/lib/ecore/ecore_types.eot | 2 - src/tests/ecore/ecore_test_animator.c | 6 +- 8 files changed, 45 insertions(+), 174 deletions(-) diff --git a/src/Makefile_Ecore.am b/src/Makefile_Ecore.am index b027694..1f544c6 100644 --- a/src/Makefile_Ecore.am +++ b/src/Makefile_Ecore.am @@ -4,7 +4,6 @@ ecore_eolian_files_legacy = \ lib/ecore/ecore_poller.eo \ lib/ecore/ecore_exe.eo \ - lib/ecore/ecore_animator.eo \ lib/ecore/efl_timer.eo ecore_eolian_files = \ diff --git a/src/lib/ecore/Ecore_Common.h b/src/lib/ecore/Ecore_Common.h index 1dac869..c2ed8a3 100644 --- a/src/lib/ecore/Ecore_Common.h +++ b/src/lib/ecore/Ecore_Common.h @@ -2648,9 +2648,6 @@ typedef Eina_Bool (*Ecore_Timeline_Cb)(void *data, double pos); /* * @since 1.8 */ -typedef Eo Ecore_Animator; /**< A handle for animators */ - -#define _ECORE_ANIMATOR_EO_CLASS_TYPE /** * @brief Set the animator call interval in seconds. diff --git a/src/lib/ecore/Ecore_Eo.h b/src/lib/ecore/Ecore_Eo.h index 4c53c21..5214680 100644 --- a/src/lib/ecore/Ecore_Eo.h +++ b/src/lib/ecore/Ecore_Eo.h @@ -18,18 +18,6 @@ extern "C" { */ /** - * @ingroup Ecore_Animator_Group - * - * @{ - */ - -#include "ecore_animator.eo.h" - -/** - * @} - */ - -/** * @ingroup Ecore_Timer_Group * * @{ diff --git a/src/lib/ecore/Ecore_Legacy.h b/src/lib/ecore/Ecore_Legacy.h index 80626de..ecf6a69 100644 --- a/src/lib/ecore/Ecore_Legacy.h +++ b/src/lib/ecore/Ecore_Legacy.h @@ -77,6 +77,8 @@ EAPI double ecore_poller_poll_interval_get(Ecore_Poller_Type type); * @{ */ +typedef struct _Ecore_Animator Ecore_Animator; + /** * @brief Add an animator to call @p func at every animation tick during main * loop execution. @@ -172,8 +174,6 @@ EAPI void ecore_animator_freeze(Ecore_Animator *animator); */ EAPI void ecore_animator_thaw(Ecore_Animator *animator); -#include "ecore_animator.eo.legacy.h" - /** * @} */ diff --git a/src/lib/ecore/ecore_anim.c b/src/lib/ecore/ecore_anim.c index 80b389c..707916c 100644 --- a/src/lib/ecore/ecore_anim.c +++ b/src/lib/ecore/ecore_anim.c @@ -30,23 +30,12 @@ #endif /* ! _WIN32 */ -#include - #include "Ecore.h" #include "ecore_private.h" -#define MY_CLASS ECORE_ANIMATOR_CLASS - -#define MY_CLASS_NAME "Ecore_Animator" - -#define ECORE_ANIMATOR_CHECK(obj) \ - if (!eo_isa((obj), ECORE_ANIMATOR_CLASS)) \ -return - -struct _Ecore_Animator_Data +struct _Ecore_Animator { EINA_INLIST; - Ecore_Animator *obj; Ecore_Task_Cb func; void *data; @@ -60,13 +49,11 @@ struct _Ecore_Animator_Data Eina_Bool just_added : 1; }; -typedef struct _Ecore_Animator_Data Ecore_Animator_Data; - static Eina_Bool _do_tick(void); static Eina_Bool _ecore_animator_run(void *data); static int animators_delete_me = 0; -static Ecore_Animator_Data *animators = NULL; +static Ecore_Animator *animators = NULL; static double animators_frametime = 1.0 / 30.0; static unsigned int animators_suspended = 0; @@ -281,7 +268,7 @@ _end_tick(void) static Eina_Bool _do_tick(void) { - Ecore_Animator_Data *animator; + Ecore_Animator *animator; EINA_INLIST_FOREACH(animators, animator) { @@ -307,23 +294,19 @@ _do_tick(void) } if (animators_delete_me) { -Ecore_Animator_Data *l; +Ecore_Animator *l; for (l = animators; l; ) { animator = l; - l = (Ecore_Animator_Data *)EINA_INLIST_GET(l)->next; + l = (Ecore_Animator *)EINA_INLIST_GET(l)->next; if (animator->delete_me) { if (animator->suspended) animators_suspended--; - animators = (Ecore_Animator_Data *) + animators = (Ecore_Animator *) eina_inlist_remove(EINA_INLIST_GET(animators), EINA_INLIST_GET(animator)); - eo_parent_set(animator->obj, NULL); - if (eo_destructed_is(animator->obj)) - eo_manual_free(animator->obj); - else - eo_manual_free_set(animator->obj, EINA_FALSE); + free(animator); animators_delete_me--; if (animators_delete_me
[EGIT] [core/efl] master 03/08: ecore: Ecore_Cb is used by elm_box.eo.
cedric pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=2b12aea5e63139ddabab9c1e93d3b052a2100b4c commit 2b12aea5e63139ddabab9c1e93d3b052a2100b4c Author: Cedric BAILDate: Fri Jun 3 16:45:12 2016 -0700 ecore: Ecore_Cb is used by elm_box.eo. --- src/lib/ecore/ecore_types.eot | 1 + 1 file changed, 1 insertion(+) diff --git a/src/lib/ecore/ecore_types.eot b/src/lib/ecore/ecore_types.eot index f1d7191..dce6260 100644 --- a/src/lib/ecore/ecore_types.eot +++ b/src/lib/ecore/ecore_types.eot @@ -1,3 +1,4 @@ +type @extern Ecore_Cb: __undefined_type; type @extern Ecore_Task_Cb: __undefined_type; enum Ecore.Pos_Map --
[EGIT] [core/efl] master 07/08: ecore: properly handle double free case of timeout promise.
cedric pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=58c477a30a513b15f2c10e2e61bdb80018ef8fdb commit 58c477a30a513b15f2c10e2e61bdb80018ef8fdb Author: Cedric BAILDate: Fri Jun 3 16:57:53 2016 -0700 ecore: properly handle double free case of timeout promise. The bug came from the fact we need to handle the destruction of the main loop which destroy the underlying timer. The event handler that catch the destruction of the timer can not make the difference between eo_del call from the timeout code and eo_del from the main loop destruction. By removing the event handler, the double free is properly avoided. --- src/lib/ecore/ecore_main.c | 65 +++--- 1 file changed, 38 insertions(+), 27 deletions(-) diff --git a/src/lib/ecore/ecore_main.c b/src/lib/ecore/ecore_main.c index 7520ce5..5a011a4 100644 --- a/src/lib/ecore/ecore_main.c +++ b/src/lib/ecore/ecore_main.c @@ -2826,18 +2826,6 @@ _efl_loop_job_cb(void *data) free(j); } -static Eina_Bool -_efl_loop_timeout_cb(void *data, const Eo_Event *event EINA_UNUSED) -{ - Efl_Internal_Promise *t = data; - - eina_promise_owner_value_set(t->promise, t->data, NULL); - - eo_del(t->u.timer); - - return EO_CALLBACK_CONTINUE; -} - static void _efl_loop_args_job_cb(void *data, void *value EINA_UNUSED) { @@ -2860,6 +2848,37 @@ _efl_loop_args_add(Eo *obj, Efl_Loop_Data *pd EINA_UNUSED, int argc, const char eina_promise_then(job, _efl_loop_args_job_cb, NULL, args); } +static Eina_Bool _efl_loop_timeout_force_cancel_cb(void *data, const Eo_Event *event EINA_UNUSED); +static Eina_Bool _efl_loop_timeout_cb(void *data, const Eo_Event *event EINA_UNUSED); + +EO_CALLBACKS_ARRAY_DEFINE(timeout, + { EFL_LOOP_TIMER_EVENT_TICK, _efl_loop_timeout_cb }, + { EO_EVENT_DEL, _efl_loop_timeout_force_cancel_cb }); + +/* This event will be triggered when the main loop is destroyed and destroy its timers along */ +static void _efl_loop_internal_cancel(Efl_Internal_Promise *p); + +static Eina_Bool +_efl_loop_timeout_force_cancel_cb(void *data, const Eo_Event *event EINA_UNUSED) +{ + _efl_loop_internal_cancel(data); + + return EO_CALLBACK_CONTINUE; +} + +static Eina_Bool +_efl_loop_timeout_cb(void *data, const Eo_Event *event EINA_UNUSED) +{ + Efl_Internal_Promise *t = data; + + eina_promise_owner_value_set(t->promise, t->data, NULL); + + eo_event_callback_array_del(t->u.timer, timeout(), t); + eo_del(t->u.timer); + + return EO_CALLBACK_CONTINUE; +} + static void _efl_loop_internal_cancel(Efl_Internal_Promise *p) { @@ -2875,9 +2894,14 @@ _efl_loop_job_cancel(void* data, Eina_Promise_Owner* promise EINA_UNUSED) if (j->job_is) { ecore_job_del(j->u.job); -_efl_loop_internal_cancel(j); } - else eo_del(j->u.timer); + else + { +eo_event_callback_array_del(j->u.timer, timeout(), j); +eo_del(j->u.timer); + } + + _efl_loop_internal_cancel(j); } static Efl_Internal_Promise * @@ -2920,19 +2944,6 @@ _efl_loop_job(Eo *obj EINA_UNUSED, Efl_Loop_Data *pd EINA_UNUSED, const void *da return NULL; } -/* This event will be triggered when the main loop is destroyed and destroy its timers along */ -static Eina_Bool -_efl_loop_timeout_force_cancel_cb(void *data, const Eo_Event *event EINA_UNUSED) -{ - _efl_loop_internal_cancel(data); - - return EO_CALLBACK_CONTINUE; -} - -EO_CALLBACKS_ARRAY_DEFINE(timeout, - { EFL_LOOP_TIMER_EVENT_TICK, _efl_loop_timeout_cb }, - { EO_EVENT_DEL, _efl_loop_timeout_force_cancel_cb }); - static Eina_Promise * _efl_loop_timeout(Eo *obj, Efl_Loop_Data *pd EINA_UNUSED, double time, const void *data) { --
[EGIT] [core/efl] master 08/08: ecore: add a test for detecting the double free problem.
cedric pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=b7facb2f0b684f168aa4b9565f9c7b8d42844252 commit b7facb2f0b684f168aa4b9565f9c7b8d42844252 Author: Cedric BAILDate: Fri Jun 3 16:59:55 2016 -0700 ecore: add a test for detecting the double free problem. --- src/tests/ecore/ecore_test_timer.c | 35 +++ 1 file changed, 35 insertions(+) diff --git a/src/tests/ecore/ecore_test_timer.c b/src/tests/ecore/ecore_test_timer.c index 25018bd..747e33e 100644 --- a/src/tests/ecore/ecore_test_timer.c +++ b/src/tests/ecore/ecore_test_timer.c @@ -208,8 +208,43 @@ START_TEST(ecore_test_timeout) } END_TEST +static void +_ecore_promise_then(void *data EINA_UNUSED, void *value EINA_UNUSED) +{ + abort(); +} + +static void +_ecore_promise_cancel(void *data, Eina_Error error) +{ + Eina_Bool *bob = data; + + fail_if(error != EINA_ERROR_PROMISE_CANCEL); + *bob = EINA_TRUE; +} + +START_TEST(ecore_test_timeout_cancel) +{ + Eina_Promise *timeout = NULL; + Eina_Bool bob = EINA_FALSE; + double start; + + ecore_init(); + + start = ecore_time_get(); + timeout = efl_loop_timeout(ecore_main_loop_get(), 0.2, ); + eina_promise_then(timeout, &_ecore_promise_then, &_ecore_promise_cancel, ); + eina_promise_cancel(timeout); + + fail_if(bob != EINA_TRUE); + + ecore_shutdown(); +} +END_TEST + void ecore_test_timer(TCase *tc) { tcase_add_test(tc, ecore_test_timers); tcase_add_test(tc, ecore_test_timeout); + tcase_add_test(tc, ecore_test_timeout_cancel); } --
[EGIT] [core/efl] master 04/08: eina: protect promise death during callbacks cancel.
cedric pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=af2b0c8629d6cdfd70f6b21b6d06434717bd3373 commit af2b0c8629d6cdfd70f6b21b6d06434717bd3373 Author: Cedric BAILDate: Fri Jun 3 16:54:38 2016 -0700 eina: protect promise death during callbacks cancel. --- src/lib/eina/eina_promise.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/lib/eina/eina_promise.c b/src/lib/eina/eina_promise.c index 7eac26e..8a207f7 100644 --- a/src/lib/eina/eina_promise.c +++ b/src/lib/eina/eina_promise.c @@ -193,6 +193,7 @@ _eina_promise_cancel_calls(_Eina_Promise_Default_Owner* promise, Eina_Bool call_ { _Eina_Promise_Cancel_Cb* callback; + _eina_promise_ref(>promise); EINA_INLIST_FREE(promise->promise.cancel_callbacks, callback) { promise->promise.cancel_callbacks = eina_inlist_remove(promise->promise.cancel_callbacks, EINA_INLIST_GET(callback)); @@ -207,6 +208,7 @@ _eina_promise_cancel_calls(_Eina_Promise_Default_Owner* promise, Eina_Bool call_ { _eina_promise_then_calls(promise); } + _eina_promise_unref(>promise); } static void --
[EGIT] [core/efl] master 05/08: ecore: do not generate error while rescheduling the last timer.
cedric pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=10ee8bc844db4d0210139a821cce25fc0f5e12a6 commit 10ee8bc844db4d0210139a821cce25fc0f5e12a6 Author: Cedric BAILDate: Fri Jun 3 16:55:56 2016 -0700 ecore: do not generate error while rescheduling the last timer. --- src/lib/ecore/ecore_timer.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/lib/ecore/ecore_timer.c b/src/lib/ecore/ecore_timer.c index 39cba76..89f9616 100644 --- a/src/lib/ecore/ecore_timer.c +++ b/src/lib/ecore/ecore_timer.c @@ -561,7 +561,8 @@ _efl_loop_timer_reschedule(Efl_Loop_Timer_Data *timer, { if (timer->frozen) return; - timers = eina_inlist_remove(timers, EINA_INLIST_GET(timer)); + if (timers) + timers = eina_inlist_remove(timers, EINA_INLIST_GET(timer)); /* if the timer would have gone off more than 15 seconds ago, * assume that the system hung and set the timer to go off --
[EGIT] [core/efl] master 06/08: ecore: use EINA_ERROR_PROMISE_CANCEL instead of a custom Ecore one.
cedric pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=0e6d5df60c7fb19baa2f4b2fc426dbb48de9a74a commit 0e6d5df60c7fb19baa2f4b2fc426dbb48de9a74a Author: Cedric BAILDate: Fri Jun 3 16:57:30 2016 -0700 ecore: use EINA_ERROR_PROMISE_CANCEL instead of a custom Ecore one. --- src/lib/ecore/ecore.c | 4 src/lib/ecore/ecore_main.c| 2 +- src/lib/ecore/ecore_private.h | 2 -- 3 files changed, 1 insertion(+), 7 deletions(-) diff --git a/src/lib/ecore/ecore.c b/src/lib/ecore/ecore.c index 389355c..5a9e2d2 100644 --- a/src/lib/ecore/ecore.c +++ b/src/lib/ecore/ecore.c @@ -67,8 +67,6 @@ static int _ecore_init_count_threshold = 0; int _ecore_log_dom = -1; int _ecore_fps_debug = 0; -Eina_Error _promise_canceled; - typedef struct _Ecore_Safe_Call Ecore_Safe_Call; struct _Ecore_Safe_Call { @@ -252,8 +250,6 @@ ecore_init(void) if (!ecore_mempool_init()) goto shutdown_mempool; _ecore_main_loop_init(); - _promise_canceled = eina_error_msg_static_register("Promise has been canceled."); - vpath = eo_add(EFL_VPATH_CORE_CLASS, NULL); if (vpath) efl_vpath_manager_register(EFL_VPATH_MANAGER_CLASS, 0, vpath); diff --git a/src/lib/ecore/ecore_main.c b/src/lib/ecore/ecore_main.c index 01b7875..7520ce5 100644 --- a/src/lib/ecore/ecore_main.c +++ b/src/lib/ecore/ecore_main.c @@ -2863,7 +2863,7 @@ _efl_loop_args_add(Eo *obj, Efl_Loop_Data *pd EINA_UNUSED, int argc, const char static void _efl_loop_internal_cancel(Efl_Internal_Promise *p) { - eina_promise_owner_error_set(p->promise, _promise_canceled); + eina_promise_owner_error_set(p->promise, EINA_ERROR_PROMISE_CANCEL); free(p); } diff --git a/src/lib/ecore/ecore_private.h b/src/lib/ecore/ecore_private.h index 37303f4..1b4b355 100644 --- a/src/lib/ecore/ecore_private.h +++ b/src/lib/ecore/ecore_private.h @@ -359,8 +359,6 @@ GENERIC_ALLOC_FREE_HEADER(Ecore_Win32_Handler, ecore_win32_handler); #undef GENERIC_ALLOC_FREE_HEADER -extern Eina_Error _promise_canceled; - extern Eo *_mainloop_singleton; extern Eo *_ecore_parent; #define ECORE_PARENT_CLASS ecore_parent_class_get() --
[EGIT] [core/efl] master 02/08: ecore: Efl.Timer should be Efl.Loop.Timer for coherence.
cedric pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=b3d56820d53897958379aaf9061378fc6df7b078 commit b3d56820d53897958379aaf9061378fc6df7b078 Author: Cedric BAILDate: Fri Jun 3 16:01:08 2016 -0700 ecore: Efl.Timer should be Efl.Loop.Timer for coherence. As we add more object in the main loop, they can't live in the top namespace as they make little sense there (Efl.Fd !). For coherence, everyone should in the loop namespace, so move timer there. --- src/Makefile_Ecore.am | 2 +- src/lib/ecore/Ecore_Eo.h | 2 +- src/lib/ecore/Ecore_Legacy.h | 2 +- src/lib/ecore/ecore.c | 2 +- src/lib/ecore/ecore_main.c| 58 src/lib/ecore/ecore_private.h | 16 +-- src/lib/ecore/ecore_timer.c | 164 +++--- src/lib/ecore/{efl_timer.eo => efl_loop_timer.eo} | 2 +- 8 files changed, 124 insertions(+), 124 deletions(-) diff --git a/src/Makefile_Ecore.am b/src/Makefile_Ecore.am index 1f544c6..83f5407 100644 --- a/src/Makefile_Ecore.am +++ b/src/Makefile_Ecore.am @@ -4,7 +4,7 @@ ecore_eolian_files_legacy = \ lib/ecore/ecore_poller.eo \ lib/ecore/ecore_exe.eo \ - lib/ecore/efl_timer.eo + lib/ecore/efl_loop_timer.eo ecore_eolian_files = \ lib/ecore/efl_loop.eo \ diff --git a/src/lib/ecore/Ecore_Eo.h b/src/lib/ecore/Ecore_Eo.h index 5214680..c2a1311 100644 --- a/src/lib/ecore/Ecore_Eo.h +++ b/src/lib/ecore/Ecore_Eo.h @@ -23,7 +23,7 @@ extern "C" { * @{ */ -#include "efl_timer.eo.h" +#include "efl_loop_timer.eo.h" /** * @} diff --git a/src/lib/ecore/Ecore_Legacy.h b/src/lib/ecore/Ecore_Legacy.h index ecf6a69..ca47e07 100644 --- a/src/lib/ecore/Ecore_Legacy.h +++ b/src/lib/ecore/Ecore_Legacy.h @@ -235,7 +235,7 @@ EAPI Eina_Bool ecore_timer_freeze_get(Ecore_Timer *timer); EAPI void ecore_timer_thaw(Ecore_Timer *timer); -#include "efl_timer.eo.legacy.h" +#include "efl_loop_timer.eo.legacy.h" /** * @} diff --git a/src/lib/ecore/ecore.c b/src/lib/ecore/ecore.c index 6c5..389355c 100644 --- a/src/lib/ecore/ecore.c +++ b/src/lib/ecore/ecore.c @@ -406,7 +406,7 @@ ecore_shutdown(void) #ifndef HAVE_EXOTIC _ecore_exe_shutdown(); #endif - _efl_timer_shutdown(); + _efl_loop_timer_shutdown(); _ecore_event_shutdown(); _ecore_main_shutdown(); _ecore_signal_shutdown(); diff --git a/src/lib/ecore/ecore_main.c b/src/lib/ecore/ecore_main.c index 38d888f..01b7875 100644 --- a/src/lib/ecore/ecore_main.c +++ b/src/lib/ecore/ecore_main.c @@ -460,7 +460,7 @@ _ecore_main_uv_poll_cb(uv_poll_t* handle, int status, int events) _ecore_signal_received_process(); _ecore_event_call(); _ecore_main_fd_handlers_cleanup(); - _efl_timer_expired_timers_call(_ecore_time_loop_time); + _efl_loop_timer_expired_timers_call(_ecore_time_loop_time); } static int @@ -704,7 +704,7 @@ _ecore_main_gsource_prepare(GSource *source EINA_UNUSED, if (!ecore_idling && !_ecore_glib_idle_enterer_called) { _ecore_time_loop_time = ecore_time_get(); -_efl_timer_expired_timers_call(_ecore_time_loop_time); +_efl_loop_timer_expired_timers_call(_ecore_time_loop_time); _ecore_idle_enterer_call(_mainloop_singleton); _ecore_throttle(); @@ -722,10 +722,10 @@ _ecore_main_gsource_prepare(GSource *source EINA_UNUSED, /* only set idling state in dispatch */ if (ecore_idling && !_ecore_idler_exist(_mainloop_singleton) && !_ecore_event_exist()) { - if (_efl_timers_exists()) + if (_efl_loop_timers_exists()) { int r = -1; - double t = _efl_timer_next_get(); + double t = _efl_loop_timer_next_get(); if (timer_fd >= 0 && t > 0.0) { struct itimerspec ts; @@ -821,8 +821,8 @@ _ecore_main_gsource_check(GSource *source EINA_UNUSED) ret = TRUE; /* check timers after updating loop time */ - if (!ret && _efl_timers_exists()) - ret = (0.0 == _efl_timer_next_get()); + if (!ret && _efl_loop_timers_exists()) + ret = (0.0 == _efl_loop_timer_next_get()); in_main_loop--; @@ -839,11 +839,11 @@ _ecore_main_gsource_dispatch(GSource*source EINA_UNUSED, double next_time; _ecore_time_loop_time = ecore_time_get(); - _efl_timer_enable_new(); - next_time = _efl_timer_next_get(); + _efl_loop_timer_enable_new(); + next_time = _efl_loop_timer_next_get(); events_ready = _ecore_event_exist(); - timers_ready = _efl_timers_exists() && (0.0 == next_time); + timers_ready = _efl_loop_timers_exists() && (0.0 == next_time); idlers_ready = _ecore_idler_exist(_mainloop_singleton); in_main_loop++; @@ -886,7 +886,7 @@
Re: [E-devel] Next release
On 06/04/2016 08:54 AM, Cedric BAIL wrote: > Hello, > > I just would like to start a thread regarding what is still pending > for next release and what we should do about it. First let's start > with what is not ready : > - Most of the elementary widgets have not been renamed correctly to be > in efl.ui namespace. > - Edje and Elm.Layout have not been refactorized and properly > inherited from each other. > - Text interface is not there (this impact also entry, label and edje). > - Genlist is also not there. > - All eo object still needs a proper cleanup and use of own(). > - Uri manager is not there. > - Color/Color_Class is not there. > - Efl photocam is not there. > - Efl video is not there. > - Efl.Ui.Window is not there. > - Efl.Ui.Focus cleanup is not there. > > Sone of the above have patch in review process that may land before > Monday morning, but I prefer to just give the current status as I may > not have time this weekend as I am moving. Also most of the API that > have landed so far have not been tested in any real application and we > don't really if they do fit their purpose (making life easier). > > It is obvious to me, and I am pretty to sure to everyone involved in > the development of 1.18 that we can not do an alpha while some of the > biggest change are not there yet. Now the question is should we delay > the alpha ? Or should we make the alpha a technical preview followed > by an alpha later on ? Should we just move on and delay the above > change for 1.19, in which case all the new API need to remain BETA. > Also if we do delay, how much longer is needed for a release ? Isn't > it going to drag on ? > > Oh and did I miss anything in the above list ? > The technical Preview hasn't even been possible till now as building elementary examples from a make dist tar fails for a number of reasons, there is also no point in doing a alpha with known issues building it. I'm yet to build with evas_generic_loaders / emotion generic players to test that they build either, its probably worth someone building a dist tar then actually compiling the contents before the alpha (I'll get to that this weekend or next week). Cheers -- Simon Lees (Simotek)http://simotek.net Emergency Update Team keybase.io/simotek SUSE LinuxAdeliade Australia, UTC+9:30 GPG Fingerprint: 5B87 DB9D 88DC F606 E489 CEC5 0922 C246 02F0 014B signature.asc Description: OpenPGP digital signature -- What NetFlow Analyzer can do for you? Monitors network bandwidth and traffic patterns at an interface-level. Reveals which users, apps, and protocols are consuming the most bandwidth. Provides multi-vendor support for NetFlow, J-Flow, sFlow and other flows. Make informed decisions using capacity planning reports. https://ad.doubleclick.net/ddm/clk/305295220;132659582;e___ enlightenment-devel mailing list enlightenment-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
[E-devel] Next release
Hello, I just would like to start a thread regarding what is still pending for next release and what we should do about it. First let's start with what is not ready : - Most of the elementary widgets have not been renamed correctly to be in efl.ui namespace. - Edje and Elm.Layout have not been refactorized and properly inherited from each other. - Text interface is not there (this impact also entry, label and edje). - Genlist is also not there. - All eo object still needs a proper cleanup and use of own(). - Uri manager is not there. - Color/Color_Class is not there. - Efl photocam is not there. - Efl video is not there. - Efl.Ui.Window is not there. - Efl.Ui.Focus cleanup is not there. Sone of the above have patch in review process that may land before Monday morning, but I prefer to just give the current status as I may not have time this weekend as I am moving. Also most of the API that have landed so far have not been tested in any real application and we don't really if they do fit their purpose (making life easier). It is obvious to me, and I am pretty to sure to everyone involved in the development of 1.18 that we can not do an alpha while some of the biggest change are not there yet. Now the question is should we delay the alpha ? Or should we make the alpha a technical preview followed by an alpha later on ? Should we just move on and delay the above change for 1.19, in which case all the new API need to remain BETA. Also if we do delay, how much longer is needed for a release ? Isn't it going to drag on ? Oh and did I miss anything in the above list ? -- Cedric BAIL -- What NetFlow Analyzer can do for you? Monitors network bandwidth and traffic patterns at an interface-level. Reveals which users, apps, and protocols are consuming the most bandwidth. Provides multi-vendor support for NetFlow, J-Flow, sFlow and other flows. Make informed decisions using capacity planning reports. https://ad.doubleclick.net/ddm/clk/305295220;132659582;e ___ enlightenment-devel mailing list enlightenment-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
[EGIT] [core/efl] master 02/02: eina: Remove Eina_Promise* parameter to callbacks to promises in examples
felipealmeida pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=f6a260e7a9ff550483d0a081cf4ce90cc4e2bfc8 commit f6a260e7a9ff550483d0a081cf4ce90cc4e2bfc8 Author: Felipe Magno de AlmeidaDate: Fri Jun 3 20:03:13 2016 -0300 eina: Remove Eina_Promise* parameter to callbacks to promises in examples --- src/examples/eio/eio_job_ls.c | 1 - src/examples/eio/eio_job_open.c | 6 +++--- src/examples/eio/eio_job_open_multi.c | 1 - src/examples/eldbus/dbusmodel.c | 20 +++- src/examples/elementary/filemvc.c | 2 +- 5 files changed, 15 insertions(+), 15 deletions(-) diff --git a/src/examples/eio/eio_job_ls.c b/src/examples/eio/eio_job_ls.c index 2e2db1f..9426c23 100644 --- a/src/examples/eio/eio_job_ls.c +++ b/src/examples/eio/eio_job_ls.c @@ -21,7 +21,6 @@ void done_cb(void *data, void *value EINA_UNUSED) void error_cb(void *data, Eina_Error error) { Eio_Job *job = data; -EINA_SAFETY_ON_NULL_RETURN(error); const char *msg = eina_error_msg_get(error); printf("%s error: %s\n", __FUNCTION__, msg); ecore_main_loop_quit(); diff --git a/src/examples/eio/eio_job_open.c b/src/examples/eio/eio_job_open.c index 7662bfb..9977243 100644 --- a/src/examples/eio/eio_job_open.c +++ b/src/examples/eio/eio_job_open.c @@ -9,7 +9,7 @@ #include #include -void error_cb(void *data, Eina_Error error, Eina_Promise* promise EINA_UNUSED) +void error_cb(void *data, Eina_Error error) { EINA_SAFETY_ON_NULL_RETURN(data); @@ -19,7 +19,7 @@ void error_cb(void *data, Eina_Error error, Eina_Promise* promise EINA_UNUSED) ecore_main_loop_quit(); } -void done_closing_cb(void* data EINA_UNUSED, void *value EINA_UNUSED, Eina_Promise* promise EINA_UNUSED) +void done_closing_cb(void* data EINA_UNUSED, void *value EINA_UNUSED) { printf("%s closed file.\n", __FUNCTION__); @@ -34,7 +34,7 @@ void closing_job(Eio_Job *job, Eina_File *file) eina_promise_then(promise, _closing_cb, _cb, job); } -void done_open_cb(void *data, void* value, Eina_Promise* promise) +void done_open_cb(void *data, void* value) { EINA_SAFETY_ON_NULL_RETURN(data); EINA_SAFETY_ON_NULL_RETURN(value); diff --git a/src/examples/eio/eio_job_open_multi.c b/src/examples/eio/eio_job_open_multi.c index d1f8fa9..c621ade 100644 --- a/src/examples/eio/eio_job_open_multi.c +++ b/src/examples/eio/eio_job_open_multi.c @@ -11,7 +11,6 @@ void error_cb(void *data, Eina_Error error) { -EINA_SAFETY_ON_NULL_RETURN(error); EINA_SAFETY_ON_NULL_RETURN(data); const char *msg = eina_error_msg_get(error); diff --git a/src/examples/eldbus/dbusmodel.c b/src/examples/eldbus/dbusmodel.c index 4cc7178..9695bd5 100644 --- a/src/examples/eldbus/dbusmodel.c +++ b/src/examples/eldbus/dbusmodel.c @@ -16,8 +16,9 @@ static int prop_count = 0; static void -promise_then_prop_c(Eo* obj, void* data) +promise_then_prop_c(void* priv_obj, void* data) { + Eo* obj = priv_obj; Eina_Value * property_value; const Eina_Array *properties_list; Eina_Array_Iterator a_it; @@ -46,14 +47,14 @@ promise_then_prop_c(Eo* obj, void* data) } static void -error_cb(void* data EINA_UNUSED, const Eina_Error *error EINA_UNUSED) +error_cb(void* data EINA_UNUSED, Eina_Error error EINA_UNUSED) { printf(" ERROR\n"); ecore_main_loop_quit(); } static void -promise_then_a(Eo* obj EINA_UNUSED, void* data) +promise_then_a(void* priv_obj EINA_UNUSED, void* data) { const Eina_Array *properties_list; Eina_Array_Iterator a_it; @@ -95,7 +96,7 @@ promise_then_a(Eo* obj EINA_UNUSED, void* data) ecore_main_loop_quit(); } static void -promise_then(Eo* obj EINA_UNUSED, void* data) +promise_then(void* obj EINA_UNUSED, void* data) { Eina_Accessor *accessor; unsigned int* count; @@ -109,12 +110,13 @@ promise_then(Eo* obj EINA_UNUSED, void* data) return; } - eina_iterator_next(iterator, (void **)); - - printf("efl_model_loaded count %d\n", (int)*count); fflush(stdout); - printf("efl_model_loaded accessor %p\n", accessor); fflush(stdout); + if(eina_iterator_next(iterator, (void **))) + { +printf("efl_model_loaded count %d\n", (int)*count); fflush(stdout); +printf("efl_model_loaded accessor %p\n", accessor); fflush(stdout); - promise_then_a(NULL, accessor); +promise_then_a(NULL, accessor); + } } int diff --git a/src/examples/elementary/filemvc.c b/src/examples/elementary/filemvc.c index 1f05feb..75fe652 100644 --- a/src/examples/elementary/filemvc.c +++ b/src/examples/elementary/filemvc.c @@ -71,7 +71,7 @@ _promise_then(void *data, void *value) } static void -_promise_error(void *data, const Eina_Error *err) +_promise_error(void *data, const Eina_Error err) { } --
[EGIT] [core/efl] master 01/02: eina: Add NULL checks and EINA_MAGIC checks to promises
felipealmeida pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=cd91b02dd1f04daaed19b51c7fda2d4047b4ad78 commit cd91b02dd1f04daaed19b51c7fda2d4047b4ad78 Author: Felipe Magno de AlmeidaDate: Fri Jun 3 20:02:02 2016 -0300 eina: Add NULL checks and EINA_MAGIC checks to promises Add NULL checks and EINA_MAGIC checks that avoid crashing when it shouldn't. --- src/lib/eina/eina_promise.c | 64 +++-- src/lib/eina/eina_promise.h | 8 ++ 2 files changed, 70 insertions(+), 2 deletions(-) diff --git a/src/lib/eina/eina_promise.c b/src/lib/eina/eina_promise.c index e1fda3c..7eac26e 100644 --- a/src/lib/eina/eina_promise.c +++ b/src/lib/eina/eina_promise.c @@ -667,6 +667,8 @@ eina_promise_all(Eina_Iterator* it) Eina_Promise **cur_promise, **last; _Eina_Promise_Iterator* internal_it; + EINA_SAFETY_ON_NULL_RETURN_VAL(it, NULL); + promises = eina_array_new(20); EINA_ITERATOR_FOREACH(it, current) @@ -755,6 +757,7 @@ _eina_promise_progress_notify_fulfilled(void* data, Eina_Promise_Owner* p EINA_U EAPI Eina_Error EINA_ERROR_PROMISE_NO_NOTIFY; EAPI Eina_Error EINA_ERROR_PROMISE_CANCEL; +EAPI Eina_Error EINA_ERROR_PROMISE_NULL; static void _eina_promise_progress_notify_failed(void* data) @@ -831,6 +834,8 @@ eina_promise_race(Eina_Iterator* it) _Eina_Promise_Race_Value_Type *value; int num_promises; + EINA_SAFETY_ON_NULL_RETURN_VAL(it, NULL); + promises = eina_array_new(20); EINA_ITERATOR_FOREACH(it, current) @@ -872,36 +877,65 @@ EAPI void eina_promise_then(Eina_Promise* promise, Eina_Promise_Cb callback, Eina_Promise_Error_Cb error_cb, void* data) { - promise->then(promise, callback, error_cb, data); -} + if(!promise) + { +error_cb(data, EINA_ERROR_PROMISE_NULL); +return; + } + else + promise->then(promise, callback, error_cb, data); +} + +#define _EINA_PROMISE_NULL_CHECK(promise, v)\ + if(!promise) \ +{ \ + eina_error_set(EINA_ERROR_PROMISE_NULL); \ + return v; \ +} +#define EINA_MAGIC_CHECK_PROMISE(promise) \ + do if(!EINA_MAGIC_CHECK(promise, EINA_MAGIC_PROMISE))\ + {EINA_MAGIC_FAIL(promise, EINA_MAGIC_PROMISE);} while(0) +#define EINA_MAGIC_CHECK_PROMISE_OWNER(promise) \ + do {if(!EINA_MAGIC_CHECK(promise, EINA_MAGIC_PROMISE_OWNER)) \ + {EINA_MAGIC_FAIL(promise, EINA_MAGIC_PROMISE_OWNER);} } while(0) EAPI void eina_promise_owner_value_set(Eina_Promise_Owner* promise, const void* value, Eina_Promise_Free_Cb free) { + _EINA_PROMISE_NULL_CHECK(promise, ); + EINA_MAGIC_CHECK_PROMISE_OWNER(promise); promise->value_set(promise, value, free); } EAPI void eina_promise_owner_error_set(Eina_Promise_Owner* promise, Eina_Error error) { + _EINA_PROMISE_NULL_CHECK(promise, ); + EINA_MAGIC_CHECK_PROMISE_OWNER(promise); promise->error_set(promise, error); } EAPI void * eina_promise_value_get(Eina_Promise const* promise) { + _EINA_PROMISE_NULL_CHECK(promise, NULL); + EINA_MAGIC_CHECK_PROMISE(promise); return promise->value_get(promise); } EAPI Eina_Error eina_promise_error_get(Eina_Promise const* promise) { + _EINA_PROMISE_NULL_CHECK(promise, EINA_ERROR_PROMISE_NULL); + EINA_MAGIC_CHECK_PROMISE(promise); return promise->error_get(promise); } EAPI Eina_Bool eina_promise_pending_is(Eina_Promise const* promise) { + _EINA_PROMISE_NULL_CHECK(promise, EINA_FALSE); + EINA_MAGIC_CHECK_PROMISE(promise); return promise->pending_is(promise); } @@ -909,66 +943,88 @@ EAPI void eina_promise_progress_cb_add(Eina_Promise* promise, Eina_Promise_Progress_Cb callback, void* data, Eina_Promise_Free_Cb free_cb) { + _EINA_PROMISE_NULL_CHECK(promise, ); + EINA_MAGIC_CHECK_PROMISE(promise); promise->progress_cb_add(promise, callback, data, free_cb); } EAPI void eina_promise_cancel(Eina_Promise* promise) { + _EINA_PROMISE_NULL_CHECK(promise, ); + EINA_MAGIC_CHECK_PROMISE(promise); promise->cancel(promise); } EAPI void eina_promise_ref(Eina_Promise* promise) { + _EINA_PROMISE_NULL_CHECK(promise, ); + EINA_MAGIC_CHECK_PROMISE(promise); promise->ref(promise); } EAPI void eina_promise_unref(Eina_Promise* promise) { + _EINA_PROMISE_NULL_CHECK(promise, ); + EINA_MAGIC_CHECK_PROMISE(promise); promise->unref(promise); } EAPI void * eina_promise_owner_buffer_get(Eina_Promise_Owner* promise) { + _EINA_PROMISE_NULL_CHECK(promise, NULL); + EINA_MAGIC_CHECK_PROMISE(promise); return promise->buffer_get(promise); } EAPI void * eina_promise_buffer_get(Eina_Promise* promise) { + _EINA_PROMISE_NULL_CHECK(promise, NULL); + EINA_MAGIC_CHECK_PROMISE(promise); return
[EGIT] [core/efl] master 01/01: eina: Remove more Eina_Promise* parameter in promise callback
felipealmeida pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=e98c57d9d414c654c2e90cad19ec791d02374448 commit e98c57d9d414c654c2e90cad19ec791d02374448 Author: Felipe Magno de AlmeidaDate: Fri Jun 3 18:34:42 2016 -0300 eina: Remove more Eina_Promise* parameter in promise callback Remove not very useful parameter to eina_promise_then callbacks. --- src/tests/ecore/ecore_test_job.c | 2 +- src/tests/eina/eina_test_promise.c | 10 +- src/tests/eio/eio_test_job_xattr.c | 8 3 files changed, 10 insertions(+), 10 deletions(-) diff --git a/src/tests/ecore/ecore_test_job.c b/src/tests/ecore/ecore_test_job.c index 60eebde..2e1a528 100644 --- a/src/tests/ecore/ecore_test_job.c +++ b/src/tests/ecore/ecore_test_job.c @@ -6,7 +6,7 @@ #include "ecore_suite.h" static void -_ecore_promise_quit(void *data, void *value, Eina_Promise* promise EINA_UNUSED) +_ecore_promise_quit(void *data, void *value) { Eina_Bool *bob = data; diff --git a/src/tests/eina/eina_test_promise.c b/src/tests/eina/eina_test_promise.c index 7c6d33a..8df6e26 100644 --- a/src/tests/eina/eina_test_promise.c +++ b/src/tests/eina/eina_test_promise.c @@ -32,7 +32,7 @@ #include "eina_suite.h" static void -_eina_test_promise_cb(void* data, void* value EINA_UNUSED, Eina_Promise* promise EINA_UNUSED) +_eina_test_promise_cb(void* data, void* value EINA_UNUSED) { *(Eina_Bool*)data = EINA_TRUE; } @@ -122,7 +122,7 @@ START_TEST(eina_test_promise_immediate_set_lifetime_all) } END_TEST -static void _eina_test_promise_value_all_cb(void* data, void* value, Eina_Promise* promise EINA_UNUSED) +static void _eina_test_promise_value_all_cb(void* data, void* value) { Eina_Iterator* iterator = value; int *i, *j; @@ -178,7 +178,7 @@ static void cancel_callback(void* data, Eina_Promise_Owner* promise EINA_UNUSED) *(Eina_Bool*)data = EINA_TRUE; } -static void _cancel_promise_callback(void* data EINA_UNUSED, Eina_Error error EINA_UNUSED, Eina_Promise* promise EINA_UNUSED) +static void _cancel_promise_callback(void* data EINA_UNUSED, Eina_Error error EINA_UNUSED) { *(Eina_Bool*)data = EINA_TRUE; } @@ -284,13 +284,13 @@ START_TEST(eina_test_promise_progress_notify2) END_TEST static void -_eina_promise_progress_notify_fulfilled(void* data, void* value EINA_UNUSED, Eina_Promise* promise EINA_UNUSED) +_eina_promise_progress_notify_fulfilled(void* data, void* value EINA_UNUSED) { *(Eina_Bool*)data = EINA_TRUE; } static void -_eina_promise_progress_notify_error(void* data EINA_UNUSED, Eina_Error error EINA_UNUSED, Eina_Promise* promise EINA_UNUSED) +_eina_promise_progress_notify_error(void* data EINA_UNUSED, Eina_Error error EINA_UNUSED) { ck_assert(EINA_FALSE); } diff --git a/src/tests/eio/eio_test_job_xattr.c b/src/tests/eio/eio_test_job_xattr.c index d47fb50..f2fd2bb 100644 --- a/src/tests/eio/eio_test_job_xattr.c +++ b/src/tests/eio/eio_test_job_xattr.c @@ -60,7 +60,7 @@ _main_cb(void *data, void *v) } static void -_done_cb(void *data, void *value EINA_UNUSED, Eina_Promise* promise EINA_UNUSED) +_done_cb(void *data, void *value EINA_UNUSED) { int *num_of_attr = (int *)data; @@ -71,7 +71,7 @@ _done_cb(void *data, void *value EINA_UNUSED, Eina_Promise* promise EINA_UNUSED) } static void -_done_get_cb(void *data EINA_UNUSED, void* v, Eina_Promise* promise EINA_UNUSED) +_done_get_cb(void *data EINA_UNUSED, void* v) { Eina_Iterator** it = (Eina_Iterator**)v; int i = 0; @@ -90,7 +90,7 @@ _done_get_cb(void *data EINA_UNUSED, void* v, Eina_Promise* promise EINA_UNUSED) } static void -_done_set_cb(void *data, void* v, Eina_Promise* promise EINA_UNUSED) +_done_set_cb(void *data, void* v) { Eina_Iterator** it = (Eina_Iterator**)v; int *placeholder; @@ -104,7 +104,7 @@ _done_set_cb(void *data, void* v, Eina_Promise* promise EINA_UNUSED) } static void -_error_cb(void *data EINA_UNUSED, Eina_Error error, Eina_Promise* promise EINA_UNUSED) +_error_cb(void *data EINA_UNUSED, Eina_Error error) { fprintf(stderr, "Something has gone wrong:%s\n", eina_error_msg_get(error)); --
Re: [E-devel] E22 Reprioritizing
2016-06-03 13:19 GMT-03:00 Mike Blumenkrantz: > Thanks for all your understanding and support, Take care man. Get well. -- Vinícius dos Santos Oliveira https://vinipsmaker.github.io/ -- What NetFlow Analyzer can do for you? Monitors network bandwidth and traffic patterns at an interface-level. Reveals which users, apps, and protocols are consuming the most bandwidth. Provides multi-vendor support for NetFlow, J-Flow, sFlow and other flows. Make informed decisions using capacity planning reports. https://ad.doubleclick.net/ddm/clk/305295220;132659582;e ___ enlightenment-devel mailing list enlightenment-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
[EGIT] [core/efl] master 02/03: psd_loader: Fix bad assumption about signedness of chars
derekf pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=34ce296cac84980a55a842675c260d32c1a958bd commit 34ce296cac84980a55a842675c260d32c1a958bd Author: Derek ForemanDate: Fri Jun 3 16:25:50 2016 -0500 psd_loader: Fix bad assumption about signedness of chars Whether "char" is signed or unsigned is architecture dependent, so if we know we need a -1 in a char type we must declared it to be signed. --- src/modules/evas/image_loaders/psd/evas_image_load_psd.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/modules/evas/image_loaders/psd/evas_image_load_psd.c b/src/modules/evas/image_loaders/psd/evas_image_load_psd.c index 6c8879a..f39fd28 100644 --- a/src/modules/evas/image_loaders/psd/evas_image_load_psd.c +++ b/src/modules/evas/image_loaders/psd/evas_image_load_psd.c @@ -200,7 +200,8 @@ read_compressed_channel(const unsigned char *map, size_t length, size_t *positio { // FIXME: what does channel_length means, and why is it not used unsigned int i; - char headbyte, c; + signed char headbyte; + unsigned char c; #define CHECK_RET(Call) \ if (!Call) return READ_COMPRESSED_ERROR_FILE_READ_ERROR;\ @@ -502,7 +503,7 @@ get_single_channel(PSD_Header *head, Eina_Bool compressed) { unsigned int i, bpc; - char headbyte; + signed char headbyte; int c; int pixels_count; --
[EGIT] [core/efl] master 03/03: wayland_shm: Fix more dmabuf failure corner cases
derekf pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=3de4e3100371206b1343afd7a4c4832b61964fcd commit 3de4e3100371206b1343afd7a4c4832b61964fcd Author: Derek ForemanDate: Fri Jun 3 16:27:14 2016 -0500 wayland_shm: Fix more dmabuf failure corner cases With the exynos allocator a failure can happen during a resize, and the resize path wasn't properly falling back to wl_shm buffering. --- src/modules/evas/engines/wayland_shm/evas_dmabuf.c | 52 +- 1 file changed, 32 insertions(+), 20 deletions(-) diff --git a/src/modules/evas/engines/wayland_shm/evas_dmabuf.c b/src/modules/evas/engines/wayland_shm/evas_dmabuf.c index 3cb112c..5d39e41 100644 --- a/src/modules/evas/engines/wayland_shm/evas_dmabuf.c +++ b/src/modules/evas/engines/wayland_shm/evas_dmabuf.c @@ -322,31 +322,19 @@ static const struct wl_buffer_listener buffer_listener = }; static void -_allocation_complete(Dmabuf_Buffer *b) +_fallback(Dmabuf_Surface *s, int w, int h) { - Surface *s; - int w, h, num_buf; Eina_Bool recovered; - b->pending = EINA_FALSE; - if (!dmabuf_totally_hosed) return; - - if (!b->surface) return; - - /* Something went wrong, better try to fall back to a different -* buffer type... -*/ - s = b->surface->surface; - w = b->w; - h = b->h; - num_buf = b->surface->nbuf; + dmabuf_totally_hosed = EINA_TRUE; /* Depending when things broke we may need this commit to get * the frame callback to fire and keep the animator running */ - wl_surface_commit(b->surface->wl_surface); - _evas_dmabuf_surface_destroy(b->surface->surface); - recovered = _evas_surface_init(s, w, h, num_buf); + wl_surface_commit(s->wl_surface); + + _evas_dmabuf_surface_destroy(s->surface); + recovered = _evas_surface_init(s->surface, w, h, s->nbuf); if (recovered) return; ERR("Fallback from dmabuf to shm attempted and failed."); @@ -354,6 +342,20 @@ _allocation_complete(Dmabuf_Buffer *b) } static void +_allocation_complete(Dmabuf_Buffer *b) +{ + b->pending = EINA_FALSE; + if (!dmabuf_totally_hosed) return; + + if (!b->surface) return; + + /* Something went wrong, better try to fall back to a different +* buffer type... +*/ + _fallback(b->surface, b->w, b->h); +} + +static void _create_succeeded(void *data, struct zwp_linux_buffer_params_v1 *params, struct wl_buffer *new_buffer) @@ -417,6 +419,8 @@ _evas_dmabuf_buffer_unlock(Dmabuf_Buffer *b) static void _evas_dmabuf_buffer_destroy(Dmabuf_Buffer *b) { + if (!b) return; + if (b->locked || b->busy || b->pending) { b->orphaned = EINA_TRUE; @@ -432,6 +436,7 @@ _evas_dmabuf_buffer_destroy(Dmabuf_Buffer *b) static void _evas_dmabuf_surface_reconfigure(Surface *s, int w, int h, uint32_t flags EINA_UNUSED) { + Dmabuf_Buffer *buf; Dmabuf_Surface *surface; int i; @@ -449,7 +454,13 @@ _evas_dmabuf_surface_reconfigure(Surface *s, int w, int h, uint32_t flags EINA_U } _evas_dmabuf_buffer_destroy(b); -surface->buffer[i] = _evas_dmabuf_buffer_init(surface, w, h); +buf = _evas_dmabuf_buffer_init(surface, w, h); +surface->buffer[i] = buf; +if (!buf) + { + _fallback(surface, w, h); + return; + } } } @@ -581,6 +592,7 @@ _evas_dmabuf_buffer_init(Dmabuf_Surface *s, int w, int h) if (!out->bh) { free(out); + _fallback(s, w, h); return NULL; } out->w = w; @@ -660,6 +672,6 @@ _evas_dmabuf_surface_create(Surface *s, int w, int h, int num_buff) return EINA_TRUE; err: - _evas_dmabuf_surface_destroy(s); + _fallback(surf, w, h); return EINA_FALSE; } --
[EGIT] [core/efl] master 01/03: ecore_anim: Fix bad assumption about signedness of chars
derekf pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=6c2a3a2034dca023c01db6316a7ec8d5313c228d commit 6c2a3a2034dca023c01db6316a7ec8d5313c228d Author: Derek ForemanDate: Fri Jun 3 16:24:26 2016 -0500 ecore_anim: Fix bad assumption about signedness of chars Whether "char" is signed or unsigned is architecture dependent, so if we know we need a -1 in a char type we must declared it to be signed. --- src/lib/ecore/ecore_anim.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/lib/ecore/ecore_anim.c b/src/lib/ecore/ecore_anim.c index 5e5e034..80b389c 100644 --- a/src/lib/ecore/ecore_anim.c +++ b/src/lib/ecore/ecore_anim.c @@ -84,7 +84,7 @@ static Ecore_Thread *timer_thread = NULL; static volatile int timer_event_is_busy = 0; static void -_tick_send(char val) +_tick_send(signed char val) { DBG("_tick_send(%i)", val); if (pipe_write(timer_fd_write, , 1) != 1) @@ -111,7 +111,7 @@ _timer_tick_core(void *data EINA_UNUSED, Ecore_Thread *thread) fd_set rfds, wfds, exfds; struct timeval tv; unsigned int t; - char tick = 0; + signed char tick = 0; double t0, d; int ret; --
[EGIT] [core/efl] master 01/01: eina: Remove Eina_Promise* parameter in promise callback
felipealmeida pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=e79eb53e8d20bdb4838fbb42c9e5b1ee47b7f263 commit e79eb53e8d20bdb4838fbb42c9e5b1ee47b7f263 Author: Felipe Magno de AlmeidaDate: Fri Jun 3 18:15:57 2016 -0300 eina: Remove Eina_Promise* parameter in promise callback Remove not very useful parameter to eina_promise_then callbacks. --- src/lib/ecore/ecore_main.c | 3 +-- src/lib/ecore/ecore_thread_promise.c| 2 +- src/lib/eina/eina_promise.c | 6 +++--- src/lib/eina/eina_promise.h | 4 ++-- src/lib/elementary/elm_view_form.c | 8 src/lib/elementary/elm_view_list.c | 6 +++--- src/tests/ecore/ecore_test_promise.c| 26 ++ src/tests/ecore/ecore_test_timer.c | 2 +- src/tests/eio/eio_model_test_file.c | 8 src/tests/eio/eio_model_test_monitor_add.c | 4 ++-- src/tests/eio/eio_test_job.c| 14 +++--- src/tests/eldbus/eldbus_test_eldbus_model.c | 12 ++-- 12 files changed, 40 insertions(+), 55 deletions(-) diff --git a/src/lib/ecore/ecore_main.c b/src/lib/ecore/ecore_main.c index b9d5699..38d888f 100644 --- a/src/lib/ecore/ecore_main.c +++ b/src/lib/ecore/ecore_main.c @@ -2839,8 +2839,7 @@ _efl_loop_timeout_cb(void *data, const Eo_Event *event EINA_UNUSED) } static void -_efl_loop_args_job_cb(void *data, void *value EINA_UNUSED, - Eina_Promise *promise EINA_UNUSED) +_efl_loop_args_job_cb(void *data, void *value EINA_UNUSED) { Efl_Loop_Args *args = data; Eo *obj = eo_parent_get(args); diff --git a/src/lib/ecore/ecore_thread_promise.c b/src/lib/ecore/ecore_thread_promise.c index dcdd653..443920a 100644 --- a/src/lib/ecore/ecore_thread_promise.c +++ b/src/lib/ecore/ecore_thread_promise.c @@ -47,7 +47,7 @@ static void _ecore_promise_ref_update(_Ecore_Thread_Promise_Owner* p) } } -static void _ecore_promise_thread_release_ref(void* data, void* value EINA_UNUSED, Eina_Promise* promise EINA_UNUSED) +static void _ecore_promise_thread_release_ref(void* data, void* value EINA_UNUSED) { _Ecore_Thread_Promise_Owner* p = data; p->ref_count -= p->then_count; diff --git a/src/lib/eina/eina_promise.c b/src/lib/eina/eina_promise.c index 71f0381..e1fda3c 100644 --- a/src/lib/eina/eina_promise.c +++ b/src/lib/eina/eina_promise.c @@ -169,7 +169,7 @@ _eina_promise_then_calls(_Eina_Promise_Default_Owner* promise) if (error) { if (callback->error_cb) - (*callback->error_cb)(callback->data, promise->promise.error, >promise.vtable); + (*callback->error_cb)(callback->data, promise->promise.error); } else if (callback->callback) { @@ -177,10 +177,10 @@ _eina_promise_then_calls(_Eina_Promise_Default_Owner* promise) { char* buffer = promise->value; void** p = (void**)buffer; - (*callback->callback)(callback->data, *p, >promise.vtable); + (*callback->callback)(callback->data, *p); } else - (*callback->callback)(callback->data, >value[0], >promise.vtable); + (*callback->callback)(callback->data, >value[0]); } free(callback); _eina_promise_unref(>promise); diff --git a/src/lib/eina/eina_promise.h b/src/lib/eina/eina_promise.h index b1aa7fb..21a5db2 100644 --- a/src/lib/eina/eina_promise.h +++ b/src/lib/eina/eina_promise.h @@ -29,12 +29,12 @@ typedef void(*Eina_Promise_Progress_Notify_Cb)(void* data, Eina_Promise_Owner* p /* * @brief Function callback type for when using eina_promise_then */ -typedef void(*Eina_Promise_Cb)(void* data, void* value, Eina_Promise* promise); +typedef void(*Eina_Promise_Cb)(void* data, void* value); /* * @brief Function callback type for when using eina_promise_then */ -typedef void(*Eina_Promise_Error_Cb)(void* data, Eina_Error error, Eina_Promise* promise); +typedef void(*Eina_Promise_Error_Cb)(void* data, Eina_Error error); /* * @brief Function callback type for progress information diff --git a/src/lib/elementary/elm_view_form.c b/src/lib/elementary/elm_view_form.c index 57aafdc..ffc08a2 100644 --- a/src/lib/elementary/elm_view_form.c +++ b/src/lib/elementary/elm_view_form.c @@ -46,7 +46,7 @@ struct _Elm_View_Form_Promise static void -_efl_promise_then_widget(void* data, void* v, Eina_Promise* promise EINA_UNUSED) +_efl_promise_then_widget(void* data, void* v) { Elm_View_Form_Widget *w = data; Eina_Value *value = v; @@ -54,12 +54,12 @@ _efl_promise_then_widget(void* data, void* v, Eina_Promise* promise EINA_UNUSED) } static void -_efl_promise_error_widget(void *data EINA_UNUSED, Eina_Error err EINA_UNUSED, Eina_Promise* promise EINA_UNUSED) +_efl_promise_error_widget(void *data
[EGIT] [core/efl] master 02/03: eina: Fix examples using new Eina_Promise semantics
felipealmeida pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=865b69f6ff3f095e5d81648c391b2e9fb8519fdf commit 865b69f6ff3f095e5d81648c391b2e9fb8519fdf Author: Felipe Magno de AlmeidaDate: Fri Jun 3 16:53:54 2016 -0300 eina: Fix examples using new Eina_Promise semantics --- src/examples/eio/eio_job_ls.c | 8 src/examples/eio/eio_job_open.c | 23 +++ src/examples/eio/eio_job_open_multi.c | 14 -- src/examples/eldbus/dbusmodel.c | 27 +++ src/examples/elementary/filemvc.c | 2 +- 5 files changed, 35 insertions(+), 39 deletions(-) diff --git a/src/examples/eio/eio_job_ls.c b/src/examples/eio/eio_job_ls.c index 354325e..2e2db1f 100644 --- a/src/examples/eio/eio_job_ls.c +++ b/src/examples/eio/eio_job_ls.c @@ -18,11 +18,11 @@ void done_cb(void *data, void *value EINA_UNUSED) eo_unref(job); } -void error_cb(void *data, Eina_Error *error) +void error_cb(void *data, Eina_Error error) { Eio_Job *job = data; EINA_SAFETY_ON_NULL_RETURN(error); -const char *msg = eina_error_msg_get(*error); +const char *msg = eina_error_msg_get(error); printf("%s error: %s\n", __FUNCTION__, msg); ecore_main_loop_quit(); @@ -54,9 +54,9 @@ void list_files(void *data) Eio_Job *job = eo_add(EIO_JOB_CLASS, NULL); eo_event_callback_add(job, EIO_JOB_EVENT_FILTER_NAME, (Eo_Event_Cb)_cb, NULL); -eio_job_file_ls(job, path, ); +promise = eio_job_file_ls(job, path); eina_promise_progress_cb_add(promise, (Eina_Promise_Progress_Cb)_cb, NULL, NULL); -eina_promise_then(promise, (Eina_Promise_Cb)_cb, (Eina_Promise_Error_Cb)_cb, job); +eina_promise_then(promise, _cb, _cb, job); } int main(int argc, char const *argv[]) diff --git a/src/examples/eio/eio_job_open.c b/src/examples/eio/eio_job_open.c index fb235c2..7662bfb 100644 --- a/src/examples/eio/eio_job_open.c +++ b/src/examples/eio/eio_job_open.c @@ -9,18 +9,17 @@ #include #include -void error_cb(void *data, Eina_Error *error) +void error_cb(void *data, Eina_Error error, Eina_Promise* promise EINA_UNUSED) { -EINA_SAFETY_ON_NULL_RETURN(error); EINA_SAFETY_ON_NULL_RETURN(data); -const char *msg = eina_error_msg_get(*error); +const char *msg = eina_error_msg_get(error); EINA_LOG_ERR("error: %s", msg); ecore_main_loop_quit(); } -void done_closing_cb(int *result EINA_UNUSED) +void done_closing_cb(void* data EINA_UNUSED, void *value EINA_UNUSED, Eina_Promise* promise EINA_UNUSED) { printf("%s closed file.\n", __FUNCTION__); @@ -32,21 +31,22 @@ void closing_job(Eio_Job *job, Eina_File *file) Eina_Promise *promise = NULL; printf("%s Will close the file...\n", __FUNCTION__); eio_job_file_close(job, file, ); -eina_promise_then(promise, (Eina_Promise_Cb)_closing_cb, (Eina_Promise_Error_Cb)_cb, job); +eina_promise_then(promise, _closing_cb, _cb, job); } -void done_open_cb(void *data, Eina_File **file) +void done_open_cb(void *data, void* value, Eina_Promise* promise) { EINA_SAFETY_ON_NULL_RETURN(data); -EINA_SAFETY_ON_NULL_RETURN(file); -EINA_SAFETY_ON_NULL_RETURN(*file); +EINA_SAFETY_ON_NULL_RETURN(value); + +Eina_File *file = eina_file_dup(value); Eio_Job *job = data; -const char *name = eina_file_filename_get(*file); +const char *name = eina_file_filename_get(file); printf("%s opened file %s\n", __FUNCTION__, name); -closing_job(job, *file); +closing_job(job, file); } void open_file(const char *path) @@ -54,8 +54,7 @@ void open_file(const char *path) Eina_Promise *promise; Eio_Job *job = eo_add(EIO_JOB_CLASS, NULL); -eio_job_file_open(job, path, EINA_FALSE, ); -eina_promise_then(promise, (Eina_Promise_Cb)_open_cb, (Eina_Promise_Error_Cb)_cb, job); +eina_promise_then(eio_job_file_open(job, path, EINA_FALSE), _open_cb, _cb, job); eo_unref(job); } diff --git a/src/examples/eio/eio_job_open_multi.c b/src/examples/eio/eio_job_open_multi.c index 8082d4b..d1f8fa9 100644 --- a/src/examples/eio/eio_job_open_multi.c +++ b/src/examples/eio/eio_job_open_multi.c @@ -9,12 +9,12 @@ #include #include -void error_cb(void *data, Eina_Error *error) +void error_cb(void *data, Eina_Error error) { EINA_SAFETY_ON_NULL_RETURN(error); EINA_SAFETY_ON_NULL_RETURN(data); -const char *msg = eina_error_msg_get(*error); +const char *msg = eina_error_msg_get(error); EINA_LOG_ERR("error: %s", msg); Eio_Job *job = data; @@ -23,10 +23,12 @@ void error_cb(void *data, Eina_Error *error) ecore_main_loop_quit(); } -void done_closing_cb(void *data, Eina_Iterator **result EINA_UNUSED) +void done_closing_cb(void *data, void* value EINA_UNUSED) { EINA_SAFETY_ON_NULL_RETURN(data); +Eina_Iterator* result = value; + printf("%s closed file.\n", __FUNCTION__); Eio_Job
[EGIT] [core/efl] master 01/03: eina: Remove unnecessary indirection to promises
felipealmeida pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=8fec0d5139a3ff30037ba159bb62ff2f733d96a8 commit 8fec0d5139a3ff30037ba159bb62ff2f733d96a8 Author: Felipe Magno de AlmeidaDate: Fri Jun 3 16:52:03 2016 -0300 eina: Remove unnecessary indirection to promises Now when dealing with pointer types, we will not get pointer to pointer semantics in callbacks and eina_promise_owner_value_set for Eina_Promise. It will work as expected: Eina_Promise_Owner* promise = eina_promise_add(); void* p = malloc(sizeof(T)); eina_promise_owner_value_set(promise, p, ); --- src/benchmarks/eina/eina_bench_promise.c| 48 ++--- src/bin/eolian/eo_generator.c | 8 +- src/lib/ecore/Ecore_Common.h| 2 +- src/lib/ecore/ecore_main.c | 8 +- src/lib/ecore/ecore_thread_promise.c| 11 +- src/lib/eina/eina_promise.c | 116 --- src/lib/eina/eina_promise.h | 43 ++-- src/lib/eio/eio_job.c | 36 ++-- src/lib/eldbus/eldbus_model_arguments.c | 3 +- src/lib/eldbus/eldbus_model_connection.c| 4 +- src/lib/eldbus/eldbus_model_object.c| 11 +- src/lib/eldbus/eldbus_model_private.h | 2 - src/lib/eldbus/eldbus_model_proxy.c | 2 +- src/lib/elementary/elm_view_form.c | 25 ++- src/lib/elementary/elm_view_list.c | 21 +- src/tests/ecore/ecore_test_job.c| 6 +- src/tests/ecore/ecore_test_promise.c| 50 ++--- src/tests/ecore/ecore_test_timer.c | 2 +- src/tests/eina/eina_test_promise.c | 313 ++-- src/tests/eio/eio_test_job.c| 43 ++-- src/tests/eldbus/eldbus_test_eldbus_model.c | 20 +- 21 files changed, 554 insertions(+), 220 deletions(-) diff --git a/src/benchmarks/eina/eina_bench_promise.c b/src/benchmarks/eina/eina_bench_promise.c index 0d1afc5..ee6153c 100644 --- a/src/benchmarks/eina/eina_bench_promise.c +++ b/src/benchmarks/eina/eina_bench_promise.c @@ -67,7 +67,7 @@ eina_bench_promise_sync_then(int request) eina_init(); - Eina_Promise_Owner* owner = eina_promise_default_add(sizeof(struct value_type)); + Eina_Promise_Owner* owner = eina_promise_value_add(sizeof(struct value_type)); Eina_Promise* promise = eina_promise_owner_promise_get(owner); eina_promise_ref(promise); @@ -101,7 +101,7 @@ eina_bench_promise_copy_value_set_after_then(int request) for (j = 0; j != 200; ++j) for (i = 0; i != request; ++i) { - Eina_Promise_Owner* owner = eina_promise_default_add(sizeof(struct value_type)); + Eina_Promise_Owner* owner = eina_promise_value_add(sizeof(struct value_type)); Eina_Promise* promise = eina_promise_owner_promise_get(owner); eina_promise_then(promise, , NULL, NULL); @@ -126,7 +126,7 @@ eina_bench_promise_no_copy_value_set_after_then(int request) for (j = 0; j != 200; ++j) for (i = 0; i != request; ++i) { - Eina_Promise_Owner* owner = eina_promise_default_add(sizeof(struct value_type)); + Eina_Promise_Owner* owner = eina_promise_value_add(sizeof(struct value_type)); Eina_Promise* promise = eina_promise_owner_promise_get(owner); struct value_type* v = eina_promise_owner_buffer_get(owner); @@ -154,7 +154,7 @@ eina_bench_promise_no_copy_value_set_before_then(int request) for (j = 0; j != 200; ++j) for (i = 0; i != request; ++i) { - Eina_Promise_Owner* owner = eina_promise_default_add(sizeof(struct value_type)); + Eina_Promise_Owner* owner = eina_promise_value_add(sizeof(struct value_type)); Eina_Promise* promise = eina_promise_owner_promise_get(owner); struct value_type* v = eina_promise_owner_buffer_get(owner); @@ -184,7 +184,7 @@ eina_bench_promise_copy_value_set_before_then(int request) for (j = 0; j != 200; ++j) for (i = 0; i != request; ++i) { - Eina_Promise_Owner* owner = eina_promise_default_add(sizeof(struct value_type)); + Eina_Promise_Owner* owner = eina_promise_value_add(sizeof(struct value_type)); Eina_Promise* promise = eina_promise_owner_promise_get(owner); eina_promise_then(promise, , NULL, NULL); @@ -214,15 +214,14 @@ eina_bench_promise_pointer_value_set_before_then(int request) for (j = 0; j != 200; ++j) for (i = 0; i != request; ++i) { - Eina_Promise_Owner* owner = eina_promise_default_add(sizeof(struct value_type*)); + Eina_Promise_Owner* owner = eina_promise_add(); Eina_Promise* promise = eina_promise_owner_promise_get(owner); - struct value_type* p = *(struct value_type**)eina_promise_owner_buffer_get(owner) - = malloc(sizeof(struct value_type));
[EGIT] [core/efl] master 03/03: eolian-cxx: Fix C++ example compilation
felipealmeida pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=09446ccb90c1f3180e5b2e0a52b3ce2c78c7c140 commit 09446ccb90c1f3180e5b2e0a52b3ce2c78c7c140 Author: Felipe Magno de AlmeidaDate: Fri Jun 3 16:54:16 2016 -0300 eolian-cxx: Fix C++ example compilation --- src/examples/eolian_cxx/Makefile.am | 22 +- 1 file changed, 9 insertions(+), 13 deletions(-) diff --git a/src/examples/eolian_cxx/Makefile.am b/src/examples/eolian_cxx/Makefile.am index bfc44b7..8b6b68f 100644 --- a/src/examples/eolian_cxx/Makefile.am +++ b/src/examples/eolian_cxx/Makefile.am @@ -25,12 +25,12 @@ AM_CXXFLAGS = \ -I$(top_builddir)/src/lib/emile \ -I$(top_srcdir)/src/lib/eo \ -I$(top_builddir)/src/lib/eo \ - -I$(top_srcdir)/src/bindings/eo_cxx \ - -I$(top_builddir)/src/bindings/eo_cxx \ - -I$(top_srcdir)/src/bindings/eina_cxx \ - -I$(top_builddir)/src/bindings/eina_cxx \ - -I$(top_srcdir)/src/bindings/ecore_cxx \ - -I$(top_builddir)/src/bindings/ecore_cxx \ + -I$(top_srcdir)/src/bindings/cxx/eo_cxx \ + -I$(top_builddir)/src/bindings/cxx/eo_cxx \ + -I$(top_srcdir)/src/bindings/cxx/eina_cxx \ + -I$(top_builddir)/src/bindings/cxx/eina_cxx \ + -I$(top_srcdir)/src/bindings/cxx/ecore_cxx \ + -I$(top_builddir)/src/bindings/cxx/ecore_cxx \ -I$(top_srcdir)/src/lib/evas/ \ -I$(top_builddir)/src/lib/evas/ \ -I$(top_srcdir)/src/lib/evas/common \ @@ -89,9 +89,7 @@ IMPL = \ colourable.c \ colourable_cxx.cc \ colourablesquare.c \ - colourablesquare_cxx.cc \ - colourable_stub.c \ - colourablesquare_stub.c + colourablesquare_cxx.cc SRCS = \ eolian_cxx_simple_01.cc \ @@ -116,10 +114,8 @@ eolian_cxx_simple_01.$(OBJEXT): $(GENERATED) eolian_cxx_simple_01_cxx_impl_SOURCES = \ eolian_cxx_simple_01.cc \ - colourable_stub.c \ - colourable_stub.h \ - colourablesquare_stub.c \ - colourablesquare_stub.h \ + colourable.c \ + colourablesquare.c \ colourable_cxx.cc \ colourablesquare_cxx.cc eolian_cxx_simple_01_cxx_impl.$(OBJEXT): $(GENERATED) --
Re: [E-devel] promises...
On Fri, Jun 3, 2016 at 12:20 AM, Jean-Philippe Andréwrote: > On 3 June 2016 at 15:42, Carsten Haitzler wrote: >> ok. interacting with promises... >> >> these are just a mess. >> >> 1. the value thing is just odd. That is a known issue that should be fixed today as Felipe is working on it. >> 2. they are complex to set up inside our api (setting them up setting >> cancel cb's and more) What do you mean by that ? >> 3. they totally screw with what eo and interfaces was all about - making >> the api EASIER to use. promises make it harder. >> >> why harder? longer lines of code with more parameters and more special >> casing... but the WORST... >> >> void _cb_promise(void *data, void *vaue, Eina_Promise *promise) >> >> that's a promise cb >> >> Eina_Bool _cb_event(void *data, const Eo_Event *event) >> >> and that's an event cb. they are different. eo events were meant to >> simplify and unify our callback handling. to have a single cb signature. now >> promises break that. this is just bad. > > That's bad. Doesn't look good. You just can't do with eo event what promise do. Eo event are a repeated event which doesn't allow any easy synchronisation and lead to race condition. Promise do allow easy synchronisation and avoid any race condition. They make life easier on that side. The price to pay is that we can't use the same prototype. I see no problem with this as they are apple and orange and can't be used for the same purpose (see below with timeout and timer). The only change still coming is the removal of the Eina_Promise parameter from the function as we have not found any use case for it. Having a single signature and loosing the benefit of avoiding race condition. Is like avoiding to type a few characteres to avoid debugging for hours. This is just not where the problem is. You can't implement promise on top of Eo event. Not just because of the overhead of Eo object, but because the event are in nature different from the asynchronous operation provided by promise. Switching efl model to use promise instead of event has massively simplified the code (Still quite complex, but way better). Also last point, I think having the same signature, would actually be more confusing to people. Like why does that event not accept to be in a promise_all or promise_race ? If it has the same signature, people would expect to be able to use random event in promise_all/race and that is just not doable. >> i wasn't sold on promises. i was skeptical, but whatever... but now i am >> seeing they are visibly making things worse. code is harder to write, harder >> to >> read, harder to maintain, harder to get right. now we have timeouts that >> cannot >> repeat. no - creating a new timer in the cb is not repeating. it has to >> repeat with the "zero time" being the time when the timer was ticked off, not >> "now". So, the point of timeout is to provide a timeout, not a timer. If you want a timer, efl.timer is there for that purpose. It is an Eo object and it does exactly what you expect from it. Repeating itself over and over until it is destroyed or freezed. The main difference, as you have noted, is that a timeout doesn't repeat and is a one off. It makes it super easy to implement timeout behavior with network for example. You would have a promise to a connection object, you create a timeout and you link them in a promise_race. Not a single callback to write to get the timeout to cancel the connect. As for maintenance and readability, I disagree. Moving eio_model to use eina_promise instead of eo events lead to a net removal of 1/3 of the code and I think that there is more to win now that we have an eoified Eio, but that's for later. The point of promise is to allow easy synchronisation without race condition. If you try to use them to do something else, like your attempt to implement a timer with timeout, it doesn't work. There is no synchronisation expected in that case. >> please - everyone. take a look at promises and how they are used. forget >> all of the "but node.js has them" and all the "i can chain promises" and so >> on. >> the BASIC usage of them is harder now in efl. It is to be understood that they are only useful for synchronisation purpose. If you do not need to synchronise, then promise is not the answer. If there are place where a promise is returned and that there is no use of it for any synchronisation purpose then it is obviously a bad place to have a promise. Otherwise it is. >> what to do? well... minimize their use for one. do not use them unless you >> ABSOLUTELY HAVE TO. As I just said above, promise is to be used only for synchronisation purpose. It is not a matter of minimizing their use, it is a matter of using them at the right place. Using a timeout for a timer, make no sense from the beginning. Also most of our API that should be asynchronous is not there yet, so it is hard to synchronise anything, when nothing is asynchronous
Re: [E-devel] [EGIT] [core/efl] master 01/04: autotools: we can't destroy this files as it break a make clean all cycle.
On Fri, Jun 3, 2016 at 5:05 AM, Eduardo Lima (Etrunko)wrote: > Put them under DISTCLEANFILES= Thanks, that is indeed working. > On Fri, Jun 3, 2016 at 7:18 AM, Stefan Schmidt > wrote: > >> Hello. >> >> Give me another solution in this case. >> >> ERROR: files left in build directory after distclean: >> ./src/lib/efl/Efl_Config.h >> ./src/lib/eina/eina_config.h >> ./src/lib/elementary/Elementary.h >> Makefile:3198: recipe for target 'distcleancheck' failed >> make[1]: *** [distcleancheck] Error 1 >> Makefile:3125: recipe for target 'distcheck' failed >> >> That means no releases. And alpha is up for Monday. >> >> regards >> Stefan Schmidt >> >> On 02/06/16 19:54, Cedric BAIL wrote: >> > cedric pushed a commit to branch master. >> > >> > >> http://git.enlightenment.org/core/efl.git/commit/?id=776e3ae28cfa8bde42413ed2c763034c755eedfa >> > >> > commit 776e3ae28cfa8bde42413ed2c763034c755eedfa >> > Author: Cedric BAIL >> > Date: Thu Jun 2 10:42:21 2016 -0700 >> > >> > autotools: we can't destroy this files as it break a make clean all >> cycle. >> > --- >> > Makefile.am | 3 --- >> > 1 file changed, 3 deletions(-) >> > >> > diff --git a/Makefile.am b/Makefile.am >> > index 64ea014..e744ffd 100644 >> > --- a/Makefile.am >> > +++ b/Makefile.am >> > @@ -509,12 +509,9 @@ clean-local: >> > rm -f ./src/lib/eet/Makefile >> > rm -f ./src/lib/ecore/Makefile >> > rm -f ./src/lib/efl/Makefile >> > - rm -f ./src/lib/efl/Efl_Config.h >> > rm -f ./src/lib/eina/Makefile >> > - rm -f ./src/lib/eina/eina_config.h >> > rm -f ./src/lib/eio/Makefile >> > rm -f ./src/lib/elementary/Makefile >> > - rm -f ./src/lib/elementary/Elementary.h >> > rm -f ./src/lib/ector/Makefile >> > rm -rf ./src/lib/ector/static_libs/rg_etc/.deps/ >> > rm -f ./src/lib/evil/Makefile >> > >> >> >> >> -- >> What NetFlow Analyzer can do for you? Monitors network bandwidth and >> traffic >> patterns at an interface-level. Reveals which users, apps, and protocols >> are >> consuming the most bandwidth. Provides multi-vendor support for NetFlow, >> J-Flow, sFlow and other flows. Make informed decisions using capacity >> planning reports. https://ad.doubleclick.net/ddm/clk/305295220;132659582;e >> ___ >> enlightenment-devel mailing list >> enlightenment-devel@lists.sourceforge.net >> https://lists.sourceforge.net/lists/listinfo/enlightenment-devel >> > > > > -- > Eduardo de Barros Lima ◤✠◢ > ebl...@gmail.com > -- > What NetFlow Analyzer can do for you? Monitors network bandwidth and traffic > patterns at an interface-level. Reveals which users, apps, and protocols are > consuming the most bandwidth. Provides multi-vendor support for NetFlow, > J-Flow, sFlow and other flows. Make informed decisions using capacity > planning reports. https://ad.doubleclick.net/ddm/clk/305295220;132659582;e > ___ > enlightenment-devel mailing list > enlightenment-devel@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/enlightenment-devel -- Cedric BAIL -- What NetFlow Analyzer can do for you? Monitors network bandwidth and traffic patterns at an interface-level. Reveals which users, apps, and protocols are consuming the most bandwidth. Provides multi-vendor support for NetFlow, J-Flow, sFlow and other flows. Make informed decisions using capacity planning reports. https://ad.doubleclick.net/ddm/clk/305295220;132659582;e ___ enlightenment-devel mailing list enlightenment-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
[EGIT] [core/efl] master 01/02: ector: variable in _SOURCES do not work.
cedric pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=2ea85a2075600e6c55a0f6092dcb1639cb9198d7 commit 2ea85a2075600e6c55a0f6092dcb1639cb9198d7 Author: Cedric BAILDate: Fri Jun 3 11:10:27 2016 -0700 ector: variable in _SOURCES do not work. This fix the left over etc .deps during make distcheck. --- src/Makefile_Ector.am | 8 +++- src/lib/ector/Makefile.am | 14 ++ 2 files changed, 9 insertions(+), 13 deletions(-) diff --git a/src/Makefile_Ector.am b/src/Makefile_Ector.am index a4f874a..33c3bfd 100644 --- a/src/Makefile_Ector.am +++ b/src/Makefile_Ector.am @@ -101,15 +101,14 @@ lib/ector/cairo/ector_cairo_software_surface.c \ lib/ector/cairo/ector_cairo_surface.c # SW draw static lib -draw_sources = \ +lib_ector_libector_la_SOURCES += \ static_libs/draw/draw_main_sse2.c \ static_libs/draw/draw_main.c \ static_libs/draw/draw_main_neon.c \ static_libs/rg_etc/rg_etc1.c \ static_libs/rg_etc/rg_etc2.c \ static_libs/rg_etc/rg_etc1.h \ -static_libs/rg_etc/etc2_encoder.c \ -$(NULL) +static_libs/rg_etc/etc2_encoder.c # And the default software backend lib_ector_libector_la_SOURCES += \ @@ -123,8 +122,7 @@ lib/ector/software/ector_software_surface.c \ lib/ector/software/ector_software_buffer.c \ static_libs/freetype/sw_ft_math.c \ static_libs/freetype/sw_ft_raster.c \ -static_libs/freetype/sw_ft_stroker.c \ -$(draw_sources) +static_libs/freetype/sw_ft_stroker.c # And now the gl backend lib_ector_libector_la_SOURCES += \ diff --git a/src/lib/ector/Makefile.am b/src/lib/ector/Makefile.am index 96e3a18..158760e 100644 --- a/src/lib/ector/Makefile.am +++ b/src/lib/ector/Makefile.am @@ -90,15 +90,14 @@ cairo/ector_cairo_software_surface.c \ cairo/ector_cairo_surface.c # SW draw static lib -draw_sources = \ +libector_la_SOURCES += \ ../../static_libs/draw/draw_main_sse2.c \ ../../static_libs/draw/draw_main.c \ ../../static_libs/draw/draw_main_neon.c \ -static_libs/rg_etc/rg_etc1.c \ -static_libs/rg_etc/rg_etc2.c \ -static_libs/rg_etc/rg_etc1.h \ -static_libs/rg_etc/etc2_encoder.c \ -$(NULL) +../../static_libs/rg_etc/rg_etc1.c \ +../../static_libs/rg_etc/rg_etc2.c \ +../../static_libs/rg_etc/rg_etc1.h \ +../../static_libs/rg_etc/etc2_encoder.c # And the default software backend libector_la_SOURCES += \ @@ -112,8 +111,7 @@ software/ector_software_surface.c \ software/ector_software_buffer.c \ ../../static_libs/freetype/sw_ft_math.c \ ../../static_libs/freetype/sw_ft_raster.c \ -../../static_libs/freetype/sw_ft_stroker.c \ -$(draw_sources) +../../static_libs/freetype/sw_ft_stroker.c # And now the gl backend libector_la_SOURCES += \ --
[EGIT] [core/efl] master 02/02: autotools: use DISTCLEAN rules to properly destroy files.
cedric pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=1dcccfdf8160ca6113d66c51c226302221b9a049 commit 1dcccfdf8160ca6113d66c51c226302221b9a049 Author: Cedric BAILDate: Fri Jun 3 11:11:05 2016 -0700 autotools: use DISTCLEAN rules to properly destroy files. --- Makefile.am | 28 1 file changed, 16 insertions(+), 12 deletions(-) diff --git a/Makefile.am b/Makefile.am index e744ffd..e6ef149 100644 --- a/Makefile.am +++ b/Makefile.am @@ -504,15 +504,19 @@ pkgbuild:: clean-local: rm -rf benchmark coverage - rm -f ./src/lib/emile/Makefile - rm -f ./src/lib/eo/Makefile - rm -f ./src/lib/eet/Makefile - rm -f ./src/lib/ecore/Makefile - rm -f ./src/lib/efl/Makefile - rm -f ./src/lib/eina/Makefile - rm -f ./src/lib/eio/Makefile - rm -f ./src/lib/elementary/Makefile - rm -f ./src/lib/ector/Makefile - rm -rf ./src/lib/ector/static_libs/rg_etc/.deps/ - rm -f ./src/lib/evil/Makefile - rm -f ./src/lib/edje/Makefile + +DISTCLEANFILES= \ +./src/lib/emile/Makefile \ +./src/lib/eo/Makefile \ +./src/lib/eet/Makefile \ +./src/lib/ecore/Makefile \ +./src/lib/efl/Makefile \ +./src/lib/eina/Makefile \ +./src/lib/eio/Makefile \ +./src/lib/elementary/Makefile \ +./src/lib/ector/Makefile \ +./src/lib/evil/Makefile \ +./src/lib/edje/Makefile \ +./src/lib/efl/Efl_Config.h \ +./src/lib/eina/eina_config.h \ +./src/lib/elementary/Elementary.h --
[E-devel] E22 Reprioritizing
With the final E21 release pending, the E22 cycle is just around the corner. I'll be needing to make some changes to my priorities during this time due to health issues. Originally, the E22 cycle was to focus on rewriting the settings infrastructure. This is a monumental task, and I would estimate that the time required for it is 1-2 months of my near full-time attention. Unfortunately, due to the amount of time and energy that I've been putting into Enlightenment development and testing for the E21 release cycle, the RSI (https://en.wikipedia.org/wiki/Repetitive_strain_injury) in my hands and wirsts has gotten significantly worse. It's becoming more difficult to type and debug, and it's no exaggeration to say that it's literally a struggle for me to open my hands all the way. I've been in physical therapy for some time to mitigate the effects so that I could complete this release cycle and get all of the changes out, but this was not going to be a long-term solution. For the present, I'll be scaling back the time that I spend doing development in order to focus on my recovery. This will have some impact on Enlightenment development: * A full settings rewrite is unlikely at this time unless other community members want to shoulder significant portions of the work required * Bug fixes and my responses to tickets will be considerably less immediate than people have grown accustomed to I plan to prioritize my (limited) time following the release on trying to resolve reported bugs. Once that quiets down, I'll likely try to work on improving some UI elements or doing more gadget conversions unless someone has begun a settings taskforce. It's disappointing to me that I won't be able to effectively achieve the community-set roadmap for E22 at this time, but the situation is such that I need to take my physical condition into account for a while. Thanks for all your understanding and support, Mike -- What NetFlow Analyzer can do for you? Monitors network bandwidth and traffic patterns at an interface-level. Reveals which users, apps, and protocols are consuming the most bandwidth. Provides multi-vendor support for NetFlow, J-Flow, sFlow and other flows. Make informed decisions using capacity planning reports. https://ad.doubleclick.net/ddm/clk/305295220;132659582;e ___ enlightenment-devel mailing list enlightenment-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
[EGIT] [core/efl] master 02/02: wayland_shm: Add exynos allocator for dmabuf
derekf pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=821aada3c442af82339b01df036fa13aa086491a commit 821aada3c442af82339b01df036fa13aa086491a Author: Derek ForemanDate: Thu Jun 2 07:06:26 2016 -0500 wayland_shm: Add exynos allocator for dmabuf Allows clients on exynos hardware to allocate GEM buffer objects to back DMAbuf buffers. --- src/modules/evas/engines/wayland_shm/evas_dmabuf.c | 99 src/static_libs/libdrm/exynos_drm.h| 172 + src/static_libs/libdrm/exynos_drmif.h | 112 ++ 3 files changed, 383 insertions(+) diff --git a/src/modules/evas/engines/wayland_shm/evas_dmabuf.c b/src/modules/evas/engines/wayland_shm/evas_dmabuf.c index 60093ae..3cb112c 100644 --- a/src/modules/evas/engines/wayland_shm/evas_dmabuf.c +++ b/src/modules/evas/engines/wayland_shm/evas_dmabuf.c @@ -10,6 +10,10 @@ #include #include +#include +#include +#include + #include "linux-dmabuf-unstable-v1-client-protocol.h" #define SYM(lib, xx) \ @@ -88,6 +92,11 @@ drm_intel_bo *(*sym_drm_intel_bo_alloc_tiled)(drm_intel_bufmgr *mgr, const char void (*sym_drm_intel_bo_unreference)(drm_intel_bo *bo) = NULL; int (*sym_drmPrimeHandleToFD)(int fd, uint32_t handle, uint32_t flags, int *prime_fd); +struct exynos_device *(*sym_exynos_device_create)(int fd) = NULL; +struct exynos_bo *(*sym_exynos_bo_create)(struct exynos_device *dev, size_t size, uint32_t flags) = NULL; +void *(*sym_exynos_bo_map)(struct exynos_bo *bo) = NULL; +void (*sym_exynos_bo_destroy)(struct exynos_bo *bo) = NULL; + static Buffer_Handle * _intel_alloc(Buffer_Manager *self, const char *name, int w, int h, unsigned long *stride, int32_t *fd) { @@ -179,6 +188,95 @@ err: return EINA_FALSE; } +static Buffer_Handle * +_exynos_alloc(Buffer_Manager *self, const char *name EINA_UNUSED, int w, int h, unsigned long *stride, int32_t *fd) +{ + size_t size = w * h * 4; + struct exynos_bo *out; + + *stride = w * 4; + out = sym_exynos_bo_create(self->priv, size, 0); + if (!out) return NULL; + /* First try to allocate an mmapable buffer with O_RDWR, +* if that fails retry unmappable - if the compositor is +* using GL it won't need to mmap the buffer and this can +* work - otherwise it'll reject this buffer and we'll +* have to fall back to shm rendering. +*/ + if (sym_drmPrimeHandleToFD(drm_fd, out->handle, + DRM_CLOEXEC | O_RDWR, fd) != 0) + if (sym_drmPrimeHandleToFD(drm_fd, out->handle, +DRM_CLOEXEC, fd) != 0) goto err; + + return (Buffer_Handle *)out; + +err: + sym_exynos_bo_destroy(out); + return NULL; +} + +static void * +_exynos_map(Dmabuf_Buffer *buf) +{ + struct exynos_bo *bo; + void *ptr; + + bo = (struct exynos_bo *)buf->bh; + ptr = mmap(0, bo->size, PROT_READ | PROT_WRITE, MAP_SHARED, buf->fd, 0); + if (ptr == MAP_FAILED) return NULL; + return ptr; +} + +static void +_exynos_unmap(Dmabuf_Buffer *buf) +{ + struct exynos_bo *bo; + + bo = (struct exynos_bo *)buf->bh; + munmap(buf->mapping, bo->size); +} + +static void +_exynos_discard(Dmabuf_Buffer *buf) +{ + struct exynos_bo *bo; + + bo = (struct exynos_bo *)buf->bh; + sym_exynos_bo_destroy(bo); +} + +static Eina_Bool +_exynos_buffer_manager_setup(int fd) +{ + Eina_Bool fail = EINA_FALSE; + void *drm_exynos_lib; + + drm_exynos_lib = dlopen("libdrm_exynos.so", RTLD_LAZY | RTLD_GLOBAL); + if (!drm_exynos_lib) return EINA_FALSE; + + SYM(drm_exynos_lib, exynos_device_create); + SYM(drm_exynos_lib, exynos_bo_create); + SYM(drm_exynos_lib, exynos_bo_map); + SYM(drm_exynos_lib, exynos_bo_destroy); + SYM(drm_exynos_lib, drmPrimeHandleToFD); + + if (fail) goto err; + + buffer_manager->priv = sym_exynos_device_create(fd); + if (!buffer_manager->priv) goto err; + + buffer_manager->alloc = _exynos_alloc; + buffer_manager->map = _exynos_map; + buffer_manager->unmap = _exynos_unmap; + buffer_manager->discard = _exynos_discard; + + return EINA_TRUE; + +err: + dlclose(drm_exynos_lib); + return EINA_FALSE; +} + static Buffer_Manager * _buffer_manager_get(void) { @@ -194,6 +292,7 @@ _buffer_manager_get(void) if (fd < 0) goto err_drm; success = _intel_buffer_manager_setup(fd); + if (!success) success = _exynos_buffer_manager_setup(fd); if (!success) goto err_bm; drm_fd = fd; diff --git a/src/static_libs/libdrm/exynos_drm.h b/src/static_libs/libdrm/exynos_drm.h new file mode 100644 index 000..c3af0ac --- /dev/null +++ b/src/static_libs/libdrm/exynos_drm.h @@ -0,0 +1,172 @@ +/* exynos_drm.h + * + * Copyright (c) 2011 Samsung Electronics Co., Ltd. + * Authors: + * Inki Dae + * Joonyoung Shim + * Seung-Woo Kim + * + * Permission is hereby granted, free of charge, to
[EGIT] [core/efl] master 01/02: wayland_shm: Abstract out dmabuf management
derekf pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=0f07f67b127ae2c1810b7955f049ff53584a53fc commit 0f07f67b127ae2c1810b7955f049ff53584a53fc Author: Derek ForemanDate: Wed Jun 1 15:52:05 2016 -0500 wayland_shm: Abstract out dmabuf management Split out the intel specific stuff into an abstraction in preparation for adding exynos support. --- src/modules/evas/engines/wayland_shm/evas_dmabuf.c | 178 +++-- 1 file changed, 132 insertions(+), 46 deletions(-) diff --git a/src/modules/evas/engines/wayland_shm/evas_dmabuf.c b/src/modules/evas/engines/wayland_shm/evas_dmabuf.c index 18901b0..60093ae 100644 --- a/src/modules/evas/engines/wayland_shm/evas_dmabuf.c +++ b/src/modules/evas/engines/wayland_shm/evas_dmabuf.c @@ -2,9 +2,6 @@ #include "evas_private.h" #include "evas_engine.h" -/* When other buffer managers are supported this will become - * #ifdef HAVE_DRM_FOR_WAYLAND_SHM - */ #include #include #include @@ -23,8 +20,6 @@ }\ } while (0) -static drm_intel_bufmgr *buffer_manager; - static Eina_Bool dmabuf_totally_hosed; static int drm_fd = -1; @@ -32,15 +27,30 @@ static int drm_fd = -1; typedef struct _Dmabuf_Surface Dmabuf_Surface; typedef struct _Dmabuf_Buffer Dmabuf_Buffer; +typedef struct _Buffer_Handle Buffer_Handle; +typedef struct _Buffer_Manager Buffer_Manager; +struct _Buffer_Manager +{ + Buffer_Handle *(*alloc)(Buffer_Manager *self, const char *name, int w, int h, unsigned long *stride, int32_t *fd); + void *(*map)(Dmabuf_Buffer *buf); + void (*unmap)(Dmabuf_Buffer *buf); + void (*discard)(Dmabuf_Buffer *buf); + void *priv; +}; + +Buffer_Manager *buffer_manager = NULL; + struct _Dmabuf_Buffer { + Buffer_Manager *bm; Dmabuf_Surface *surface; struct wl_buffer *wl_buffer; int w, h; int age; unsigned long stride; - drm_intel_bo *bo; + Buffer_Handle *bh; int fd; + void *mapping; int index; Eina_Bool locked : 1; @@ -78,17 +88,72 @@ drm_intel_bo *(*sym_drm_intel_bo_alloc_tiled)(drm_intel_bufmgr *mgr, const char void (*sym_drm_intel_bo_unreference)(drm_intel_bo *bo) = NULL; int (*sym_drmPrimeHandleToFD)(int fd, uint32_t handle, uint32_t flags, int *prime_fd); -static drm_intel_bufmgr * -_get_buffer_manager(void) +static Buffer_Handle * +_intel_alloc(Buffer_Manager *self, const char *name, int w, int h, unsigned long *stride, int32_t *fd) { - int fd; - void *drm_intel_lib; - Eina_Bool fail = EINA_FALSE; + uint32_t tile = I915_TILING_NONE; + drm_intel_bo *out; - if (buffer_manager) return buffer_manager; + out = sym_drm_intel_bo_alloc_tiled(self->priv, name, w, h, 4, , + stride, 0); + + if (!out) return NULL; + + if (tile != I915_TILING_NONE) goto err; + /* First try to allocate an mmapable buffer with O_RDWR, +* if that fails retry unmappable - if the compositor is +* using GL it won't need to mmap the buffer and this can +* work - otherwise it'll reject this buffer and we'll +* have to fall back to shm rendering. +*/ + if (sym_drmPrimeHandleToFD(drm_fd, out->handle, + DRM_CLOEXEC | O_RDWR, fd) != 0) + if (sym_drmPrimeHandleToFD(drm_fd, out->handle, +DRM_CLOEXEC, fd) != 0) goto err; + + return (Buffer_Handle *)out; + +err: + sym_drm_intel_bo_unreference(out); + return NULL; +} + +static void * +_intel_map(Dmabuf_Buffer *buf) +{ + drm_intel_bo *bo; + + bo = (drm_intel_bo *)buf->bh; + if (sym_drm_intel_gem_bo_map_gtt(bo) != 0) return NULL; + return bo->virtual; +} + +static void +_intel_unmap(Dmabuf_Buffer *buf) +{ + drm_intel_bo *bo; + + bo = (drm_intel_bo *)buf->bh; + sym_drm_intel_gem_bo_unmap_gtt(bo); +} + +static void +_intel_discard(Dmabuf_Buffer *buf) +{ + drm_intel_bo *bo; + + bo = (drm_intel_bo *)buf->bh; + sym_drm_intel_bo_unreference(bo); +} + +static Eina_Bool +_intel_buffer_manager_setup(int fd) +{ + Eina_Bool fail = EINA_FALSE; + void *drm_intel_lib; drm_intel_lib = dlopen("libdrm_intel.so", RTLD_LAZY | RTLD_GLOBAL); - if (!drm_intel_lib) goto err_dlopen; + if (!drm_intel_lib) return EINA_FALSE; SYM(drm_intel_lib, drm_intel_bufmgr_gem_init); SYM(drm_intel_lib, drm_intel_gem_bo_unmap_gtt); @@ -97,22 +162,48 @@ _get_buffer_manager(void) SYM(drm_intel_lib, drm_intel_bo_unreference); SYM(drm_intel_lib, drmPrimeHandleToFD); - if (fail) goto err_dlsym; + if (fail) goto err; + + buffer_manager->priv = sym_drm_intel_bufmgr_gem_init(fd, 32); + if (!buffer_manager->priv) goto err; + + buffer_manager->alloc = _intel_alloc; + buffer_manager->map = _intel_map; + buffer_manager->unmap = _intel_unmap; + buffer_manager->discard = _intel_discard; + + return EINA_TRUE; + +err: + dlclose(drm_intel_lib); + return EINA_FALSE; +} + +static Buffer_Manager *
[EGIT] [core/enlightenment] enlightenment-0.20 17/20: handle shaded state when receiving x11 configure requests
discomfitor pushed a commit to branch enlightenment-0.20. http://git.enlightenment.org/core/enlightenment.git/commit/?id=ea1b0a2b02dff326b6e0089cb1028056e9351ce5 commit ea1b0a2b02dff326b6e0089cb1028056e9351ce5 Author: Mike BlumenkrantzDate: Tue May 31 12:31:50 2016 -0400 handle shaded state when receiving x11 configure requests previously this would resize the window without unshading it, leading to a confusing state for the window and the user --- src/bin/e_comp_x.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/bin/e_comp_x.c b/src/bin/e_comp_x.c index 0b96c87..09cbe58 100644 --- a/src/bin/e_comp_x.c +++ b/src/bin/e_comp_x.c @@ -1655,7 +1655,7 @@ _e_comp_x_configure_request(void *data EINA_UNUSED, int type EINA_UNUSED, Ecore if (resize && (!ec->lock_client_size) && (move || ((!ec->maximized) && (!ec->fullscreen { -if ((ec->maximized & E_MAXIMIZE_TYPE) != E_MAXIMIZE_NONE) +if (ec->shaded || ((ec->maximized & E_MAXIMIZE_TYPE) != E_MAXIMIZE_NONE)) e_comp_object_frame_wh_unadjust(ec->frame, w, h, >saved.w, >saved.h); else if (!ec->maximize_override) { --
[EGIT] [core/enlightenment] enlightenment-0.20 01/20: stop filling logs with buffer transform/scale spam
discomfitor pushed a commit to branch enlightenment-0.20. http://git.enlightenment.org/core/enlightenment.git/commit/?id=1d5a19a54c5c4413d7375366606a74db07ce21fe commit 1d5a19a54c5c4413d7375366606a74db07ce21fe Author: Chris MichaelDate: Sun May 15 10:47:53 2016 -0400 stop filling logs with buffer transform/scale spam Signed-off-by: Chris Michael --- src/bin/e_comp_wl.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/bin/e_comp_wl.c b/src/bin/e_comp_wl.c index 1abbc2b..392eb24 100644 --- a/src/bin/e_comp_wl.c +++ b/src/bin/e_comp_wl.c @@ -1393,13 +1393,13 @@ _e_comp_wl_surface_cb_commit(struct wl_client *client EINA_UNUSED, struct wl_res static void _e_comp_wl_surface_cb_buffer_transform_set(struct wl_client *client EINA_UNUSED, struct wl_resource *resource EINA_UNUSED, int32_t transform EINA_UNUSED) { - DBG("Surface Buffer Transform: %d", wl_resource_get_id(resource)); + /* DBG("Surface Buffer Transform: %d", wl_resource_get_id(resource)); */ } static void _e_comp_wl_surface_cb_buffer_scale_set(struct wl_client *client EINA_UNUSED, struct wl_resource *resource EINA_UNUSED, int32_t scale EINA_UNUSED) { - DBG("Surface Buffer Scale: %d", wl_resource_get_id(resource)); + /* DBG("Surface Buffer Scale: %d", wl_resource_get_id(resource)); */ } static const struct wl_surface_interface _e_surface_interface = --
[EGIT] [core/enlightenment] enlightenment-0.20 15/20: delete x11 mouse-in job when hiding the job's client
discomfitor pushed a commit to branch enlightenment-0.20. http://git.enlightenment.org/core/enlightenment.git/commit/?id=a4011ee2d6e226f2a60184ecdc7211d9141cfae9 commit a4011ee2d6e226f2a60184ecdc7211d9141cfae9 Author: Mike BlumenkrantzDate: Tue May 31 12:21:09 2016 -0400 delete x11 mouse-in job when hiding the job's client spurious x11 mouse events will be received when activating a mouse binding which flips the active desk fix T3716 --- src/bin/e_comp_x.c | 6 ++ 1 file changed, 6 insertions(+) diff --git a/src/bin/e_comp_x.c b/src/bin/e_comp_x.c index 28ddea2..0b96c87 100644 --- a/src/bin/e_comp_x.c +++ b/src/bin/e_comp_x.c @@ -989,6 +989,12 @@ _e_comp_x_evas_hide_cb(void *data, Evas *e EINA_UNUSED, Evas_Object *obj EINA_UN E_Client *ec = data, *tmp; Eina_List *l; + if (ec == mouse_client) + { +mouse_client = NULL; +E_FREE_FUNC(mouse_in_job, ecore_job_del); + } + if (!_e_comp_x_client_data_get(ec)) return; // already deleted, happens with internal wins _e_comp_x_client_hide(ec); --
[EGIT] [core/enlightenment] enlightenment-0.20 12/20: change 'if' clause to make gcc-6 happy
discomfitor pushed a commit to branch enlightenment-0.20. http://git.enlightenment.org/core/enlightenment.git/commit/?id=1aee9676674d6d848d343b65ff1c8f4a4dbda5bb commit 1aee9676674d6d848d343b65ff1c8f4a4dbda5bb Author: Chris MichaelDate: Tue May 24 15:48:18 2016 -0400 change 'if' clause to make gcc-6 happy Gcc 6 was spitting a nasty little compiler warning here: src/bin/e_fm.c: In function ‘e_fm2_icon_geometry_get’: src/bin/e_fm.c:2354:4: warning: this ‘if’ clause does not guard... [-Wmisleading-indentation] if (x) *x = 0; if (y) *y = 0; if (w) *w = 0; if (h) *h = 0; ^~ src/bin/e_fm.c:2354:19: note: ...this statement, but the latter is misleadingly indented as if it is guarded by the ‘if’ if (x) *x = 0; if (y) *y = 0; if (w) *w = 0; if (h) *h = 0; Signed-off-by: Chris Michael --- src/bin/e_fm.c | 6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/bin/e_fm.c b/src/bin/e_fm.c index c748c47..662eab4 100644 --- a/src/bin/e_fm.c +++ b/src/bin/e_fm.c @@ -2351,7 +2351,11 @@ e_fm2_icon_geometry_get(E_Fm2_Icon *ic, int *x, int *y, int *w, int *h) { int xx, yy, ww, hh; - if (x) *x = 0; if (y) *y = 0; if (w) *w = 0; if (h) *h = 0; + if (x) *x = 0; + if (y) *y = 0; + if (w) *w = 0; + if (h) *h = 0; + if (ic) { evas_object_geometry_get(ic->obj, , , , ); --
[EGIT] [core/enlightenment] enlightenment-0.20 13/20: set x11 maximized window hint correctly on resize end
discomfitor pushed a commit to branch enlightenment-0.20. http://git.enlightenment.org/core/enlightenment.git/commit/?id=5cdd0deb588d8b8b0bb0d0df1442471385448e64 commit 5cdd0deb588d8b8b0bb0d0df1442471385448e64 Author: Mike BlumenkrantzDate: Fri May 27 11:57:41 2016 -0400 set x11 maximized window hint correctly on resize end fix T3702 --- src/bin/e_client.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/bin/e_client.c b/src/bin/e_client.c index 398a133..4dcc44a 100644 --- a/src/bin/e_client.c +++ b/src/bin/e_client.c @@ -1048,8 +1048,8 @@ _e_client_resize_end(E_Client *ec) /* If this border was maximized, we need to unset Maximized state or * on restart, E still thinks it's maximized */ if (ec->maximized != E_MAXIMIZE_NONE) - e_hints_window_maximized_set(ec, ec->maximized & E_MAXIMIZE_NONE, - ec->maximized & E_MAXIMIZE_NONE); + e_hints_window_maximized_set(ec, ec->maximized & E_MAXIMIZE_HORIZONTAL, + ec->maximized & E_MAXIMIZE_VERTICAL); _e_client_hook_call(E_CLIENT_HOOK_RESIZE_END, ec); --
[EGIT] [core/enlightenment] enlightenment-0.20 14/20: just a small patch to make sure evry_hide does not get called synchronously from an Evry_Action
discomfitor pushed a commit to branch enlightenment-0.20. http://git.enlightenment.org/core/enlightenment.git/commit/?id=ce6da215fd2451d7e0c15cd5f467237a63811f8f commit ce6da215fd2451d7e0c15cd5f467237a63811f8f Author: Hannes JanetzekDate: Tue May 31 11:41:33 2016 -0400 just a small patch to make sure evry_hide does not get called synchronously from an Evry_Action --- src/modules/everything/evry.c | 22 +++--- 1 file changed, 19 insertions(+), 3 deletions(-) diff --git a/src/modules/everything/evry.c b/src/modules/everything/evry.c index ff7b000..9dab641 100644 --- a/src/modules/everything/evry.c +++ b/src/modules/everything/evry.c @@ -71,6 +71,7 @@ static Eina_Bool _evry_cb_selection_notify(void *data, int type, void *even static Eina_Bool _evry_cb_mouse(void *data, int type, void *event); static Eina_Bool _evry_delay_hide_timer(void *data); +static Eina_Bool _evry_focus_out_timer(void *data); static Eina_List *windows = NULL; @@ -151,17 +152,32 @@ _evry_cb_item_changed(EINA_UNUSED void *data, EINA_UNUSED int type, void *event) return ECORE_CALLBACK_PASS_ON; } -static void -_evry_focus_out(void *data, Evas *e EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED) +static Eina_Bool +_evry_focus_out_timer(void *data) { Evry_Window *win = data; E_Client *ec; - if (!win->grab) return; + win->delay_hide_action = NULL; ec = e_win_client_get(win->ewin); if (ec && (!e_object_is_del(E_OBJECT(ec evry_hide(win, 0); + + return ECORE_CALLBACK_CANCEL; +} + +static void +_evry_focus_out(void *data, Evas *e EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event_info EINA_UNUSED) +{ + Evry_Window *win = data; + + if (!win->grab) return; + + if (win->delay_hide_action) + ecore_timer_del(win->delay_hide_action); + + win->delay_hide_action = ecore_timer_add(0.0, _evry_focus_out_timer, win); } Evry_Window * --
[EGIT] [core/enlightenment] enlightenment-0.20 06/20: add client util function for detecting popups, block popups in ibar/tasks
discomfitor pushed a commit to branch enlightenment-0.20. http://git.enlightenment.org/core/enlightenment.git/commit/?id=d7a934c09a216447620e31f1ff38c94f9fb169f7 commit d7a934c09a216447620e31f1ff38c94f9fb169f7 Author: Mike BlumenkrantzDate: Wed May 18 14:42:30 2016 -0400 add client util function for detecting popups, block popups in ibar/tasks mainly a wayland issue where popup menus would cause the tasks gadget to grow and shrink uncontrollably --- src/bin/e_client.x | 20 src/modules/ibar/e_mod_main.c | 1 + src/modules/tasks/e_mod_main.c | 5 - 3 files changed, 25 insertions(+), 1 deletion(-) diff --git a/src/bin/e_client.x b/src/bin/e_client.x index 2a27855..c2ec18c 100644 --- a/src/bin/e_client.x +++ b/src/bin/e_client.x @@ -77,6 +77,26 @@ e_client_util_ignored_get(const E_Client *ec) } static inline Eina_Bool +e_client_util_is_popup(const E_Client *ec) +{ + if (!ec) return EINA_FALSE; + switch (ec->netwm.type) + { + case E_WINDOW_TYPE_MENU: + case E_WINDOW_TYPE_SPLASH: + case E_WINDOW_TYPE_DROPDOWN_MENU: + case E_WINDOW_TYPE_POPUP_MENU: + case E_WINDOW_TYPE_TOOLTIP: + case E_WINDOW_TYPE_NOTIFICATION: + case E_WINDOW_TYPE_COMBO: + case E_WINDOW_TYPE_DND: +return EINA_TRUE; + default: break; + } + return EINA_FALSE; +} + +static inline Eina_Bool e_client_util_desk_visible(const E_Client *ec, const E_Desk *desk) { if (!ec) return EINA_FALSE; diff --git a/src/modules/ibar/e_mod_main.c b/src/modules/ibar/e_mod_main.c index 5b5538e..3f805ec 100644 --- a/src/modules/ibar/e_mod_main.c +++ b/src/modules/ibar/e_mod_main.c @@ -1299,6 +1299,7 @@ _ibar_icon_menu_client_add(IBar_Icon *ic, E_Client *ec) int w, h; if (ec->netwm.state.skip_taskbar || e_client_util_ignored_get(ec)) return EINA_FALSE; + if (e_client_util_is_popup(ec)) return EINA_FALSE; o = ic->menu->o_bg; it = edje_object_add(e_comp->evas); ic->client_objs = eina_list_append(ic->client_objs, it); diff --git a/src/modules/tasks/e_mod_main.c b/src/modules/tasks/e_mod_main.c index fa78b69..e7fdfaa 100644 --- a/src/modules/tasks/e_mod_main.c +++ b/src/modules/tasks/e_mod_main.c @@ -369,7 +369,8 @@ _tasks_new(Evas *e, E_Zone *zone, const char *id) tasks->horizontal = 1; EINA_LIST_FOREACH(e_comp->clients, l, ec) { -if ((!e_client_util_ignored_get(ec)) && (!e_object_is_del(E_OBJECT(ec +if ((!e_client_util_ignored_get(ec)) && (!e_object_is_del(E_OBJECT(ec))) && +(!e_client_util_is_popup(ec))) tasks->clients = eina_list_append(tasks->clients, ec); } @@ -892,6 +893,8 @@ _tasks_cb_event_client_add(void *data EINA_UNUSED, int type EINA_UNUSED, void *e Eina_List *l; if (e_client_util_ignored_get(ev->ec) || e_object_is_del(E_OBJECT(ev->ec))) return ECORE_CALLBACK_RENEW; + if (e_client_util_is_popup(ev->ec)) return ECORE_CALLBACK_RENEW; + EINA_LIST_FOREACH(tasks_config->tasks, l, tasks) { if ((!tasks->clients) || (!eina_list_data_find(tasks->clients, ev->ec))) --
[EGIT] [core/enlightenment] enlightenment-0.20 03/20: e - suspend.hibernat intelligently - dont account for ac power
discomfitor pushed a commit to branch enlightenment-0.20. http://git.enlightenment.org/core/enlightenment.git/commit/?id=cad34648c6e321577b37cadd5f25f9958607ef2e commit cad34648c6e321577b37cadd5f25f9958607ef2e Author: Carsten Haitzler (Rasterman)Date: Tue May 17 00:33:47 2016 +0900 e - suspend.hibernat intelligently - dont account for ac power this means only lid/screen status affects intelligent suspending. it's not what people expect and doesnt rely on ecore getting mains power stuff right too. --- src/bin/e_actions.c | 6 ++ 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/bin/e_actions.c b/src/bin/e_actions.c index d2f1d71..17ca842 100644 --- a/src/bin/e_actions.c +++ b/src/bin/e_actions.c @@ -2454,8 +2454,7 @@ _have_lid_and_external_screens_on(void) ACT_FN_GO(suspend_smart, EINA_UNUSED) { - if ((!_have_lid_and_external_screens_on()) && - (ecore_power_state_get() != ECORE_POWER_STATE_MAINS)) + if (!_have_lid_and_external_screens_on()) e_sys_action_do(E_SYS_SUSPEND, NULL); } @@ -2523,8 +2522,7 @@ ACT_FN_GO(hibernate, ) ACT_FN_GO(hibernate_smart, EINA_UNUSED) { - if ((!_have_lid_and_external_screens_on()) && - (ecore_power_state_get() != ECORE_POWER_STATE_MAINS)) + if (!_have_lid_and_external_screens_on()) e_sys_action_do(E_SYS_HIBERNATE, NULL); } --
[EGIT] [core/enlightenment] enlightenment-0.20 16/20: use current zone when activating a client's menu with the mouse
discomfitor pushed a commit to branch enlightenment-0.20. http://git.enlightenment.org/core/enlightenment.git/commit/?id=e8c495b2f245e4085e981122b8fc6360076f9052 commit e8c495b2f245e4085e981122b8fc6360076f9052 Author: Mike BlumenkrantzDate: Tue May 31 12:23:50 2016 -0400 use current zone when activating a client's menu with the mouse the mouse defines position of a mouse-activated menu fix T3701 --- src/bin/e_int_client_menu.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/bin/e_int_client_menu.c b/src/bin/e_int_client_menu.c index 637bd7b..e8625ca 100644 --- a/src/bin/e_int_client_menu.c +++ b/src/bin/e_int_client_menu.c @@ -259,7 +259,7 @@ e_int_client_menu_show(E_Client *ec, Evas_Coord x, Evas_Coord y, int key, unsign e_menu_activate_key(ec->border_menu, ec->zone, x, y, 1, 1, E_MENU_POP_DIRECTION_DOWN); else - e_menu_activate_mouse(ec->border_menu, ec->zone, x, y, 1, 1, + e_menu_activate_mouse(ec->border_menu, e_zone_current_get(), x, y, 1, 1, E_MENU_POP_DIRECTION_DOWN, timestamp); } --
[EGIT] [core/enlightenment] enlightenment-0.20 18/20: only block mouse-out callback for wl action clients if the mouse is grabbed
discomfitor pushed a commit to branch enlightenment-0.20. http://git.enlightenment.org/core/enlightenment.git/commit/?id=4c64703f74fe0d5339cf87dc0f4db7dd53d2c037 commit 4c64703f74fe0d5339cf87dc0f4db7dd53d2c037 Author: Mike BlumenkrantzDate: Wed Jun 1 13:06:27 2016 -0400 only block mouse-out callback for wl action clients if the mouse is grabbed --- src/bin/e_comp_wl.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/bin/e_comp_wl.c b/src/bin/e_comp_wl.c index 392eb24..fbdb610 100644 --- a/src/bin/e_comp_wl.c +++ b/src/bin/e_comp_wl.c @@ -177,7 +177,7 @@ _e_comp_wl_evas_cb_mouse_out(void *data, Evas *evas EINA_UNUSED, Evas_Object *ob uint32_t serial; if (!(ec = data)) return; - if (ec->cur_mouse_action) return; + if (ec->cur_mouse_action && e_grabinput_mouse_win_get()) return; /* FIXME? this is a hack to just reset the cursor whenever we mouse out. not sure if accurate */ { Evas_Object *o; --
[EGIT] [core/enlightenment] enlightenment-0.20 07/20: enlightenment_open: correctly return the exist status code of the executed command
discomfitor pushed a commit to branch enlightenment-0.20. http://git.enlightenment.org/core/enlightenment.git/commit/?id=22377939176d98d44ec6fa508a09f5d890eacee4 commit 22377939176d98d44ec6fa508a09f5d890eacee4 Author: Dave AndreoliDate: Fri May 20 19:24:43 2016 +0200 enlightenment_open: correctly return the exist status code of the executed command @fix and close T3555 --- src/bin/e_open.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/bin/e_open.c b/src/bin/e_open.c index 045fa76..fa787e8 100644 --- a/src/bin/e_open.c +++ b/src/bin/e_open.c @@ -8,6 +8,7 @@ #include #include #include +#include # ifdef E_API # undef E_API @@ -562,7 +563,7 @@ main(int argc, char *argv[]) } free(cmds); -return ret; +return WEXITSTATUS(ret); } } --
[EGIT] [core/enlightenment] enlightenment-0.20 11/20: use current zone for shelf config dialog
discomfitor pushed a commit to branch enlightenment-0.20. http://git.enlightenment.org/core/enlightenment.git/commit/?id=f4f42e8a28100dba9e5b609da4f7c3c30ce04e06 commit f4f42e8a28100dba9e5b609da4f7c3c30ce04e06 Author: Mike BlumenkrantzDate: Tue May 24 11:59:56 2016 -0400 use current zone for shelf config dialog fix T3683 --- src/modules/conf_shelves/e_int_config_shelf.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/modules/conf_shelves/e_int_config_shelf.c b/src/modules/conf_shelves/e_int_config_shelf.c index 63f8f85..c28bebd 100644 --- a/src/modules/conf_shelves/e_int_config_shelf.c +++ b/src/modules/conf_shelves/e_int_config_shelf.c @@ -265,7 +265,7 @@ _ilist_fill(E_Config_Dialog_Data *cfdata) e_widget_ilist_freeze(cfdata->o_list); e_widget_ilist_clear(cfdata->o_list); e_widget_ilist_go(cfdata->o_list); - zone = e_comp_object_util_zone_get(cfdata->cfd->dia->win); + zone = e_zone_current_get(); desk = e_desk_current_get(zone); EINA_LIST_FOREACH(e_shelf_list(), l, es) --
[EGIT] [core/enlightenment] enlightenment-0.20 08/20: Updating italian translation
discomfitor pushed a commit to branch enlightenment-0.20. http://git.enlightenment.org/core/enlightenment.git/commit/?id=e8e41b18794441246421ae63836df1dfbd1a8442 commit e8e41b18794441246421ae63836df1dfbd1a8442 Author: maxerbaDate: Sun May 22 18:00:53 2016 +0200 Updating italian translation --- po/it.po | 1092 +++--- 1 file changed, 538 insertions(+), 554 deletions(-) diff --git a/po/it.po b/po/it.po index b198159..6061ce6 100644 --- a/po/it.po +++ b/po/it.po @@ -6,8 +6,8 @@ msgid "" msgstr "" "Project-Id-Version: Enlightenment\n" "Report-Msgid-Bugs-To: enlightenment-devel@lists.sourceforge.net\n" -"POT-Creation-Date: 2016-04-02 18:49+0200\n" -"PO-Revision-Date: 2015-12-12 11:47+0100\n" +"POT-Creation-Date: 2016-05-22 12:11+0200\n" +"PO-Revision-Date: 2016-05-22 17:49+0200\n" "Last-Translator: Massimo Maiurana \n" "Language-Team: General\n" "Language: it\n" @@ -20,20 +20,20 @@ msgstr "" msgid "About Enlightenment" msgstr "Informazioni su Enlightenment" -#: src/bin/e_about.c:20 src/bin/e_actions.c:2037 src/bin/e_actions.c:3125 +#: src/bin/e_about.c:20 src/bin/e_actions.c:2037 src/bin/e_actions.c:3123 #: src/bin/e_config_dialog.c:290 src/bin/e_fm.c:1073 #: src/bin/e_int_client_menu.c:243 src/bin/e_int_client_prop.c:81 -#: src/bin/e_startup.c:88 src/bin/e_theme_about.c:22 +#: src/bin/e_startup.c:101 src/bin/e_theme_about.c:22 #: src/modules/conf/e_conf.c:157 #: src/modules/conf_bindings/e_int_config_edgebindings.c:872 #: src/modules/everything/evry_plug_windows.c:455 -#: src/modules/fileman/e_fwin.c:2571 +#: src/modules/fileman/e_fwin.c:2572 msgid "Close" msgstr "Chiudi" -#: src/bin/e_about.c:21 src/bin/e_actions.c:3529 src/bin/e_actions.c:3533 -#: src/bin/e_actions.c:3537 src/bin/e_init.c:78 src/bin/e_int_menus.c:228 -#: src/modules/conf_interaction/e_int_config_mouse.c:167 +#: src/bin/e_about.c:21 src/bin/e_actions.c:3527 src/bin/e_actions.c:3531 +#: src/bin/e_actions.c:3535 src/bin/e_init.c:78 src/bin/e_int_menus.c:228 +#: src/modules/conf_interaction/e_int_config_mouse.c:168 #: src/modules/conf_window_remembers/e_int_config_remembers.c:242 #: src/modules/wizard/page_000.c:34 msgid "Enlightenment" @@ -70,15 +70,15 @@ msgstr "" msgid "Are you sure you want to kill this window?" msgstr "Siete sicuri di voler uccidere questa finestra?" -#: src/bin/e_actions.c:375 src/bin/e_actions.c:3130 +#: src/bin/e_actions.c:375 src/bin/e_actions.c:3128 #: src/bin/e_int_client_menu.c:851 msgid "Kill" msgstr "Uccidi" #: src/bin/e_actions.c:377 src/bin/e_actions.c:2154 src/bin/e_actions.c:2245 #: src/bin/e_actions.c:2305 src/bin/e_actions.c:2362 src/bin/e_actions.c:2424 -#: src/bin/e_actions.c:2515 src/bin/e_confirm_dialog.c:53 -#: src/bin/e_desklock.c:589 src/bin/e_fm.c:10644 src/bin/e_fm.c:10997 +#: src/bin/e_actions.c:2514 src/bin/e_confirm_dialog.c:53 +#: src/bin/e_desklock.c:589 src/bin/e_fm.c:10642 src/bin/e_fm.c:10995 #: src/bin/e_screensaver.c:202 src/modules/quickaccess/e_mod_quickaccess.c:1306 msgid "No" msgstr "No" @@ -87,7 +87,7 @@ msgstr "No" msgid "Action Params Syntax Error" msgstr "Errore di sintassi nei parametri dell'azione" -#: src/bin/e_actions.c:2149 src/bin/e_actions.c:3533 src/bin/e_int_menus.c:257 +#: src/bin/e_actions.c:2149 src/bin/e_actions.c:3531 src/bin/e_int_menus.c:257 msgid "Exit" msgstr "Esci" @@ -96,8 +96,8 @@ msgid "Are you sure you want to exit Enlightenment?" msgstr "Siete sicuri di voler uscire da Enlightement?" #: src/bin/e_actions.c:2152 src/bin/e_actions.c:2243 src/bin/e_actions.c:2303 -#: src/bin/e_actions.c:2360 src/bin/e_actions.c:2422 src/bin/e_actions.c:2513 -#: src/bin/e_confirm_dialog.c:52 src/bin/e_desklock.c:587 src/bin/e_fm.c:10647 +#: src/bin/e_actions.c:2360 src/bin/e_actions.c:2422 src/bin/e_actions.c:2512 +#: src/bin/e_confirm_dialog.c:52 src/bin/e_desklock.c:587 src/bin/e_fm.c:10645 #: src/bin/e_screensaver.c:200 src/modules/quickaccess/e_mod_quickaccess.c:1306 msgid "Yes" msgstr "Sì" @@ -118,7 +118,7 @@ msgstr "Spegni" msgid "Are you sure you want to power off your computer?" msgstr "Siete sicuri di voler spegnere il computer?" -#: src/bin/e_actions.c:2357 src/bin/e_actions.c:3576 +#: src/bin/e_actions.c:2357 src/bin/e_actions.c:3574 msgid "Reboot" msgstr "Riavvia" @@ -126,7 +126,7 @@ msgstr "Riavvia" msgid "Are you sure you want to reboot your computer?" msgstr "Siete sicuri di voler riavviare il computer?" -#: src/bin/e_actions.c:2419 src/bin/e_actions.c:3584 +#: src/bin/e_actions.c:2419 src/bin/e_actions.c:3582 msgid "Suspend" msgstr "Sospendi" @@ -134,193 +134,193 @@ msgstr "Sospendi" msgid "Are you sure you want to suspend your computer?" msgstr "Siete sicuri di voler sospendere il computer?" -#: src/bin/e_actions.c:2510 src/bin/e_actions.c:3592 +#: src/bin/e_actions.c:2509 src/bin/e_actions.c:3590 #: src/modules/conf_bindings/e_int_config_acpibindings.c:379 msgid "Hibernate" msgstr
[EGIT] [core/enlightenment] enlightenment-0.20 05/20: fix e_place_zone_region_smart_cleanup()
discomfitor pushed a commit to branch enlightenment-0.20. http://git.enlightenment.org/core/enlightenment.git/commit/?id=608650a2b8916b34c6f868c0651211dadbc5d7d0 commit 608650a2b8916b34c6f868c0651211dadbc5d7d0 Author: Mike BlumenkrantzDate: Wed May 18 12:32:27 2016 -0400 fix e_place_zone_region_smart_cleanup() this function was adding the same client multiple times, failing to cleanup windows effectively, and misusing the skiplist functionality of e_place functions fix T3654 --- src/bin/e_place.c | 8 +--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/bin/e_place.c b/src/bin/e_place.c index 3780c9d..e32210d 100644 --- a/src/bin/e_place.c +++ b/src/bin/e_place.c @@ -29,7 +29,7 @@ e_place_zone_region_smart_cleanup(E_Zone *zone) /* Insert the ec if larger than the current ec */ if (area >= testarea) { - clients = eina_list_prepend_relative(clients, ec2, ec); + clients = eina_list_prepend_relative_list(clients, ec, ll); break; } } @@ -41,10 +41,12 @@ e_place_zone_region_smart_cleanup(E_Zone *zone) /* Loop over the clients moving each one using the smart placement */ EINA_LIST_FREE(clients, ec) { -int new_x, new_y; +int new_x = zone->x, new_y = zone->y; +Eina_List *l = eina_list_append(NULL, ec); -e_place_zone_region_smart(zone, clients, ec->x, ec->y, +e_place_zone_region_smart(zone, l, zone->x, zone->y, ec->w, ec->h, _x, _y); +eina_list_free(l); evas_object_move(ec->frame, new_x, new_y); } } --
[EGIT] [core/enlightenment] enlightenment-0.20 10/20: update client remember on opacity change
discomfitor pushed a commit to branch enlightenment-0.20. http://git.enlightenment.org/core/enlightenment.git/commit/?id=c31b607ba6ec9931163fcce90ab7d534b7476735 commit c31b607ba6ec9931163fcce90ab7d534b7476735 Author: Mike BlumenkrantzDate: Tue May 24 11:52:31 2016 -0400 update client remember on opacity change fix T3681 --- src/bin/e_comp_object.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/bin/e_comp_object.c b/src/bin/e_comp_object.c index 611bb79..b496917 100644 --- a/src/bin/e_comp_object.c +++ b/src/bin/e_comp_object.c @@ -2194,6 +2194,9 @@ _e_comp_smart_color_set(Evas_Object *obj, int r, int g, int b, int a) { INTERNAL_ENTRY; evas_object_color_set(cw->clip, r, g, b, a); + cw->ec->netwm.opacity = a; + if (cw->ec->remember && (cw->ec->remember->apply & E_REMEMBER_APPLY_OPACITY)) + e_remember_update(cw->ec); evas_object_smart_callback_call(obj, "color_set", NULL); } --
[EGIT] [core/enlightenment] enlightenment-0.20 19/20: unset comp_grabbed flag before action client compositor ungrab
discomfitor pushed a commit to branch enlightenment-0.20. http://git.enlightenment.org/core/enlightenment.git/commit/?id=90ecf5401ba711aeeb3f65505dc646780e21eb11 commit 90ecf5401ba711aeeb3f65505dc646780e21eb11 Author: Mike BlumenkrantzDate: Wed Jun 1 13:06:52 2016 -0400 unset comp_grabbed flag before action client compositor ungrab this flag was blocking accurate event propagation in some cases --- src/bin/e_client.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/bin/e_client.c b/src/bin/e_client.c index 4dcc44a..b0ba907 100644 --- a/src/bin/e_client.c +++ b/src/bin/e_client.c @@ -387,8 +387,8 @@ _e_client_action_input_win_del(void) { if (!comp_grabbed) return 0; - e_comp_ungrab_input(1, 1); comp_grabbed = 0; + e_comp_ungrab_input(1, 1); return 1; } --
[EGIT] [core/enlightenment] enlightenment-0.20 04/20: remove pulse sinks/sources from list before running cbs which access the list
discomfitor pushed a commit to branch enlightenment-0.20. http://git.enlightenment.org/core/enlightenment.git/commit/?id=a71b5170dcdef2106ac6551125d171b6687acf63 commit a71b5170dcdef2106ac6551125d171b6687acf63 Author: Mike BlumenkrantzDate: Tue May 17 15:05:18 2016 -0400 remove pulse sinks/sources from list before running cbs which access the list this guarantees a crash any time the default sink gets removed since it will always re-set the about-to-be-deleted default sink as the default sink fix T3277 probably --- src/modules/mixer/lib/backends/pulseaudio/pulse.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/modules/mixer/lib/backends/pulseaudio/pulse.c b/src/modules/mixer/lib/backends/pulseaudio/pulse.c index 9660318..15fadea 100644 --- a/src/modules/mixer/lib/backends/pulseaudio/pulse.c +++ b/src/modules/mixer/lib/backends/pulseaudio/pulse.c @@ -257,11 +257,11 @@ _sink_remove_cb(int index, void *data EINA_UNUSED) { if (sink->idx == index) { + ctx->sinks = eina_list_remove_list(ctx->sinks, l); if (ctx->cb) ctx->cb((void *)ctx->userdata, EMIX_SINK_REMOVED_EVENT, (Emix_Sink *)sink); _sink_del(sink); - ctx->sinks = eina_list_remove_list(ctx->sinks, l); break; } } @@ -405,13 +405,13 @@ _sink_input_remove_cb(int index, void *data EINA_UNUSED) { if (input->idx == index) { + ctx->inputs = eina_list_remove_list(ctx->inputs, l); if (ctx->cb) ctx->cb((void *)ctx->userdata, EMIX_SINK_INPUT_REMOVED_EVENT, (Emix_Sink_Input *)input); _sink_input_del(input); - ctx->inputs = eina_list_remove_list(ctx->inputs, l); break; } } @@ -510,12 +510,12 @@ _source_remove_cb(int index, void *data EINA_UNUSED) { if (source->idx == index) { + ctx->sources = eina_list_remove_list(ctx->sources, l); if (ctx->cb) ctx->cb((void *)ctx->userdata, EMIX_SOURCE_REMOVED_EVENT, (Emix_Source *)source); _source_del(source); - ctx->sources = eina_list_remove_list(ctx->sources, l); break; } } --
[EGIT] [core/enlightenment] enlightenment-0.20 02/20: e start - no it doesny need dbus-launch
discomfitor pushed a commit to branch enlightenment-0.20. http://git.enlightenment.org/core/enlightenment.git/commit/?id=1f0e9fb0ab7c409aaebc15651a2ec4994dd67439 commit 1f0e9fb0ab7c409aaebc15651a2ec4994dd67439 Author: Carsten Haitzler (Rasterman)Date: Mon May 16 18:09:12 2016 +0900 e start - no it doesny need dbus-launch no. perhaps you should see the execvp("dbus-launch", dbus_argv); code that auto re-launches using dbus-launch if a dbus session bus etc. is not "found" (env vars). if your issue is that its mis-detecting the fix the detection, but this coe went into e_start like a decade ago or so... and it's worked every since in x11 mode and gave us a dbus session. it SHOULD work for wayland too. don't make instructions change and become more complex if not absoultely needed. :) --- README.wayland | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.wayland b/README.wayland index 1d49e7f..15de1f3 100644 --- a/README.wayland +++ b/README.wayland @@ -70,7 +70,7 @@ Enlightenment, when compiled with Wayland support and started from a tty, will automatically attempt to load the wl_drm output module and start a Wayland session. Simply start as usual: - dbus-launch enlightenment_start + enlightenment_start If you have a separate configuration profile that you would like to use, you can tell Enlightenment to use that when you start it: --
[EGIT] [core/enlightenment] enlightenment-0.20 20/20: force mouse-in again during comp ungrab if client previously had mouse-in
discomfitor pushed a commit to branch enlightenment-0.20. http://git.enlightenment.org/core/enlightenment.git/commit/?id=08867e544099387f938b8f680ce0b86715f8fca2 commit 08867e544099387f938b8f680ce0b86715f8fca2 Author: Mike BlumenkrantzDate: Wed Jun 1 13:07:45 2016 -0400 force mouse-in again during comp ungrab if client previously had mouse-in unfocus performs a mouse-out, so this is necessary in order to allow events to reach the client again after a grab ends --- src/bin/e_comp.c | 7 +++ 1 file changed, 7 insertions(+) diff --git a/src/bin/e_comp.c b/src/bin/e_comp.c index 78f3869..db255ac 100644 --- a/src/bin/e_comp.c +++ b/src/bin/e_comp.c @@ -1696,8 +1696,15 @@ e_comp_ungrab_input(Eina_Bool mouse, Eina_Bool kbd) if (e_comp->comp_type == E_PIXMAP_TYPE_WL) { + Eina_Bool mouse_in = ec->mouse.in; + int x, y; + + x = ec->mouse.current.mx; + y = ec->mouse.current.my; evas_object_focus_set(ec->frame, 0); evas_object_focus_set(ec->frame, 1); + if (mouse_in) + e_client_mouse_in(ec, x, y); } return; } --
[EGIT] [core/enlightenment] enlightenment-0.20 09/20: update README.wayland to include xwayland crash bug
discomfitor pushed a commit to branch enlightenment-0.20. http://git.enlightenment.org/core/enlightenment.git/commit/?id=6c93189233bd180397543995469af67c16dffab5 commit 6c93189233bd180397543995469af67c16dffab5 Author: Mike BlumenkrantzDate: Mon May 23 11:49:49 2016 -0400 update README.wayland to include xwayland crash bug https://bugs.freedesktop.org/show_bug.cgi?id=95337 --- README.wayland | 2 ++ 1 file changed, 2 insertions(+) diff --git a/README.wayland b/README.wayland index 15de1f3..610bf05 100644 --- a/README.wayland +++ b/README.wayland @@ -96,3 +96,5 @@ Known Issues - Requires upstream XWayland improvements * Keyboard layout switching is not available - Requires various improvements +* XWayland crashes on start + - Requires XWayland release - https://bugs.freedesktop.org/show_bug.cgi?id=95337 --
[EGIT] [core/efl] master 01/01: Eina: Fix eina_promise_all refcount ordering problem
felipealmeida pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=507bbdb054044640f5c8cbcdd6ff6751e275d1da commit 507bbdb054044640f5c8cbcdd6ff6751e275d1da Author: Larry JrDate: Thu Jun 2 13:59:23 2016 -0300 Eina: Fix eina_promise_all refcount ordering problem The call to eina_promise_then steals the first ref'count, so it is possible that the promise is freed after the eina_promise_then, so we need to eina_promise_ref before eina_promise_then. --- src/lib/eina/eina_promise.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/lib/eina/eina_promise.c b/src/lib/eina/eina_promise.c index a39e52e..2c5a14a 100644 --- a/src/lib/eina/eina_promise.c +++ b/src/lib/eina/eina_promise.c @@ -614,9 +614,9 @@ eina_promise_all(Eina_Iterator* it) last = internal_it->data.promises + internal_it->data.num_promises; for (;cur_promise != last; ++cur_promise) { +eina_promise_ref(*cur_promise); // We need to keep the value alive until this promise is freed eina_promise_then(*cur_promise, (Eina_Promise_Cb)&_eina_promise_all_compose_then_cb, (Eina_Promise_Error_Cb)&_eina_promise_all_compose_error_then_cb, promise); -eina_promise_ref(*cur_promise); // We need to keep the value alive until this promise is freed } return >promise.vtable; --
[EGIT] [tools/eflete] master 01/02: Tizen theme: fix tabs style.
rimmed pushed a commit to branch master. http://git.enlightenment.org/tools/eflete.git/commit/?id=7326142f3ca72d7ca767c8b9b073458897d410c2 commit 7326142f3ca72d7ca767c8b9b073458897d410c2 Author: Mykyta BiliavskyiDate: Fri Jun 3 15:30:03 2016 +0300 Tizen theme: fix tabs style. --- data/themes/tizen/widgets/toolbar.edc | 20 ++-- 1 file changed, 14 insertions(+), 6 deletions(-) diff --git a/data/themes/tizen/widgets/toolbar.edc b/data/themes/tizen/widgets/toolbar.edc index 0797e4f..9deb2f5 100644 --- a/data/themes/tizen/widgets/toolbar.edc +++ b/data/themes/tizen/widgets/toolbar.edc @@ -550,8 +550,14 @@ group { name: "elm/toolbar/base/tabs_horizontal"; part { name: "clipper"; type: RECT; description { state: "default" 0.0; -rel1.to: "elm.swallow.content"; -rel2.to: "elm.swallow.content"; +rel1 { + offset: 0 -1; + to: "elm.swallow.content"; +} +rel2 { + to_x: "elm.swallow.content"; + to_y: "separator"; +} } } part { name: "separator"; @@ -572,7 +578,10 @@ group { name: "elm/toolbar/base/tabs_horizontal"; fixed: 1 0; min: 0 31; max: -1 31; -rel2.to_y: "separator"; +rel2 { + relative: 1.0 0.0; + to_y: "separator"; +} } } part { name: "arrow_right"; @@ -767,8 +776,8 @@ group { name: "elm/toolbar/item/tabs_horizontal"; } description { state: "selected" 0.0; inherit: "default" 0.00; -min: 136 31; -max: 136 31; +min: 136 32; +max: 136 32; rel2.offset: -2 -1; } } @@ -854,7 +863,6 @@ group { name: "elm/toolbar/item/tabs_horizontal"; description { state: "selected" 0.0; inherit: "default" 0.00; color_class: "text_tabs_selected"; -text.text: ""; } } part { name: "clipper"; --
[EGIT] [tools/eflete] master 02/02: Tizen theme: fix tabs toolbar resize on any action.
rimmed pushed a commit to branch master. http://git.enlightenment.org/tools/eflete.git/commit/?id=7e4138570acd1a817852ab87df980e2164ecb607 commit 7e4138570acd1a817852ab87df980e2164ecb607 Author: Mykyta BiliavskyiDate: Fri Jun 3 16:28:22 2016 +0300 Tizen theme: fix tabs toolbar resize on any action. --- data/themes/tizen/widgets/toolbar.edc | 478 +- 1 file changed, 239 insertions(+), 239 deletions(-) diff --git a/data/themes/tizen/widgets/toolbar.edc b/data/themes/tizen/widgets/toolbar.edc index 9deb2f5..f0965ad 100644 --- a/data/themes/tizen/widgets/toolbar.edc +++ b/data/themes/tizen/widgets/toolbar.edc @@ -283,6 +283,245 @@ group { name: "elm/toolbar/base/default"; } } + group { name: "elm/toolbar/base/tabs_horizontal"; + data { + item: "icon_size" "16"; + } + parts { + part { name: "base"; +type: RECT; +description { state: "default" 0.0; + align: 0.5 0.0; + min: 0 31; + max: -1 31; + color: 215 215 215 255; +} + } + part { name: "clipper_arrow_left"; +type: RECT; +description { state: "default" 0.0; + visible: 0; + align: 0.0 0.5; + min: 18 0; + max: 18 -1; +} +description { state: "visible" 0.0; + inherit: "default" 0.00; + visible: 1; +} + } + part { name: "clipper_arrow_right"; +type: RECT; +description { state: "default" 0.0; + visible: 0; + align: 1.0 0.5; + min: 18 0; + max: 18 -1; +} +description { state: "visible" 0.0; + inherit: "default" 0.00; + visible: 1; +} + } + part { name: "clipper"; +type: RECT; +description { state: "default" 0.0; + rel1 { + offset: 0 -1; + to: "elm.swallow.content"; + } + rel2 { + to_x: "elm.swallow.content"; + to_y: "separator"; + } +} + } + part { name: "separator"; +type: RECT; +description { state: "default" 0.0; + align: 0.5 1.0; + min: 0 1; + max: -1 1; + color: 170 170 170 255; + rel1.to_y: "base"; +} + } + part { name: "elm.swallow.content"; +type: SWALLOW; +clip_to: "clipper"; +description { state: "default" 0.0; + align: 0.5 0.0; + fixed: 1 0; + min: 0 32; + max: -1 32; + rel1.to_y: "base"; + rel2 { + relative: 1.0 0.0; + offset: -1 0; + to_y: "separator"; + } +} + } + part { name: "arrow_right"; +type: IMAGE; +clip_to: "clipper_arrow_right"; +description { state: "default" 0.0; + max: 16 16; + color_class: "bg_main"; + image.normal: "icon_arrow_right.png"; + rel1 { + to_x: "clipper_arrow_right"; + to_y: "elm.swallow.content"; + } + rel2 { + to_x: "clipper_arrow_right"; + to_y: "elm.swallow.content"; + } +} +description { state: "focused" 0.0; + inherit: "default" 0.00; + color_class: "select_light"; +} +description { state: "clicked" 0.0; + inherit: "default" 0.00; + color_class: "select"; +} + } + part { name: "arrow_left"; +type: IMAGE; +clip_to: "clipper_arrow_left"; +description { state: "default" 0.0; + max: 16 16; + color_class: "bg_main"; + image.normal: "icon_arrow_left.png"; + rel1 { + to_x: "clipper_arrow_left"; + to_y: "elm.swallow.content"; + } + rel2 { + to_x: "clipper_arrow_left"; + to_y: "elm.swallow.content"; + } +} +description { state: "focused" 0.0; + inherit: "default" 0.00; + color_class: "select_light"; +} +description { state: "clicked" 0.0; + inherit: "default" 0.00; + color_class: "select"; +} + } + } + programs { + program { name: "arrow_left_focused"; +signal: "mouse,in"; +source: "arrow_left"; +
[EGIT] [apps/ephoto] master 01/01: Ephoto: Cleanup some of the filters
okra pushed a commit to branch master. http://git.enlightenment.org/apps/ephoto.git/commit/?id=eef305202ce79918b92377b2c6c144748bae77bc commit eef305202ce79918b92377b2c6c144748bae77bc Author: Stephen HoustonDate: Thu Jun 2 18:26:57 2016 -0500 Ephoto: Cleanup some of the filters --- src/bin/ephoto_filters.c | 30 +++--- 1 file changed, 15 insertions(+), 15 deletions(-) diff --git a/src/bin/ephoto_filters.c b/src/bin/ephoto_filters.c index 5acb70b..abfda01 100644 --- a/src/bin/ephoto_filters.c +++ b/src/bin/ephoto_filters.c @@ -148,7 +148,7 @@ _grayscale(Evas_Object *image) { } static unsigned int * -_posterize(unsigned int *im_data, Evas_Coord w, Evas_Coord h, float rad) +_posterize(unsigned int *im_data, double rad, Evas_Coord w, Evas_Coord h) { unsigned int *im_data_new; int i, rr, gg, bb, a; @@ -209,7 +209,7 @@ static unsigned int * _dodge(unsigned int *im_data, unsigned int *im_data_two, Evas_Coord w, Evas_Coord h) { unsigned int *im_data_new; - float r, g, b, rr, gg, bb; + double r, g, b, rr, gg, bb; int i, rrr, ggg, bbb; im_data_new = malloc(sizeof(unsigned int) * w * h); for (i = 0; i < (w * h); i++) @@ -217,23 +217,23 @@ _dodge(unsigned int *im_data, unsigned int *im_data_two, Evas_Coord w, Evas_Coor b = ((im_data[i]) & 0xff); g = ((im_data[i] >> 8) & 0xff); r = ((im_data[i] >> 16) & 0xff); - + bb = ((im_data_two[i]) & 0xff); gg = ((im_data_two[i] >> 8) & 0xff); rr = ((im_data_two[i] >> 16) & 0xff); - -b *= 256; -g *= 256; -r *= 256; -bbb = rint(b / (256 - bb)); -ggg = rint(g / (256 - gg)); -rrr = rint(r / (256 - rr)); +b *= 255; +g *= 255; +r *= 255; + +bbb = rint(b / (255 - bb)); +ggg = rint(g / (255 - gg)); +rrr = rint(r / (255 - rr)); rrr = _normalize_color(rrr); ggg = _normalize_color(ggg); bbb = _normalize_color(bbb); - + im_data_new[i] = (255 << 24) | (rrr << 16) | (ggg << 8) | bbb; } return im_data_new; @@ -363,7 +363,7 @@ ephoto_filter_posterize(Evas_Object *main, Evas_Object *image) im_data = evas_object_image_data_get(elm_image_object_get(image), EINA_FALSE); evas_object_image_size_get(elm_image_object_get(image), , ); - im_data_new = _posterize(im_data, w, h, 2.0); + im_data_new = _posterize(im_data, 2.0, w, h); ephoto_single_browser_image_data_done(main, im_data_new, w, h); @@ -379,7 +379,7 @@ ephoto_filter_cartoon(Evas_Object *main, Evas_Object *image) evas_object_image_data_get(elm_image_object_get(image), EINA_FALSE); evas_object_image_size_get(elm_image_object_get(image), , ); im_data_new = _blur(im_data, 5, w, h); - im_data_new_two = _posterize(im_data_new, w, h, 5.0); + im_data_new_two = _posterize(im_data_new, 5.0, w, h); ephoto_single_browser_image_data_done(main, im_data_new_two, w, h); @@ -407,8 +407,8 @@ void ephoto_filter_sketch(Evas_Object *main, Evas_Object *image) evas_object_image_size_get(elm_image_object_get(image), , ); im_data = _grayscale(image); im_data_new = _negative(im_data, w, h); - im_data_new_two = _dodge(im_data, im_data_new, w, h); - im_data_new_three = _blur(im_data_new_two, 3, w, h); + im_data_new_two = _blur(im_data_new, 4, w, h); + im_data_new_three = _dodge(im_data, im_data_new_two, w, h); ephoto_single_browser_image_data_done(main, im_data_new_three, w, h); --
[EGIT] [tools/eflete] master 01/01: sound manager: stop plaing sample after close manager
rimmed pushed a commit to branch master. http://git.enlightenment.org/tools/eflete.git/commit/?id=59b5b70118dd25701f8c801e757b5e4c4b3e6546 commit 59b5b70118dd25701f8c801e757b5e4c4b3e6546 Author: Vyacheslav ReutskiyDate: Fri Jun 3 15:14:29 2016 +0300 sound manager: stop plaing sample after close manager Change-Id: I8dd29765c314d001720162b9955425786f970c75 --- src/bin/ui/sound_manager.c | 2 ++ src/bin/ui/sound_player/sound_player.c | 9 + src/bin/ui/sound_player/sound_player.h | 3 +++ 3 files changed, 14 insertions(+) diff --git a/src/bin/ui/sound_manager.c b/src/bin/ui/sound_manager.c index 4fd0474..9ec61a6 100644 --- a/src/bin/ui/sound_manager.c +++ b/src/bin/ui/sound_manager.c @@ -467,6 +467,7 @@ _mw_cancel_cb(void *data __UNUSED__, /* unset and hide the image property */ content = elm_object_content_unset(mng.win); evas_object_hide(content); + sound_player_sound_unset(); } static void @@ -479,6 +480,7 @@ _mw_done_cb(void *data __UNUSED__, /* unset and hide the image property */ content = elm_object_content_unset(mng.win); evas_object_hide(content); + sound_player_sound_unset(); } static void diff --git a/src/bin/ui/sound_player/sound_player.c b/src/bin/ui/sound_player/sound_player.c index e9720de..0fe2a0b 100644 --- a/src/bin/ui/sound_player/sound_player.c +++ b/src/bin/ui/sound_player/sound_player.c @@ -335,6 +335,15 @@ sound_player_sound_set(Sound_Data *sound) #endif } +void +sound_player_sound_unset(void) +{ + ecore_audio_obj_paused_set(in, true); + ecore_timer_freeze(timer); + + _play_finished_cb(NULL, NULL); +} + Evas_Object * sound_player_add(Evas_Object *parent) { diff --git a/src/bin/ui/sound_player/sound_player.h b/src/bin/ui/sound_player/sound_player.h index c5653a4..968d7cc 100644 --- a/src/bin/ui/sound_player/sound_player.h +++ b/src/bin/ui/sound_player/sound_player.h @@ -26,6 +26,9 @@ void sound_player_sound_set(Sound_Data *sound); +void +sound_player_sound_unset(void); + Evas_Object * sound_player_add(Evas_Object *parent); --
[EGIT] [bindings/python/python-efl] master 02/02: Follow recent Eo class names change
davemds pushed a commit to branch master. http://git.enlightenment.org/bindings/python/python-efl.git/commit/?id=36ca39e015c5fdb8a0f63382a52ab479134bbd6f commit 36ca39e015c5fdb8a0f63382a52ab479134bbd6f Author: Dave AndreoliDate: Fri Jun 3 14:21:22 2016 +0200 Follow recent Eo class names change --- efl/elementary/image.pxi | 2 +- efl/evas/efl.evas_object_polygon.pxi | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/efl/elementary/image.pxi b/efl/elementary/image.pxi index 95eb637..bb4341a 100644 --- a/efl/elementary/image.pxi +++ b/efl/elementary/image.pxi @@ -560,4 +560,4 @@ cdef class Image(Object): self._callback_del_full("download,error", _image_download_error_conv, func) -_object_mapping_register("Elm_Image", Image) +_object_mapping_register("Efl_Ui_Image", Image) diff --git a/efl/evas/efl.evas_object_polygon.pxi b/efl/evas/efl.evas_object_polygon.pxi index 1d1359f..c203a34 100644 --- a/efl/evas/efl.evas_object_polygon.pxi +++ b/efl/evas/efl.evas_object_polygon.pxi @@ -55,4 +55,4 @@ cdef class Polygon(Object): evas_object_polygon_points_clear(self.obj) -_object_mapping_register("Evas_Polygon", Polygon) +_object_mapping_register("Efl_Canvas_Polygon", Polygon) --
[EGIT] [bindings/python/python-efl] master 01/02: Add a test to check eo class names
davemds pushed a commit to branch master. http://git.enlightenment.org/bindings/python/python-efl.git/commit/?id=243664d73887b1831c4accddf73b714141b2949d commit 243664d73887b1831c4accddf73b714141b2949d Author: Dave AndreoliDate: Fri Jun 3 14:20:41 2016 +0200 Add a test to check eo class names a bit hackish, but do his work. And is important to check those names now that efl class names are going to be shuffled around :P --- efl/eo/efl.eo.pyx | 5 +++ tests/eo/test_02_class_names.py | 85 + 2 files changed, 90 insertions(+) diff --git a/efl/eo/efl.eo.pyx b/efl/eo/efl.eo.pyx index 282c8ec..bd3549a 100644 --- a/efl/eo/efl.eo.pyx +++ b/efl/eo/efl.eo.pyx @@ -266,6 +266,11 @@ cdef class Eo(object): return 1 +def _wipe_obj_data_NEVER_USE_THIS(self): +# only used in tests/eo/test_02_class_names.py +# to force object_from_instance() to recreate the obj +eo_key_data_set(self.obj, "python-eo", NULL) + cdef int _set_properties_from_keyword_args(self, dict kwargs) except 0: if kwargs: for k, v in kwargs.items(): diff --git a/tests/eo/test_02_class_names.py b/tests/eo/test_02_class_names.py new file mode 100644 index 000..d86823e --- /dev/null +++ b/tests/eo/test_02_class_names.py @@ -0,0 +1,85 @@ +#!/usr/bin/env python + +from efl import evas +from efl import elementary as elm + +import unittest + + +""" NOT TESTED YET: + +Evas_Canvas -> Canvas +Evas_Smart -> SmartObject +Evas_FilledImage -> FilledImage + +Elm_Conformant -> Conformant +Elm_Widget -> Object +Elm_Web -> Web + +""" + +class TestElmClassNames(unittest.TestCase): + +def setUp(self): +elm.need_ethumb() +self.win = elm.Window("t", elm.ELM_WIN_BASIC) +self.frame = elm.Frame(self.win) + +def tearDown(self): +self.win.delete() + +def testElm(self): +# 1. test window + +# this code will force the recreation of the py object (by class name) +# in the function object_from_instance() +self.win._wipe_obj_data_NEVER_USE_THIS() +del self.win +self.win = self.frame.top_widget_get() +self.assertIsInstance(self.win, elm.Window) + +# 2. test all the other widgets +for cls in [elm.Actionslider, elm.Background, elm.Box, +elm.Bubble, elm.Button, elm.Calendar, elm.Check, elm.Clock, +elm.Colorselector, elm.Combobox, elm.Ctxpopup, elm.Datetime, +elm.Dayselector, elm.Diskselector, elm.Entry, elm.Fileselector, +elm.FileselectorButton, elm.FileselectorEntry, elm.Flip, +elm.FlipSelector, elm.Frame, elm.Gengrid, elm.Genlist, +elm.GestureLayer, elm.Grid, elm.Hover, elm.Hoversel, elm.Icon, +elm.Image, elm.Index, elm.InnerWindow, elm.Label, elm.Layout, +elm.List, elm.Map, elm.Mapbuf, elm.Menu, elm.MultiButtonEntry, +elm.Naviframe, elm.Notify, elm.Panel, elm.Panes, elm.Photo, +elm.Photocam, elm.Plug, elm.Popup, elm.Progressbar, elm.Radio, +elm.Scroller, elm.SegmentControl, elm.Separator, elm.Slider, +elm.Slideshow, elm.Spinner, elm.Table, elm.Thumb, elm.Toolbar, +elm.Video, elm.Player]: +obj1 = cls(self.win) +self.frame.content = obj1 + +obj1._wipe_obj_data_NEVER_USE_THIS() +del obj1 +obj2 = self.frame.content +self.assertIsInstance(obj2, cls) + +obj2.delete() +del obj2 + +def testEvas(self): +for cls in [evas.Image, evas.Line, evas.Polygon, evas.Text, evas.Textblock, +evas.Box, evas.Textgrid, evas.Table, evas.Grid]: +obj1 = cls(self.win.evas) +self.frame.content = obj1 + +obj1._wipe_obj_data_NEVER_USE_THIS() +del obj1 +obj2 = self.frame.content +self.assertIsInstance(obj2, cls) + +obj2.delete() +del obj2 + + +if __name__ == '__main__': +unittest.main(verbosity=2) + + --
[EGIT] [tools/eflete] master 01/01: sound manager: don't create an eo_stream on select sample
rimmed pushed a commit to branch master. http://git.enlightenment.org/tools/eflete.git/commit/?id=97a797fdae89731e930abe9c8277f309458a73e3 commit 97a797fdae89731e930abe9c8277f309458a73e3 Author: Vyacheslav ReutskiyDate: Fri Jun 3 14:36:13 2016 +0300 sound manager: don't create an eo_stream on select sample Fixes T3499 T3498 @fix Change-Id: Ic234e2d5081644e2cb22b4472ce557a3942b6ef8 --- src/bin/ui/sound_player/sound_player.c | 38 +- 1 file changed, 10 insertions(+), 28 deletions(-) diff --git a/src/bin/ui/sound_player/sound_player.c b/src/bin/ui/sound_player/sound_player.c index 611a6d3..e9720de 100644 --- a/src/bin/ui/sound_player/sound_player.c +++ b/src/bin/ui/sound_player/sound_player.c @@ -198,6 +198,8 @@ _tone_play() ERR("Couldn't attach input and output!"); abort(); } + elm_slider_min_max_set(rewin, 0.0, TONE_PLAYING_DURATION); + elm_slider_value_set(rewin, 0.0); value = elm_slider_value_get(rewin); if (value) @@ -208,7 +210,7 @@ _tone_play() static void _sample_play() { - double value; + double value, len = 0.0; Eina_Bool ret = false; External_Resource *sample; @@ -223,6 +225,10 @@ _sample_play() ERR("Can not set source obj for added sample"); return; } +len = ecore_audio_obj_in_length_get(in); +elm_slider_min_max_set(rewin, 0, len); +elm_slider_value_set(rewin, 0.0); +length = ecore_file_size(sample->source); } ret = ecore_audio_obj_out_input_attach(out, in); @@ -314,41 +320,17 @@ _interrupt_playing() void sound_player_sound_set(Sound_Data *sound) { -#ifdef HAVE_AUDIO - External_Resource *sample; - Eina_Bool ret; - double len = 0.0; -#endif - snd = sound; #ifdef HAVE_AUDIO if (!snd) { - elm_object_disabled_set(play, true); +elm_object_disabled_set(play, true); } - else if (snd->type == SOUND_TYPE_SAMPLE) - { - elm_object_disabled_set(play, false); -_interrupt_playing(); - -sample = (External_Resource *)snd->resource; -_create_io_stream(); -ecore_audio_obj_name_set(in, sample->source); -ret = ecore_audio_obj_source_set(in, sample->source); -if (!ret) ERR("Can not set source '%s' to obj sample", sample->source) - len = ecore_audio_obj_in_length_get(in); -elm_slider_min_max_set(rewin, 0, len); -elm_slider_value_set(rewin, 0.0); -length = ecore_file_size(sample->source); - } - else if (snd->type == SOUND_TYPE_TONE) + else { - elm_object_disabled_set(play, false); +elm_object_disabled_set(play, false); _interrupt_playing(); - -elm_slider_min_max_set(rewin, 0.0, TONE_PLAYING_DURATION); -elm_slider_value_set(rewin, 0.0); } #endif } --
Re: [E-devel] [EGIT] [core/efl] master 01/04: autotools: we can't destroy this files as it break a make clean all cycle.
Put them under DISTCLEANFILES= On Fri, Jun 3, 2016 at 7:18 AM, Stefan Schmidtwrote: > Hello. > > Give me another solution in this case. > > ERROR: files left in build directory after distclean: > ./src/lib/efl/Efl_Config.h > ./src/lib/eina/eina_config.h > ./src/lib/elementary/Elementary.h > Makefile:3198: recipe for target 'distcleancheck' failed > make[1]: *** [distcleancheck] Error 1 > Makefile:3125: recipe for target 'distcheck' failed > > That means no releases. And alpha is up for Monday. > > regards > Stefan Schmidt > > On 02/06/16 19:54, Cedric BAIL wrote: > > cedric pushed a commit to branch master. > > > > > http://git.enlightenment.org/core/efl.git/commit/?id=776e3ae28cfa8bde42413ed2c763034c755eedfa > > > > commit 776e3ae28cfa8bde42413ed2c763034c755eedfa > > Author: Cedric BAIL > > Date: Thu Jun 2 10:42:21 2016 -0700 > > > > autotools: we can't destroy this files as it break a make clean all > cycle. > > --- > > Makefile.am | 3 --- > > 1 file changed, 3 deletions(-) > > > > diff --git a/Makefile.am b/Makefile.am > > index 64ea014..e744ffd 100644 > > --- a/Makefile.am > > +++ b/Makefile.am > > @@ -509,12 +509,9 @@ clean-local: > > rm -f ./src/lib/eet/Makefile > > rm -f ./src/lib/ecore/Makefile > > rm -f ./src/lib/efl/Makefile > > - rm -f ./src/lib/efl/Efl_Config.h > > rm -f ./src/lib/eina/Makefile > > - rm -f ./src/lib/eina/eina_config.h > > rm -f ./src/lib/eio/Makefile > > rm -f ./src/lib/elementary/Makefile > > - rm -f ./src/lib/elementary/Elementary.h > > rm -f ./src/lib/ector/Makefile > > rm -rf ./src/lib/ector/static_libs/rg_etc/.deps/ > > rm -f ./src/lib/evil/Makefile > > > > > > -- > What NetFlow Analyzer can do for you? Monitors network bandwidth and > traffic > patterns at an interface-level. Reveals which users, apps, and protocols > are > consuming the most bandwidth. Provides multi-vendor support for NetFlow, > J-Flow, sFlow and other flows. Make informed decisions using capacity > planning reports. https://ad.doubleclick.net/ddm/clk/305295220;132659582;e > ___ > enlightenment-devel mailing list > enlightenment-devel@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/enlightenment-devel > -- Eduardo de Barros Lima ◤✠◢ ebl...@gmail.com -- What NetFlow Analyzer can do for you? Monitors network bandwidth and traffic patterns at an interface-level. Reveals which users, apps, and protocols are consuming the most bandwidth. Provides multi-vendor support for NetFlow, J-Flow, sFlow and other flows. Make informed decisions using capacity planning reports. https://ad.doubleclick.net/ddm/clk/305295220;132659582;e ___ enlightenment-devel mailing list enlightenment-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
[EGIT] [core/efl] master 01/01: evas: Get pixels from rendered 3D scene
nikawhite pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=7e0601c98027a710e273fc2abe1dc2278a54a093 commit 7e0601c98027a710e273fc2abe1dc2278a54a093 Author: Oleksandr ShcherbinaDate: Fri Jun 3 14:22:33 2016 +0300 evas: Get pixels from rendered 3D scene Summary: Implemented interface Efl.Gfx.Buffer functions bufer_map/unmap for Efl.Canvas3D.Scene. Added function e3d_drawable_texture_rendered_pixels_get to module evas_gl_3d to getting pixels from FBO. Added wrappers for functions e3d_drawable_texture_rendered_pixels_get and e3d_drawable_texture_id_get to have possibility call it through engine functions. Reviewers: cedric, Hermet, raster, jpeg Reviewed By: jpeg Subscribers: jpeg Differential Revision: https://phab.enlightenment.org/D3978 --- src/lib/evas/canvas/efl_canvas_scene3d.c | 73 ++ src/lib/evas/canvas/efl_canvas_scene3d.eo | 6 +- src/lib/evas/include/evas_private.h| 3 +- src/modules/evas/engines/gl_common/evas_gl_3d.c| 47 ++ .../evas/engines/gl_common/evas_gl_3d_common.h | 5 +- src/modules/evas/engines/gl_generic/evas_engine.c | 15 - .../evas/engines/software_generic/evas_engine.c| 2 + 7 files changed, 146 insertions(+), 5 deletions(-) diff --git a/src/lib/evas/canvas/efl_canvas_scene3d.c b/src/lib/evas/canvas/efl_canvas_scene3d.c index d0623fe..c8ce097 100644 --- a/src/lib/evas/canvas/efl_canvas_scene3d.c +++ b/src/lib/evas/canvas/efl_canvas_scene3d.c @@ -208,4 +208,77 @@ _evas_image_3d_unset(Evas_Object *eo_obj EINA_UNUSED, Evas_Object_Protected_Data EINA_COW_WRITE_END(evas_object_3d_cow, obj->data_3d, data); } +EOLIAN static void * +_efl_canvas_scene3d_efl_gfx_buffer_buffer_map(Eo *eo_obj, void *_pd EINA_UNUSED, +int *length EINA_UNUSED, +Efl_Gfx_Buffer_Access_Mode mode, +int x, int y, int w, int h, +Efl_Gfx_Colorspace cspace, int *stride EINA_UNUSED) +{ + Evas_Image_Data *o = eo_data_scope_get(eo_obj, EVAS_IMAGE_CLASS); + Evas_Public_Data *e; + Evas_Canvas3D_Object_Data *pd_parent; + Evas_Canvas3D_Scene_Data *pd_scene; + int width = -1, height = -1, ntex = -1; + unsigned char *pixels = NULL; + + if (!o->cur->scene) + { +ERR("invalid scene data"); +return NULL; + } + if (mode & EFL_GFX_BUFFER_ACCESS_MODE_WRITE) + { +ERR("invalid map access mode"); +return NULL; + } + if (cspace != EFL_GFX_COLORSPACE_ARGB) + { +ERR("invalid map colorspace. Only ARGB is supported"); +return NULL; + } + + pd_parent = eo_data_scope_get(o->cur->scene, EVAS_CANVAS3D_OBJECT_CLASS); + e = eo_data_scope_get(pd_parent->evas, EVAS_CANVAS_CLASS); + pd_scene = eo_data_scope_get(o->cur->scene, EVAS_CANVAS3D_SCENE_CLASS); + + if (e->engine.func->drawable_size_get) + { + e->engine.func->drawable_size_get(e->engine.data.output, + pd_scene->surface, , ); + } + + if ((x < 0) || (y < 0) || ((x + w) > width) || ((y + h) > height)) + { +ERR("Invalid map dimensions : %dx%d +%d,%d. Image is %dx%d.", +w, h, x, y, width, height); +return NULL; + } + + if (e->engine.func->drawable_texture_target_id_get) + { +ntex = e->engine.func->drawable_texture_target_id_get(pd_scene->surface); + +if (e->engine.func->drawable_texture_rendered_pixels_get) + { + pixels = malloc(w * h * sizeof(DATA32)); //four component texture + e->engine.func->drawable_texture_rendered_pixels_get(ntex, x, y, w, h, + pd_scene->surface, pixels); + } +else + return NULL; + } + else + return NULL; + + return pixels; +} +EOLIAN static Eina_Bool +_efl_canvas_scene3d_efl_gfx_buffer_buffer_unmap(Eo *eo_obj EINA_UNUSED, void *_pd EINA_UNUSED, +void *data, int length EINA_UNUSED) +{ + free(data); + return EINA_TRUE; +} + #include "efl_canvas_scene3d.eo.c" diff --git a/src/lib/evas/canvas/efl_canvas_scene3d.eo b/src/lib/evas/canvas/efl_canvas_scene3d.eo index b157587..4df2239 100644 --- a/src/lib/evas/canvas/efl_canvas_scene3d.eo +++ b/src/lib/evas/canvas/efl_canvas_scene3d.eo @@ -1,4 +1,4 @@ -class Efl.Canvas.Scene3d (Evas.Image) +class Efl.Canvas.Scene3d (Evas.Image, Efl.Gfx.Buffer) { [[A UI view for EFL Canvas 3D.]] data: null; @@ -15,4 +15,8 @@ class Efl.Canvas.Scene3d (Evas.Image) } } } + implements { + Efl.Gfx.Buffer.buffer_map; + Efl.Gfx.Buffer.buffer_unmap; + } } diff --git
[EGIT] [apps/rage] master 01/01: rage videothubm - use sh explicitly for thumbnailer tool
raster pushed a commit to branch master. http://git.enlightenment.org/apps/rage.git/commit/?id=4780a4b07acf90301667f5ca93e13fbf466fd4a3 commit 4780a4b07acf90301667f5ca93e13fbf466fd4a3 Author: Carsten Haitzler (Rasterman)Date: Fri Jun 3 19:43:34 2016 +0900 rage videothubm - use sh explicitly for thumbnailer tool fixes problems for peolpe with bizarre shells... like fish. @fix --- src/bin/videothumb.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/bin/videothumb.c b/src/bin/videothumb.c index 0b4ee19..294955a 100644 --- a/src/bin/videothumb.c +++ b/src/bin/videothumb.c @@ -147,6 +147,7 @@ _videothumb_launch_do(Evas_Object *obj) "%s/rage/utils/rage_thumb %s 1 %i >& /dev/null", libdir, s, sd->poster_mode ? 1 : 0); sd->thumb_exe = ecore_exe_pipe_run(buf, + ECORE_EXE_USE_SH | ECORE_EXE_TERM_WITH_PARENT | ECORE_EXE_NOT_LEADER, obj); --
[EGIT] [core/efl] master 01/01: evas: fix huge memory leak for non-async rendering
jayji pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=5b0ddfec3816377761a122a2eb862446bb415ba9 commit 5b0ddfec3816377761a122a2eb862446bb415ba9 Author: Jean Guyomarc'hDate: Fri Jun 3 12:08:40 2016 +0200 evas: fix huge memory leak for non-async rendering So... I had issues with evas-fb engine which was massively leaking, one image per frame. After investigating a bit with @cedric on IRC, the reference count of the cache entries was always 2 before the engine dropped. So, for each frame with an animation, we could never drop a cache entry, leading to a trumendous amount of memory leaking. Now for non-async rendering, we copy the behaviour of evas_render_pipe_wakeup() which is called in async-mode, and actually drops a reference in the cache entry. Fixes T3763 --- src/lib/evas/canvas/evas_render.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/lib/evas/canvas/evas_render.c b/src/lib/evas/canvas/evas_render.c index 3a8322a..8b61d85 100644 --- a/src/lib/evas/canvas/evas_render.c +++ b/src/lib/evas/canvas/evas_render.c @@ -2949,6 +2949,8 @@ evas_render_updates_internal(Evas *eo_e, EINA_LIST_FOREACH(e->render.updates, l, ru) { post.updated_area = eina_list_append(post.updated_area, ru->area); + evas_cache_image_drop(ru->surface); + ru->surface = NULL; } eina_spinlock_take(&(e->render.lock)); _cb_always_call(eo_e, EVAS_CALLBACK_RENDER_POST, post.updated_area ? : NULL); --
Re: [E-devel] [EGIT] [core/efl] master 01/04: autotools: we can't destroy this files as it break a make clean all cycle.
Hello. Give me another solution in this case. ERROR: files left in build directory after distclean: ./src/lib/efl/Efl_Config.h ./src/lib/eina/eina_config.h ./src/lib/elementary/Elementary.h Makefile:3198: recipe for target 'distcleancheck' failed make[1]: *** [distcleancheck] Error 1 Makefile:3125: recipe for target 'distcheck' failed That means no releases. And alpha is up for Monday. regards Stefan Schmidt On 02/06/16 19:54, Cedric BAIL wrote: > cedric pushed a commit to branch master. > > http://git.enlightenment.org/core/efl.git/commit/?id=776e3ae28cfa8bde42413ed2c763034c755eedfa > > commit 776e3ae28cfa8bde42413ed2c763034c755eedfa > Author: Cedric BAIL> Date: Thu Jun 2 10:42:21 2016 -0700 > > autotools: we can't destroy this files as it break a make clean all > cycle. > --- > Makefile.am | 3 --- > 1 file changed, 3 deletions(-) > > diff --git a/Makefile.am b/Makefile.am > index 64ea014..e744ffd 100644 > --- a/Makefile.am > +++ b/Makefile.am > @@ -509,12 +509,9 @@ clean-local: > rm -f ./src/lib/eet/Makefile > rm -f ./src/lib/ecore/Makefile > rm -f ./src/lib/efl/Makefile > - rm -f ./src/lib/efl/Efl_Config.h > rm -f ./src/lib/eina/Makefile > - rm -f ./src/lib/eina/eina_config.h > rm -f ./src/lib/eio/Makefile > rm -f ./src/lib/elementary/Makefile > - rm -f ./src/lib/elementary/Elementary.h > rm -f ./src/lib/ector/Makefile > rm -rf ./src/lib/ector/static_libs/rg_etc/.deps/ > rm -f ./src/lib/evil/Makefile > -- What NetFlow Analyzer can do for you? Monitors network bandwidth and traffic patterns at an interface-level. Reveals which users, apps, and protocols are consuming the most bandwidth. Provides multi-vendor support for NetFlow, J-Flow, sFlow and other flows. Make informed decisions using capacity planning reports. https://ad.doubleclick.net/ddm/clk/305295220;132659582;e ___ enlightenment-devel mailing list enlightenment-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
[EGIT] [website/www-content] master 01/01: Wiki page start-event deleted with reason [] by Raster
WWW-www.enlightenment.org pushed a commit to branch master. http://git.enlightenment.org/website/www-content.git/commit/?id=fe22d5dde77bd7957d6d772c59cb5b2a73ba182b commit fe22d5dde77bd7957d6d772c59cb5b2a73ba182b Author: RasterDate: Fri Jun 3 03:08:26 2016 -0700 Wiki page start-event deleted with reason [] by Raster --- pages/start-event.txt | 4 1 file changed, 4 deletions(-) diff --git a/pages/start-event.txt b/pages/start-event.txt deleted file mode 100644 index 7c56b1e..000 --- a/pages/start-event.txt +++ /dev/null @@ -1,4 +0,0 @@ - -Enlightenment Developer Days 2016 in Paris, May 14-16th. -[[https://phab.enlightenment.org/w/events/enlightenment_developer_days_2016/ | More information.]] - \ No newline at end of file --
[EGIT] [bindings/python/python-efl] master 01/01: better indent
davemds pushed a commit to branch master. http://git.enlightenment.org/bindings/python/python-efl.git/commit/?id=e0456df2a22e42af6ed15c7e5c42faeb1953d0c1 commit e0456df2a22e42af6ed15c7e5c42faeb1953d0c1 Author: Dave AndreoliDate: Fri Jun 3 11:45:08 2016 +0200 better indent --- tests/elementary/test_02_image_icon.py | 14 -- 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/tests/elementary/test_02_image_icon.py b/tests/elementary/test_02_image_icon.py index dbb21b0..1c9b638 100644 --- a/tests/elementary/test_02_image_icon.py +++ b/tests/elementary/test_02_image_icon.py @@ -30,13 +30,14 @@ class TestElmImage(unittest.TestCase): def testImageFile(self): self.o.file = os.path.join(script_path, u"icon.png") -self.assertEqual( -self.o.file[0], os.path.join(script_path, u"icon.png")) +self.assertEqual(self.o.file[0], + os.path.join(script_path, u"icon.png")) self.assertEqual(self.o.object_size, (48, 48)) def testImageFileException(self): -self.assertRaises( -RuntimeError, setattr, self.o, "file", u"this_fails.png") +self.assertRaises(RuntimeError, + setattr, self.o, "file", + u"this_fails.png") def testImageEvas(self): self.assertIsInstance(self.o.object, evasImage) @@ -89,8 +90,9 @@ class TestElmIcon(unittest.TestCase): self.assertEqual(u"elementary", self.o.standard) def testIconStandardException(self): -self.assertRaises( -RuntimeWarning, setattr, self.o, "standard", u"this_fails") +self.assertRaises(RuntimeWarning, + setattr, self.o, "standard", + u"this_fails") if __name__ == '__main__': unittest.main(verbosity=2) --
[EGIT] [tools/eflete] master 01/01: Tizen theme: show correct over icon for group navi
rimmed pushed a commit to branch master. http://git.enlightenment.org/tools/eflete.git/commit/?id=4a1d3f865d95a5d60aa9f58caa30789cf3924a0a commit 4a1d3f865d95a5d60aa9f58caa30789cf3924a0a Author: Vyacheslav ReutskiyDate: Thu Jun 2 16:04:33 2016 +0300 Tizen theme: show correct over icon for group navi Change-Id: I9cf0d629573130fb19ca59a66e21efa5fd473507 --- data/themes/tizen/widgets/genlist.edc | 22 +- 1 file changed, 17 insertions(+), 5 deletions(-) diff --git a/data/themes/tizen/widgets/genlist.edc b/data/themes/tizen/widgets/genlist.edc index 542d0fe..47690da 100644 --- a/data/themes/tizen/widgets/genlist.edc +++ b/data/themes/tizen/widgets/genlist.edc @@ -1443,30 +1443,42 @@ group { name: "elm/genlist/tree/part/default"; source: "disclip"; action: STATE_SET "over" 0.00; target: "bg1"; - after: "over_icon"; - target: "elm.swallow.end2"; } program { name: "over_icon"; + signal: "mouse,in"; + source: "disclip"; action: STATE_SET "hide" 0.0; + filter: "bg" "default" 0.0; target: "elm.swallow.end"; target: "elm.swallow.end1"; + after: "over_i"; + } + program { name: "over_i"; + action: STATE_SET "over" 0.00; + target: "elm.swallow.end2"; } program { name: "over,out"; signal: "mouse,out"; source: "disclip"; action: STATE_SET "default" 0.00; target: "bg1"; - target: "elm.swallow.end"; - after: "unover_icon"; } program { name: "unover_icon"; + signal: "mouse,out"; + source: "disclip"; action: STATE_SET "hide" 0.0; + filter: "bg" "default" 0.0; target: "elm.swallow.end1"; target: "elm.swallow.end2"; + after: "unover_i"; + } + program { name: "unover_i"; + action: STATE_SET "default" 0.00; + target: "elm.swallow.end"; } - } } + group { name: "elm/genlist/item/state/default"; data { item: "texts" "elm.text"; --
[EGIT] [core/efl] master 01/01: edje_edit: add API for set/get part item
rimmed pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=b612fe2485402407603aafc8c3ec6f1e5db71649 commit b612fe2485402407603aafc8c3ec6f1e5db71649 Author: Vyacheslav ReutskiyDate: Fri Jun 3 12:26:57 2016 +0300 edje_edit: add API for set/get part item --- src/lib/edje/Edje_Edit.h | 25 +++ src/lib/edje/edje_edit.c | 53 2 files changed, 78 insertions(+) diff --git a/src/lib/edje/Edje_Edit.h b/src/lib/edje/Edje_Edit.h index 1135703..06052f8 100644 --- a/src/lib/edje/Edje_Edit.h +++ b/src/lib/edje/Edje_Edit.h @@ -2782,6 +2782,31 @@ EAPI Eina_Bool edje_edit_part_item_del(Evas_Object *obj, const char *part, const EAPI Eina_Bool edje_edit_part_item_index_del(Evas_Object *obj, const char *part, unsigned int index); +/** Set name for item from table or box items. + * + * @param obj Object being edited. + * @param part Part to change item's source. This part should have BOX or TABLE type. + * @param index Index of item + * @param name New item name. + * + * @return @c EINA_TRUE in case of success, @c EINA_FALSE otherwise. + * @since 1.18 + */ +EAPI Eina_Bool +edje_edit_part_item_index_name_set(Evas_Object *obj, const char *part, unsigned int index, const char *name); + +/** Get name for item from table or box items. + * + * @param obj Object being edited. + * @param part Part to return item's source. This part should have BOX or TABLE type. + * @param index Index of item. + * + * @return name of the given item. + * @since 1.18 + */ +EAPI const char * +edje_edit_part_item_index_name_get(Evas_Object *obj, const char *part, unsigned int index); + /** Set source for item from table or box items. * * @param obj Object being edited. diff --git a/src/lib/edje/edje_edit.c b/src/lib/edje/edje_edit.c index 2e98460..a231ed0 100644 --- a/src/lib/edje/edje_edit.c +++ b/src/lib/edje/edje_edit.c @@ -5236,6 +5236,59 @@ edje_edit_part_item_index_del(Evas_Object *obj, const char *part, unsigned int i return EINA_TRUE; } +EAPI Eina_Bool +edje_edit_part_item_index_name_set(Evas_Object *obj, const char *part, unsigned int index, const char *name) +{ + Edje_Part *ep; + unsigned int i; + + GET_RP_OR_RETURN(EINA_FALSE); + + /* There is only Box and Table is allowed. */ + if ((rp->part->type != EDJE_PART_TYPE_BOX) && + (rp->part->type != EDJE_PART_TYPE_TABLE)) + return EINA_FALSE; + if (rp->part->items_count < index) + return EINA_FALSE; + + ep = rp->part; + + if (!ed->file) return EINA_FALSE; + + /* check if a part with given name is exists. */ + for (i = 0; i < ep->items_count; ++i) + { +if (ep->items[i]->name && (!strcmp(ep->items[i]->name, name))) + return EINA_FALSE; + } + + eina_stringshare_del(ep->items[index]->name); + ep->items[index]->name = eina_stringshare_add(name); + + return EINA_TRUE; +} + +EAPI const char * +edje_edit_part_item_index_name_get(Evas_Object *obj, const char *part, unsigned int index) +{ + Edje_Part *ep; + + GET_RP_OR_RETURN(NULL); + + /* There is only Box and Table is allowed. */ + if ((rp->part->type != EDJE_PART_TYPE_BOX) && + (rp->part->type != EDJE_PART_TYPE_TABLE)) + return NULL; + if (rp->part->items_count < index) + return EINA_FALSE; + + ep = rp->part; + + if (!ed->file) return NULL; + + return eina_stringshare_add(ep->items[index]->name); +} + /* deprecated */ EAPI Eina_Bool edje_edit_part_item_source_set(Evas_Object *obj, const char *part, const char *item_name, const char *source_group) --
[EGIT] [bindings/python/python-efl] master 02/02: Follow eo class rename
davemds pushed a commit to branch master. http://git.enlightenment.org/bindings/python/python-efl.git/commit/?id=51946aaf8b13ff1838d12426072b52c251535446 commit 51946aaf8b13ff1838d12426072b52c251535446 Author: Dave AndreoliDate: Fri Jun 3 11:14:40 2016 +0200 Follow eo class rename --- efl/evas/efl.evas_object_rectangle.pxi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/efl/evas/efl.evas_object_rectangle.pxi b/efl/evas/efl.evas_object_rectangle.pxi index 385978e..b106d1d 100644 --- a/efl/evas/efl.evas_object_rectangle.pxi +++ b/efl/evas/efl.evas_object_rectangle.pxi @@ -103,4 +103,4 @@ cdef class Rectangle(Object): self._set_properties_from_keyword_args(kwargs) -_object_mapping_register("Evas_Rectangle", Rectangle) +_object_mapping_register("Efl_Canvas_Rectangle", Rectangle) --
[EGIT] [bindings/python/python-efl] master 01/02: Going back to use eo_del instead of eo_unref
davemds pushed a commit to branch master. http://git.enlightenment.org/bindings/python/python-efl.git/commit/?id=cadf4094047cede50c8b9ebf0734bb34d847133f commit cadf4094047cede50c8b9ebf0734bb34d847133f Author: Dave AndreoliDate: Fri Jun 3 09:14:31 2016 +0200 Going back to use eo_del instead of eo_unref ...still untested as the bindings are broken for something else atm --- efl/eo/efl.eo.pyx| 4 ++-- include/efl.c_eo.pxd | 1 + 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/efl/eo/efl.eo.pyx b/efl/eo/efl.eo.pyx index 5bcbb86..282c8ec 100644 --- a/efl/eo/efl.eo.pyx +++ b/efl/eo/efl.eo.pyx @@ -36,7 +36,7 @@ from efl.eina cimport Eina_Bool, \ Eina_Hash, eina_hash_string_superfast_new, eina_hash_add, eina_hash_del, \ eina_hash_find, EINA_LOG_DOM_DBG, EINA_LOG_DOM_INFO, \ Eina_Iterator, eina_iterator_next, eina_iterator_free -from efl.c_eo cimport Eo as cEo, eo_init, eo_shutdown, eo_unref, \ +from efl.c_eo cimport Eo as cEo, eo_init, eo_shutdown, eo_del, \ eo_class_name_get, eo_class_get, eo_base_class_get,\ eo_key_data_set, eo_key_data_get, \ eo_event_callback_add, eo_event_callback_del, EO_EVENT_DEL, \ @@ -283,7 +283,7 @@ cdef class Eo(object): garbage collector when there are no more reference to it. """ -eo_unref(self.obj) +eo_del(self.obj) def is_deleted(self): """Check if the object has been deleted thus leaving the object shallow. diff --git a/include/efl.c_eo.pxd b/include/efl.c_eo.pxd index c35b103..a21cfd3 100644 --- a/include/efl.c_eo.pxd +++ b/include/efl.c_eo.pxd @@ -101,6 +101,7 @@ cdef extern from "Eo.h": int eo_shutdown() Eo *eo_add(const Eo_Class *klass, Eo *parent, ...) +void eo_del(const Eo *obj) Eo *eo_ref(const Eo *obj) void eo_unref(const Eo *obj) int eo_ref_get(const Eo *obj) --
[EGIT] [core/efl] master 01/02: fix warning in build with uninit variable in generic loaders for xcf
raster pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=c3440ff947a4078b9a34244c8a7aca530dcec84e commit c3440ff947a4078b9a34244c8a7aca530dcec84e Author: Carsten Haitzler (Rasterman)Date: Fri Jun 3 18:07:22 2016 +0900 fix warning in build with uninit variable in generic loaders for xcf --- src/generic/evas/xcf/main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/generic/evas/xcf/main.c b/src/generic/evas/xcf/main.c index 373823b..8ffa099 100644 --- a/src/generic/evas/xcf/main.c +++ b/src/generic/evas/xcf/main.c @@ -585,7 +585,7 @@ xcf_load_image_props(void) break; case PROP_COMPRESSION: { - char compression; + char compression = 0; image->cp += xcf_read_int8(image->file, (DATA8 *), 1); --
[EGIT] [core/efl] master 02/02: ecore timeouts - dont crash on cancel
raster pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=f3b6d34a0fc0af17643098615a5cfde1b1890ad6 commit f3b6d34a0fc0af17643098615a5cfde1b1890ad6 Author: Carsten Haitzler (Rasterman)Date: Fri Jun 3 17:57:58 2016 +0900 ecore timeouts - dont crash on cancel this fixes a nasty double deletion on cancel of timeouts. at least for now as long as we have promises. --- src/lib/ecore/ecore_main.c | 9 + 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/src/lib/ecore/ecore_main.c b/src/lib/ecore/ecore_main.c index e17a5dd..a361289 100644 --- a/src/lib/ecore/ecore_main.c +++ b/src/lib/ecore/ecore_main.c @@ -2874,10 +2874,11 @@ _efl_loop_job_cancel(void* data, Eina_Promise_Owner* promise EINA_UNUSED) Efl_Internal_Promise *j = data; if (j->job_is) - ecore_job_del(j->u.job); - else - eo_del(j->u.timer); - _efl_loop_internal_cancel(j); + { +ecore_job_del(j->u.job); +_efl_loop_internal_cancel(j); + } + else eo_del(j->u.timer); } static Efl_Internal_Promise * --
[EGIT] [core/efl] master 01/01: elm_image: fix break related with elm image error enum
jypark pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=dc7b91cb7cf918f57a137a94652be5a0257c65d6 commit dc7b91cb7cf918f57a137a94652be5a0257c65d6 Author: Ji-Youn ParkDate: Fri Jun 3 17:14:37 2016 +0830 elm_image: fix break related with elm image error enum --- src/lib/elementary/elm_image_legacy.h | 25 + 1 file changed, 25 insertions(+) diff --git a/src/lib/elementary/elm_image_legacy.h b/src/lib/elementary/elm_image_legacy.h index ed9f6f2..2cb4b71 100644 --- a/src/lib/elementary/elm_image_legacy.h +++ b/src/lib/elementary/elm_image_legacy.h @@ -10,6 +10,31 @@ */ EAPI Evas_Object *elm_image_add(Evas_Object *parent); +/** Structure associated with smart callback 'download,progress'. + * + * @since 1.8 + * + * @ingroup Elm_Image + */ +typedef struct _Elm_Image_Progress +{ + double now; + double total; +} Elm_Image_Progress; + +/** Structure associated with smart callback 'download,progress'. + * + * @since 1.8 + * + * @ingroup Elm_Image + */ +typedef struct _Elm_Image_Error +{ + int status; + Eina_Bool open_error; +} Elm_Image_Error; + + typedef Evas_Object Elm_Image; /** --
[EGIT] [core/efl] master 01/01: Efl.Pack: Replace pack_direction with Efl.Orientation
jpeg pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=31279d2513f02588854c3720aa811be0ea83c0e4 commit 31279d2513f02588854c3720aa811be0ea83c0e4 Author: Jean-Philippe AndreDate: Fri Jun 3 15:55:29 2016 +0900 Efl.Pack: Replace pack_direction with Efl.Orientation Since I first made the pack_direction before orientation existed, the names didn't match. This should improve API consistency. --- src/bin/elementary/test_events.c | 3 +-- src/bin/elementary/test_ui_box.c | 16 src/bin/elementary/test_ui_grid.c| 20 ++-- src/lib/edje/edje_containers.c | 2 +- src/lib/edje/efl_canvas_layout_internal_box.eo | 5 +++-- src/lib/efl/interfaces/efl_pack_grid.eo | 4 ++-- src/lib/efl/interfaces/efl_pack_linear.eo| 11 --- src/lib/elementary/efl_ui_box.c | 4 ++-- src/lib/elementary/efl_ui_box.eo | 15 --- src/lib/elementary/efl_ui_grid.c | 10 +- src/lib/elementary/efl_ui_grid.eo| 19 ++- src/lib/elementary/efl_ui_layout_internal_box.eo | 5 +++-- src/lib/elementary/elm_layout_pack.c | 4 ++-- 13 files changed, 47 insertions(+), 71 deletions(-) diff --git a/src/bin/elementary/test_events.c b/src/bin/elementary/test_events.c index 5fdfd94..fadbdee 100644 --- a/src/bin/elementary/test_events.c +++ b/src/bin/elementary/test_events.c @@ -192,8 +192,7 @@ test_events(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event_in win = elm_win_util_standard_add("buttons", "Buttons"); elm_win_autodel_set(win, EINA_TRUE); - // FIXME: should be efl_orientation_set - bx = eo_add(EFL_UI_BOX_CLASS, win, efl_pack_direction_set(eo_self, EFL_ORIENT_VERTICAL)); + bx = eo_add(EFL_UI_BOX_CLASS, win, efl_orientation_set(eo_self, EFL_ORIENT_VERTICAL)); evas_object_size_hint_weight_set(bx, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); evas_object_size_hint_align_set(bx, -1, -1); efl_pack(win, bx); diff --git a/src/bin/elementary/test_ui_box.c b/src/bin/elementary/test_ui_box.c index be7f3b1..3ac8b47 100644 --- a/src/bin/elementary/test_ui_box.c +++ b/src/bin/elementary/test_ui_box.c @@ -121,7 +121,7 @@ static Eina_Bool horiz_check_cb(void *data, const Eo_Event *event) { Eina_Bool chk = elm_check_selected_get(event->object); - efl_pack_direction_set(data, chk ? EFL_ORIENT_HORIZONTAL : EFL_ORIENT_VERTICAL); + efl_orientation_set(data, chk ? EFL_ORIENT_HORIZONTAL : EFL_ORIENT_VERTICAL); return EO_CALLBACK_CONTINUE; } @@ -217,7 +217,7 @@ test_ui_box(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event_in vbox = eo_add(EFL_UI_BOX_CLASS, win); efl_pack_padding_set(vbox, 10, 10, EINA_TRUE); - efl_pack_direction_set(vbox, EFL_ORIENT_DOWN); + efl_orientation_set(vbox, EFL_ORIENT_DOWN); evas_object_size_hint_weight_set(vbox, 1, 1); evas_object_size_hint_padding_set(vbox, 5, 5, 5, 5); elm_win_resize_object_add(win, vbox); @@ -244,7 +244,7 @@ test_ui_box(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event_in /* weights radio group */ bx = eo_add(EFL_UI_BOX_CLASS, win, - efl_pack_direction_set(eo_self, EFL_ORIENT_DOWN)); + efl_orientation_set(eo_self, EFL_ORIENT_DOWN)); evas_object_size_hint_align_set(bx, 0, -1); efl_pack(hbox, bx); efl_gfx_visible_set(bx, 1); @@ -298,7 +298,7 @@ test_ui_box(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event_in /* misc */ bx = eo_add(EFL_UI_BOX_CLASS, win, - efl_pack_direction_set(eo_self, EFL_ORIENT_DOWN)); + efl_orientation_set(eo_self, EFL_ORIENT_DOWN)); evas_object_size_hint_align_set(bx, 0, -1); evas_object_size_hint_weight_set(bx, 0, 1); efl_pack(hbox, bx); @@ -361,7 +361,7 @@ test_ui_box(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event_in /* requested size setter */ bx = eo_add(EFL_UI_BOX_CLASS, win, - efl_pack_direction_set(eo_self, EFL_ORIENT_DOWN)); + efl_orientation_set(eo_self, EFL_ORIENT_DOWN)); evas_object_size_hint_align_set(bx, 0, -1); evas_object_size_hint_weight_set(bx, 0, 1); efl_pack(hbox, bx); @@ -388,7 +388,7 @@ test_ui_box(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event_in /* inner box padding */ bx = eo_add(EFL_UI_BOX_CLASS, win, - efl_pack_direction_set(eo_self, EFL_ORIENT_DOWN)); + efl_orientation_set(eo_self, EFL_ORIENT_DOWN)); evas_object_size_hint_align_set(bx, 0, -1); evas_object_size_hint_weight_set(bx, 0, 1); efl_pack(hbox, bx); @@ -415,7 +415,7 @@ test_ui_box(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event_in /* outer margin */ bx = eo_add(EFL_UI_BOX_CLASS, win, -
Re: [E-devel] promises...
On 3 June 2016 at 15:42, Carsten Haitzlerwrote: > ok. interacting with promises... > > these are just a mess. > > 1. the value thing is just odd. > 2. they are complex to set up inside our api (setting them up setting > cancel > cb's and more) > 3. they totally screw with what eo and interfaces was all about - making > the > api EASIER to use. promises make it harder. > > why harder? longer lines of code with more parameters and more special > casing... but the WORST... > > void _cb_promise(void *data, void *vaue, Eina_Promise *promise) > > that's a promise cb > > Eina_Bool _cb_event(void *data, const Eo_Event *event) > > and that's an event cb. they are different. eo events were meant to > simplify > and unify our callback handling. to have a single cb signature. now > promises > break that. this is just bad. > That's bad. Doesn't look good. > i wasn't sold on promises. i was skeptical, but whatever... but now i am > seeing > they are visibly making things worse. code is harder to write, harder to > read, > harder to maintain, harder to get right. now we have timeouts that cannot > repeat. no - creating a new timer in the cb is not repeating. it has to > repeat > with the "zero time" being the time when the timer was ticked off, not > "now". > > please - everyone. take a look at promises and how they are used. forget > all of > the "but node.js has them" and all the "i can chain promises" and so on. > the > BASIC usage of them is harder now in efl. > > what to do? well... minimize their use for one. do not use them unless you > ABSOLUTELY HAVE TO. also promises should become eo objects with event cb's > so > they work just like everything else. i can ref, unref, delete and whatever > them > like everything else. > > right now i think promises are just not in a shape to use or ship. they > need a > lot more work. i think we need to drop them for efl 1.18 and defer for efl > 2.0 > I also haven't understood the data stuff. value vs data, and which to pass where. My problem right now is I basically can not use efl_loop_timeout. p = efl_loop_timeout(evas_obj); --> p is NULL p = efl_loop_timeout(eo_provider_find(evas_obj, EFL_LOOP_CLASS)); --> p is NULL because evas_obj is not able to find the loop (not a Loop.User) p = efl_loop_timeout(ecore_main_loop_get()); --> p is valid. But I just called a non EO API. oops Now I want to cancel my previous timeout to renew it from "now": eina_promise_cancel(p); --> crash if p is NULL (2 most convenient cases above) --> crashes later if p is valid... but the timeout cb is still triggered (bug) Basically promises as they are right now are incredibly unsafe. Any misstep will crash. Last point is: ecore_timeout takes one line only to create the timeout, efl_loop_timeout takes two lines (create promise + use it). Less convenient. Best regards, -- Jean-Philippe André -- What NetFlow Analyzer can do for you? Monitors network bandwidth and traffic patterns at an interface-level. Reveals which users, apps, and protocols are consuming the most bandwidth. Provides multi-vendor support for NetFlow, J-Flow, sFlow and other flows. Make informed decisions using capacity planning reports. https://ad.doubleclick.net/ddm/clk/305295220;132659582;e ___ enlightenment-devel mailing list enlightenment-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
[EGIT] [core/efl] master 01/01: Fix legacy name of elm_win_efl_screen_dpi_get()
davemds pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=681ddb2f909d0282f0c0ec04230d8e90983a commit 681ddb2f909d0282f0c0ec04230d8e90983a Author: Dave AndreoliDate: Fri Jun 3 08:50:58 2016 +0200 Fix legacy name of elm_win_efl_screen_dpi_get() ...spank again goes to Ji-Youn Park, that insist to not even try his work --- src/lib/elementary/elm_win.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/lib/elementary/elm_win.c b/src/lib/elementary/elm_win.c index 77a4aef..9ac7243 100644 --- a/src/lib/elementary/elm_win.c +++ b/src/lib/elementary/elm_win.c @@ -6033,7 +6033,7 @@ elm_win_screen_position_get(const Evas_Object *obj, int *x, int *y) } EAPI void -elm_win_efl_screen_dpi_get(const Evas_Object *obj, int *xdpi, int *ydpi) +elm_win_screen_dpi_get(const Evas_Object *obj, int *xdpi, int *ydpi) { ELM_WIN_CHECK(obj); ELM_WIN_DATA_GET_OR_RETURN(obj, sd); --
[EGIT] [core/efl] master 01/01: elm_win: remove main_menu, window_id, fake_canvas property from eo
jypark pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=242f79a98c27cb34c00847641652277ce4f5ac48 commit 242f79a98c27cb34c00847641652277ce4f5ac48 Author: Ji-Youn ParkDate: Fri Jun 3 15:06:13 2016 +0830 elm_win: remove main_menu, window_id, fake_canvas property from eo --- src/lib/elementary/elm_win.c| 237 +++- src/lib/elementary/elm_win.eo | 27 src/lib/elementary/elm_win_legacy.h | 62 +- 3 files changed, 155 insertions(+), 171 deletions(-) diff --git a/src/lib/elementary/elm_win.c b/src/lib/elementary/elm_win.c index 0cb8574..77a4aef 100644 --- a/src/lib/elementary/elm_win.c +++ b/src/lib/elementary/elm_win.c @@ -3438,7 +3438,7 @@ elm_win_add(Evas_Object *parent, EAPI Evas_Object * elm_win_fake_add(Ecore_Evas *ee) { - return eo_add(MY_CLASS, NULL, elm_obj_win_fake_canvas_set(eo_self, ee), elm_obj_win_name_set(eo_self, NULL), elm_obj_win_type_set(eo_self, ELM_WIN_FAKE)); + return eo_add(MY_CLASS, NULL, elm_win_fake_canvas_set(eo_self, ee), elm_obj_win_name_set(eo_self, NULL), elm_obj_win_type_set(eo_self, ELM_WIN_FAKE)); } static void @@ -4173,12 +4173,6 @@ _elm_win_eo_base_constructor(Eo *obj, Elm_Win_Data *_pd EINA_UNUSED) } EOLIAN static void -_elm_win_fake_canvas_set(Eo *obj EINA_UNUSED, Elm_Win_Data *pd, Ecore_Evas *oee) -{ - pd->ee = oee; -} - -EOLIAN static void _elm_win_type_set(Eo *obj, Elm_Win_Data *sd, Elm_Win_Type type) { if (eo_finalized_get(obj)) @@ -4581,36 +4575,6 @@ _dbus_menu_set(Eina_Bool dbus_connect, void *data) } } -EOLIAN static Evas_Object * -_elm_win_main_menu_get(Eo *obj, Elm_Win_Data *sd) -{ -#ifdef HAVE_ELEMENTARY_X - Eina_Bool use_dbus = EINA_FALSE; -#endif - - if (sd->main_menu) goto end; - - sd->main_menu = elm_menu_add(obj); - _elm_menu_menu_bar_set(sd->main_menu, EINA_TRUE); - -#ifdef HAVE_ELEMENTARY_X - if (!_elm_config->disable_external_menu && sd->x.xwin) use_dbus = EINA_TRUE; -#endif - -#ifdef HAVE_ELEMENTARY_X - if (use_dbus && _elm_dbus_menu_register(sd->main_menu)) - { -_elm_dbus_menu_app_menu_register(sd->x.xwin, sd->main_menu, - _dbus_menu_set, obj); - } - else -#endif - _dbus_menu_set(EINA_FALSE, obj); - -end: - return sd->main_menu; -} - EOLIAN static void _elm_win_maximized_set(Eo *obj EINA_UNUSED, Elm_Win_Data *sd, Eina_Bool maximized) { @@ -5268,67 +5232,6 @@ elm_win_floating_mode_get(const Evas_Object *obj) return sd->floating; } -EOLIAN static Ecore_Window -_elm_win_window_id_get(Eo *obj EINA_UNUSED, Elm_Win_Data *sd) -{ - const char *engine_name = ecore_evas_engine_name_get(sd->ee); - - if ((engine_name && -((!strcmp(engine_name, ELM_WAYLAND_SHM)) || - (!strcmp(engine_name, ELM_WAYLAND_EGL) - { -#if HAVE_ELEMENTARY_WL2 -if (sd->wl.win) - return (Ecore_Window)ecore_wl2_window_id_get(sd->wl.win); -if (sd->parent) - { - Ecore_Wl2_Window *parent; - - parent = elm_win_wl_window_get(sd->parent); - if (parent) - return (Ecore_Window)ecore_wl2_window_id_get(parent); - return 0; - } -#endif - } - else if ((engine_name && - ((!strcmp(engine_name, ELM_SOFTWARE_X11)) || - (!strcmp(engine_name, ELM_OPENGL_X11) - { -#ifdef HAVE_ELEMENTARY_X -_internal_elm_win_xwindow_get(sd); -if (sd->x.xwin) return (Ecore_Window)sd->x.xwin; -if (sd->parent) return (Ecore_Window)elm_win_xwindow_get(sd->parent); -#endif - } - else if (engine_name && -((!strcmp(engine_name, ELM_OPENGL_COCOA)) || - (!strcmp(engine_name, "gl_cocoa" - { -#ifdef HAVE_ELEMENTARY_COCOA -if (sd->cocoa.win) return (Ecore_Window)(sd->cocoa.win); -if (sd->parent) - { - Ecore_Cocoa_Window *pwin; - pwin = elm_win_cocoa_window_get(sd->parent); - return (Ecore_Window)pwin; - } -#endif - } - else if ((engine_name && - ((!strcmp(engine_name, ELM_SOFTWARE_WIN32)) || - (!strcmp(engine_name, ELM_SOFTWARE_DDRAW) - { -#ifdef HAVE_ELEMENTARY_WIN32 -_internal_elm_win_win32window_get(sd); -if (sd->win32.win) return (Ecore_Window)sd->win32.win; -if (sd->parent) return (Ecore_Window)elm_win_win32_window_get(sd->parent); -#endif - } - - return 0; -} - void _elm_win_focus_highlight_in_theme_update(Evas_Object *obj, Eina_Bool in_theme) { @@ -5375,23 +5278,6 @@ _elm_win_focus_auto_hide(Evas_Object *obj) } } -EAPI Ecore_Window -elm_win_window_id_get(const Evas_Object *obj) -{ - if (!obj) return 0; - - if (!evas_object_smart_type_check_ptr(obj, MY_CLASS_NAME_LEGACY)) - { -Ecore_Evas *ee = ecore_evas_ecore_evas_get(evas_object_evas_get(obj)); -return ecore_evas_window_get(ee);
[E-devel] promises...
ok. interacting with promises... these are just a mess. 1. the value thing is just odd. 2. they are complex to set up inside our api (setting them up setting cancel cb's and more) 3. they totally screw with what eo and interfaces was all about - making the api EASIER to use. promises make it harder. why harder? longer lines of code with more parameters and more special casing... but the WORST... void _cb_promise(void *data, void *vaue, Eina_Promise *promise) that's a promise cb Eina_Bool _cb_event(void *data, const Eo_Event *event) and that's an event cb. they are different. eo events were meant to simplify and unify our callback handling. to have a single cb signature. now promises break that. this is just bad. i wasn't sold on promises. i was skeptical, but whatever... but now i am seeing they are visibly making things worse. code is harder to write, harder to read, harder to maintain, harder to get right. now we have timeouts that cannot repeat. no - creating a new timer in the cb is not repeating. it has to repeat with the "zero time" being the time when the timer was ticked off, not "now". please - everyone. take a look at promises and how they are used. forget all of the "but node.js has them" and all the "i can chain promises" and so on. the BASIC usage of them is harder now in efl. what to do? well... minimize their use for one. do not use them unless you ABSOLUTELY HAVE TO. also promises should become eo objects with event cb's so they work just like everything else. i can ref, unref, delete and whatever them like everything else. right now i think promises are just not in a shape to use or ship. they need a lot more work. i think we need to drop them for efl 1.18 and defer for efl 2.0 -- - Codito, ergo sum - "I code, therefore I am" -- The Rasterman (Carsten Haitzler)ras...@rasterman.com -- What NetFlow Analyzer can do for you? Monitors network bandwidth and traffic patterns at an interface-level. Reveals which users, apps, and protocols are consuming the most bandwidth. Provides multi-vendor support for NetFlow, J-Flow, sFlow and other flows. Make informed decisions using capacity planning reports. https://ad.doubleclick.net/ddm/clk/305295220;132659582;e ___ enlightenment-devel mailing list enlightenment-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
[EGIT] [core/efl] master 01/04: Efl.Ui.Box: Fix direction set
jpeg pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=5fd02a79cc7e0fcc934b784a747a1aca4436bc08 commit 5fd02a79cc7e0fcc934b784a747a1aca4436bc08 Author: Jean-Philippe AndreDate: Thu Jun 2 18:32:47 2016 +0900 Efl.Ui.Box: Fix direction set VERTICAL means UP but UP was ignored... --- src/lib/elementary/efl_ui_box.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/lib/elementary/efl_ui_box.c b/src/lib/elementary/efl_ui_box.c index 9f8291f..fe30fe0 100644 --- a/src/lib/elementary/efl_ui_box.c +++ b/src/lib/elementary/efl_ui_box.c @@ -567,13 +567,13 @@ _efl_ui_box_efl_pack_linear_pack_direction_set(Eo *obj, Efl_Ui_Box_Data *pd, Efl { switch (dir) { - //case EFL_ORIENT_UP: + case EFL_ORIENT_UP: case EFL_ORIENT_DOWN: pd->orient = EFL_ORIENT_DOWN; break; case EFL_ORIENT_RIGHT: -//case EFL_ORIENT_LEFT: + case EFL_ORIENT_LEFT: default: pd->orient = EFL_ORIENT_RIGHT; break; --
[EGIT] [core/efl] master 03/04: elm_win: Forward events between window and evas
jpeg pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=b147911bad2b216b23f504ad3470278418ff32d2 commit b147911bad2b216b23f504ad3470278418ff32d2 Author: Jean-Philippe AndreDate: Thu Jun 2 14:36:55 2016 +0900 elm_win: Forward events between window and evas This does: 1. Forward keyboard events from evas to win 2. Allow feeding external input events Input events can be faked by apps by simply forging eo objects of the proper type (key or pointer evt) and calling eo_event_callback_call(). Such events will be forwarded to the internal Evas, and some bool flags prevent infinite refeeding loops. efl_event_dup() returns fake events for this to work. @feature --- src/lib/ecore_evas/ecore_evas.c | 14 ++-- src/lib/efl/Efl.h| 1 + src/lib/efl/interfaces/efl_common_internal.h | 8 ++- src/lib/efl/interfaces/efl_event.eo | 7 ++ src/lib/elementary/elm_win.c | 88 ++- src/lib/evas/canvas/efl_event_input.eo | 7 ++ src/lib/evas/canvas/efl_event_key.c | 100 ++- src/lib/evas/canvas/efl_event_key.eo | 3 + src/lib/evas/canvas/efl_event_pointer.c | 32 ++--- src/lib/evas/canvas/efl_event_pointer.eo | 12 +--- src/lib/evas/canvas/evas_events.c| 5 +- 11 files changed, 231 insertions(+), 46 deletions(-) diff --git a/src/lib/ecore_evas/ecore_evas.c b/src/lib/ecore_evas/ecore_evas.c index 7f7b1dc..fb225ad 100644 --- a/src/lib/ecore_evas/ecore_evas.c +++ b/src/lib/ecore_evas/ecore_evas.c @@ -3,6 +3,7 @@ #endif #define ECORE_EVAS_INTERNAL +#define EFL_EVENT_PROTECTED #include #include @@ -4358,7 +4359,7 @@ _direct_mouse_updown(Ecore_Evas *ee, const Ecore_Event_Mouse_Button *info, Efl_P * modifiers (already passed to evas, no need to do anything) */ - evt = efl_event_pointer_instance_get(EFL_EVENT_POINTER_CLASS, e, (void **) ); + evt = efl_event_instance_get(EFL_EVENT_POINTER_CLASS, e, (void **) ); if (!evt) return EINA_FALSE; ev->action = action; @@ -4418,7 +4419,7 @@ _direct_mouse_move_cb(Ecore_Evas *ee, const Ecore_Event_Mouse_Move *info) * modifiers (already passed to evas, no need to do anything) */ - evt = efl_event_pointer_instance_get(EFL_EVENT_POINTER_CLASS, e, (void **) ); + evt = efl_event_instance_get(EFL_EVENT_POINTER_CLASS, e, (void **) ); if (!evt) return EINA_FALSE; ev->action = EFL_POINTER_ACTION_MOVE; @@ -4455,7 +4456,7 @@ _direct_mouse_wheel_cb(Ecore_Evas *ee, const Ecore_Event_Mouse_Wheel *info) * modifiers (already passed to evas, no need to do anything) */ - evt = efl_event_pointer_instance_get(EFL_EVENT_POINTER_CLASS, e, (void **) ); + evt = efl_event_instance_get(EFL_EVENT_POINTER_CLASS, e, (void **) ); if (!evt) return EINA_FALSE; ev->action = EFL_POINTER_ACTION_WHEEL; @@ -4484,7 +4485,7 @@ _direct_mouse_inout(Ecore_Evas *ee, const Ecore_Event_Mouse_IO *info, Efl_Pointe * modifiers (already passed to evas, no need to do anything) */ - evt = efl_event_pointer_instance_get(EFL_EVENT_POINTER_CLASS, e, (void **) ); + evt = efl_event_instance_get(EFL_EVENT_POINTER_CLASS, e, (void **) ); if (!evt) return EINA_FALSE; ev->action = action; @@ -4526,9 +4527,8 @@ _direct_key_updown_cb(Ecore_Evas *ee, const Ecore_Event_Key *info, Eina_Bool dow * modifiers (already passed to evas, no need to do anything) */ - evt = eo_add(EFL_EVENT_KEY_CLASS, e); - ev = eo_data_scope_get(evt, EFL_EVENT_KEY_CLASS); - if (!ev) return EINA_FALSE; + evt = efl_event_instance_get(EFL_EVENT_KEY_CLASS, e, (void **) ); + if (!evt || !ev) return EINA_FALSE; ev->timestamp = info->timestamp; ev->pressed = down; diff --git a/src/lib/efl/Efl.h b/src/lib/efl/Efl.h index 0dba0f2..cca5614 100644 --- a/src/lib/efl/Efl.h +++ b/src/lib/efl/Efl.h @@ -38,6 +38,7 @@ extern "C" { /* Add here all the required ifdef for any @protected method */ #ifdef EFL_EFL_BUILD # define EFL_PACK_LAYOUT_PROTECTED +# define EFL_EVENT_PROTECTED #endif /** diff --git a/src/lib/efl/interfaces/efl_common_internal.h b/src/lib/efl/interfaces/efl_common_internal.h index b7eb818..60adfef 100644 --- a/src/lib/efl/interfaces/efl_common_internal.h +++ b/src/lib/efl/interfaces/efl_common_internal.h @@ -50,7 +50,9 @@ struct _Efl_Event_Pointer_Data (see input vs. feed: this is "input") */ Evas_Modifier *modifiers; Evas_Lock *locks; - Eina_Bool evas_done; /* set by evas */ + Eina_Bool evas_done : 1; /* set by evas */ + Eina_Bool fake : 1; + Eina_Bool win_fed : 1; }; struct _Efl_Event_Key_Data @@ -70,7 +72,9 @@ struct _Efl_Event_Key_Data Evas_Lock
[EGIT] [core/efl] master 02/04: elm: Partially revert "elementary: avoid random memory access."
jpeg pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=a4701ea9696d3e6aab9d5b14895cee903ea5f048 commit a4701ea9696d3e6aab9d5b14895cee903ea5f048 Author: Jean-Philippe AndreDate: Fri Jun 3 12:01:35 2016 +0900 elm: Partially revert "elementary: avoid random memory access." This reverts commit ac5a0b7e79d6b32285bd7b794f050826f38cc7c2. I added assert(pd == sd) in the modified code and couldn't find anything suspicious. The proper class is used in eo_data_scope_get(). I also can't find a crash or a bug currently in hover. I know there was a problem earlier, but that was fixed in 3092e08a83f754ba8d49c. Now, if there is still a problem, we should check it carefully. Pinging @cedric --- src/lib/elementary/elm_dayselector.c | 3 +-- src/lib/elementary/elm_hover.c | 3 +-- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/src/lib/elementary/elm_dayselector.c b/src/lib/elementary/elm_dayselector.c index a65ca94..bc03214 100644 --- a/src/lib/elementary/elm_dayselector.c +++ b/src/lib/elementary/elm_dayselector.c @@ -220,10 +220,9 @@ _item_find(const Evas_Object *obj, } static Eina_Bool -_elm_dayselector_content_set(Eo *obj, Elm_Dayselector_Data *pd, const char *item, Evas_Object *content) +_elm_dayselector_content_set(Eo *obj, Elm_Dayselector_Data *sd, const char *item, Evas_Object *content) { Eina_Bool int_ret = EINA_FALSE; - Elm_Dayselector_Data *sd = eo_data_scope_get(obj, MY_CLASS); int day; char buf[1024]; diff --git a/src/lib/elementary/elm_hover.c b/src/lib/elementary/elm_hover.c index 5d05458..5246986 100644 --- a/src/lib/elementary/elm_hover.c +++ b/src/lib/elementary/elm_hover.c @@ -400,10 +400,9 @@ _elm_hover_subs_del(Elm_Hover_Data *sd) } static Eina_Bool -_elm_hover_content_set(Eo *obj, Elm_Hover_Data *pd, const char *swallow, Evas_Object *content) +_elm_hover_content_set(Eo *obj, Elm_Hover_Data *sd, const char *swallow, Evas_Object *content) { Eina_Bool int_ret; - Elm_Hover_Data *sd = eo_data_scope_get(obj, MY_CLASS); if (!swallow) return EINA_FALSE; --
[EGIT] [core/efl] master 04/04: elm_test: Add test case for event refeed
jpeg pushed a commit to branch master. http://git.enlightenment.org/core/efl.git/commit/?id=57b279cd569799e5d6c30567e5afdf3a40441954 commit 57b279cd569799e5d6c30567e5afdf3a40441954 Author: Jean-Philippe AndreDate: Fri Jun 3 11:56:57 2016 +0900 elm_test: Add test case for event refeed Not sure if this test case is really good, but it was necessary to prove that input event refeed can work from application side. This is a feature that should work but shouldn't be used :) --- src/Makefile_Elementary.am | 1 + src/bin/elementary/test.c| 4 + src/bin/elementary/test_events.c | 240 +++ 3 files changed, 245 insertions(+) diff --git a/src/Makefile_Elementary.am b/src/Makefile_Elementary.am index 829cb8a..9685694 100644 --- a/src/Makefile_Elementary.am +++ b/src/Makefile_Elementary.am @@ -749,6 +749,7 @@ bin/elementary/test_entry.c \ bin/elementary/test_entry_anchor.c \ bin/elementary/test_entry_anchor2.c \ bin/elementary/test_external.c \ +bin/elementary/test_events.c \ bin/elementary/test_fileselector_button.c \ bin/elementary/test_fileselector.c \ bin/elementary/test_fileselector_entry.c \ diff --git a/src/bin/elementary/test.c b/src/bin/elementary/test.c index fff22fe..02d48c9 100644 --- a/src/bin/elementary/test.c +++ b/src/bin/elementary/test.c @@ -29,6 +29,7 @@ void test_box_align(void *data, Evas_Object *obj, void *event_info); void test_ui_box(void *data, Evas_Object *obj, void *event_info); void test_button(void *data, Evas_Object *obj, void *event_info); void test_cnp(void *data, Evas_Object *obj, void *event_info); +void test_events(void *data, Evas_Object *obj, void *event_info); void test_transit(void *data, Evas_Object *obj, void *event_info); void test_transit_blend(void *data, Evas_Object *obj, void *event_info); void test_transit_chain(void *data, Evas_Object *obj, void *event_info); @@ -600,6 +601,9 @@ add_tests: ADD_TEST(NULL, "New Containers", "Ui.Grid Linear", test_ui_grid_linear); //--// + ADD_TEST(NULL, "New Events", "Event Refeed", test_events); + + //--// ADD_TEST(NULL, "Entries", "Entry", test_entry); ADD_TEST(NULL, "Entries", "Entry Style Default", test_entry_style_default); ADD_TEST(NULL, "Entries", "Entry Style User", test_entry_style_user); diff --git a/src/bin/elementary/test_events.c b/src/bin/elementary/test_events.c new file mode 100644 index 000..5fdfd94 --- /dev/null +++ b/src/bin/elementary/test_events.c @@ -0,0 +1,240 @@ +#ifdef HAVE_CONFIG_H +# include "elementary_config.h" +#endif +#include + +#define EFL_INTERNAL_UNSTABLE +#include "interfaces/efl_common_internal.h" + +#define DEFAULT_TEXT "Click the white rectangle to get started" + +typedef struct { + int down; + Eo *evdown, *evup, *evmove, *evkeydown, *evkeyup; + Eo *win, *button, *text; + int id; + Eina_Promise *p; + Eo *timer; +} testdata; + +static Eina_Bool +_pointer_down(void *data, const Eo_Event *ev) +{ + testdata *td = data; + td->down = 1; + eo_del(td->evdown); + td->evdown = efl_event_dup(ev->info); + return 1; +} + +static Eina_Bool +_pointer_move(void *data, const Eo_Event *ev) +{ + testdata *td = data; + eo_del(td->evmove); + td->evmove = efl_event_dup(ev->info); + return 1; +} + +static Eina_Bool +_pointer_up(void *data, const Eo_Event *ev) +{ + testdata *td = data; + td->down = 0; + eo_del(td->evup); + td->evup = efl_event_dup(ev->info); + return 1; +} + +static Eina_Bool +_key_down(void *data, const Eo_Event *ev) +{ + testdata *td = data; + char str[1024]; + + // FIXME: By default the elm_win object is the focussed object + // this means that evas callbacks will transfer the KEY_UP/KEY_DOWN events + // to the elm_win. So, we get two key_down & two key_up events: + // 1. ecore_evas -> evas -> elm_win forward -> here + // 2. ecore_evas -> evas -> focussed obj (elm_win) -> here + + sprintf(str, "key=%s keyname=%s string=%s compose=%s", + efl_event_key_get(ev->info), + efl_event_key_name_get(ev->info), + efl_event_key_string_get(ev->info), + efl_event_key_compose_get(ev->info)); + elm_object_text_set(td->text, str); + + eo_del(td->evkeydown); + td->evkeydown = efl_event_dup(ev->info); + + return 1; +} + +#if 0 +static void +_timeout_cb(void *data, void *value EINA_UNUSED, Eina_Promise *promise EINA_UNUSED) +{ + testdata *td = data; + elm_object_text_set(td->text, NULL); + td->p = NULL; +} +#else +static Eina_Bool +_ecore_timeout_cb(void *data) +{ + testdata *td = data; + + elm_object_text_set(td->text, DEFAULT_TEXT); + td->timer = NULL; + + return ECORE_CALLBACK_CANCEL; +} + +#endif + +static Eina_Bool +_key_up(void *data, const Eo_Event *ev) +{ + testdata *td = data; + + eo_del(td->evkeyup); + td->evkeyup = efl_event_dup(ev->info); + + // FIXME: how to use efl_loop_timeout? +