cedric pushed a commit to branch master.

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

commit 4a434a94aa339fbde420906dcd8af073303f7143
Author: Cedric BAIL <ced...@osg.samsung.com>
Date:   Tue Nov 1 11:36:10 2016 -0700

    elementary: not every call are from ecore_job infrastructure, NULL only 
when they are.
    
    This is something that our tests suite detected. Please pay attention.
---
 src/lib/elementary/els_cursor.c | 17 ++++++++++++-----
 1 file changed, 12 insertions(+), 5 deletions(-)

diff --git a/src/lib/elementary/els_cursor.c b/src/lib/elementary/els_cursor.c
index 3037e41..6c007c7 100644
--- a/src/lib/elementary/els_cursor.c
+++ b/src/lib/elementary/els_cursor.c
@@ -197,15 +197,12 @@ _elm_cursor_obj_del(void *data, Evas *evas EINA_UNUSED, 
Evas_Object *obj EINA_UN
 }
 
 static void
-_elm_cursor_set_hot_spots(void *data)
+_elm_cursor_set_hot_spots(Elm_Cursor *cur)
 {
-   Elm_Cursor *cur = data;
    const char *str;
    Evas_Coord cx, cy, cw, ch, x, y, w, h;
    int prev_hot_x, prev_hot_y;
 
-   cur->hotupdate_job = NULL;
-
    prev_hot_x = cur->hot_x;
    prev_hot_y = cur->hot_y;
 
@@ -229,11 +226,21 @@ _elm_cursor_set_hot_spots(void *data)
 }
 
 static void
+_elm_cursor_set_hot_spots_job(void *data)
+{
+   Elm_Cursor *cur = data;
+
+   cur->hotupdate_job = NULL;
+
+   _elm_cursor_set_hot_spots(cur);
+}
+
+static void
 _elm_cursor_hot_change(void *data, Evas *evas EINA_UNUSED, Evas_Object *obj 
EINA_UNUSED, void *event_info EINA_UNUSED)
 {
    Elm_Cursor *cur = data;
    if (cur->hotupdate_job) ecore_job_del(cur->hotupdate_job);
-   cur->hotupdate_job = ecore_job_add(_elm_cursor_set_hot_spots, data);
+   cur->hotupdate_job = ecore_job_add(_elm_cursor_set_hot_spots_job, data);
 }
 
 static Eina_Bool

-- 


Reply via email to