diff options
author | perepelits.m <perepelits.m@samsung.com> | 2015-04-16 19:29:01 +0200 |
---|---|---|
committer | Cedric BAIL <cedric@osg.samsung.com> | 2015-05-07 09:53:09 +0200 |
commit | 83bb3b5b5180bbe96d6ea8da1f3b82071b6a01c9 (patch) | |
tree | f2ca80043f59c631c456a1e2505ad1a9adfe968c /src/bin/edje/edje_cc_handlers.c | |
parent | 970afe9bea5bd61bef208d65af0a3a6c7b912a42 (diff) |
edje: add align 3d support.
Summary: Adding of Z axis to be aligned
Reviewers: cedric, raster, Hermet
Subscribers: cedric, artem.popov
Differential Revision: https://phab.enlightenment.org/D2368
Signed-off-by: Cedric BAIL <cedric@osg.samsung.com>
Diffstat (limited to '')
-rw-r--r-- | src/bin/edje/edje_cc_handlers.c | 23 |
1 files changed, 17 insertions, 6 deletions
diff --git a/src/bin/edje/edje_cc_handlers.c b/src/bin/edje/edje_cc_handlers.c index 41da0f20a0..fe11ddb6ee 100644 --- a/src/bin/edje/edje_cc_handlers.c +++ b/src/bin/edje/edje_cc_handlers.c | |||
@@ -6377,6 +6377,9 @@ ob_collections_group_parts_part_description(void) | |||
6377 | ed->minmul.have = 1; | 6377 | ed->minmul.have = 1; |
6378 | ed->minmul.w = FROM_INT(1); | 6378 | ed->minmul.w = FROM_INT(1); |
6379 | ed->minmul.h = FROM_INT(1); | 6379 | ed->minmul.h = FROM_INT(1); |
6380 | ed->align_3d.x = FROM_DOUBLE(0.5); | ||
6381 | ed->align_3d.y = FROM_DOUBLE(0.5); | ||
6382 | ed->align_3d.z = FROM_DOUBLE(0.5); | ||
6380 | } | 6383 | } |
6381 | 6384 | ||
6382 | static void | 6385 | static void |
@@ -6870,7 +6873,7 @@ st_collections_group_parts_part_description_limit(void) | |||
6870 | @property | 6873 | @property |
6871 | align | 6874 | align |
6872 | @parameters | 6875 | @parameters |
6873 | [X axis] [Y axis] | 6876 | [X axis] [Y axis] ([Z axis]) |
6874 | @effect | 6877 | @effect |
6875 | When the displayed object's size is smaller (or bigger) than | 6878 | When the displayed object's size is smaller (or bigger) than |
6876 | its container, this property moves it relatively along both | 6879 | its container, this property moves it relatively along both |
@@ -6878,16 +6881,24 @@ st_collections_group_parts_part_description_limit(void) | |||
6878 | the object touching container's respective ones, while @c | 6881 | the object touching container's respective ones, while @c |
6879 | "1.0" stands for right/bottom edges of the object (on | 6882 | "1.0" stands for right/bottom edges of the object (on |
6880 | horizonal/vertical axis, respectively). The default value is | 6883 | horizonal/vertical axis, respectively). The default value is |
6881 | @c "0.5 0.5". | 6884 | @c "0.5 0.5". There is one more parametr for Z axis in case |
6885 | of MESH_NODE. | ||
6882 | @endproperty | 6886 | @endproperty |
6883 | */ | 6887 | */ |
6884 | static void | 6888 | static void |
6885 | st_collections_group_parts_part_description_align(void) | 6889 | st_collections_group_parts_part_description_align(void) |
6886 | { | 6890 | { |
6887 | check_arg_count(2); | 6891 | if (get_arg_count() == 2) |
6888 | 6892 | { | |
6889 | current_desc->align.x = FROM_DOUBLE(parse_float_range(0, 0.0, 1.0)); | 6893 | current_desc->align.x = FROM_DOUBLE(parse_float_range(0, 0.0, 1.0)); |
6890 | current_desc->align.y = FROM_DOUBLE(parse_float_range(1, 0.0, 1.0)); | 6894 | current_desc->align.y = FROM_DOUBLE(parse_float_range(1, 0.0, 1.0)); |
6895 | } | ||
6896 | else if (get_arg_count() == 3) | ||
6897 | { | ||
6898 | current_desc->align_3d.x = FROM_DOUBLE(parse_float_range(0, 0.0, 1.0)); | ||
6899 | current_desc->align_3d.y = FROM_DOUBLE(parse_float_range(1, 0.0, 1.0)); | ||
6900 | current_desc->align_3d.z = FROM_DOUBLE(parse_float_range(2, 0.0, 1.0)); | ||
6901 | } | ||
6891 | } | 6902 | } |
6892 | 6903 | ||
6893 | /** | 6904 | /** |