eina: fix Eina_Inarray API to at least match Eina_Array API.
authorcedric <cedric@7cbeb6ba-43b4-40fd-8cce-4c39aea84d33>
Fri, 20 Apr 2012 08:30:59 +0000 (08:30 +0000)
committercedric <cedric@7cbeb6ba-43b4-40fd-8cce-4c39aea84d33>
Fri, 20 Apr 2012 08:30:59 +0000 (08:30 +0000)
NOTE: some of this function should be moved as inline, but that's to late for a change
I think. So we will fix that if needed.

Second point, I am not happy with is eina_inarray_insert and eina_inarray_insert_at. The
naming is really poor.

git-svn-id: svn+ssh://svn.enlightenment.org/var/svn/e/trunk/evas@70352 7cbeb6ba-43b4-40fd-8cce-4c39aea84d33

src/modules/engines/buffer/evas_engine.c

index 758ef10..371c783 100644 (file)
@@ -119,7 +119,7 @@ _output_setup(int w,
      }
    re->tb = evas_common_tilebuf_new(w, h);
    evas_common_tilebuf_set_tile_size(re->tb, TILESIZE, TILESIZE);
-   eina_inarray_setup(&re->previous_rects, sizeof (Eina_Rectangle), 8);
+   eina_inarray_step_set(&re->previous_rects, sizeof (Eina_Inarray), sizeof (Eina_Rectangle), 8);
    return re;
 }
 
@@ -312,7 +312,7 @@ eng_output_redraws_next_update_get(void *data, int *x, int *y, int *w, int *h, i
                   Eina_Rectangle local;
 
                   EINA_RECTANGLE_SET(&local, rect->x, rect->y, rect->w, rect->h);
-                  eina_inarray_append(&re->previous_rects, &local);
+                  eina_inarray_push(&re->previous_rects, &local);
                }
 
              /* and regenerate the damage list by tacking into account the damage over two frames */