cedric pushed a commit to branch master.

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

commit cc801e2e2aa625d282e60073eba17faa750e1f3c
Author: Cedric BAIL <[email protected]>
Date:   Thu Nov 22 16:45:17 2018 -0800

    elementary: simplify code by using proper helper.
    
    efl_loop_promise_new is a helper function that does automatically figure 
out an
    available scheduler and create a promise from it. Basically replacing the 
call to
    eina_promise_new(efl_loop_future_scheduler_get(o), ...).
    
    Reviewed-by: Xavi Artigas <[email protected]>
    Reviewed-by: Vitor Sousa da Silva <[email protected]>
    Differential Revision: https://phab.enlightenment.org/D7336
---
 src/lib/elementary/efl_selection_manager.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/src/lib/elementary/efl_selection_manager.c 
b/src/lib/elementary/efl_selection_manager.c
index fc0c503c79..42d66a9918 100644
--- a/src/lib/elementary/efl_selection_manager.c
+++ b/src/lib/elementary/efl_selection_manager.c
@@ -247,8 +247,7 @@ _update_sel_lost_list(Efl_Object *obj, Efl_Selection_Type 
type,
    sel_lost->seat_sel = seat_sel;
    seat_sel->sel_lost_list = eina_list_append(seat_sel->sel_lost_list, 
sel_lost);
 
-   p = eina_promise_new(efl_loop_future_scheduler_get(obj),
-                        _sel_manager_promise_cancel, NULL);
+   p = efl_loop_promise_new(obj, _sel_manager_promise_cancel, NULL);
    eina_promise_data_set(p, sel_lost);
    if (!p) return NULL;
    sel_lost->promise = p;

-- 


Reply via email to