Track whether objects are on the post_updates list or not 82/66782/2
authorDerek Foreman <derekf@osg.samsung.com>
Fri, 19 Feb 2016 17:50:16 +0000 (11:50 -0600)
committerDoyoun Kang <doyoun.kang@samsung.com>
Mon, 25 Apr 2016 01:10:11 +0000 (18:10 -0700)
Will use this to prevent accidentally adding objects to the list twice

Change-Id: Ic1aedde9e89fc2044938e9a4a08a3624b07d4d08

src/bin/e_client.h
src/bin/e_comp_canvas.c
src/bin/e_comp_object.c

index 1a9e69bba8caf4267af4fe9fb4fa4e6404470879..d1ed8166d7c8113ac1be73c0abb2d8a6d0f8d8db 100644 (file)
@@ -810,6 +810,7 @@ struct E_Client
    Eina_Bool keyboard_resizing : 1;
    Eina_Bool gesture_disable : 1;
 
+   Eina_Bool on_post_updates : 1; // client is on the post update list
 #ifdef HAVE_WAYLAND
    uuid_t uuid;
 #endif
index c89999c85b85ba54927de7ac65598803ed410cb8..1711b0c32ed3c56b29f63204d6d274be13aa98e7 100644 (file)
@@ -53,6 +53,7 @@ _e_comp_canvas_render_post(void *data EINA_UNUSED, Evas *e EINA_UNUSED, void *ev
    EINA_LIST_FREE(e_comp->post_updates, ec)
      {
         //INF("POST %p", ec);
+        ec->on_post_updates = EINA_FALSE;
         if (!e_object_is_del(E_OBJECT(ec)))
           e_pixmap_image_clear(ec->pixmap, 1);
         UNREFD(ec, 111);
index bea5f3d1f1535730cea20aa52fdb74e48c19cd4a..a58dbd218a965edf66f4c3a05e6b0ef662298a86 100644 (file)
@@ -944,6 +944,7 @@ _e_comp_object_pixels_get(void *data, Evas_Object *obj EINA_UNUSED)
    if (cw->native)
      {
         E_FREE_FUNC(cw->pending_updates, eina_tiler_free);
+        cw->ec->on_post_updates = EINA_TRUE;
         e_comp->post_updates = eina_list_append(e_comp->post_updates, cw->ec);
         REFD(cw->ec, 111);
         e_object_ref(E_OBJECT(cw->ec));
@@ -3827,6 +3828,7 @@ end:
    E_FREE_FUNC(cw->pending_updates, eina_tiler_free);
    if (ret)
      {
+        cw->ec->on_post_updates = EINA_TRUE;
         e_comp->post_updates = eina_list_append(e_comp->post_updates, cw->ec);
         REFD(cw->ec, 111);
         e_object_ref(E_OBJECT(cw->ec));