summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChunEon Park <hermet@hermet.pe.kr>2013-05-31 17:35:30 +0900
committerChunEon Park <hermet@hermet.pe.kr>2013-05-31 17:35:30 +0900
commit80e13538076f5e72ce96ac6f59e6b872441a18b5 (patch)
treea33bd3cc549f55fbed1e988ad2f238c428a8a938
parentf87c0503423f0ca35031b7a703ac914ae00f38b1 (diff)
edje - support edc source_visible
-rw-r--r--ChangeLog3
-rw-r--r--NEWS1
-rw-r--r--data/edje/vim/syntax/edc.vim3
-rw-r--r--src/bin/edje/edje_cc_handlers.c24
-rw-r--r--src/lib/edje/edje_calc.c10
-rw-r--r--src/lib/edje/edje_data.c1
-rw-r--r--src/lib/edje/edje_edit.c1
-rw-r--r--src/lib/edje/edje_private.h1
8 files changed, 39 insertions, 5 deletions
diff --git a/ChangeLog b/ChangeLog
index 608a15649d..d08de9ff8d 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,6 @@
12013-05-31 ChunEon Park (Hermet)
2 * Edje: support edc proxy.source_visible
3
12013-05-31 Jérémy Zurcher 42013-05-31 Jérémy Zurcher
2 * Added --enable-image-loader-xyz=yes|static|auto|no for all loaders 5 * Added --enable-image-loader-xyz=yes|static|auto|no for all loaders
3 * compilation fail if not found and option set to yes or static 6 * compilation fail if not found and option set to yes or static
diff --git a/NEWS b/NEWS
index 3fcda0b5dc..bae0c24d6b 100644
--- a/NEWS
+++ b/NEWS
@@ -103,6 +103,7 @@ Additions:
103 * Edje: 103 * Edje:
104 - Add edje_object_part_text_input_panel_layout_variation_set/get API 104 - Add edje_object_part_text_input_panel_layout_variation_set/get API
105 - Add EDJE_INPUT_PANEL_LAYOUT_DATETIME layout 105 - Add EDJE_INPUT_PANEL_LAYOUT_DATETIME layout
106 - support edc proxy.source_visible
106 * Evil: 107 * Evil:
107 - Add mkdtemp. 108 - Add mkdtemp.
108 * ecore_x: 109 * ecore_x:
diff --git a/data/edje/vim/syntax/edc.vim b/data/edje/vim/syntax/edc.vim
index c47d701023..08c6bec6e9 100644
--- a/data/edje/vim/syntax/edc.vim
+++ b/data/edje/vim/syntax/edc.vim
@@ -14,7 +14,7 @@ endif
14" A bunch of useful keywords 14" A bunch of useful keywords
15syn keyword edcBlock images data fonts collections group contained 15syn keyword edcBlock images data fonts collections group contained
16syn keyword edcBlock part parts dragable description contained 16syn keyword edcBlock part parts dragable description contained
17syn keyword edcBlock text font fill origin size image contained 17syn keyword edcBlock text font fill origin size image proxy contained
18syn keyword edcBlock programs program styles style contained 18syn keyword edcBlock programs program styles style contained
19syn keyword edcBlock gradient spectra spectrum contained 19syn keyword edcBlock gradient spectra spectrum contained
20syn keyword edcBlock color_classes color_class rel1 rel2 contained 20syn keyword edcBlock color_classes color_class rel1 rel2 contained
@@ -31,6 +31,7 @@ syn keyword edcLabel source5 source6 multiline pointer_mode contained
31syn keyword edcLabel state visible step aspect fixed middle contained 31syn keyword edcLabel state visible step aspect fixed middle contained
32syn keyword edcLabel aspect_preference ellipsis elipsis image contained 32syn keyword edcLabel aspect_preference ellipsis elipsis image contained
33syn keyword edcLabel relative offset to to_x to_y contained 33syn keyword edcLabel relative offset to to_x to_y contained
34syn keyword edcLabel source_visible contained
34syn keyword edcLabel border border_scale scale_hint color color2 color3 font size contained 35syn keyword edcLabel border border_scale scale_hint color color2 color3 font size contained
35syn keyword edcLabel signal action transition in filter contained 36syn keyword edcLabel signal action transition in filter contained
36syn keyword edcLabel target after fit align contained 37syn keyword edcLabel target after fit align contained
diff --git a/src/bin/edje/edje_cc_handlers.c b/src/bin/edje/edje_cc_handlers.c
index ef3ad6b0b4..dd9840c910 100644
--- a/src/bin/edje/edje_cc_handlers.c
+++ b/src/bin/edje/edje_cc_handlers.c
@@ -321,6 +321,8 @@ static void st_collections_group_parts_part_description_table_homogeneous(void);
321static void st_collections_group_parts_part_description_table_align(void); 321static void st_collections_group_parts_part_description_table_align(void);
322static void st_collections_group_parts_part_description_table_padding(void); 322static void st_collections_group_parts_part_description_table_padding(void);
323static void st_collections_group_parts_part_description_table_min(void); 323static void st_collections_group_parts_part_description_table_min(void);
324static void st_collections_group_parts_part_description_proxy_source_visible(void);
325
324#ifdef HAVE_EPHYSICS 326#ifdef HAVE_EPHYSICS
325static void st_collections_group_parts_part_description_physics_mass(void); 327static void st_collections_group_parts_part_description_physics_mass(void);
326static void st_collections_group_parts_part_description_physics_restitution(void); 328static void st_collections_group_parts_part_description_physics_restitution(void);
@@ -633,6 +635,8 @@ New_Statement_Handler statement_handlers[] =
633 {"collections.group.parts.part.description.table.align", st_collections_group_parts_part_description_table_align}, 635 {"collections.group.parts.part.description.table.align", st_collections_group_parts_part_description_table_align},
634 {"collections.group.parts.part.description.table.padding", st_collections_group_parts_part_description_table_padding}, 636 {"collections.group.parts.part.description.table.padding", st_collections_group_parts_part_description_table_padding},
635 {"collections.group.parts.part.description.table.min", st_collections_group_parts_part_description_table_min}, 637 {"collections.group.parts.part.description.table.min", st_collections_group_parts_part_description_table_min},
638 {"collections.group.parts.part.description.proxy.source_visible", st_collections_group_parts_part_description_proxy_source_visible},
639
636#ifdef HAVE_EPHYSICS 640#ifdef HAVE_EPHYSICS
637 {"collections.group.parts.part.description.physics.mass", st_collections_group_parts_part_description_physics_mass}, 641 {"collections.group.parts.part.description.physics.mass", st_collections_group_parts_part_description_physics_mass},
638 {"collections.group.parts.part.description.physics.restitution", st_collections_group_parts_part_description_physics_restitution}, 642 {"collections.group.parts.part.description.physics.restitution", st_collections_group_parts_part_description_physics_restitution},
@@ -1095,7 +1099,7 @@ _edje_part_description_alloc(unsigned char type, const char *collection, const c
1095 ed = mem_alloc(SZ(Edje_Part_Description_Proxy)); 1099 ed = mem_alloc(SZ(Edje_Part_Description_Proxy));
1096 1100
1097 ed->proxy.id = -1; 1101 ed->proxy.id = -1;
1098 1102 ed->proxy.source_visible = EINA_TRUE;
1099 _edje_part_description_fill(&ed->proxy.fill); 1103 _edje_part_description_fill(&ed->proxy.fill);
1100 1104
1101 result = &ed->common; 1105 result = &ed->common;
@@ -7392,6 +7396,24 @@ static void st_collections_group_parts_part_description_table_padding(void)
7392} 7396}
7393 7397
7394static void 7398static void
7399st_collections_group_parts_part_description_proxy_source_visible(void)
7400{
7401 Edje_Part_Description_Proxy *ed;
7402
7403 check_arg_count(1);
7404
7405 if (current_part->type != EDJE_PART_TYPE_PROXY)
7406 {
7407 ERR("parse error %s:%i. proxy attributes in non-PROXY part.",
7408 file_in, line - 1);
7409 exit(-1);
7410 }
7411
7412 ed = (Edje_Part_Description_Proxy*) current_desc;
7413 ed->proxy.source_visible = parse_bool(0);
7414}
7415
7416static void
7395st_collections_group_parts_part_description_table_min(void) 7417st_collections_group_parts_part_description_table_min(void)
7396{ 7418{
7397 Edje_Part_Description_Table *ed; 7419 Edje_Part_Description_Table *ed;
diff --git a/src/lib/edje/edje_calc.c b/src/lib/edje/edje_calc.c
index 26614e25e7..ce1796aab9 100644
--- a/src/lib/edje/edje_calc.c
+++ b/src/lib/edje/edje_calc.c
@@ -2486,9 +2486,13 @@ _edje_proxy_recalc_apply(Edje *ed, Edje_Real_Part *ep, Edje_Calc_Params *p3, Edj
2486 } 2486 }
2487 2487
2488 eo_do(ep->object, 2488 eo_do(ep->object,
2489 evas_obj_image_fill_set(p3->type.common.fill.x, p3->type.common.fill.y, 2489 evas_obj_image_fill_set(p3->type.common.fill.x,
2490 p3->type.common.fill.w, p3->type.common.fill.h), 2490 p3->type.common.fill.y,
2491 evas_obj_image_smooth_scale_set(p3->smooth)); 2491 p3->type.common.fill.w,
2492 p3->type.common.fill.h),
2493 evas_obj_image_smooth_scale_set(p3->smooth),
2494 evas_obj_image_source_visible_set(chosen_desc->proxy.source_visible)
2495 );
2492} 2496}
2493 2497
2494static void 2498static void
diff --git a/src/lib/edje/edje_data.c b/src/lib/edje/edje_data.c
index f531af473c..7a9a31d92e 100644
--- a/src/lib/edje/edje_data.c
+++ b/src/lib/edje/edje_data.c
@@ -723,6 +723,7 @@ _edje_edd_init(void)
723 EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_edje_part_description_proxy, Edje_Part_Description_Proxy, "proxy.fill.angle", proxy.fill.angle, EET_T_INT); 723 EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_edje_part_description_proxy, Edje_Part_Description_Proxy, "proxy.fill.angle", proxy.fill.angle, EET_T_INT);
724 EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_edje_part_description_proxy, Edje_Part_Description_Proxy, "proxy.fill.spread", proxy.fill.spread, EET_T_INT); 724 EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_edje_part_description_proxy, Edje_Part_Description_Proxy, "proxy.fill.spread", proxy.fill.spread, EET_T_INT);
725 EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_edje_part_description_proxy, Edje_Part_Description_Proxy, "proxy.fill.type", proxy.fill.type, EET_T_CHAR); 725 EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_edje_part_description_proxy, Edje_Part_Description_Proxy, "proxy.fill.type", proxy.fill.type, EET_T_CHAR);
726 EET_DATA_DESCRIPTOR_ADD_BASIC(_edje_edd_edje_part_description_proxy, Edje_Part_Description_Proxy, "proxy.source_visible", proxy.source_visible, EET_T_CHAR);
726 727
727 EET_EINA_FILE_DATA_DESCRIPTOR_CLASS_SET(&eddc, Edje_Part_Description_Text); 728 EET_EINA_FILE_DATA_DESCRIPTOR_CLASS_SET(&eddc, Edje_Part_Description_Text);
728 eddc.func.mem_free = mem_free_text; 729 eddc.func.mem_free = mem_free_text;
diff --git a/src/lib/edje/edje_edit.c b/src/lib/edje/edje_edit.c
index 95842958f3..c9b9f84e60 100644
--- a/src/lib/edje/edje_edit.c
+++ b/src/lib/edje/edje_edit.c
@@ -3095,6 +3095,7 @@ edje_edit_state_add(Evas_Object *obj, const char *part, const char *name, double
3095 memset(&pro->proxy, 0, sizeof (pro->proxy)); 3095 memset(&pro->proxy, 0, sizeof (pro->proxy));
3096 3096
3097 pro->proxy.id = -1; 3097 pro->proxy.id = -1;
3098 pro->proxy.source_visible = EINA_TRUE;
3098 pro->proxy.fill.smooth = 1; 3099 pro->proxy.fill.smooth = 1;
3099 pro->proxy.fill.pos_rel_x = 0.0; 3100 pro->proxy.fill.pos_rel_x = 0.0;
3100 pro->proxy.fill.pos_abs_x = 0; 3101 pro->proxy.fill.pos_abs_x = 0;
diff --git a/src/lib/edje/edje_private.h b/src/lib/edje/edje_private.h
index 5cc0075d80..968bc4962e 100644
--- a/src/lib/edje/edje_private.h
+++ b/src/lib/edje/edje_private.h
@@ -1130,6 +1130,7 @@ struct _Edje_Part_Description_Spec_Proxy
1130 Edje_Part_Description_Spec_Fill fill; 1130 Edje_Part_Description_Spec_Fill fill;
1131 1131
1132 int id; /* the part id to use as a source for this state */ 1132 int id; /* the part id to use as a source for this state */
1133 Eina_Bool source_visible; /* source object visibility */
1133}; 1134};
1134 1135
1135struct _Edje_Part_Description_Spec_Text 1136struct _Edje_Part_Description_Spec_Text