netstar pushed a commit to branch master.

http://git.enlightenment.org/apps/evisum.git/commit/?id=68c56667bcb3d4c3cf3da42283156d022c5800c7

commit 68c56667bcb3d4c3cf3da42283156d022c5800c7
Author: Alastair Poole <nets...@gmail.com>
Date:   Sat Apr 18 02:35:02 2020 +0100

    ui: item cache size init
---
 src/bin/ui.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/src/bin/ui.c b/src/bin/ui.c
index 28b9cb7..35ac1fb 100644
--- a/src/bin/ui.c
+++ b/src/bin/ui.c
@@ -17,6 +17,8 @@ static Eina_Lock _lock;
 static Eina_List *_list = NULL;
 static Evisum_Config *_evisum_config = NULL;
 
+#define ITEM_CACHE_INIT_SIZE 50
+
 typedef struct _Item_Cache {
    Evas_Object *obj;
    Eina_Bool   used;
@@ -1027,7 +1029,7 @@ _item_create(Evas_Object *parent)
 static void
 _item_cache_init(Ui *ui)
 {
-   for (int i = 0; i < 100; i++)
+   for (int i = 0; i < ITEM_CACHE_INIT_SIZE; i++)
      {
         Item_Cache *it = calloc(1, sizeof(Item_Cache));
         it->obj = _item_create(ui->genlist_procs);

-- 


Reply via email to