* edje: new file format.

WARNING ! WARNING ! WARNING ! WARNING !
	Old file format is not readable by edje directly. If you have old edje
	file that you want to convert, use edje_convert. Their is no way back.

	Recompile your file as soon as possible. Please report any issue you
	spot as this is a huge and needed change.



SVN revision: 50936
devs/devilhorns/wayland_egl
Cedric BAIL 13 years ago
parent 4ce36d937e
commit 9ecc1354c6
  1. 1
      legacy/edje/configure.ac
  2. 13
      legacy/edje/src/bin/Makefile.am
  3. 4
      legacy/edje/src/bin/edje_cc.h
  4. 2
      legacy/edje/src/bin/edje_cc_handlers.c
  5. 100
      legacy/edje/src/bin/edje_cc_out.c
  6. 455
      legacy/edje/src/bin/edje_convert.c
  7. 152
      legacy/edje/src/bin/edje_convert.h
  8. 445
      legacy/edje/src/bin/edje_data_convert.c
  9. 9
      legacy/edje/src/bin/edje_decc.c
  10. 3
      legacy/edje/src/lib/Makefile.am
  11. 23
      legacy/edje/src/lib/edje_cache.c
  12. 8
      legacy/edje/src/lib/edje_calc.c
  13. 624
      legacy/edje/src/lib/edje_data.c
  14. 314
      legacy/edje/src/lib/edje_edit.c
  15. 37
      legacy/edje/src/lib/edje_load.c
  16. 26
      legacy/edje/src/lib/edje_private.h
  17. 8
      legacy/edje/src/lib/edje_text.c
  18. 2
      legacy/edje/src/lib/edje_textblock_styles.c
  19. 6
      legacy/edje/src/lib/edje_util.c

@ -91,6 +91,7 @@ EFL_ENABLE_BIN([edje-cc])
EFL_ENABLE_BIN([edje-decc])
EFL_ENABLE_BIN([edje-recc])
EFL_ENABLE_BIN([edje-player])
EFL_ENABLE_BIN([edje-convert])
# Optional EDJE_PROGRAM_CACHE (use much more ram, but increase speed in some cases)
want_edje_program_cache="no"

@ -15,9 +15,9 @@ AM_CPPFLAGS = \
bin_SCRIPTS = @EDJE_RECC_PRG@
bin_PROGRAMS = @EDJE_CC_PRG@ @EDJE_DECC_PRG@ @EDJE_PLAYER_PRG@
bin_PROGRAMS = @EDJE_CC_PRG@ @EDJE_DECC_PRG@ @EDJE_PLAYER_PRG@ @EDJE_CONVERT_PRG@
EXTRA_PROGRAMS = edje_cc edje_decc edje_player
EXTRA_PROGRAMS = edje_cc edje_decc edje_player edje_convert
edje_cc_SOURCES = \
edje_cc.c \
@ -26,7 +26,8 @@ edje_cc_parse.c \
edje_cc_mem.c \
edje_cc_handlers.c \
edje_cc_sources.c \
edje_prefix.c
edje_prefix.c \
edje_convert.c
edje_cc_LDADD = $(top_builddir)/src/lib/libedje.la $(ECORE_EVAS_LIBS) $(EVIL_LIBS)
edje_cc_LDFLAGS = @lt_enable_auto_import@
@ -45,5 +46,9 @@ edje_player_SOURCES = edje_player.c
edje_player_LDADD = $(top_builddir)/src/lib/libedje.la $(ECORE_EVAS_LIBS) $(EVIL_LIBS)
edje_player_LDFLAGS = @lt_enable_auto_import@
EXTRA_DIST = @EDJE_RECC_PRG@ edje_prefix.h edje_cc.h
edje_convert_SOURCES = edje_convert.c edje_convert_main.c edje_data_convert.c
edje_convert_LDADD = $(top_builddir)/src/lib/libedje.la $(EVIL_LIBS)
edje_convert_LDFLAGS = @lt_enable_auto_import@
EXTRA_DIST = @EDJE_RECC_PRG@ edje_prefix.h edje_cc.h edje_convert.h
EXTRA_SCRIPTS = edje_recc

@ -3,6 +3,8 @@
#include <edje_private.h>
#include "edje_convert.h"
/*
* On Windows, if the file is not opened in binary mode,
* read does not return the correct size, because of
@ -149,6 +151,8 @@ void *mem_alloc(size_t size);
char *mem_strdup(const char *s);
#define SZ sizeof
void error_and_abort(Eet_File *ef, const char *fmt, ...);
/* global vars */
extern Eina_List *ext_dirs;
extern Eina_List *img_dirs;

@ -1557,7 +1557,7 @@ static void
ob_collections(void)
{
if (!edje_file->collection_dir)
edje_file->collection_dir = mem_alloc(SZ(Edje_Part_Collection_Directory));
edje_file->collection_dir = mem_alloc(SZ(Old_Edje_Part_Collection_Directory));
}
/**

@ -28,6 +28,7 @@ void *alloca (size_t);
#include "edje_cc.h"
#include "edje_prefix.h"
#include "edje_convert.h"
#include <lua.h>
#include <lauxlib.h>
@ -95,6 +96,7 @@ struct _Code_Lookup
static void data_process_string(Old_Edje_Part_Collection *pc, const char *prefix, char *s, void (*func)(Old_Edje_Part_Collection *pc, char *name, char *ptr, int len));
Old_Edje_File *edje_file = NULL;
Edje_File *new_edje_file = NULL;
Eina_List *edje_collections = NULL;
Eina_List *externals = NULL;
Eina_List *fonts = NULL;
@ -103,16 +105,7 @@ Eina_List *code_lookups = NULL;
Eina_List *aliases = NULL;
static Eet_Data_Descriptor *edd_edje_file = NULL;
static Eet_Data_Descriptor *edd_edje_image_directory = NULL;
static Eet_Data_Descriptor *edd_edje_image_directory_entry = NULL;
static Eet_Data_Descriptor *edd_edje_program = NULL;
static Eet_Data_Descriptor *edd_edje_program_target = NULL;
static Eet_Data_Descriptor *edd_edje_part_collection_directory = NULL;
static Eet_Data_Descriptor *edd_edje_part_collection_directory_entry = NULL;
static Eet_Data_Descriptor *edd_edje_part_collection = NULL;
static Eet_Data_Descriptor *edd_edje_part = NULL;
static Eet_Data_Descriptor *edd_edje_part_description = NULL;
static Eet_Data_Descriptor *edd_edje_part_image_id = NULL;
static Eina_List *part_lookups = NULL;
static Eina_List *program_lookups = NULL;
@ -126,7 +119,7 @@ static Eina_List *image_slave_lookups= NULL;
unlink(file); \
exit(-1);
static void
void
error_and_abort(Eet_File *ef, const char *fmt, ...)
{
va_list ap;
@ -143,16 +136,7 @@ void
data_setup(void)
{
edd_edje_file = _edje_edd_edje_file;
edd_edje_image_directory = _edje_edd_edje_image_directory;
edd_edje_image_directory_entry = _edje_edd_edje_image_directory_entry;
edd_edje_program = _edje_edd_edje_program;
edd_edje_program_target = _edje_edd_edje_program_target;
edd_edje_part_collection_directory = _edje_edd_edje_part_collection_directory;
edd_edje_part_collection_directory_entry = _edje_edd_edje_part_collection_directory_entry;
edd_edje_part_collection = _edje_edd_edje_part_collection;
edd_edje_part = _edje_edd_edje_part;
edd_edje_part_description = _edje_edd_edje_part_description;
edd_edje_part_image_id = _edje_edd_edje_part_image_id;
}
static void
@ -244,19 +228,21 @@ data_write_header(Eet_File *ef)
{
int bytes = 0;
if (edje_file)
if (new_edje_file)
{
if (edje_file->collection_dir)
if (new_edje_file->collection)
{
Edje_Part_Collection_Directory_Entry *ce;
/* copy aliases into collection directory */
while (aliases)
EINA_LIST_FREE(aliases, ce)
{
edje_file->collection_dir->entries = eina_list_append(edje_file->collection_dir->entries, eina_list_data_get(aliases));
aliases = eina_list_remove_list(aliases, aliases);
if (!ce->entry)
error_and_abort(ef, "Collection %i: name missing.\n", ce->id);
eina_hash_direct_add(new_edje_file->collection, ce->entry, ce);
}
}
bytes = eet_data_write(ef, edd_edje_file, "edje_file", edje_file, 1);
bytes = eet_data_write(ef, edd_edje_file, "edje/file", new_edje_file, 1);
if (bytes <= 0)
error_and_abort(ef, "Unable to write \"edje_file\" entry to \"%s\" \n",
file_out);
@ -343,7 +329,7 @@ data_write_fonts(Eet_File *ef, int *font_num, int *input_bytes, int *input_raw_b
{
char buf[4096];
snprintf(buf, sizeof(buf), "fonts/%s", fn->name);
snprintf(buf, sizeof(buf), "edje/fonts/%s", fn->name);
bytes = eet_write(ef, buf, fdata, fsize, 1);
if (bytes <= 0)
error_and_abort(ef, "Unable to write font part \"%s\" as \"%s\" "
@ -453,11 +439,11 @@ error_and_abort_image_load_error(Eet_File *ef, const char *file, int error)
static int
data_write_images(Eet_File *ef, int *image_num, int *input_bytes, int *input_raw_bytes)
{
Eina_List *l;
unsigned int i;
int bytes = 0;
int total_bytes = 0;
if ((edje_file) && (edje_file->image_dir))
if ((new_edje_file) && (new_edje_file->image_dir))
{
Ecore_Evas *ee;
Evas *evas;
@ -472,8 +458,10 @@ data_write_images(Eet_File *ef, int *image_num, int *input_bytes, int *input_raw
"load.\n");
evas = ecore_evas_get(ee);
EINA_LIST_FOREACH(edje_file->image_dir->entries, l, img)
for (i = 0; i < new_edje_file->image_dir->entries_count; i++)
{
img = &new_edje_file->image_dir->entries[i];
if (img->source_type == EDJE_IMAGE_SOURCE_TYPE_EXTERNAL)
{
}
@ -532,7 +520,7 @@ data_write_images(Eet_File *ef, int *image_num, int *input_bytes, int *input_raw
{
int mode, qual;
snprintf(buf, sizeof(buf), "images/%i", img->id);
snprintf(buf, sizeof(buf), "edje/images/%i", img->id);
qual = 80;
if ((img->source_type == EDJE_IMAGE_SOURCE_TYPE_INLINE_PERFECT) &&
(img->source_param == 0))
@ -626,21 +614,6 @@ data_write_images(Eet_File *ef, int *image_num, int *input_bytes, int *input_raw
return total_bytes;
}
static void
check_groups_names(Eet_File *ef)
{
Eina_List *l;
Edje_Part_Collection_Directory_Entry *de;
if (!edje_file->collection_dir)
return;
/* check that all groups have names */
EINA_LIST_FOREACH(edje_file->collection_dir->entries, l, de)
if (!de->entry)
error_and_abort(ef, "Collection %i: name missing.\n", de->id);
}
static void
check_groups(Eet_File *ef)
{
@ -665,7 +638,7 @@ static int
data_write_groups(Eet_File *ef, int *collection_num)
{
Eina_List *l;
Old_Edje_Part_Collection *pc;
Edje_Part_Collection *pc;
int bytes = 0;
int total_bytes = 0;
@ -673,7 +646,7 @@ data_write_groups(Eet_File *ef, int *collection_num)
{
char buf[4096];
snprintf(buf, sizeof(buf), "collections/%i", pc->id);
snprintf(buf, sizeof(buf), "edje/collections/%i", pc->id);
bytes = eet_data_write(ef, edd_edje_part_collection, buf, pc, 1);
if (bytes <= 0)
error_and_abort(ef, "Error. Unable to write \"%s\" part entry "
@ -806,7 +779,7 @@ compile_script_file(Eet_File *ef, const char *source, const char *output,
error_and_abort(ef, "Unable to read all of script object "
"\"%s\"\n", output);
snprintf(buf, sizeof(buf), "scripts/%i", script_num);
snprintf(buf, sizeof(buf), "edje/scripts/embryo/compiled/%i", script_num);
eet_write(ef, buf, data, size, 1);
free(data);
}
@ -1005,7 +978,7 @@ data_write_lua_scripts(Eet_File *ef)
printf("lua call error: %s\n", lua_tostring (L, -1));
*/
snprintf(buf, sizeof(buf), "lua_scripts/%i", i);
snprintf(buf, sizeof(buf), "edje/scripts/lua/%i", i);
eet_write(ef, buf, data.buf, data.size, 1);
#ifdef LUA_BINARY
free(data.buf);
@ -1018,6 +991,10 @@ void
data_write(void)
{
Eet_File *ef;
Edje_Part_Collection_Directory_Entry *ce;
Old_Edje_Part_Collection *pc;
Eina_Iterator *it;
Eina_List *tmp = NULL;
int input_bytes = 0;
int total_bytes = 0;
int src_bytes = 0;
@ -1035,15 +1012,32 @@ data_write(void)
exit(-1);
}
check_groups(ef);
new_edje_file = _edje_file_convert(ef, edje_file);
_edje_file_set(new_edje_file);
/* convert old structure to new one */
it = eina_hash_iterator_data_new(new_edje_file->collection);
EINA_ITERATOR_FOREACH(it, ce)
{
pc = eina_list_nth(edje_collections, ce->id);
tmp = eina_list_append(tmp,
_edje_collection_convert(ef,
ce, pc));
}
eina_iterator_free(it);
edje_collections = eina_list_free(edje_collections);
edje_collections = tmp;
total_bytes += data_write_header(ef);
total_bytes += data_write_fonts(ef, &font_num, &input_bytes,
&input_raw_bytes);
total_bytes += data_write_images(ef, &image_num, &input_bytes,
&input_raw_bytes);
check_groups_names(ef);
check_groups(ef);
total_bytes += data_write_groups(ef, &collection_num);
data_write_scripts(ef);
data_write_lua_scripts(ef);

@ -0,0 +1,455 @@
#include "edje_private.h"
#include "edje_cc.h"
#include "edje_prefix.h"
static const Edje_File *_current_edje_file = NULL;
const Edje_File *
_edje_file_get(void)
{
return _current_edje_file;
}
void
_edje_file_set(const Edje_File *edf)
{
_current_edje_file = edf;
}
static Eina_Bool
_edje_file_convert_external(Edje_File *edf, Old_Edje_File *oedf)
{
Edje_External_Directory_Entry *ede;
unsigned int max;
unsigned int i = 0;
edf->external_dir = calloc(1, sizeof (Edje_External_Directory));
if (!edf->external_dir) return EINA_FALSE;
if (!oedf->external_dir) return EINA_TRUE;
max = eina_list_count(oedf->external_dir->entries);
edf->external_dir->entries = calloc(1, sizeof (Edje_External_Directory_Entry) * max);
edf->external_dir->entries_count = max;
if (!edf->external_dir->entries && max)
return EINA_FALSE;
EINA_LIST_FREE(oedf->external_dir->entries, ede)
{
edf->external_dir->entries[i++].entry = ede->entry;
free(ede);
}
free(oedf->external_dir);
oedf->external_dir = NULL;
return EINA_TRUE;
}
static Eina_Bool
_edje_file_convert_images(Edje_File *edf, Old_Edje_File *oedf)
{
Edje_Image_Directory_Entry *de;
Edje_Image_Directory_Set *ds;
Eina_List *l;
int max;
edf->image_dir = calloc(1, sizeof (Edje_Image_Directory));
if (!edf->image_dir) return EINA_FALSE;
if (!oedf->image_dir) return EINA_TRUE;
max = -1;
EINA_LIST_FOREACH(oedf->image_dir->entries, l, de)
if (max < de->id)
max = de->id;
edf->image_dir->entries = calloc(1, sizeof (Edje_Image_Directory_Entry) * (max + 1));
edf->image_dir->entries_count = max + 1;
if (!edf->image_dir->entries && edf->image_dir->entries_count)
return EINA_FALSE;
EINA_LIST_FREE(oedf->image_dir->entries, de)
{
memcpy(edf->image_dir->entries + de->id,
de,
sizeof (Edje_Image_Directory_Entry));
free(de);
}
max = -1;
EINA_LIST_FOREACH(oedf->image_dir->sets, l, ds)
if (max < ds->id)
max = ds->id;
edf->image_dir->sets = calloc(1, sizeof (Edje_Image_Directory_Set) * (max + 1));
edf->image_dir->sets_count = max + 1;
if (!edf->image_dir->sets && edf->image_dir->sets_count)
{
free(edf->image_dir->entries);
edf->image_dir->entries = NULL;
return EINA_FALSE;
}
EINA_LIST_FREE(oedf->image_dir->sets, ds)
{
memcpy(edf->image_dir->sets + ds->id,
ds,
sizeof (Edje_Image_Directory_Set));
free(ds);
}
return EINA_TRUE;
}
Edje_File *
_edje_file_convert(Eet_File *ef, Old_Edje_File *oedf)
{
Edje_Part_Collection_Directory_Entry *ce;
Edje_Font_Directory_Entry *fnt;
Edje_File *edf;
Eina_List *l;
Edje_Data *ed;
if (oedf->version != 2) return NULL;
edf = calloc(1, sizeof (Edje_File));
if (!edf) return NULL;
edf->free_strings = 0;
edf->fonts = eina_hash_string_small_new(free);
edf->collection = eina_hash_string_small_new(free);
edf->data = eina_hash_string_small_new(NULL);
if (!edf->fonts || !edf->collection || !edf->data)
goto on_error;
EINA_LIST_FREE(oedf->data, ed)
{
eina_hash_direct_add(edf->data, ed->key, ed->value);
free(ed);
}
EINA_LIST_FOREACH(oedf->collection_dir->entries, l, ce)
if (ce->entry)
eina_hash_direct_add(edf->collection, ce->entry, ce);
else
error_and_abort(ef, "Collection %i: name missing.\n", ce->id);
if (oedf->font_dir)
EINA_LIST_FOREACH(oedf->font_dir->entries, l, fnt)
{
char *tmp;
int length;
length = strlen(fnt->entry) + 7;
tmp = alloca(length);
snprintf(tmp, length, "fonts/%s", fnt->entry);
fnt->path = eina_stringshare_add(tmp);
if (edf->free_strings)
eina_stringshare_del(fnt->entry);
fnt->entry = fnt->path + 6;
eina_hash_direct_add(edf->fonts, fnt->entry, fnt);
}
if (!_edje_file_convert_images(edf, oedf))
goto on_error;
if (!_edje_file_convert_external(edf, oedf))
goto on_error;
edf->styles = oedf->styles;
edf->color_classes = oedf->color_classes;
edf->version = EDJE_FILE_VERSION;
edf->feature_ver = oedf->feature_ver;
edf->compiler = oedf->compiler;
edf->dangling = EINA_FALSE;
edf->warning = EINA_FALSE;
/* Below you will find all memory structure that could be cleaned when under
memory pressure */
edf->collection_cache = NULL;
edf->collection_patterns = NULL;
return edf;
on_error:
eina_hash_free(edf->fonts);
eina_hash_free(edf->collection);
eina_hash_free(edf->data);
free(edf->image_dir);
free(edf->external_dir);
free(edf);
return NULL;
}
static void
_edje_collection_program_add(Edje_Program ***array,
unsigned int *count,
Edje_Program *add)
{
Edje_Program **tmp;
tmp = realloc(*array, sizeof (Edje_Program*) * (*count + 1));
if (!tmp) return ;
tmp[(*count)++] = add;
*array = tmp;
}
Edje_Part_Collection *
_edje_collection_convert(Eet_File *ef, Edje_Part_Collection_Directory_Entry *ce, Old_Edje_Part_Collection *oedc)
{
Edje_Part_Collection *edc;
Old_Edje_Part *part;
Edje_Program *pg;
Edje_Data *di;
Eina_List *l;
unsigned int k;
oedc->part = ce->entry;
/* Count each type part and their respective state */
EINA_LIST_FOREACH(oedc->parts, l, part)
{
int *count;
int dummy = 0;
switch (part->type)
{
#define CSP(Tp, Ce) \
case EDJE_PART_TYPE_##Tp : \
count = &Ce->count.Tp; \
break;
CSP(RECTANGLE, ce);
CSP(TEXT, ce);
CSP(IMAGE, ce);
CSP(SWALLOW, ce);
CSP(TEXTBLOCK, ce);
CSP(GROUP, ce);
CSP(BOX, ce);
CSP(TABLE, ce);
CSP(EXTERNAL, ce);
default:
count = &dummy;
break;
}
*count += eina_list_count(part->other_desc) + 1;
}
ce->count.part = eina_list_count(oedc->parts);
#define CONVERT_EMN(Tp, Sz, Ce) \
Ce->mp.Tp = eina_mempool_add("one_big", #Tp, NULL, sizeof (Sz), Ce->count.Tp);
CONVERT_EMN(RECTANGLE, Edje_Part_Description_Common, ce);
CONVERT_EMN(TEXT, Edje_Part_Description_Text, ce);
CONVERT_EMN(IMAGE, Edje_Part_Description_Image, ce);
CONVERT_EMN(SWALLOW, Edje_Part_Description_Common, ce);
CONVERT_EMN(TEXTBLOCK, Edje_Part_Description_Text, ce);
CONVERT_EMN(GROUP, Edje_Part_Description_Common, ce);
CONVERT_EMN(BOX, Edje_Part_Description_Box, ce);
CONVERT_EMN(TABLE, Edje_Part_Description_Table, ce);
CONVERT_EMN(EXTERNAL, Edje_Part_Description_External, ce);
CONVERT_EMN(part, Edje_Part, ce);
/* Change structure layout */
edc = calloc(1, sizeof (Edje_Part_Collection));
if (!edc) error_and_abort(ef, "Not enough memory\n");
ce->ref = edc;
EINA_LIST_FREE(oedc->programs, pg)
{
if (!pg->signal && !pg->source)
_edje_collection_program_add(&edc->programs.nocmp,
&edc->programs.nocmp_count,
pg);
else if (pg->signal && strpbrk(pg->signal, "*?[\\") == NULL
&& pg->source && strpbrk(pg->source, "*?[\\") == NULL)
_edje_collection_program_add(&edc->programs.strcmp,
&edc->programs.strcmp_count,
pg);
else if (pg->signal && edje_program_is_strncmp(pg->signal)
&& pg->source && edje_program_is_strncmp(pg->source))
_edje_collection_program_add(&edc->programs.strncmp,
&edc->programs.strncmp_count,
pg);
else if (pg->signal && edje_program_is_strrncmp(pg->signal)
&& pg->source && edje_program_is_strrncmp(pg->source))
_edje_collection_program_add(&edc->programs.strrncmp,
&edc->programs.strrncmp_count,
pg);
else
_edje_collection_program_add(&edc->programs.fnmatch,
&edc->programs.fnmatch_count,
pg);
}
edc->data = eina_hash_string_small_new(NULL);
EINA_LIST_FREE(oedc->data, di)
{
eina_hash_direct_add(edc->data, di->key, di->value);
free(di);
}
edc->parts_count = eina_list_count(oedc->parts);
edc->parts = calloc(edc->parts_count, sizeof (Edje_Part *));
if (edc->parts_count && !edc->parts)
error_and_abort(ef, "Not enough memory\n");
k = 0;
EINA_LIST_FREE(oedc->parts, part)
{
Old_Edje_Part_Description *oepd;
Edje_Pack_Element *elm;
Edje_Part *replacement;
unsigned int i;
replacement = eina_mempool_malloc(ce->mp.part, sizeof (Edje_Part));
if (!replacement)
error_and_abort(ef, "Not enough memory\n");
replacement->name = part->name;
replacement->default_desc = _edje_description_convert(part->type, ce, part->default_desc);
replacement->other.desc_count = eina_list_count(part->other_desc);
replacement->other.desc = calloc(replacement->other.desc_count, sizeof (Edje_Part_Description_Common*));
i = 0;
EINA_LIST_FREE(part->other_desc, oepd)
replacement->other.desc[i++] = _edje_description_convert(part->type, ce, oepd);
replacement->source = part->source;
replacement->source2 = part->source2;
replacement->source3 = part->source3;
replacement->source4 = part->source4;
replacement->source5 = part->source5;
replacement->source6 = part->source6;
replacement->id = part->id;
replacement->clip_to_id = part->clip_to_id;
replacement->dragable = part->dragable;
replacement->items_count = eina_list_count(part->items);
replacement->items = calloc(replacement->items_count, sizeof (Edje_Pack_Element*));
i = 0;
EINA_LIST_FREE(part->items, elm)
replacement->items[i++] = elm;
replacement->type = part->type;
replacement->effect = part->effect;
replacement->mouse_events = part->mouse_events;
replacement->repeat_events = part->repeat_events;
replacement->ignore_flags = part->ignore_flags;
replacement->scale = part->scale;
replacement->precise_is_inside = part->precise_is_inside;
replacement->use_alternate_font_metrics = part->use_alternate_font_metrics;
replacement->pointer_mode = part->pointer_mode;
replacement->entry_mode = part->entry_mode;
replacement->select_mode = part->select_mode;
replacement->multiline = part->multiline;
replacement->api = part->api;
edc->parts[k++] = replacement;
free(part);
}
edc->id = oedc->id;
edc->alias = oedc->alias;
edc->prop.min = oedc->prop.min;
edc->prop.max = oedc->prop.max;
edc->script = oedc->script;
edc->part = oedc->part;
edc->script_only = oedc->script_only;
edc->lua_script_only = oedc->lua_script_only;
edc->checked = oedc->checked;
free(oedc);
return edc;
}
Edje_Part_Description_Common*
_edje_description_convert(int type,
Edje_Part_Collection_Directory_Entry *ce,
Old_Edje_Part_Description *oed)
{
Edje_Part_Description_Common *result = NULL;
switch (type)
{
case EDJE_PART_TYPE_RECTANGLE:
result = eina_mempool_malloc(ce->mp.RECTANGLE,
sizeof (Edje_Part_Description_Common));
break;
case EDJE_PART_TYPE_SWALLOW:
result = eina_mempool_malloc(ce->mp.SWALLOW,
sizeof (Edje_Part_Description_Common));
break;
case EDJE_PART_TYPE_GROUP:
result = eina_mempool_malloc(ce->mp.GROUP,
sizeof (Edje_Part_Description_Common));
break;
case EDJE_PART_TYPE_IMAGE:
{
Edje_Part_Description_Image *img;
Edje_Part_Image_Id *id;
unsigned int i = 0;
img = eina_mempool_malloc(ce->mp.IMAGE, sizeof (Edje_Part_Description_Image));
img->image.tweens_count = eina_list_count(oed->image.tween_list);
img->image.tweens = calloc(img->image.tweens_count,
sizeof (Edje_Part_Image_Id*));
if (img->image.tweens_count > 0 && !img->image.tweens)
{
eina_mempool_free(ce->mp.IMAGE, img);
return NULL;
}
EINA_LIST_FREE(oed->image.tween_list, id)
img->image.tweens[i++] = id;
img->image.id = oed->image.id;
img->image.scale_hint = oed->image.scale_hint;
img->image.set = oed->image.set;
img->image.border = oed->image.border;
img->image.fill = oed->image.fill;
result = &img->common;
break;
}
#define CONVERT_ALLOC_POOL(Short, Type, Name) \
case EDJE_PART_TYPE_##Short: \
{ \
Edje_Part_Description_##Type *Name; \
\
Name = eina_mempool_malloc(ce->mp.Short, sizeof (Edje_Part_Description_##Type)); \
Name->Name = oed->Name; \
result = &Name->common; \
break; \
}
CONVERT_ALLOC_POOL(TEXT, Text, text);
CONVERT_ALLOC_POOL(TEXTBLOCK, Text, text);
CONVERT_ALLOC_POOL(BOX, Box, box);
CONVERT_ALLOC_POOL(TABLE, Table, table);
CONVERT_ALLOC_POOL(EXTERNAL, External, external_params);
}
*result = oed->common;
free(oed);
return result;
}

@ -0,0 +1,152 @@
#ifndef EDJE_CONVERT_H__
# define EDJE_CONVERT_H__
typedef struct _Old_Edje_Image_Directory Old_Edje_Image_Directory;
typedef struct _Old_Edje_Font_Directory Old_Edje_Font_Directory;
typedef struct _Old_Edje_External_Directory Old_Edje_External_Directory;
typedef struct _Old_Edje_Part Old_Edje_Part;
typedef struct _Old_Edje_Part_Collection Old_Edje_Part_Collection;
typedef struct _Old_Edje_Part_Collection_Directory Old_Edje_Part_Collection_Directory;
typedef struct _Old_Edje_Part_Description Old_Edje_Part_Description;
typedef struct _Old_Edje_Part_Description_Spec_Image Old_Edje_Part_Description_Spec_Image;
typedef struct _Edje_Data Edje_Data;
struct _Edje_Data
{
const char *key;
char *value;
};
/*----------*/
struct _Old_Edje_Font_Directory
{
Eina_List *entries; /* a list of Edje_Font_Directory_Entry */
};
struct _Old_Edje_Image_Directory
{
Eina_List *entries; /* a list of Edje_Image_Directory_Entry */
Eina_List *sets; /* a list of Edje_Image_Directory_Set */
};
struct _Old_Edje_External_Directory
{
Eina_List *entries; /* a list of Edje_External_Directory_Entry */
};
struct _Old_Edje_File
{
const char *path;
time_t mtime;
Old_Edje_External_Directory *external_dir;
Old_Edje_Font_Directory *font_dir;
Old_Edje_Image_Directory *image_dir;
Old_Edje_Part_Collection_Directory *collection_dir;
Eina_List *data;
Eina_List *styles;
Eina_List *color_classes;
const char *compiler;
int version;
int feature_ver;
};
struct _Old_Edje_Part_Collection
{
Eina_List *programs; /* a list of Edje_Program */
Eina_List *parts; /* a list of Edje_Part */
Eina_List *data;
int id; /* the collection id */
Eina_Hash *alias; /* aliasing part*/
struct {
Edje_Size min, max;
} prop;
int references;
#ifdef EDJE_PROGRAM_CACHE
struct {
Eina_Hash *no_matches;
Eina_Hash *matches;
} prog_cache;
#endif
Embryo_Program *script; /* all the embryo script code for this group */
const char *part;
unsigned char script_only;
unsigned char lua_script_only;
unsigned char checked : 1;
};
struct _Old_Edje_Part
{
const char *name; /* the name if any of the part */
Old_Edje_Part_Description *default_desc; /* the part descriptor for default */
Eina_List *other_desc; /* other possible descriptors */
const char *source, *source2, *source3, *source4, *source5, *source6;
int id; /* its id number */
int clip_to_id; /* the part id to clip this one to */
Edje_Part_Dragable dragable;
Eina_List *items; /* packed items for box and table */
unsigned char type; /* what type (image, rect, text) */
unsigned char effect; /* 0 = plain... */
unsigned char mouse_events; /* it will affect/respond to mouse events */
unsigned char repeat_events; /* it will repeat events to objects below */
Evas_Event_Flags ignore_flags;
unsigned char scale; /* should certain properties scale with edje scale factor? */
unsigned char precise_is_inside;
unsigned char use_alternate_font_metrics;
unsigned char pointer_mode;
unsigned char entry_mode;
unsigned char select_mode;
unsigned char multiline;
Edje_Part_Api api;
};
struct _Old_Edje_Part_Description_Spec_Image
{
Eina_List *tween_list; /* list of Edje_Part_Image_Id */
int id; /* the image id to use */
int scale_hint; /* evas scale hint */
Eina_Bool set; /* if image condition it's content */
Edje_Part_Description_Spec_Border border;
Edje_Part_Description_Spec_Fill fill;
};
struct _Old_Edje_Part_Description
{
Edje_Part_Description_Common common;
Old_Edje_Part_Description_Spec_Image image;
Edje_Part_Description_Spec_Text text;
Edje_Part_Description_Spec_Box box;
Edje_Part_Description_Spec_Table table;
Eina_List *external_params; /* parameters for external objects */
};
struct _Old_Edje_Part_Collection_Directory
{
Eina_List *entries; /* a list of Edje_Part_Collection_Directory_Entry */
int references;
};
Edje_File *_edje_file_convert(Eet_File *ef, Old_Edje_File *oedf);
Edje_Part_Collection *_edje_collection_convert(Eet_File *ef,
Edje_Part_Collection_Directory_Entry *ce,
Old_Edje_Part_Collection *oedc);
Edje_Part_Description_Common *_edje_description_convert(int type,
Edje_Part_Collection_Directory_Entry *ce,
Old_Edje_Part_Description *oed);
const Edje_File *_edje_file_get(void);
void _edje_file_set(const Edje_File *edf);
#endif

@ -0,0 +1,445 @@
#include "edje_private.h"
#include "edje_convert.h"
Eet_Data_Descriptor *_edje_edd_old_edje_file = NULL;
Eet_Data_Descriptor *_edje_edd_old_edje_style = NULL;
Eet_Data_Descriptor *_edje_edd_old_edje_style_tag = NULL;
Eet_Data_Descriptor *_edje_edd_old_edje_color_class = NULL;
Eet_Data_Descriptor *_edje_edd_old_edje_data = NULL;
Eet_Data_Descriptor *_edje_edd_old_edje_external_directory = NULL;
Eet_Data_Descriptor *_edje_edd_old_edje_external_directory_entry = NULL;
Eet_Data_Descriptor *_edje_edd_old_edje_font_directory = NULL;
Eet_Data_Descriptor *_edje_edd_old_edje_font_directory_entry = NULL;
Eet_Data_Descriptor *_edje_edd_old_edje_image_directory = NULL;
Eet_Data_Descriptor *_edje_edd_old_edje_image_directory_entry = NULL;
Eet_Data_Descriptor *_edje_edd_old_edje_image_directory_set = NULL;
Eet_Data_Descriptor *_edje_edd_old_edje_image_directory_set_entry = NULL;
Eet_Data_Descriptor *_edje_edd_old_edje_program = NULL;
Eet_Data_Descriptor *_edje_edd_old_edje_program_target = NULL;
Eet_Data_Descriptor *_edje_edd_old_edje_program_after = NULL;
Eet_Data_Descriptor *_edje_edd_old_edje_part_collection_directory = NULL;
Eet_Data_Descriptor *_edje_edd_old_edje_part_collection_directory_entry = NULL;
Eet_Data_Descriptor *_edje_edd_old_edje_pack_element = NULL;
Eet_Data_Descriptor *_edje_edd_old_edje_part_collection = NULL;
Eet_Data_Descriptor *_edje_edd_old_edje_part = NULL;
Eet_Data_Descriptor *_edje_edd_old_edje_part_description = NULL;
Eet_Data_Descriptor *_edje_edd_old_edje_part_image_id = NULL;
Eet_Data_Descriptor *_edje_edd_old_edje_external_param = NULL;
#define FREED(eed) \
if (eed) \
{ \
eet_data_descriptor_free((eed)); \
(eed) = NULL; \
}
void
_edje_edd_old_shutdown(void)
{
FREED(_edje_edd_old_edje_file);
FREED(_edje_edd_old_edje_style);
FREED(_edje_edd_old_edje_style_tag);
FREED(_edje_edd_old_edje_color_class);
FREED(_edje_edd_old_edje_data);
FREED(_edje_edd_old_edje_external_directory);
FREED(_edje_edd_old_edje_external_directory_entry);
FREED(_edje_edd_old_edje_font_directory);
FREED(_edje_edd_old_edje_font_directory_entry);
FREED(_edje_edd_old_edje_image_directory);
FREED(_edje_edd_old_edje_image_directory_entry);
FREED(_edje_edd_old_edje_program);
FREED(_edje_edd_old_edje_program_target);
FREED(_edje_edd_old_edje_program_after);
FREED(_edje_edd_old_edje_part_collection_directory);
FREED(_edje_edd_old_edje_part_collection_directory_entry);
FREED(_edje_edd_old_edje_pack_element);
FREED(_edje_edd_old_edje_part_collection);
FREED(_edje_edd_old_edje_part);
FREED(_edje_edd_old_edje_part_description);
FREED(_edje_edd_old_edje_part_image_id);
FREED(_edje_edd_old_edje_external_param);
FREED(_edje_edd_old_edje_image_directory_set);
FREED(_edje_edd_old_edje_image_directory_set_entry);
}
void
_edje_edd_old_init(void)
{
Eet_Data_Descriptor_Class eddc;
/* external directory */
EET_EINA_FILE_DATA_DESCRIPTOR_CLASS_SET(&eddc, Edje_External_Directory_Entry);
_edje_edd_old_edje_external_directory_entry =
eet_data_descriptor_file_new(&eddc);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_external_directory_entry, Edje_External_Directory_Entry, "entry", entry, EET_T_STRING);
eet_eina_file_data_descriptor_class_set(&eddc, "Edje_External_Directory",
sizeof (Old_Edje_External_Directory));
_edje_edd_old_edje_external_directory =
eet_data_descriptor_file_new(&eddc);
EET_DATA_DESCRIPTOR_ADD_LIST(_edje_edd_old_edje_external_directory, Edje_External_Directory, "entries", entries, _edje_edd_old_edje_external_directory_entry);
/* font directory */
EET_EINA_FILE_DATA_DESCRIPTOR_CLASS_SET(&eddc, Edje_Font_Directory_Entry);
_edje_edd_old_edje_font_directory_entry =
eet_data_descriptor_file_new(&eddc);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_font_directory_entry, Edje_Font_Directory_Entry, "entry", entry, EET_T_STRING);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_font_directory_entry, Edje_Font_Directory_Entry, "file", file, EET_T_STRING);
eet_eina_file_data_descriptor_class_set(&eddc, "Edje_Font_Directory",
sizeof (Old_Edje_Font_Directory));
_edje_edd_old_edje_font_directory =
eet_data_descriptor_file_new(&eddc);
EET_DATA_DESCRIPTOR_ADD_LIST(_edje_edd_old_edje_font_directory, Old_Edje_Font_Directory, "entries", entries, _edje_edd_old_edje_font_directory_entry);
/* image directory */
EET_EINA_FILE_DATA_DESCRIPTOR_CLASS_SET(&eddc, Edje_Image_Directory_Entry);
_edje_edd_old_edje_image_directory_entry =
eet_data_descriptor_file_new(&eddc);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_image_directory_entry, Edje_Image_Directory_Entry, "entry", entry, EET_T_STRING);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_image_directory_entry, Edje_Image_Directory_Entry, "source_type", source_type, EET_T_INT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_image_directory_entry, Edje_Image_Directory_Entry, "source_param", source_param, EET_T_INT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_image_directory_entry, Edje_Image_Directory_Entry, "id", id, EET_T_INT);
EET_EINA_FILE_DATA_DESCRIPTOR_CLASS_SET(&eddc, Edje_Image_Directory_Set_Entry);
_edje_edd_old_edje_image_directory_set_entry =
eet_data_descriptor_file_new(&eddc);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_image_directory_set_entry, Edje_Image_Directory_Set_Entry, "name", name, EET_T_STRING);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_image_directory_set_entry, Edje_Image_Directory_Set_Entry, "id", id, EET_T_INT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_image_directory_set_entry, Edje_Image_Directory_Set_Entry, "min.w", size.min.w, EET_T_INT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_image_directory_set_entry, Edje_Image_Directory_Set_Entry, "min.h", size.min.h, EET_T_INT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_image_directory_set_entry, Edje_Image_Directory_Set_Entry, "max.w", size.max.w, EET_T_INT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_image_directory_set_entry, Edje_Image_Directory_Set_Entry, "max.h", size.max.h, EET_T_INT);
EET_EINA_FILE_DATA_DESCRIPTOR_CLASS_SET(&eddc, Edje_Image_Directory_Set);
_edje_edd_old_edje_image_directory_set =
eet_data_descriptor_file_new(&eddc);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_image_directory_set, Edje_Image_Directory_Set, "name", name, EET_T_STRING);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_image_directory_set, Edje_Image_Directory_Set, "id", id, EET_T_INT);
EET_DATA_DESCRIPTOR_ADD_LIST(_edje_edd_old_edje_image_directory_set, Edje_Image_Directory_Set, "entries", entries, _edje_edd_old_edje_image_directory_set_entry);
eet_eina_file_data_descriptor_class_set(&eddc, "Edje_Image_Directory",
sizeof (Old_Edje_Image_Directory));
_edje_edd_old_edje_image_directory =
eet_data_descriptor_file_new(&eddc);
EET_DATA_DESCRIPTOR_ADD_LIST(_edje_edd_old_edje_image_directory, Old_Edje_Image_Directory, "entries", entries, _edje_edd_old_edje_image_directory_entry);
EET_DATA_DESCRIPTOR_ADD_LIST(_edje_edd_old_edje_image_directory, Old_Edje_Image_Directory, "sets", sets, _edje_edd_old_edje_image_directory_set);
/* collection directory */
EET_EINA_FILE_DATA_DESCRIPTOR_CLASS_SET(&eddc, Edje_Part_Collection_Directory_Entry);
_edje_edd_old_edje_part_collection_directory_entry =
eet_data_descriptor_file_new(&eddc);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_collection_directory_entry, Edje_Part_Collection_Directory_Entry, "entry", entry, EET_T_STRING);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_collection_directory_entry, Edje_Part_Collection_Directory_Entry, "id", id, EET_T_INT);
eet_eina_file_data_descriptor_class_set(&eddc, "Edje_Part_Collection_Directory",
sizeof (Old_Edje_Part_Collection_Directory));
_edje_edd_old_edje_part_collection_directory =
eet_data_descriptor_file_new(&eddc);
EET_DATA_DESCRIPTOR_ADD_LIST(_edje_edd_old_edje_part_collection_directory, Old_Edje_Part_Collection_Directory, "entries", entries, _edje_edd_old_edje_part_collection_directory_entry);
/* generic data attachment */
EET_EINA_FILE_DATA_DESCRIPTOR_CLASS_SET(&eddc, Edje_Data);
_edje_edd_old_edje_data =
eet_data_descriptor_file_new(&eddc);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_data, Edje_Data, "key", key, EET_T_STRING);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_data, Edje_Data, "value", value, EET_T_STRING);
EET_EINA_FILE_DATA_DESCRIPTOR_CLASS_SET(&eddc, Edje_Style_Tag);
_edje_edd_old_edje_style_tag =
eet_data_descriptor_file_new(&eddc);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_style_tag, Edje_Style_Tag, "key", key, EET_T_STRING);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_style_tag, Edje_Style_Tag, "value", value, EET_T_STRING);
EET_EINA_FILE_DATA_DESCRIPTOR_CLASS_SET(&eddc, Edje_Style);
_edje_edd_old_edje_style =
eet_data_descriptor_file_new(&eddc);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_style, Edje_Style, "name", name, EET_T_STRING);
EET_DATA_DESCRIPTOR_ADD_LIST(_edje_edd_old_edje_style, Edje_Style, "tags", tags, _edje_edd_old_edje_style_tag);
EET_EINA_FILE_DATA_DESCRIPTOR_CLASS_SET(&eddc, Edje_Color_Class);
_edje_edd_old_edje_color_class =
eet_data_descriptor_file_new(&eddc);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_color_class, Edje_Color_Class, "name", name, EET_T_STRING);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_color_class, Edje_Color_Class, "r", r, EET_T_UCHAR);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_color_class, Edje_Color_Class, "g", g, EET_T_UCHAR);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_color_class, Edje_Color_Class, "b", b, EET_T_UCHAR);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_color_class, Edje_Color_Class, "a", a, EET_T_UCHAR);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_color_class, Edje_Color_Class, "r2", r2, EET_T_UCHAR);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_color_class, Edje_Color_Class, "g2", g2, EET_T_UCHAR);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_color_class, Edje_Color_Class, "b2", b2, EET_T_UCHAR);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_color_class, Edje_Color_Class, "a2", a2, EET_T_UCHAR);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_color_class, Edje_Color_Class, "r3", r3, EET_T_UCHAR);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_color_class, Edje_Color_Class, "g3", g3, EET_T_UCHAR);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_color_class, Edje_Color_Class, "b3", b3, EET_T_UCHAR);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_color_class, Edje_Color_Class, "a3", a3, EET_T_UCHAR);
/* the main file directory */
eet_eina_file_data_descriptor_class_set(&eddc, "Edje_File", sizeof (Old_Edje_File));
_edje_edd_old_edje_file =
eet_data_descriptor_file_new(&eddc);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_file, Old_Edje_File, "compiler", compiler, EET_T_STRING);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_file, Old_Edje_File, "version", version, EET_T_INT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_file, Old_Edje_File, "feature_ver", feature_ver, EET_T_INT);
EET_DATA_DESCRIPTOR_ADD_SUB(_edje_edd_old_edje_file, Old_Edje_File, "external_dir", external_dir, _edje_edd_old_edje_external_directory);
EET_DATA_DESCRIPTOR_ADD_SUB(_edje_edd_old_edje_file, Old_Edje_File, "font_dir", font_dir, _edje_edd_old_edje_font_directory);
EET_DATA_DESCRIPTOR_ADD_SUB(_edje_edd_old_edje_file, Old_Edje_File, "image_dir", image_dir, _edje_edd_old_edje_image_directory);
EET_DATA_DESCRIPTOR_ADD_SUB(_edje_edd_old_edje_file, Old_Edje_File, "collection_dir", collection_dir, _edje_edd_old_edje_part_collection_directory);
EET_DATA_DESCRIPTOR_ADD_LIST(_edje_edd_old_edje_file, Old_Edje_File, "data", data, _edje_edd_old_edje_data);
EET_DATA_DESCRIPTOR_ADD_LIST(_edje_edd_old_edje_file, Old_Edje_File, "styles", styles, _edje_edd_old_edje_style);
EET_DATA_DESCRIPTOR_ADD_LIST(_edje_edd_old_edje_file, Old_Edje_File, "color_classes", color_classes, _edje_edd_old_edje_color_class);
/* parts & programs - loaded induvidually */
EET_EINA_FILE_DATA_DESCRIPTOR_CLASS_SET(&eddc, Edje_Program_Target);
_edje_edd_old_edje_program_target =
eet_data_descriptor_file_new(&eddc);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_program_target, Edje_Program_Target, "id", id, EET_T_INT);
EET_EINA_FILE_DATA_DESCRIPTOR_CLASS_SET(&eddc, Edje_Program_After);
_edje_edd_old_edje_program_after =
eet_data_descriptor_file_new(&eddc);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_program_after,
Edje_Program_After, "id", id, EET_T_INT);
EET_EINA_FILE_DATA_DESCRIPTOR_CLASS_SET(&eddc, Edje_Program);
_edje_edd_old_edje_program =
eet_data_descriptor_file_new(&eddc);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_program, Edje_Program, "id", id, EET_T_INT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_program, Edje_Program, "name", name, EET_T_STRING);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_program, Edje_Program, "signal", signal, EET_T_STRING);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_program, Edje_Program, "source", source, EET_T_STRING);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_program, Edje_Program, "filter_part", filter.part, EET_T_STRING);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_program, Edje_Program, "filter_state", filter.state, EET_T_STRING);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_program, Edje_Program, "in.from", in.from, EET_T_DOUBLE);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_program, Edje_Program, "in.range", in.range, EET_T_DOUBLE);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_program, Edje_Program, "action", action, EET_T_INT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_program, Edje_Program, "state", state, EET_T_STRING);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_program, Edje_Program, "state2", state2, EET_T_STRING);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_program, Edje_Program, "value", value, EET_T_DOUBLE);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_program, Edje_Program, "value2", value2, EET_T_DOUBLE);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_program, Edje_Program, "tween.mode", tween.mode, EET_T_INT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_program, Edje_Program, "tween.time", tween.time, EDJE_T_FLOAT);
EET_DATA_DESCRIPTOR_ADD_LIST(_edje_edd_old_edje_program, Edje_Program, "targets", targets, _edje_edd_old_edje_program_target);
EET_DATA_DESCRIPTOR_ADD_LIST(_edje_edd_old_edje_program, Edje_Program, "after", after, _edje_edd_old_edje_program_after);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_program, Edje_Program, "api.name", api.name, EET_T_STRING);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_program, Edje_Program, "api.description", api.description, EET_T_STRING);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_program, Edje_Program, "param.src", param.src, EET_T_INT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_program, Edje_Program, "param.dst", param.dst, EET_T_INT);
EET_EINA_FILE_DATA_DESCRIPTOR_CLASS_SET(&eddc, Edje_Part_Image_Id);
_edje_edd_old_edje_part_image_id =
eet_data_descriptor_file_new(&eddc);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_image_id, Edje_Part_Image_Id, "id", id, EET_T_INT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_image_id, Edje_Part_Image_Id, "set", set, EET_T_UCHAR);
EET_EINA_FILE_DATA_DESCRIPTOR_CLASS_SET(&eddc, Edje_External_Param);
_edje_edd_old_edje_external_param =
eet_data_descriptor_file_new(&eddc);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_external_param, Edje_External_Param, "name", name, EET_T_STRING);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_external_param, Edje_External_Param, "type", type, EET_T_INT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_external_param, Edje_External_Param, "i", i, EET_T_INT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_external_param, Edje_External_Param, "d", d, EET_T_DOUBLE);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_external_param, Edje_External_Param, "s", s, EET_T_STRING);
eet_eina_file_data_descriptor_class_set(&eddc, "Edje_Part_Description", sizeof (Old_Edje_Part_Description));
_edje_edd_old_edje_part_description =
eet_data_descriptor_file_new(&eddc);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "state.name", common.state.name, EET_T_STRING);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "state.value", common.state.value, EET_T_DOUBLE);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "visible", common.visible, EET_T_CHAR);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "align.x", common.align.x, EDJE_T_FLOAT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "align.y", common.align.y, EDJE_T_FLOAT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "fixed.w", common.fixed.w, EET_T_UCHAR);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "fixed.h", common.fixed.h, EET_T_UCHAR);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "min.w", common.min.w, EET_T_INT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "min.h", common.min.h, EET_T_INT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "max.w", common.max.w, EET_T_INT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "max.h", common.max.h, EET_T_INT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "step.x", common.step.x, EET_T_INT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "step.y", common.step.y, EET_T_INT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "aspect.min", common.aspect.min, EDJE_T_FLOAT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "aspect.max", common.aspect.max, EDJE_T_FLOAT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "aspect.prefer", common.aspect.prefer, EET_T_CHAR);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "rel1.relative_x", common.rel1.relative_x, EDJE_T_FLOAT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "rel1.relative_y", common.rel1.relative_y, EDJE_T_FLOAT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "rel1.offset_x", common.rel1.offset_x, EET_T_INT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "rel1.offset_y", common.rel1.offset_y, EET_T_INT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "rel1.id_x", common.rel1.id_x, EET_T_INT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "rel1.id_y", common.rel1.id_y, EET_T_INT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "rel2.relative_x", common.rel2.relative_x, EDJE_T_FLOAT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "rel2.relative_y", common.rel2.relative_y, EDJE_T_FLOAT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "rel2.offset_x", common.rel2.offset_x, EET_T_INT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "rel2.offset_y", common.rel2.offset_y, EET_T_INT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "rel2.id_x", common.rel2.id_x, EET_T_INT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "rel2.id_y", common.rel2.id_y, EET_T_INT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "image.id", image.id, EET_T_INT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "image.set", image.set, EET_T_UCHAR);
EET_DATA_DESCRIPTOR_ADD_LIST(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "image.tween_list", image.tween_list, _edje_edd_old_edje_part_image_id);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "border.l", image.border.l, EET_T_INT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "border.r", image.border.r, EET_T_INT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "border.t", image.border.t, EET_T_INT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "border.b", image.border.b, EET_T_INT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "border.no_fill", image.border.no_fill, EET_T_UCHAR);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "border.scale", image.border.scale, EET_T_UCHAR);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "fill.smooth", image.fill.smooth, EET_T_CHAR);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "fill.pos_rel_x", image.fill.pos_rel_x, EDJE_T_FLOAT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "fill.pos_abs_x", image.fill.pos_abs_x, EET_T_INT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "fill.rel_x", image.fill.rel_x, EDJE_T_FLOAT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "fill.abs_x", image.fill.abs_x, EET_T_INT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "fill.pos_rel_y", image.fill.pos_rel_y, EDJE_T_FLOAT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "fill.pos_abs_y", image.fill.pos_abs_y, EET_T_INT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "fill.rel_y", image.fill.rel_y, EDJE_T_FLOAT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "fill.abs_y", image.fill.abs_y, EET_T_INT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "fill.angle", image.fill.angle, EET_T_INT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "fill.spread", image.fill.spread, EET_T_INT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "fill.type", image.fill.type, EET_T_CHAR);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "color_class", common.color_class, EET_T_STRING);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "color.r", common.color.r, EET_T_UCHAR);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "color.g", common.color.g, EET_T_UCHAR);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "color.b", common.color.b, EET_T_UCHAR);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "color.a", common.color.a, EET_T_UCHAR);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "color2.r", common.color2.r, EET_T_UCHAR);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "color2.g", common.color2.g, EET_T_UCHAR);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "color2.b", common.color2.b, EET_T_UCHAR);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "color2.a", common.color2.a, EET_T_UCHAR);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "color3.r", text.color3.r, EET_T_UCHAR);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "color3.g", text.color3.g, EET_T_UCHAR);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "color3.b", text.color3.b, EET_T_UCHAR);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "color3.a", text.color3.a, EET_T_UCHAR);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "text.text", text.text, EET_T_STRING);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "text.text_class", text.text_class, EET_T_STRING);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "text.style", text.style, EET_T_STRING);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "text.font", text.font, EET_T_STRING);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "text.repch", text.repch, EET_T_STRING);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "text.size", text.size, EET_T_INT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "text.fit_x", text.fit_x, EET_T_UCHAR);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "text.fit_y", text.fit_y, EET_T_UCHAR);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "text.min_x", text.min_x, EET_T_UCHAR);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "text.min_y", text.min_y, EET_T_UCHAR);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "text.max_x", text.max_x, EET_T_UCHAR);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "text.max_y", text.max_y, EET_T_UCHAR);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "text.align.x", text.align.x, EDJE_T_FLOAT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "text.align.y", text.align.y, EDJE_T_FLOAT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "text.id_source", text.id_source, EET_T_INT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "text.id_text_source", text.id_text_source, EET_T_INT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "text.elipsis", text.elipsis, EET_T_DOUBLE);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "box.layout", box.layout, EET_T_STRING);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "box.alt_layout", box.alt_layout, EET_T_STRING);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "box.align.x", box.align.x, EDJE_T_FLOAT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "box.align.y", box.align.y, EDJE_T_FLOAT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "box.padding.x", box.padding.x, EET_T_INT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "box.padding.y", box.padding.y, EET_T_INT);
EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_old_edje_part_description, Old_Edje_Part_Description, "box.min.h", box.min.h, EET_T_UCHAR);