Evas filters: Quick check for existing part name
authorJean-Philippe Andre <jp.andre@samsung.com>
Wed, 5 Feb 2014 11:35:44 +0000 (20:35 +0900)
committerJean-Philippe Andre <jp.andre@samsung.com>
Fri, 7 Feb 2014 08:33:18 +0000 (17:33 +0900)
We just add all buffer source names to the part lookup queue,
so that edje_cc will check that the source part exists.

The final int key is discarded.

src/bin/edje/edje_cc_handlers.c

index f3b706b..eaa88bc 100644 (file)
@@ -7318,6 +7318,9 @@ st_collections_group_parts_part_description_text_filter(void)
    Eina_Stringshare *name;
    char *token, *code;
    Eina_Bool valid = EINA_TRUE;
+   Edje_Part_Collection *pc;
+
+   static int part_key = 0;
 
    static const char *allowed_name_chars =
          "abcdefghijklmnopqrstuvwxyzABCDEFGHJIKLMNOPQRSTUVWXYZ0123456789_";
@@ -7337,6 +7340,8 @@ st_collections_group_parts_part_description_text_filter(void)
    ed->text.filter.str = parse_str(0);
    if (!ed->text.filter.str) return;
 
+   pc = eina_list_data_get(eina_list_last(edje_collections));
+
    // Parse list of buffers that have a source
    // note: does not support comments
    code = strdup(ed->text.filter.str);
@@ -7383,6 +7388,7 @@ st_collections_group_parts_part_description_text_filter(void)
              name = eina_stringshare_add(token);
 
              sources = eina_list_append(sources, name);
+             data_queue_part_lookup(pc, name, &part_key);
           }
      }
    free(code);