Commit Graph

413 Commits

Author SHA1 Message Date
Cedric BAIL 8dcb75ad09 edje: simplify and deprecate stub function. 2014-06-07 18:13:39 +02:00
Mykyta Biliavskyi 031216369a edje: Edje_Edit - add parameters to generate source code for part.
Summary:
Add generate source code for absent parameters for part description.
Also use fields from internal structure Edje_Real_Part instead call public API

@feature

Reviewers: cedric, raster, seoz, Hermet

CC: reutskiy.v.v, cedric

Differential Revision: https://phab.enlightenment.org/D960

Signed-off-by: Cedric BAIL <c.bail@partner.samsung.com>
2014-06-06 18:29:17 +02:00
Jérémy Zurcher 82b852850f fix memory leak in Eina_Strbuf usage
buf was not freed on error, and never on success

CID 1194715
2014-06-06 00:13:11 +02:00
Jérémy Zurcher 70092ae92e fix memory leak in Eina_Strbuf usage
buf wasn't freed on success neighter on
edje_edit_image_compression_type_get(...) failure

CID 1194716
2014-06-06 00:13:11 +02:00
Vorobiov Vitalii 125bbf67b9 edje: Edje_Edit - add edje_edit_part_cursor_mode functions.
Summary:
Add two main functions
- edje_edit_part_cursor_mode_get
- edje_edit_part_cursor_mode_set
Also support cursor_mode into part's source code generation.

@feature

Reviewers: seoz, Hermet, cedric, raster

CC: reutskiy.v.v, cedric

Differential Revision: https://phab.enlightenment.org/D952

Signed-off-by: Cedric BAIL <c.bail@partner.samsung.com>
2014-06-05 19:43:52 +02:00
Vorobiov Vitalii f587307a94 edje: Edje_Edit - add edje_edit_part_multiline functions.
Summary:
Add two main functions
- edje_edit_part_multiline_get
- edje_edit_part_multiline_set
Also support multiline into part's source code generation.

@feature

Reviewers: seoz, Hermet, cedric, raster

CC: reutskiy.v.v, cedric

Differential Revision: https://phab.enlightenment.org/D951

Signed-off-by: Cedric BAIL <c.bail@partner.samsung.com>
2014-06-05 19:43:07 +02:00
Mykyta Biliavskyi 793cef0d04 edje: Edje_Edit - Improved speed generate source code for program.
Summary:
_edje_generate_source_program gets Edje_Program pointer from _edje_program_get_byname
at start of function,but in body calls public methods for get parameters of programs.
Each of this methods calls _edje_program_get_byname, what make generation of source
whole program is  slow.
Replaced public API calls with using fields of Edje_Program structure.

Reviewers: cedric, raster, seoz, Hermet

Reviewed By: cedric

CC: reutskiy.v.v, cedric

Differential Revision: https://phab.enlightenment.org/D950

Signed-off-by: Cedric BAIL <c.bail@partner.samsung.com>
2014-06-05 19:41:51 +02:00
Maksym Volodin 5cbceec23f edje: Edje_Edit - add edje_edit_group_orientation_set/_get.
Summary:
Set or get orientation for group:
0 for EDJE_ORIENTATION_AUTO, 1 for EDJE_ORIENTATION_LTR, 2 for EDJE_ORIENTATION_RTL.
_get return 0 (AUTO), 1 (LTR), 2(RTL) orientation was setted for the group. -1 if an error occurred.
_set return EINA_TRUE if successful, EINA_FALSE otherwise.

@feature

Reviewers: cedric, raster, seoz, Hermet

CC: reutskiy.v.v, cedric

Differential Revision: https://phab.enlightenment.org/D938

Signed-off-by: Cedric BAIL <c.bail@partner.samsung.com>
2014-06-05 19:38:27 +02:00
Vorobiov Vitalii 5e7a9b1225 edje: Edje_Edit - add edje_edit_part_access functions.
Summary:
Add two main functions
- edje_edit_part_access_get
- edje_edit_part_access_set
Also support access into part's source code generation.

@feature

Reviewers: seoz, Hermet, raster, cedric

CC: reutskiy.v.v, cedric

Differential Revision: https://phab.enlightenment.org/D946

Signed-off-by: Cedric BAIL <c.bail@partner.samsung.com>
2014-06-04 20:08:32 +02:00
Vorobiov Vitalii 30885daafa edje: Edje_Edit - add edje_edit_part_precide_is_inside functions.
Summary:
Add two main functions
- edje_edit_part_precise_is_inside_get
- edje_edit_part_precise_is_inside_set
Also support precise_is_inside into part's source code generation.

@feature

Reviewers: cedric, seoz, Hermet, raster

CC: reutskiy.v.v, cedric

Differential Revision: https://phab.enlightenment.org/D945

Signed-off-by: Cedric BAIL <c.bail@partner.samsung.com>
2014-06-04 20:02:56 +02:00
Andrii Kroitor 184720bf16 edje: Edje_Edit - add getters and setters for source2-source6 TEXTBLOCK properties
Reviewers: cedric, raster, seoz, Hermet

CC: reutskiy.v.v, cedric

Differential Revision: https://phab.enlightenment.org/D943

Signed-off-by: Cedric BAIL <c.bail@partner.samsung.com>
2014-06-04 19:57:13 +02:00
Vorobiov Vitalii bebcc49bd0 edje: Edje_Edit - add edje_edit_part_pointer_mode functions.
Summary:
Add two main functions
- edje_edit_part_pointer_mode_get
- edje_edit_part_pointer_mode_set

Also support pointer mode into part's source code generation.
EVAS_OBJECT_POINTER_MODE_AUTOGRAB is default value,
so generation won't add "AUTOGRAB" into source code if this type of
pointer mode is set.

@feature

Reviewers: cedric, seoz, Hermet, raster

Reviewed By: cedric

CC: reutskiy.v.v, cedric

Differential Revision: https://phab.enlightenment.org/D941

Signed-off-by: Cedric BAIL <c.bail@partner.samsung.com>
2014-06-04 19:45:34 +02:00
Vorobiov Vitalii f1000b5c36 edje: Edje_Edit - add edje_edit_part_copy function that copy parts within whole group.
Summary:
Add ability to copy whole part and create same part but with new name).
This feature also require to slightly remake function edje_edit_state_copy to make
it able to copy state from one part to different one (only for part_copy usage).

@feature

Reviewers: cedric, seoz, raster, Hermet

CC: reutskiy.v.v, cedric

Differential Revision: https://phab.enlightenment.org/D939

Signed-off-by: Cedric BAIL <c.bail@partner.samsung.com>
2014-06-04 19:39:39 +02:00
Andrii Kroitor aec9cf0a3e edje: Edje_Edit - fix edje_edit_part_source_set
Summary:
Fixed edje_edit_part_source_set so that it does not destroy TEXTBLOCK.
Changed type check to switch-case to stress allowed types.

@fix

Reviewers: cedric, raster, seoz, Hermet

Reviewed By: cedric

CC: reutskiy.v.v, cedric

Differential Revision: https://phab.enlightenment.org/D931

Signed-off-by: Cedric BAIL <c.bail@partner.samsung.com>
2014-06-04 19:15:27 +02:00
Igor Gala f0e4cba71c edje: Edje_Edit - add sounds list accessor.
Summary:
make "get" functions for block "sounds" which return
a sounds or tones list (Eina_List *) off the given edje object.
@feature

Reviewers: raster, cedric, seoz, Hermet

Reviewed By: cedric

CC: reutskiy.v.v, cedric

Differential Revision: https://phab.enlightenment.org/D932

Signed-off-by: Cedric BAIL <c.bail@partner.samsung.com>
2014-06-04 00:51:56 +02:00
Maksym Volodin fb89f79b6a edje: Edje_Edit - add new feature edje_edit_image_compression_set.
Summary:
Set compression type for the given image. Has object being edited,
the name of the image and Edje_Edit_Image_Comp(EDJE_EDIT_IMAGE_COMP_RAW,
EDJE_EDIT_IMAGE_COMP_USER, EDJE_EDIT_IMAGE_COMP_COMP,
EDJE_EDIT_IMAGE_COMP_LOSSY[_ETC1]) as in parametrs.
Return EINA_TRUE if successful, EINA_FALSE - otherwise.

Reviewers: cedric, raster, seoz, Hermet

Reviewed By: cedric

CC: reutskiy.v.v, cedric

Differential Revision: https://phab.enlightenment.org/D929

Signed-off-by: Cedric BAIL <c.bail@partner.samsung.com>
2014-06-04 00:51:56 +02:00
Tom Hacohen 0fc3279db9 Efl: Update code to use the new class names generated by eolian. 2014-06-03 11:28:01 +01:00
Mike Blumenkrantz 91bd7fa913 edje should only match swallow visibility if it's actually a group part
fixes visibility of actual swallow parts
2014-05-26 12:25:27 -04:00
Mike Blumenkrantz ceb13556b1 Revert "Revert "recursively hide edje group objects on edje hide""
This reverts commit b8ca758658.
2014-05-26 12:25:07 -04:00
Carsten Haitzler b8ca758658 Revert "recursively hide edje group objects on edje hide"
Unless you like your desktop to look something like:

http://www.enlightenment.org/ss/e-53834e0c0cb3c1.87889787.png

then this commit really needs reverting.

This reverts commit 385326b8e4.
2014-05-26 23:17:33 +09:00
zmike 385326b8e4 recursively hide edje group objects on edje hide
this massively improves edje performance when using groups, which previously would continue calculating their parts even when their parent object was hidden

CPU usage in my test case went from 20-30% to 1%.

@fix
2014-05-26 08:48:00 -04:00
Vorobiov Vitalii cf0ff2ba91 edje: Edje_Edit - fix wrong behaviour on draggable.event processing while deleting parts.
Summary:
the draggable.event field (in edje) is pointing on the id of the part it is assigned to.
The main problem is about deleting parts.
After part being deleted, all other parts (that are below the deleted part) have their id shifted,
but event doesnt shift.

For example,
1) draggable.event at some part pointing at part with id=7,
2) some other part is being deleted
3) part with id=7 have new id now (id=6)
4) draggable.event DOESN'T change it's pointer and still points at part with id=7 (which is now has id=6)
5) if there is no parts with id=7 anymore, then it could give you SEGFAULT someday (or not, depending on luck).

This commit contains next changes:
1) after deleting part, draggable.event also shifts (if required)
2) after deleting part that is being pointed with event by someone, it will remove all event points at it
@fix

Reviewers: cedric, raster, seoz

CC: reutskiy.v.v, cedric

Differential Revision: https://phab.enlightenment.org/D878

Signed-off-by: Cedric Bail <cedric.bail@free.fr>
2014-05-21 06:14:23 +02:00
Stefan Schmidt 9cfb050022 edje_calc: Document some intended fall through cases in switch-case
We share code here for different types. Make a note and also marked them as
false positive in coverity.

CID 1039377, CID 1039376
2014-05-16 15:00:10 +02:00
Carsten Haitzler c3f0a0c59d fix behavior of edje entry to match other toolkit entires
this fixes T1229 in the part about the cursor behavior when you press
updown/left/right when a selection is there. @fix
2014-05-15 17:43:00 +09:00
Jean-Philippe Andre 7bbdb68811 edje_calc: Fix invalid parameters during first calc
In particular, ellipsis is -1 by default in Evas, but at this
point (first layout calc), the parameters used for recalc are
incomplete and ellipsis would then be 0 by default (calloc).

As a consequence, Edje will call ellipsis_set(0) enabling
ellipsis even on objects that force "ellipsis: -1".

Solution: set all the parameters before entering text/tb calc.

I believe the other changes are only color and image padding
and should not affect recalc_single.
2014-05-15 16:07:00 +09:00
Vyacheslav Reutskiy e8c4e99a3c edje/Edje_Edit: _edje_edit_real_part_add init field of Edje_Real_part
Summary:
To correcly display the added pats using the edje edit api, update
init the filds of Edje_Real_Part. Initialize the next filds: type and
typedata. It filds initialized accordingly to Edje_Part_Type value.

@fix

Reviewers: raster, cedric, seoz, Hermet

CC: cedric

Differential Revision: https://phab.enlightenment.org/D854

Signed-off-by: Cedric Bail <cedric.bail@free.fr>
2014-05-14 11:11:47 +02:00
Jean-Philippe Andre 5bf1f0c918 edje_calc: Don't add padding twice to text objects
Text objects declared in Edje will see their padding added twice,
as the Evas_Object_Text itself contains the padding already.

This WILL break some EDC files. It's a bug nonetheless.

Should this be backported?
2014-05-14 14:44:47 +09:00
Jean-Philippe Andre 855c196ae8 edje_text: Remove no-op pad_get
This call to pad_get is useless.
2014-05-14 14:44:47 +09:00
Jean-Philippe Andre 5b28726e0a edje_calc: Update some disabled code so it can compile
Yup, that's basically a no-op but allows other devs to test
the old behaviour of that function as it's still there:
_edje_part_recalc_single_text
2014-05-14 14:44:47 +09:00
Mike Blumenkrantz 894c36ff11 de-elipsis edje
the word is "ellipsis". it's bad enough that we have released misspelled api, but we can at least spell things correctly internally.
2014-05-13 16:20:41 -04:00
Jérémy Zurcher f8c2c57406 do not use EINA_FALSE instead of NULL 2014-05-07 17:45:11 +02:00
zmike 564cd48a24 edje entry no longer selects none with unimplemented ctrl+w key press 2014-05-06 09:58:11 -04:00
zmike 8ae4810e65 edje entry no longer prints control codes
this has been an annoyance for way too long which has required various hacks to suppress
2014-05-06 09:58:11 -04:00
Mike Blumenkrantz e6f0deca27 edje should only apply "calculated" text size if that size exists
fixes text.source sizing when size is not specified in child part
2014-04-25 10:52:15 -04:00
Mike Blumenkrantz 5f376fde36 edje now correctly supports text.source and text.text_source for swallowed parts
fix T1186
2014-04-25 10:52:15 -04:00
Mike Blumenkrantz 939f2eea7f edje now has the group.script_recursion flag for permitting unsafe embryo recursion
this is enabled for all scripts within a group, and it should only be used if you:

1) know what you are doing

2) know why this is unsafe (T905)

@feature
2014-04-25 10:52:15 -04:00
Mike Blumenkrantz e54bb78a3e edje emit refactored to streamline emit programs with targets 2014-04-25 10:52:15 -04:00
Mike Blumenkrantz c8cc776fb1 edje_cc now supports targets for SIGNAL_EMIT actions
this is much more intuitive than somehow knowing you're supposed to add a ':' between part:signal

@feature
2014-04-25 10:52:15 -04:00
se.osadchy 709c1d86c0 Edje/Edje_edit: corrected type of input parameter for offset value
Summary: Input type for offset value must be Integer in the "edje_edit_rel1(2)_offset_x(y)_set" functions

Reviewers: cedric, Hermet

CC: cedric, Hermet, raster

Differential Revision: https://phab.enlightenment.org/D562
2014-04-25 11:19:58 +09:00
Mike Blumenkrantz 7355f67c1f revert edje ellipsis doc changes
if we're reverting functional changes, then it's probably a good idea to revert the accompanying documentation
2014-04-23 09:28:23 -04:00
Yossi Kantor d7ff6085c2 Eolian: Legacy integration of Edje 2014-04-23 15:44:17 +03:00
Mike Blumenkrantz adcc323291 edje: the ellipsis fuckup preservation commit.
what a huge, colossal cock-up of a clusterfuck. it's a good thing nobody ever uses ellipses or edje. otherwise we'd probably get complaints about this kind of thing.
2014-04-22 20:21:46 -04:00
Mike Blumenkrantz c2ced46d2d edje now correctly forces ellipsis setting on text parts
this should always be applied, not just when min_x isn't set; failure to do so causes erroneous ellipsizing in some cases where it should be explicitly prohibited

@fix
2014-04-22 19:18:45 -04:00
Mike Blumenkrantz cefebd4921 edje now alerts the user to its failure when running recursive embryo programs 2014-04-21 10:05:26 -04:00
Mike Blumenkrantz ab4ab7e73a typo from edje program info commit 2014-04-20 23:32:31 -04:00
Mike Blumenkrantz 845008da8c edje programs now provide slightly more verbose errors when disabling due to recursion limits 2014-04-20 23:30:13 -04:00
Jean-Philippe Andre f6eae69eb2 Edje: Use LOSSY_ETC1 instead of LOSSY
Add a new flag in EDC files to specify ETC1 compression
should be enabled. It follows the same rules as the
current LOSSY flag for JPEG compression.

@feature
2014-04-18 16:50:01 +09:00
Cedric Bail 7ec6a9afee edje: let's call this function before returning.
CID 1194718.
2014-04-17 21:29:31 +02:00
Andrii Kroitor c17d08d2ab edje_edit: image_del fixed
Summary: fixed segfault on broken refs in edje object

Reviewers: cedric, seoz, raster

CC: reutskiy.v.v, cedric

Differential Revision: https://phab.enlightenment.org/D759

Signed-off-by: Cedric Bail <cedric.bail@free.fr>
2014-04-17 19:40:36 +02:00
Carsten Haitzler 9fb0640d57 Revert "eo null object complaints - silence."
This reverts commit 1678d272af.

... actually... on second thought... i think eo just needs to sensibly
handle null objects.
2014-04-16 12:27:40 +09:00