Commit Graph

28235 Commits

Author SHA1 Message Date
subhransu mohanty e2663ba8f3 edje/style/optimization: Enable lazy computaion of styles.
Summary:
As user request for the evas_textblock_style through _edje_textblock_style_get()
api and that api implements lazy computation of the styles. By just marking the
style dirty (stl->cache=false) will be enough. no need to calculate the style
computaion at that time.

Reviewers: Hermet, ali.alzyod, kimcinoo, woohyun

Reviewed By: Hermet

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9776
2019-08-29 14:32:28 +09:00
subhransu mohanty 5f70cacd92 edje/textblock: Added edje_textblock_style_get() api.
Summary:
Now all textblock_style functionality are wrapped under api
for easy of optimization. so going forward no one should directly
acess the styles from the File . the styles should be acesses by
the internal api's provided by edje_textblock_style.

Reviewers: Hermet, ali.alzyod, woohyun, kimcinoo

Reviewed By: kimcinoo

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9774
2019-08-29 11:35:24 +09:00
SangHyeon Jade Lee 14f9782a81 efl_ui : add efl.extra part as layout swallow part list.
Summary:
efl.extra part is extra part of the layout swallow,
which can be generally used on overall layout object.
To be supported layout part infrastructures,
add efl.extra on layout_swallow_part[] list.

Depends on D9233

Reviewers: cedric, bu5hm4n, zmike, segfaultxavi

Reviewed By: bu5hm4n

Subscribers: #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9316
2019-08-29 10:21:39 +09:00
WooHyun Jung cfc1d3d38b efl_object: set @beta to name_find
This property should not be used by application developers
with current status.
There is no way to trace child objects from parents, because
many codes are internally calling efl_parent_set.

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9768
2019-08-28 18:08:32 +02:00
Christopher Michael 27a1ec507a tests/ecore_wl2: Skip aux_hints_supported test if not run in Enlightenment
This test will fail when run in all situations (weston, command line,
etc) except when run under Enlightenment, so add a small env check so
that it can be skipped if we are not running E.

ref T8016
2019-08-28 07:59:13 -04:00
Xavi Artigas aa4c59b0de mono-docs: Remove useless semicolon from doc comments 2019-08-28 13:42:28 +02:00
Xavi Artigas d98c2a5c3e Efl.Pack.Layout docs: remove refs to protected methods from public methods 2019-08-28 11:18:06 +02:00
Lauro Moura 3edffc0c73 pyolian: Update after event and binbuf keywords
Reviewers: q66, DaveMDS

Reviewed By: q66

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9626
2019-08-28 10:21:18 +02:00
Marcel Hollerbach f951ba5076 eolian_aux: this must be recursive
Summary:
in order to get all callables, this must be recursive, otherwise deeper
callables are forgotten.

Reviewers: q66

Reviewed By: q66

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9421
2019-08-28 10:20:49 +02:00
subhransu mohanty 4b511671de edje: refactor _edje_object_file_set_internal() part 2.
Summary:
- split functionality into smaller helper class
  _edje_process_colorclass() , _edje_process_sizeclass() and
 _edje_process_physics() for easy redability and maintenance.

Reviewers: Hermet, zmike

Reviewed By: Hermet

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9764
2019-08-28 16:23:55 +09:00
junsu choi ce62dbc1c0 efl_canvas_vg_object/evas_object_vg: Change to legacy naming rule.
Summary:
   Enum and object decleared in efl_canvas_vg_object_eo.legacy.*
   use Efl_Canvas_Vg_* nameing rule.
   This skips the definition of type declared in Efl.Canvas.Vg.Object class.
   So change these to legacy names.

Test Plan: N/A

Reviewers: Hermet, smohanty, kimcinoo

Reviewed By: Hermet

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9718
2019-08-28 14:09:13 +09:00
subhransu mohanty d7d9ed856f edje/style: remove dead code.
Summary: leftover from last refactoring.

Reviewers: Hermet, ali.alzyod

Reviewed By: Hermet

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9763
2019-08-28 14:07:05 +09:00
subhransu mohanty 4b2403d80c edje: refactor _edje_object_file_set_internal() function
Summary:
move the file related function to edje_cache so that code
is easy to read and maintainable and we don't have to do unnecessary
stuff for each edje object creation.

Reviewers: Hermet

Reviewed By: Hermet

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9761
2019-08-28 13:18:42 +09:00
Marcel Hollerbach 53739890ce efl_ui_position_manager: refactor data access
before data access has been a property on
Efl.Ui.Position_Manager.Entity. However, we are not sure how stable all
this will be, and maybe we have the demand to change that in future, in
order to allow more high-performance item passing here.

Additionally, this patch addresses a few lectures learned from the past,
that includes:
- direct group header filling.
- direct group sizing
- difference between size for caching, and size for displaying
- Have a end_id which is the maximum of id that is filled.

ref T8179

Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Differential Revision: https://phab.enlightenment.org/D9754
2019-08-27 17:47:54 +02:00
Xavi Artigas 47547ff088 efl_ui_range_display: Update docs 2019-08-27 16:38:12 +02:00
WooHyun Jung 5636bb8b0b efl_ui_slider: refactor for better data flow and code readability
1. efl_ui_range_value_set only sets value
2. remove internal eo functions (such as xxx_knob, val_fetch, and val_set)
3. make access_value_and_text works correctly

@ref T7893

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9720
2019-08-27 15:35:01 +02:00
Shinwoo Kim cfc0d4866c efl_ui_widget: keep backward compatibility
It was possilbe to add an image with improper parent object before aa2d94f and
56752e0. This patch makes it possible. Sure there are error messages when user
adds an image object using non widget object as below but you can see image.

ERR<28822>:elementary ../src/lib/elementary/efl_ui_widget.c:4801 _efl_ui_widget_efl_object_constructor() You passed a wrong parent parameter (0x400000007ced (null)). Elementary widget's parent should be an elementary widget.
ERR<28822>:elementary ../src/lib/elementary/efl_ui_widget.c:4803 _efl_ui_widget_efl_object_constructor() No widget data for object 0x400000007ced ((null))
ERR<28822>:eina_safety ../src/lib/elementary/efl_ui_win.c:9450 efl_ui_win_shared_data_get() safety check failed: pd == NULL
ERR<28822>:eo ../src/lib/eo/eo.c:579 _efl_object_call_resolve() in src/lib/elementary/efl_ui_widget.eo.c:256: func 'efl_ui_widget_sub_object_add' (698) could not be resolved for class 'Evas.Canvas'.

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9747
2019-08-27 15:02:32 +02:00
subhransu mohanty 05ea1854a9 edje/load: pass Edje_File instead of Edje to _edje_extract_mo_files()
Summary:
Why :
1. The function operates on the Edje_File level not on Edje object
   level , so express it clearly in the function argument.
2. if its clear that this function works on file level then
   this should be called when the theme file loaded for the first time
   not on every Edje object creation.

Reviewers: Hermet, zmike, raster, cedric

Reviewed By: zmike

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9753
2019-08-27 08:04:43 -04:00
Shinwoo Kim e22e7481b1 efl_ui_bg: make legacy bg use legacy image
Summary:
The legacy bg object has added a non-legacy image object internally.
The non-legacy image object caused an unexpected inconsistent behavior
and result in common widget logic because it is not true for the line
using elm_widget_is_legacy function in efl_ui_widget.

Reviewers: woohyun, Jaehyun_Cho, SanghyeonLee, YOhoho, Hermet, jsuya, devilhorns, zmike

Reviewed By: zmike

Subscribers: devilhorns, cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9746
2019-08-27 07:49:18 -04:00
subhransu mohanty fcc235b329 edje/optimization: replace eina_list with eina_array.
Summary:
We were creating 3 eina_list and destroying inside a for loop.
replace that with creating a single eina_array at start and use
eina_array_clean() function ro reuse the array.

Reviewers: Hermet, zmike, cedric, raster

Reviewed By: zmike

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9745
2019-08-27 07:42:14 -04:00
Wonki Kim 979757c845 eina_vpath: add null checking logic on vpath_resolve api
Summary:
there is a patch that add vpath_resolve() call before eina_file_open()
because `path` arg could be NULL, the patch kills some applications.
this patch add null checking logic on vpath_resolve api

Reviewers: bu5hm4n, cedric, Hermet

Reviewed By: Hermet

Subscribers: #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9748
2019-08-27 20:25:02 +09:00
Wonki Kim 4c489d5a2e eina_list: fix to check a null argument
Summary:
data should be checked regardless of EINA_MAGIC define,
because it is dereferenced in the following logic.

Reviewers: cedric, bu5hm4n, Hermet

Reviewed By: Hermet

Subscribers: #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9750
2019-08-27 20:23:29 +09:00
Yeongjong Lee 9c52484caf efl_pack_table: rename table_position to cell_column, cell_row
Summary:
Rename ambiguous `table_position` property. it is actually related to child
column, row.

ref T7900

Reviewers: segfaultxavi, zmike

Reviewed By: segfaultxavi

Subscribers: cedric, #reviewers, #committers

Tags: #efl_api

Maniphest Tasks: T7900

Differential Revision: https://phab.enlightenment.org/D9611
2019-08-27 12:57:35 +02:00
Hermet Park 4d84794f1c evas events: fix corrupted mouse events behavior on mapped object.
Summary:
This fixes an issue that inproper mapped object in/out events triggering.
The previous mouse event logic didn't care the transformed cooridates
if a child object belongs to a mapped parents in its hierarchy.

When checking the object boundary for the child on mouse moving,
it must consider if the child were belonged to the mapped parent space.

Plus, this improves the coordiates to be transformed properly for the prev cooridates,
So that user could compare cur/prev cooridnates properly in the same space
in its events callbacks.

@fix

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9751
2019-08-27 19:49:42 +09:00
Xavi Artigas ce2fcda1e2 Efl.Gfx.Image docs: whitespace and wording. 2019-08-26 17:25:10 +02:00
Carsten Haitzler bbb2dc6fad thread example - add exit with parent flags 2019-08-26 14:28:44 +01:00
Carsten Haitzler d4c123d360 efl loops/threads - by defaylt tasks (exe and threads) exit with parent
this also defers parent exit until all children exit and will wait
around looping until those children do report back with exited status
etc. - this meay mean some hangs for badly written/blocking apps that
have efl thrrads that refuse to exit. a slight policy change also
means that by default thread objects also get auto-deleted whent hey
report back exit codes etc. which leads to less code if you don't care
about this.
2019-08-26 14:19:30 +01:00
Marcel Hollerbach 634ebfeaf1 efl_ui_collection: honor desktop vs. touch setting of elm config
with this commit we do desktop-like selection on desktop systems:
- Multiselect with CTRL pressed
- Normal single selection if no CTRL is pressed
on touch devices this is simple on/off selection:
- click to add it to multiselect
- click to remote it from mutliselect

ref T8057

Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9664
2019-08-26 14:42:54 +02:00
Marcel Hollerbach fea6dc6a55 efl_input_clickable: add a flag for showing user interaction
this flag can be used to indicate that a user activly interacted with
this widget.

ref T7893

Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9663
2019-08-26 14:42:52 +02:00
Marcel Hollerbach 43edd17f41 efl_ui_single_selectable: add properties and events
this commit adds 2 new features, a new event and a new property

The fallback property is usefull if you want to have a selection that always falls back
to some preconfigured things.
As a usecase, think about a list of languges where you can select the
languages you want to have. When everything is deselected, the list will
simply fallback to the preconfigured element (for example the language
configured before)

The event is annoncing that there was a change to the selection. The
event is allowed to be defered, it will be emitted once for a range of
selection elements that happened during one loop iteration. This is
usefull if you are interested in a general selection where you want to
know that we changed from a specific set of selected element to another
set of elements, without monitoring every selectable in the widget.

ref T8057

Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9662
2019-08-26 14:42:50 +02:00
Marcel Hollerbach 1c1c3685fe suite_helpers: punsh some sanity into function names
Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Differential Revision: https://phab.enlightenment.org/D9661
2019-08-26 14:42:49 +02:00
Marcel Hollerbach 35f9fc26e3 efl_ui_multi_selectable: add APIs for selecting
this can be used to select / unselect a range or all selectables in a
container. The range selectable APIs do not have a strong ordering on a
and b, b does not have to come after a.

ref T8057

Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Differential Revision: https://phab.enlightenment.org/D9660
2019-08-26 14:42:48 +02:00
Marcel Hollerbach c467dc6e81 efl_ui_item: add keybindings for selecting changes
This started as a small commit, when pressing enter -> set the item as
selected.
However, it was a bit more complex, it seems that there was never config
update code to copy bindings into the user profile. Which lead to the
fact that you are missing a lot of keyboard related features if you
havnt wiped your config in the last 1-2 years. For me keybindings for
Efl.Ui.Scroller Tab_Bar Image_Zoomable (Item) have been missing and were
never inserted. WHich is a problem for a user just constantly updating.

For now i created a function that copies over the bindings from the
system config, and they are merged into the user config. Intentional
leaving our of keybinding structs for a user-config will result in them
beeing merged again on the next config update. If you want to get rid of
key bindings as a user you can just keep the empty struct, which is the
signal for "i know what i am doing, i do not want to have them". The
problem that the system config is partly invalidated (due to moving the
key bindings struct to the user config), is fixed due to the fact that
the config is reloaded after that.

This function should be called everytime someone updates the config in
regards of the keybindings.

Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Differential Revision: https://phab.enlightenment.org/D9723
2019-08-26 14:42:47 +02:00
Marcel Hollerbach c947485bd0 efl_ui_item: only fetch multiselection state if this is relevant
there are cases where the container does only implement single
selection, when then just asume implicitly single mode here.

Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Differential Revision: https://phab.enlightenment.org/D9722
2019-08-26 14:42:46 +02:00
subhransu mohanty 02b63b8260 edje/cache: Refactor _edje_cache_file_coll_open()
Summary:
This function does lot of things
- can be called only to load the file (by passing coll as null)
- can be called to load both file and open the collection from the file.
- handles the file_cache logic
- handles fixing the collection after reading from file.

this patch is targeting to split the responsibility to
smaller function for easy maintenance and code readability.

future patch to follow for splitting the file opening and collection
opening to two different function.

Reviewers: Hermet, raster, cedric, zmike

Reviewed By: zmike

Subscribers: zmike, cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9715
2019-08-26 08:31:08 -04:00
sub.mohanty@samsung.com 5bd95c9850 eina/array: added eina_array_find() api to eina_array.
Summary: updated test suite for testing the api.

Reviewers: zmike, Hermet, cedric, segfaultxavi

Reviewed By: zmike, segfaultxavi

Subscribers: segfaultxavi, ProhtMeyhet, cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9734
2019-08-26 08:31:08 -04:00
Hermet Park c6b52d4f09 canvas map: remove logically dead code.
the value was overflow, reduce its size.
2019-08-26 19:30:06 +09:00
Hermet Park 42a7aae58c canvas map: code refactoring.
remove dead code that unreachable looping.
2019-08-26 19:23:43 +09:00
junsu choi 03e12fe148 spinner_cxx_example: Fix use wrong api
Summary:
de18371 changes cause build errors. (D9707)
this is a patch to fix it.

Test Plan: N/A

Reviewers: woohyun, bu5hm4n

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9738
2019-08-26 16:26:08 +09:00
Taehyub Kim d53e46d76f efl_ui_format: add null checking codes for eina_strftime in _do_format_string function
Summary: efl_ui_format: add null checking codes for eina_strftime in _do_format_string function

Reviewers: kimcinoo

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9735
2019-08-26 14:52:28 +09:00
subhransu mohanty e742bf67e4 edje/style: optimize style_update function.
Summary:
If the style is readonly then we know for sure it dosen't have any text_class/color_class.
If a style has text_class tag then call update only once not for each text_class tag it has.

Reviewers: ali.alzyod, Hermet, cedric, raster

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9641
2019-08-26 14:22:43 +09:00
Marcel Hollerbach de183719b3 efl_ui_spin_button: rename editable to direct_text_input
Summary: as suggested in T8097.

Reviewers: cedric, zmike, woohyun

Reviewed By: woohyun

Subscribers: #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9707
2019-08-26 14:21:10 +09:00
Carsten Haitzler 2f534b0256 efreet - make efreet launch timeout configurable by env var
also report as an ERR explicitly if its a timeout.
2019-08-25 11:24:54 +01:00
Carsten Haitzler 9f9cfe65a6 evas - scalecache - be a bit paranoid about images being set to null
this may address a bug, but i'm not sure as i can't reproduce it.
suffice to say it smells like a possible leak.
2019-08-25 10:28:08 +01:00
Carsten Haitzler 443677c7f9 scalecache - handle possible use after free with sci still in list
the sci may still be in the list then we free it because sci->im is
NULL .. it may always have been null. this should guard against that
and fix it.

@fix
2019-08-24 15:21:42 +01:00
Lauro Moura e7510f6770 elm: Fix Scrollable_Content namespace
Summary:
Efl.Ui.Widget is already a class.

Required by the C# bindings.

Reviewers: cedric, zmike

Reviewed By: zmike

Subscribers: #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9733
2019-08-23 15:03:31 -04:00
Yeongjong Lee 471032d69d efl_canvas_text: remove unused Text_Style eo struct
Summary: `Efl.Canvas.Text_Style` is not used in eo world.

Reviewers: zmike, tasn

Reviewed By: tasn

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9565
2019-08-23 15:03:31 -04:00
Carsten Haitzler 8145d90ce7 edje signal matches - try number 3 to try plug all the holes
i found some more cases where the hash may change, so del and add from
the hash when this happens...

and... i found a nasty. _edje_signal_match_key_cmp compared pointers
like:

int return = ptr_a - ptr_b;

what happens if .... ptr_a and ptr_b are more than 2^31 (2gb) apart?
overflow (or underflow) and we return the wrong thing. i suspect this
is part of the problem and why my has remove/adds have not been
working because ... i suspect that maybe the hash dels have not been
finding things. i can't be sure right now, but it is an obvious
problem that i fixed by just doing if's and returning -1 or 1. also i
found a double-add or overwrite int he hash - when we shuffled with
_edje_signal_callback_move_last the matches CAN match exactly
something already in the hash thus adding it in will conflict with
what is already there as keys match. handle this cvase now and i have
seen segv's go away for now.

@fix
2019-08-23 19:36:42 +01:00
Carsten Haitzler a7273fc864 edje signal - let's not crash if something odd happens
better we dont just crash but err log it which can be set to abort
anyway.

@fix
2019-08-23 19:36:42 +01:00
Mike Blumenkrantz 42d10b84be elm/config: always use default profile with EFL_RUN_IN_TREE
Summary:
if this env var is set, we're probably running unit tests or something
and we should ignore ELM_PROFILE

Reviewers: cedric

Reviewed By: cedric

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9701
2019-08-23 13:38:33 -04:00
Mike Blumenkrantz 2cd4d67109 tests/edje: disable efreetd and ecore system modules in unit tests
Summary: these cause tests to take up to 100x longer

Reviewers: bu5hm4n, cedric

Reviewed By: bu5hm4n, cedric

Subscribers: cedric, #reviewers, #committers

Tags: #efl_tests

Differential Revision: https://phab.enlightenment.org/D9702
2019-08-23 13:38:33 -04:00
Yeongjong Lee b60e949fb6 efl_ui_table: remove inlist items in EINA_INLIST_FREE macro
Summary:
Check the EINA_INLIST_FREE document
```
in eina_inlist.h

NOTE: it is the duty of the body loop to properly remove the item from the
inlist and free it. This function will turn into a infinite loop if you
don't remove all items from the list.
```

This will avoid infinite loop when Efl.Ui.Table is invalidated.

ref T8145

Test Plan: See the test file in T8145

Reviewers: brunobelo, Jaehyun_Cho, zmike

Reviewed By: zmike

Subscribers: zmike, cedric, #reviewers, #committers

Tags: #efl

Maniphest Tasks: T8145

Differential Revision: https://phab.enlightenment.org/D9699
2019-08-23 13:38:33 -04:00
Mike Blumenkrantz e2b6e18577 efl_ui/scroll_util: block scroll calc tsunamis caused by repeat signal emits
Summary:
the 'efl,action,scroll' signal should only occur (at most) one time during
each signal process loop, so restrict it for this case

furthermore, the bar pos_changed and size_changed callbacks are always
triggered sequentially, so there's no need to emit the signal in both
callbacks

this fixes infinite edje embryo errors and massively improves scroll perf

Reviewers: cedric

Reviewed By: cedric

Subscribers: cedric, #reviewers, #committers

Tags: #efl_widgets

Differential Revision: https://phab.enlightenment.org/D9681
2019-08-23 13:38:33 -04:00
Mike Blumenkrantz 81962dfa1b tests/eio: unlink tmpfiles after tests
Summary:
my tmpdir is full of thousands of these things
Depends on D9710

Reviewers: cedric

Reviewed By: cedric

Subscribers: #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9711
2019-08-23 13:38:33 -04:00
Mike Blumenkrantz f9bd541e37 tests/eio: verify that the model monitor test's file is successfully created
Summary:
if this fails then the test will hang until timeout, so catch it earlier
Depends on D9709

Reviewers: cedric

Reviewed By: cedric

Subscribers: #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9710
2019-08-23 13:38:33 -04:00
Mike Blumenkrantz 42704eccc7 eio/poll: avoid ever dereferencing the backend's parent in a thread
Summary:
when a monitor is destroyed, it unconditionally and immediately deletes
the monitor struct. this means that as soon as the monitor is dead, the
backend must never access the parent pointer again if its lifetime exceeds
the lifetime of the monitor (such as in threads)

the only member of the monitor data used by the fallback monitor is the
monitor path, so we can just copy it to the fallback data to avoid ever
needing to dereference this pointer

fixes reliability issues with efl sentry unit tests

@fix

Depends on D9708

Reviewers: cedric

Reviewed By: cedric

Subscribers: #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9709
2019-08-23 13:38:33 -04:00
Mike Blumenkrantz 0b8605c35d efl/io: fix race condition with child model deletion
Summary:
if an event is emitted for a child that is added to the model during a
call to _efl_io_model_children_list(), it's possible that this child
will never be detected by the model's monitor/sentry if it is deleted
before the monitor can detect it, which means there will never be a
corresponding eio event emitted

in this case, ensure that we manually remove this child from the model
since we know we've just deleted it

this fixes reliability issues with efl io model monitor unit test

@fix

Reviewers: cedric

Reviewed By: cedric

Subscribers: #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9708
2019-08-23 13:38:32 -04:00
Yeongjong Lee 6b3d430f12 efl_ui_scrollbar_direction: replace with efl_ui_layout_orientation
Summary: ref T7924, T7884

Reviewers: segfaultxavi, bu5hm4n

Subscribers: zmike, cedric, #reviewers, #committers

Tags: #efl

Maniphest Tasks: T7924, T7884

Differential Revision: https://phab.enlightenment.org/D9612
2019-08-23 13:38:32 -04:00
Yeongjong Lee 17b0a2634c csharp: add legacy eo in mono blacklist
Summary: It is unnecessary to generate cs file of legacy class.

Test Plan: meson setup -Dbindings=mono,cxx

Reviewers: felipealmeida, lauromoura

Reviewed By: lauromoura

Subscribers: cedric, #reviewers, #committers, woohyun

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9638
2019-08-23 14:33:20 -03:00
Felipe Magno de Almeida 2f0a20b688 eolian-mono: Add support for partial classes
Summary:
Add the -p command to eolian to create a class as a partial
class. Create a list in meson build of Eolian files that should be
built with partial classes.

This allows creating more specific method overloads for C#, manually,
by generating the class as partial and adding in manual binding the
partial class with the new methods and properties.

T8034

Reviewers: segfaultxavi, lauromoura, woohyun, Jaehyun_Cho

Reviewed By: lauromoura

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9690
2019-08-23 14:28:00 -03:00
Lauro Moura b4a6444473 csharp: Only build extension methods for beta
Reviewers: felipealmeida, SanghyeonLee

Reviewed By: SanghyeonLee

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9714
2019-08-23 14:26:24 -03:00
Lauro Moura f3d9238e15 csharp: Add bindable factory parts support
Summary:
This commit makes parts that implement `Efl.IContent` use BindFactory
instead of property binding.

```
var factory = new Efl.Ui.ItemFactory<Efl.Ui.ListDefaultItem>();
var iconFactory = new Efl.Ui.ImageFactory(null);
iconFactory.PropertyBind("filename", "modelProperty");
factory.IconPart().BindFactory(iconFactory);
```

Fixes T7628

Reviewers: cedric, felipealmeida, SanghyeonLee

Reviewed By: felipealmeida

Tags: #efl

Maniphest Tasks: T7628

Differential Revision: https://phab.enlightenment.org/D9653
2019-08-23 14:17:44 -03:00
Felipe Magno de Almeida 1aa05ab41b eolian-mono: Add support for multi-value properties with tuples
Summary: T8133

Reviewers: woohyun, segfaultxavi, felipealmeida

Reviewed By: felipealmeida

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9577
2019-08-23 14:07:09 -03:00
junsu choi 8aae656b80 slider_cxx_example: Fix use wrong api
Summary:
   d50fdc0, e84ecd95 changes cause build errors.
   this is a patch to fix it.

Test Plan: N/A

Reviewers: zmike, Jaehyun_Cho

Reviewed By: Jaehyun_Cho

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9721
2019-08-23 18:08:39 +09:00
Mike Blumenkrantz 4acb83c8d9 efl_ui/image: explicitly mark 'drop' event @beta
this should probably be removed altogether but until dnd exists ensure
that this doesn't accidentally get released

ref T7873

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9705
2019-08-23 07:33:59 +02:00
Mike Blumenkrantz e84ecd9552 efl_ui/image: scalable -> efl.gfx.image::can_up/downscale
this removes the property from the image class to use the properties
from the interface

ref T7873

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9704
2019-08-23 07:33:58 +02:00
Mike Blumenkrantz d50fdce4d3 efl/gfx.image: add can_upscale and can_downscale properties
these are more granular properties which allow blocking of image
upscaling and/or downscaling regardless of scale hint

ref T7875

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9703
2019-08-23 07:33:57 +02:00
Mike Blumenkrantz ad0c805545 efl/gfx: redo image scale_type enum
this is ideally a bit more clear and flexible than the previous enum names

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9691
2019-08-23 07:33:56 +02:00
Mike Blumenkrantz 81183e0423 efl_ui/image: implement efl.gfx.arrangement content_align to replace align prop
this is effectively the same thing. no uses of this functionality exist anywhere

ref T7873

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9688
2019-08-23 07:33:55 +02:00
Mike Blumenkrantz 7442ae7092 efl_ui/image: remove geometry from internal struct, clean up geometry methods
these methods exist only to trigger efl_canvas_group_change on geometry
change and apply image sizing policies, there's no need to duplicate existing
functionality as well

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9687
2019-08-23 07:33:54 +02:00
Mike Blumenkrantz 28fff16739 efl_ui/image: add group_calc implementation, use deferred calc for sizing
this changes image internals to use the more standardized group_calc method
of sizing and causes all previous operations on the image which would have
resulted in an immediate recalc to instead defer the calc until the
group_calc function is called

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9686
2019-08-23 07:33:53 +02:00
Mike Blumenkrantz 01fc7eae35 elm: fix macro for group_calc function naming
this should be efl_canvas_group_group_calculate to match eolian function
naming

no functional changes

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9685
2019-08-23 07:33:52 +02:00
Mike Blumenkrantz f64a0966dc efl_ui/popup: remove text_alert class
this can now be done by simply calling
efl_ui_widget_scrollable_content_scrollable_text_set on an alert popup

tests have been adjusted for this

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9677
2019-08-23 07:33:51 +02:00
Mike Blumenkrantz 1d2d15bbf8 efl_ui/scrollable_content: add scrollable_text property
this creates a label with a scroller and manages sizing calcs

note that efl_ui_text cannot be used here because its sizing calc model
is incompatible with efl

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9676
2019-08-23 07:33:50 +02:00
Mike Blumenkrantz 9d8735caf7 efl_ui/popup: remove scroll_alert class
this can now be done by simply calling efl_ui_widget_scrollable_content_set
on an alert popup

tests have been adjusted for this

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9675
2019-08-23 07:33:49 +02:00
Mike Blumenkrantz 1a517b4c2d efl_ui: add scrollable_content mixin
this allows content to be set with a scroller that automatically handles
its own sizing calcs so that widgets/apps don't have to

@feature

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9674
2019-08-23 07:33:48 +02:00
Jaehyun Cho d4d1826b47 efl_ui_spotlight: add null check for manager stack data
Like other functions, null check for manager stack data is added before
referencing manager stack data.
2019-08-23 13:51:44 +09:00
Jaehyun Cho a3b3f8d95a test_ui_spotlight: remove dead default in switch 2019-08-23 13:51:19 +09:00
subhransu mohanty 1e079a7568 edje/style: Enable lazy computaion of styles.
Summary:
Instead of updating all the styles in an Edje_File just mark them
dirty so that subsequent  call to style will recompute the new style before
returning the style.

Reviewers: ali.alzyod, Hermet, raster, cedric

Reviewed By: cedric

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9697
2019-08-23 11:11:05 +09:00
subhransu mohanty 862a460e7f ecore_con/memleak: due to checking refcount using postfix decrement operator
Reviewers: Hermet, raster, cedric

Reviewed By: Hermet

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9716
2019-08-23 11:09:42 +09:00
Carsten Haitzler 239ebbbc2c emotion - webcam fix deletion of webcam still left in webcam list
we may destroy webcams but leave them in the list. this fixes that by
removing them from our global list when we do unref to 0.

@fix
2019-08-22 19:53:03 +01:00
Carsten Haitzler 456419f468 edje - signal callback matches/patterns try fix number 2
so i think there was also another bug as i saw this again now. this
should hopefully plug the signal/mtach memory bugs now by removing
and adding back to hash as the hash key relies on the memory addresses
of signal/src in the matches array which change on realloc. a bit
brute-forceey but... better than crashes.

@fix
2019-08-22 19:53:03 +01:00
WooHyun Jung ebb685aae1 efl_ui_slider_interval: cut off the dependency with efl_ui_slider
efl_ui_slider_interval is totally different widget from efl_ui_slider.
Now, it extends efl_ui_layout_base and implements all efl_ui_slider's
functionalities by its own.
This class needs to be marked to @beta till reviewing whole class
definitions again.

@ref T7893

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9696
2019-08-22 15:36:38 +02:00
subhransu mohanty 10b2f65e60 elm/config: avoid unnecessary elm cache flush
Summary:
in config_apply() we load the deafult theme and then
elm_recache() just throws it away.

so just move it before config_apply for time being.
We need to revisit to check if we really need that elm_recache() in that
function or not.

Reviewers: Hermet, raster, cedric, zmike

Reviewed By: zmike

Subscribers: zmike, cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9700
2019-08-22 08:14:14 -04:00
Yeongjong Lee e8a32d72c6 efl_ui_widget: correct the comparison parameter in scroll_freeze_pop
Summary:
It is copy/paste error.
See also, e7986cc646

Reviewers: bu5hm4n, zmike

Reviewed By: zmike

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9695
2019-08-22 07:17:03 -04:00
junsu choi 167e3c4c29 edje_cc: Fix always true condition.
Summary:
   The condition at 742 line is always true. So I fix it.
   If action is not ACTION_STOP or ACTION_TYPE_SCRIPT, go to continue.

Test Plan: N/A

Reviewers: bu5hm4n, Hermet, zmike

Reviewed By: zmike

Subscribers: zmike, cedric, #reviewers, kimcinoo, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9667
2019-08-22 07:15:30 -04:00
subhransu mohanty cce73a2b4b edje/style: fix memory leak because of typo.
Summary:
We already have a escaped string for the font_source so
this code is unnecessary.

Reviewers: Hermet

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9698
2019-08-22 14:22:23 +09:00
Hermet Park b19ea5cf53 examples: shut up edc build warnings.
This might not be proper fix (at least they are fine by me),
if these textblocks actually have something wrong sizing.
2019-08-22 14:03:51 +09:00
Hermet Park 53854e1f2d elementary: remove an unused variable. 2019-08-22 13:21:40 +09:00
Hermet Park 31d0d1ffd3 efl shape: add missing interpolation of miterlimit property. 2019-08-22 13:12:19 +09:00
junsu choi 34dc52dbd2 efl_canvas_vg_shape/ector_software : Set and use stroke miterlimit
Summary:
efl_canvas_vg_shape is set to miterlimit with Efl.Gfx.Shape.stroke_miterlimit
and pass the value from rasterizer to freetype.

NOTE: The default value is 4. It only refers to the standard of web svg.
      https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/stroke-miterlimit

Depends D9657

Test Plan: N/A

Reviewers: Hermet, smohanty, kimcinoo

Subscribers: cedric, #committers, #reviewers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9665
2019-08-22 13:00:01 +09:00
junsu choi a569a4eb27 vg_common_json: Support stroke miterlimit
Summary:
Apply miterlimit received from the node to vg_shape.

Depends D9657
        D9665

Test Plan: N/A

Reviewers: Hermet, smohanty, kimcinoo

Reviewed By: Hermet

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9666
2019-08-22 12:51:53 +09:00
junsu choi fa8f20338d efl_gfx_shape: Add stroke_miterlimit property
Summary:
Sets limit on ratio of miter value of the stroke join.
If a miter join exists, it must be supported.

Test Plan: N/A

Reviewers: Hermet, smohanty, kimcinoo

Reviewed By: Hermet

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9657
2019-08-22 12:45:09 +09:00
junsu choi ca8df7067c ector_software_rasterizer: Change default value of stroke linejoin
Summary:
SW_FT_STROKER_LINEJOIN_MITER is same SW_FT_STROKER_LINEJOIN_MITER_VARIABLE
We pass miterlimit values in fixed-point type.
Therefore, change the default value to SW_FT_STROKER_LINEJOIN_MITER_FIXED.

Test Plan: N/A

Reviewers: Hermet, smohanty, kimcinoo

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9656
2019-08-22 12:38:57 +09:00
Woochanlee 711fffe923 gesture_manager: Avoid dereferencing null pointer.
Summary:
fix coverity report. dereference before null check

CID: 1065090

Reviewers: Jaehyun_Cho, Hermet

Reviewed By: Hermet

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9694
2019-08-22 11:11:26 +09:00
subhransu mohanty 7c08d7b97c edje/style: Avoid unnecessary evas_textblock_style computation.
Summary:
If the style is not readonly we always compute the style again when
requested by edje. so this computation is unnecessary.
By avoiding the computation here we will avoid style computation of all the styles in the edje
that is not readonly hence saving memory.

Reviewers: ali.alzyod, Hermet, cedric, raster

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9693
2019-08-22 10:53:36 +09:00
Carsten Haitzler be6555e754 fix e did again after crash from dnd fix 2019-08-22 00:47:10 +01:00
Carsten Haitzler aa21bd3c60 elm - efl ui - dont crash if parent is not an elm widget 2019-08-22 00:22:39 +01:00
Mike Blumenkrantz 28a13e5114 evas/object: remove errors when user min/max size hints conflict
this scenario means, more or less, that the user just wants the widget
to be as close to the max size hint as possible. widgets should (and do)
handle this properly

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9682
2019-08-21 12:53:07 -07:00
Marcel Hollerbach ab4a628490 efl_ui_spec_suite: that fixture is unneeded
items are already getting added from the fixture added for the single
selectable interface

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9659
2019-08-21 12:53:05 -07:00
Mike Blumenkrantz 0498a4bfc8 elm_test: fix background radio usage
radio group apis need to use the radio group

Differential Revision: https://phab.enlightenment.org/D9689
2019-08-21 21:23:13 +02:00
Carsten Haitzler 2be2c3c6c3 eina list - make eina list magic optional and for now turn it off
this should bring our list nodes back to 32bytes (or 16 on 32bit)
which is the rounded up libc allocation size anyway expected. less mem
usage but less safety. i haven't seen any magic complainets to do with
eina list for a while now... so let's see.
2019-08-21 20:02:24 +01:00
Carsten Haitzler e15d9c86df eina file refs in edje/evas - audit them and plug holes where refs stay
in 1 situation at least we delete the eina file (close it) but keep
the ptr around (during destruction) which could cause issues with
callbaks and events on del and so on.... which may lead to multiple
closes where only one should happen ... which would explain my invalid
eina file ref problems i'm seeing. i carefully matched eina file
handle stores/opens/dups to closes in edje/evas and they seemed to all
match up so this audit with comments and fixes seems to have plugged
that now.

@fix
2019-08-21 20:02:24 +01:00
Carsten Haitzler 5f5e95e336 evas - font rendering - dont crash if we have color fonts and gl and sw
so if you use sw and gl enignes in a process and have color font
glyphs.. *BOOM* because the color glyph code used ext dat that was
intended for engines to extend with a gotcha of "only 1 engine can
extend this"... commented already.

so this unfortunately adds an extra ptr per glyph to store color data
explicitly. but now it both renders right and doesn't crash. we still
have a limit of 1 engine alone can extend glyphs with ext_dat though.

@fix
2019-08-21 20:02:23 +01:00
Carsten Haitzler 79228cd723 elm theme - handle error cases and eina file handles properly
@fix
2019-08-21 20:02:23 +01:00
Carsten Haitzler 14e355692b edje - handle errors and eina file handles and vpath properly
@fix
2019-08-21 20:02:23 +01:00
Carsten Haitzler d436971958 edje calc - merge 2 switch statements that are doing 2 phases
we have nigh identical switch logic, so merge these to avoid multiple
switches and type matches. it localises per-type logic too which is
nicer.
2019-08-21 20:02:23 +01:00
Carsten Haitzler cfa8224140 edje recalc - move rare recalc code out of hot path
we rarely use tables in edje, so move it out of the hot path for
intruction prefetch/cache. also for calc single - move things to sub
funcs so things like mesh, light and so on code is always out of the
hot path as much as possible. we probably can merge our 2 switch
statements as well. this really just restructures the code to move
stuff into sub functions which also does make the calc funcs look
simpler and easier to read.
2019-08-21 20:02:23 +01:00
Carsten Haitzler 55b3e8e96d evas table - use geom set instead of move+resize for fewer oe calls 2019-08-21 20:02:23 +01:00
Carsten Haitzler fa28f5a5f8 edje signal matches/patterns - handle re/alloc errors and missing ptrs
also a general cleanup of the code to make it easier to follow/read as
this seems to have problems but i cant reproduce them enough to find
them. i noted a realloc would have invalidated pre-stored pattern
ptrs that would cause segv's for sure. also code paths where reallocs may
fail and not handling those cases at all etc.

@fix
2019-08-21 20:02:23 +01:00
Vincent Torri 9336e2c51c Ecore : does not build linux-only ecore modules on Windows
while tizen module is disabled and systemd is not build on Windows, upower is built and run

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9658
2019-08-21 11:18:48 -07:00
Cedric BAIL 00d58640e5 efl: mark Efl.Ui.Factory.create a protected method.
Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9606
2019-08-21 11:18:46 -07:00
Cedric BAIL fcaec29be7 efl: use a @static function so that binding can pick it up.
Reviewed-by: Lauro Neto <Lauro Moura <lauromoura@expertisesolutions.com.br>>
Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9604
2019-08-21 11:18:44 -07:00
Cedric BAIL 869d7b05f1 elementary: use the right function for creating object from Efl.Ui.Factory.
Reviewed-by: Lauro Neto <Lauro Moura <lauromoura@expertisesolutions.com.br>>
Differential Revision: https://phab.enlightenment.org/D9635
2019-08-21 11:18:41 -07:00
Cedric BAIL 296eade307 elementary: prefer use of Efl unified API.
Reviewed-by: Lauro Neto <Lauro Moura <lauromoura@expertisesolutions.com.br>>
Differential Revision: https://phab.enlightenment.org/D9603
2019-08-21 11:18:40 -07:00
Cedric BAIL a473601ce7 elementary: Efl.Ui.Layout_Factory should not set the theme if there isn't any defined.
Reviewed-by: SangHyeon Jade Lee <sh10233.lee@samsung.com>
Differential Revision: https://phab.enlightenment.org/D9602
2019-08-21 11:18:38 -07:00
Cedric BAIL f6cdbc2d43 elementary: allow Efl.Ui.Factory to have a chance to call constructor function.
Reviewed-by: Lauro Neto <Lauro Moura <lauromoura@expertisesolutions.com.br>>
Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9599
2019-08-21 11:18:36 -07:00
Cedric BAIL 0248d504b3 elementary: switch Efl.Ui.Factory API to a batch API and update all class using it.
Reviewed-by: Lauro Neto <Lauro Moura <lauromoura@expertisesolutions.com.br>>
Differential Revision: https://phab.enlightenment.org/D9579
2019-08-21 11:18:34 -07:00
Marcel Hollerbach b8bf5b31e8 efl_ui_widget: fix model listenting logic
if we are walking this method twice (spoiler we do!) then we subscribe
twice to the event, which leads (depending on the order of executed
deletion) to the accessing of obj after its deleted.

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9684
2019-08-21 10:46:37 -07:00
Marcel Hollerbach 4cede693a5 efl_ui_widget: remove self reference
as an example: elm_test uses roughly 500 widgets, this pointer takes 8
bytes, this is wasting quite some time, which can be perfectly safed by
just structuring the code a little bit more. In some callbacks we need
to call one more time efl_data_scope_get but that is not a that big
issue, as most calls after that are also doing a eo call on that object,
so the eo_id is already cached.

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9683
2019-08-21 10:46:34 -07:00
Mike Blumenkrantz bedb6df973 efl_ui/popup: remove anchor_popup class
Summary:
all functionality is now merged into the base popup class. this greatly
simplifies the codebase and deduplicates a lot of code

ref T7902
Depends on D9651

Reviewers: cedric

Reviewed By: cedric

Subscribers: herb, cedric, #reviewers, #committers

Tags: #efl_widgets

Maniphest Tasks: T7902

Differential Revision: https://phab.enlightenment.org/D9652
2019-08-21 10:42:04 -04:00
Yeongjong Lee bb62f71fe2 efl_ui_widget: ensure that tree_unfocusable is binary number in its getter
since 2dd596084b, tree_unfocusable is changed from
Eina_Bool to int.
Double negation ensure binary return value of `elm_widget_tree_unfocusable_get`

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9673
2019-08-21 14:20:33 +02:00
WooHyun Jung 1cbcbbdfa6 efl_ui_slider : remove all the legacy checking
Summary:
Legacy checking is not needed because elm_slider
was separated from efl_ui_slider.

@ref T7893

Reviewers: Jaehyun_Cho, bu5hm4n, zmike

Reviewed By: Jaehyun_Cho

Subscribers: YOhoho, cedric, #reviewers, #committers

Tags: #efl

Maniphest Tasks: T7893

Differential Revision: https://phab.enlightenment.org/D9670
2019-08-21 19:14:57 +09:00
Yeongjong Lee 78f5efbd67 efl_ui_animation_view: add document of Efl.Ui.Animation_View_State enum
Summary:
This patch will fix mono compiler error.
```
src/bindings/mono/efl_ui_animation_view.eo.cs(2809,13): error CS1591: Warning as
Error: Missing XML comment for publicly visible type or member `Efl.Ui.AnimationViewState'
```

Test Plan: meson setup -Dbindings=mono,cxx

Reviewers: Jaehyun_Cho, SanghyeonLee

Reviewed By: Jaehyun_Cho

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9672
2019-08-21 19:00:30 +09:00
Marcel Hollerbach b5f458f5b8 efl_ui_widget: fixup field counting
this has to use tree_unfocusable not disabled.

ref D9644

Reviewed-by: YeongJong Lee <yj34.lee@samsung.com>
Differential Revision: https://phab.enlightenment.org/D9671
2019-08-21 11:59:15 +02:00
Yeongjong Lee 1c1382e09b efl_ui_panel: remove dependency with elm_interface_scrollable
`elm_interface_scrollable` is replaced with `efl_ui_scrollable_interative`.

Legacy code related to `SCROLL` event is removed because eo `SCROLL` event have
`void` event info.
```
in lib/efl/inferfaces/efl_ui_scrollable.eo

scroll: void; [[Called when scrolling]]

```
I think we need to add new `PANEL_SCROLL` event that have `Efl_Ui_Panel_Scroll_Info`

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9637
2019-08-21 11:59:14 +02:00
Yeongjong Lee e7986cc646 efl_ui_widget: correct the comparison parameter in scroll_freeze_push
I guess it is copy/paste error.

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9669
2019-08-21 11:59:12 +02:00
Hermet Park 1ada3e7427 example: replace svg resource and load it properly. 2019-08-21 18:14:48 +09:00
junsu choi 7a7d6a858d elementary_test: Add the animation view test
Summary:
Add an animation view item to test vector animation on elementary_test.
If Evas Vg Json(Lottie) Loader is not supported,
use the vector class to output the svg file.

Depends {D9451}

Test Plan:
elementart_test
Animation View

Reviewers: Hermet, smohanty, kimcinoo, zmike

Subscribers: zmike, cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9472
2019-08-21 18:03:00 +09:00
Hermet Park 8900cf0715 efl_ui_animation_view: introduce a new widget for controlling vector animation.
Summary:
This is a new convenient ui control that designed to load vector resources
-svg, json-, and control animations if it supports.

Please turn on evas-loaders-json in meson options,
if you'd like to use Lottie Animation.

Co-authored-by: JunsuChoi <jsuya.choi@samsung.com>

@feature

Reviewers: #committers, jsuya, zmike, bu5hm4n

Reviewed By: #committers, bu5hm4n

Subscribers: zmike, bu5hm4n, cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9451
2019-08-21 17:40:15 +09:00
Yeongjong Lee 5f4c9a4458 efl_ui_widget: fix dereference null return value issues
Dereference null return value issues is reported by Coverity.

If `sd` is NULL, it will return zero values.

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9668
2019-08-21 09:47:19 +02:00
Yeongjong Lee 38cec03d67 efl_ui_collection: use length value for even parameter of eina_spans_intersect
Parameter of `eina_spans_intersect` are pairs of point and length.

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9655
2019-08-21 07:56:54 +02:00
Marcel Hollerbach 9eef883312 efl_ui_position_manager_common: generalize code
move the same code to a common header file.

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9630
2019-08-21 07:50:55 +02:00
Marcel Hollerbach 8520c648b3 replace item_container benchmark
the new one has the correct name, can test grid and list, has a
changable amount of items. Additionally, it prints the pid on startup, which is usefull for perf related debugging.

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9609
2019-08-21 07:50:54 +02:00
Marcel Hollerbach 3cb3c1c4b1 efl_ui_position_manager_grid: start to honor group items
This commit introduces the correct placement of group items and normal
items. The gruop items are also floating on the top of there child items
in case they are not visible on theire own. Items without group items
between items with groups are right now a little bit troublesome and
might display the wrong group, we *need* to check later on if this case
is even needed or not.

The whole placement code now uses 2 different caches, one cache is
counting how many groups we have, and how many items each group has.
Additionally, the size of the header + the state of the header is
safes. The second cache does translate that into how much size one full
group needs on the screen to be placed, this makes the calculation of
the correct item placement a lot faster.
The invalidation of the caches is also quite good. The size cache only
depends on the viewport size and the group cache, which means its
*never* recaclulated on a normal scroll operation. Only if items are
added, or the widget is resized (The later case can also be more
optimized). The group cache is only invalidated when new items are
added (Which is normally not happening during rendering)

ref T8115

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9608
2019-08-21 07:50:53 +02:00
Marcel Hollerbach 58c3e676e8 efl_ui_position_manager_common: fix buffer_id
the buffer was accessed with the wrong id, buffer_id should be used.

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9607
2019-08-21 07:50:52 +02:00
Marcel Hollerbach 5ad686bc85 efl_ui_position_manager_list: make it handle group items
this makes the group items stick at the top of the viewport, if the
corresponding items in there do have the item available.
For now items between two groups are not really handled, the group
header will still just be displayed.

The code for this feature is explicitly written in a single block, it
was said that we might want to have this able to be enabled / disabled
later on.

This commit also shuffels the code here a bit, one single method just
got too long.

ref T8115

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9587
2019-08-21 07:50:51 +02:00
Marcel Hollerbach e2b859bdae efl_ui_position_manager: pass on information about group ids
every batched call will now contain the id of the first item, if the
conditions in the documentation are met.

ref T8115

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9586
2019-08-21 07:50:50 +02:00
Marcel Hollerbach f0b24631c0 elm_test: add group items
this is just to showcase them for now, for now they are positioned
wrong. later revisions will handle the correct positioning

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Differential Revision: https://phab.enlightenment.org/D9585
2019-08-21 07:50:49 +02:00
Marcel Hollerbach c36d374c69 elm_test: rename file and remove wrong names
additionally, we can just use efl_ui_list and grid class here, no need
for more complex stuff

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9584
2019-08-21 07:50:47 +02:00
Marcel Hollerbach 3ce3b3d48c introduce group item
this brings a group item in the style of genlist / gengrid group items.

The group item theme does currently not provide the signals in the theme
that would be needed for selecting it. This is kind of intended, but we
might need API to express that.

ref T8115

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9583
2019-08-21 07:50:46 +02:00
Marcel Hollerbach 2dfc69397b efl_ui_default_item: remove item parts
these parts are hard copies of the part implementations given from the
layouts. Replacing them with the layout implementation just works

ref T8115

Differential Revision: https://phab.enlightenment.org/D9582
2019-08-21 07:50:45 +02:00
Marcel Hollerbach 1856596698 introduce default item
default item is used as base class for all "normal style" efl items.

A "normal style" efl item does have a text,content & extra part.

- The text part is usally used to express some text in the item
- Content part is the *main* content part where the user attention is
on.
- Extra can be used to display some elements that are not directly
getting the attention of the user, it can be seen as something more than
the decoration item field.

ref T8115

Differential Revision: https://phab.enlightenment.org/D9629
2019-08-21 07:50:44 +02:00
Mike Blumenkrantz 8c1354aef9 efl_ui/popup: watch for hint change (safely) on popup object
ensure that setting user hints on this object triggers a recalc

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9651
2019-08-20 12:30:11 -07:00
Marcel Hollerbach c323a99037 efl_ui_widget: remove unused field
its not used ...

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9647
2019-08-20 12:30:09 -07:00
Marcel Hollerbach 3c098673ab efl_ui_widget: remove x,y,w,h
this is used for storing the position and size of the widget. However,
just in elm_test this eats 2KB of ram, just for saving them. The cases
where they have been used do not seem like a great performance hotspot,
additionally, in the panel cases the privat data of the widget is
achived anyways, so eo is involved and we are spending some time there
anyways.

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9646
2019-08-20 12:30:07 -07:00
Marcel Hollerbach 56752e0b3b efl_ui_widget: do not walk parent chain for none legacy cases
walking here the parent chain can be very costly, esp. if you make a lot
of widgets visible or hide them. With this commit we ensure that we only
walk the parent chain when there is a custom chain, which is only the
case in legacy. This gets us about 2-3 FPS on the rpi with the
item_container benchmark.

With earlier commits, tree_unfocusable and disabled is honoring the
whole parent chain, so checking that alone, without the parent chain, is
fine.

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9645
2019-08-20 12:30:05 -07:00
Marcel Hollerbach 2dd596084b efl_ui_widget: make treeunfocusable state easier
Before this patch tree unfocusable set just set a simple flag, getting
this state however forced you to traverse the whole parent chain to get
the real result.
With this patch the setting of the unfocusable flag is heavier as it
walks all the children of the widget, however, the getting of the flag
is way easier now. The next revision will refactor the focus related
APIs for that.

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9644
2019-08-20 12:30:03 -07:00
Marcel Hollerbach b4b17993d5 efl_ui_widget: skip custom focus parent logic
asking for a parent provider only makes sense if we are having a custom
focus parent provider, otherwise this will just result in the normal
parent relation. Not doing this safes us a lot of time that we spent for
nothing in the focus evalulation code.

The gengrid change is needed as the parent provider should be applied
after the constructor is called, otherwise there is no garantee that
shared_win_data is not NULL.

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9643
2019-08-20 12:30:00 -07:00
Marcel Hollerbach aa2d94f901 efl_ui_widget: add a place to share data
this introduces a shared place to all widgets. The shared pointer is
allocated in the window, as the window outlifes every widget that is
part of it.

This struct will be later used for further optimizations like:

1. There are really heavy focus operations which are only needed for
gengrid/genlst, there is no point in executing them if there is no
gen**** added to the window object. So we can skip the custom
parent_provider logic that is only introduced for gengrid / genlist.

2. Legacy focus APIs must do list walks, which means, on every focus
operation we always have to walk the full list up to the parent, which
is annoying and slow, as we *most of the time* do not use legacy focus
API.

This list can be continued, the above two cases are fixed in the next
revisions.

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9642
2019-08-20 12:29:58 -07:00
subhransu mohanty 10501b170f edje/optimization: keep a style hash for fast retrival of styles
As edje mostly deals with style string. to get the style data each time
it linearly search through list to find out the style which is not very
cache friendly so keep a hash to do first lookup with less impact on cache.

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9547
2019-08-20 10:40:22 -07:00
subhransu mohanty 676835458f edje/style: optimize updation of styles for a given text_style
Currently we do 2 pass updation. first we scan through all the styles
and check if they have text_style which matches the test_style we need to update
then we mark them dirty. then we call style_all_update() to go through the list
again and update those styles.
By combining them both in a single function we avoid scanning through the whole
list again.

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9639
2019-08-20 10:40:19 -07:00
Mike Blumenkrantz bc0bd4eb3f efl_ui/scroller: process edje signals during group calc
Summary:
scrollbars (and other parts) can have min sizes which affect sizing calcs,
so it's necessary to ensure that these signals are processed before trying
to size in order to get the correct size
Depends on D9593

Reviewers: bu5hm4n

Reviewed By: bu5hm4n

Subscribers: cedric, #reviewers, #committers

Tags: #efl_widgets

Differential Revision: https://phab.enlightenment.org/D9594
2019-08-20 09:11:18 -04:00
Mike Blumenkrantz cc6669c0d2 efl_ui/popup: replace legacy image use with efl_ui_image
Summary: new widgets should not use legacy widgets internally

Reviewers: bu5hm4n

Reviewed By: bu5hm4n

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9590
2019-08-20 09:11:12 -04:00
Mike Blumenkrantz 563ad2a650 tests/popup: make text alert sizing test even more strict
Summary:
ensure that the internal label size is not wider than the scroller

text alerts should never need to scroll horizontally, so ensure that this
does not break

Reviewers: bu5hm4n

Reviewed By: bu5hm4n

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9589
2019-08-20 09:11:07 -04:00
WooHyun Jung ebae12f06a elm_slider: remove dependency with efl_ui_slider
Summary:
This commit includes follwoing works.

1. change parent class from EFL_UI_SLIDER_INTERVAL
  to EFL_UI_LAYOUT_BASE
2. get all necessary codes from efl_ui_slider and
   efl_ui_slider_interval to elm_slider
3. add callbacks to slider test code

ref T7893

Test Plan:
1. elementary_test
2. slider
3. operate sliders on the window

Reviewers: bu5hm4n, segfaultxavi, eagleeye, zmike

Reviewed By: zmike

Subscribers: zmike, cedric, #reviewers, #committers

Tags: #efl

Maniphest Tasks: T7893

Differential Revision: https://phab.enlightenment.org/D9623
2019-08-20 09:09:14 -04:00
Yeongjong Lee 81a7b79235 efl_ui_scroll_util: set drag_step of parent edje object
Summary: Depends on D9649

Test Plan: elementary_test -to 'efl.ui.scroller'

Reviewers: eagleeye, bu5hm4n, zmike

Reviewed By: zmike

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9650
2019-08-20 09:07:13 -04:00
Yeongjong Lee 8f32138f1f efl_ui_scroll_util: emit edc signal that fix scroll arrow visibility
Summary:
"efl,action,scroll" signal will update arrow state.

ref T8051

Test Plan: elementary_test -to 'efl.ui.scroller'

Reviewers: eagleeye, bu5hm4n, zmike

Reviewed By: zmike

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Maniphest Tasks: T8051

Differential Revision: https://phab.enlightenment.org/D9649
2019-08-20 09:07:13 -04:00
junsu choi e850e3e5dc evas_vg_load_svg: Support "display" attribute.
Summary:
If the display attribute is "none", VG object is not show.
The default is "inline" which means visible and "none" means invisible.

Depending on the type of node, additional functionality may be required.
refer to https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute/display

Test Plan:
[SVG]
<svg viewBox="0 0 220 100" xmlns="http://www.w3.org/2000/svg">
  <!-- Here the yellow rectangle is displayed -->
  <g display="none">
    <rect x="0" y="0" width="100" height="100" fill="skyblue"></rect>
  </g>
  <rect x="20" y="20" width="60" height="60" fill="yellow"></rect>

  <!-- Here the yellow rectangle is not displayed -->
  <rect x="120" y="0" width="100" height="100" fill="skyblue"></rect>
  <rect x="140" y="20" width="60" height="60" fill="yellow" display="none"></rect>
</svg>

[C CODE]
int main(int argc, char **argv)
{
   setenv("ECTOR_BACKEND", "default", 1);
   elm_init(argc, argv);

   Evas_Object *win = elm_win_util_standard_add(NULL, "test");
   evas_object_smart_callback_add(win, "delete,request", win_del, 0);
   elm_win_autodel_set(win, 1);

   Evas *evas = evas_object_evas_get(win);

   Evas_Object *vg = evas_object_vg_add(evas);
   evas_object_show(vg);
   Evas_Object *container = evas_vg_container_add(vg);
   evas_object_vg_root_node_set(vg, container);

   Evas_Object *svg = efl_add(EFL_CANVAS_VG_OBJECT_CLASS, container);
   efl_file_simple_load(svg, "./test.svg", NULL);
   efl_gfx_entity_size_set(svg, EINA_SIZE2D(600, 600));
   efl_gfx_entity_visible_set(svg, EINA_TRUE);
   evas_object_size_hint_weight_set(svg, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
   evas_object_size_hint_align_set(svg, EVAS_HINT_FILL, EVAS_HINT_FILL);

   elm_win_resize_object_add(win, vg);
   evas_object_resize(win, WIDTH, HEIGHT);
   evas_object_show(win);
   elm_run();
   elm_shutdown();
   return 0;
}

Reviewers: Hermet, smohanty, kimcinoo

Reviewed By: Hermet

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9640
2019-08-20 20:32:15 +09:00
Hermet Park b0737c7434 Revert "ector: code refactoring."
This reverts commit dad166f84a.

Ector is not public, this breaks enlightenment compilation,
2019-08-20 20:24:27 +09:00
Hermet Park dad166f84a ector: code refactoring.
Current vector drawing requires several methods for compositing,
it's shouldnt have only masking but other blending functions
such as matte in lottie, porter&duff in android, etc.

Previously we didn't specify this method name,
just reserved the options and now we started to define the methods
with ector_renderer_composite_method() instead of mask_set().
2019-08-20 18:23:41 +09:00
Marcel Hollerbach ead8a28057 efl_ui_widget: optimize size / position setting
calling geometry set here is again calling the API in canvas object that
splits this call to size_set and position_set which means we spent quite
a bit of time in eo, just to call the same APIs we could call directly.
With this commit here, the calls are directly going to the right
objects, with the right API.

Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9619
2019-08-20 07:42:43 +02:00
Marcel Hollerbach cbf7d71eeb efl_ui_focus_manager_calc: use a mempool instead of calloc / free
if we are heaving a streak of showing / hiding a lot of widgets we free
and calloc the same nodes all the time. This now lowers the amount of
callocs / frees that we are doing

Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9618
2019-08-20 07:42:41 +02:00
Marcel Hollerbach ef858e1bfa efl_ui_focus_manager_calc: safe if this is root in a flag
otherwise we would need to get the private data of the focus manager
which is quite a heavy operation. This is slowing down enormously the
visibility setting of widgets.

Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Differential Revision: https://phab.enlightenment.org/D9617
2019-08-20 07:42:39 +02:00
Marcel Hollerbach c1e6197b21 efl_ui_focus_manager_calc: optimize item deletion
if there is high frequency adding and deleting of items, the deletion
here can be quite heavy, this makes freeing a little bit faster.

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9616
2019-08-20 07:42:38 +02:00
subhransu mohanty 6f0730cef3 edje/style: refactor style parsing to remove temporary dynamic string creation.
Summary:
pass a buffer to reparse() function for reuse.
create fontsource once and reuse.

Reviewers: ali.alzyod, Hermet, cedric, raster

Reviewed By: Hermet

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9636
2019-08-20 14:36:22 +09:00
Hermet Park 5c39e68d2b canvas svg: fix to apply premultipled color.
fill colors should be premultiplied with fill opcaity.
2019-08-20 11:25:44 +09:00
Hermet Park 3c59e23b7d evas vg: code refactoring.
try reduce code section size,
no logical changes.
2019-08-20 10:56:01 +09:00
Lauro Moura cc49c1034b csharp: MVVM parts support
Summary:
Parts binding will follow a similar approach to regular property
binding:

`var error = factory.PartName().PropertyName().Bind(modelProperty);`

* Changed both `Bind()` overloads to return the error code from
  `efl_ui_property_bind`
* Also properties from interfaces implemented didn't have their `Bindable`
  wrapper methds available.

Depends on D9563

Reviewers: felipealmeida, cedric, SanghyeonLee, woohyun

Reviewed By: cedric

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9564
2019-08-19 21:41:29 -03:00
Shinwoo Kim 2a0eeba4e5 evas: fix png regression issue
Accidentally commit "382c580 evas: add support for .9.png file to PNG loader."
adding the 9 patch feature with small code refactoring missed a line calling
eina_file_map_all taking EINA_FILE_SEQUENTIAL for data decoding.

You can see the previous change adding the line from the following commit.

   e60baa0 evas: change mapping policy to be less agressive into loading file
           in memory.

This is a response to the request of @cedric on D9580

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9614
2019-08-19 16:47:22 -07:00
Mike Blumenkrantz 409c42e46b efl_ui/text: attempt to size more accurately in non-scroll mode
the internal text object provides a min size based on its current geometry,
so temporarily match the geometry of the overall object in order to provide
a somewhat more accurate calculation sooner for this object

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9598
2019-08-19 16:47:20 -07:00
Mike Blumenkrantz e7cc65bdeb efl_ui/popups: convert from elm_scroller to efl_ui_scroller internally
efl_ui widgets should not use legacy widgets internally

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9596
2019-08-19 16:47:18 -07:00
Mike Blumenkrantz c4e03dcea4 efl_ui/scroller: create scroll manager in constructor
this fixes setting scroller properties during construction

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9593
2019-08-19 16:47:16 -07:00
Mike Blumenkrantz 6e54c58b9c efl_ui/scroller: directly trigger group_calc if pan is resized during canvas calc
this is the time when all calculations need to be handled, so ensure that the
widget directly updates itself here instead of deferring in order to avoid
infinite recalc loops

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9592
2019-08-19 16:47:14 -07:00
Mike Blumenkrantz 617bc90f12 efl_ui/scroll_util: don't trigger group_calc again on size changes
this is already handled elsewhere and can cause infinite recalc loops

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9591
2019-08-19 16:47:12 -07:00
Mike Blumenkrantz 6316455261 tests/scroller: start unit tests for efl.ui.scroller
same layout as elm_test case, start by checking scroll events after wheel

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9634
2019-08-19 16:47:10 -07:00
Mike Blumenkrantz 1114106f09 tests/elm: add util functions for triggering wheel events
Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9633
2019-08-19 16:47:08 -07:00
Mike Blumenkrantz 187425e12c elm/hoversel: manually trigger group_calc for internal objects
hoversel doesn't implement group calc or do any sane type of sizing
so just manually call these on demand to ensure the correct size is used

fix T8127

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9632
2019-08-19 16:47:06 -07:00
Mike Blumenkrantz 1948bf0d07 elm/hoversel: avoid calling api functions on null hoversel objects
the hoversel must be created before it can be shown, and its internal
hover object may be destroyed when it is hidden

@fix

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9631
2019-08-19 16:47:04 -07:00
Cedric BAIL 945447d1f8 elementary: properly refcount the key of the hash used by Efl.Ui.Layout_Factory property bind.
Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9578
2019-08-19 15:25:19 -07:00
Ali Alzyod e08ca17488 evas_textblock: markup text: improve handling invalide escape characters
Improve handling invalid escape characters.

(*) When '&' character founded in Markup text.
      Old Behavior   : Any text after '&' (if it is not escape), all text will be discarded
      New Behavior : Any text after '&' (if it is not escape), will be processes as normal plain text.

Example:
     Markup  Text :  Hello X & Y & Z 1 2 3
     Old     output :  Hello
     New   output :  Hello X & Y & Z 1 2 3

This is related to T8077

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9489
2019-08-19 11:33:25 -07:00
Ali Alzyod a821eb456a evas_common: parse color in rgb()/rgba() format
evas_common_format_color_parse: support rgb()/rgba() format

efl user can now specify colors in text formats and styles as rgb(0-255,0-255,0-255) &  rgba(0-255,0-255,0-255,0-255)  format.

This is related to task: T8068

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9309
2019-08-19 11:33:23 -07:00
Ali Alzyod 1d76452aa9 evas_textblock: reduce _evas_textblock_changed calls with markup_text_append
**_evas_textblock_changed** is internal function that mark that the textblock has changed.

When make call for
evas_object_textblock_text_markup_set(txtblock,"This is Line<br>THis is other Line<br>");

Old behaviour:
multible calles for _evas_textblock_changed will happend, for each text/format appended.

New behaviour:
Single call for _evas_textblock_changed will happend.

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9376
2019-08-19 11:33:20 -07:00
Lauro Moura ed22ad99a3 elm: avoid clash in Collection.Focus_Manager
Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9627
2019-08-19 18:21:01 +02:00
Vincent Torri 01b987df59 make mman.h private
Summary:
integrate mman.h to make Evil private to the EFL, as mman.h does not exist on Windows. After a discussion with raster, i include sys/mman.h only on non Windows platform.

One issue, though, is that src/modules/emotion/generic/Emotion_Generic_Plugin.h has inlined functions using mmap()

Test Plan: compilation on Windows

Reviewers: cedric, raster, zmike

Subscribers: #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9542
2019-08-19 09:55:13 -04:00
Hermet Park ce3d1ec7e7 evas svg: fix svg spec compatibility.
Minus degree value must be transformed to the signed before Radian.

It's easily tested i.e. the rotation degree is -350.

@fix
2019-08-19 21:37:45 +09:00
junsu choi 8f440cdedc vg_common_svg: Apply node opacity to stroke color
Summary:
  When an object to be converted to a stroke or
  path uses "opacity" attribute, opacity is also applied.

Test Plan:
[SVG]
<?xml version="1.0" encoding="UTF-8"?>
<svg width="40px" height="40px" viewBox="0 0 40 40" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
    <!-- Generator: Sketch 52.6 (67491) - http://www.bohemiancoding.com/sketch -->
        <rect fill="#FF0000" opacity="0" x="0" y="0" width="40" height="40"></rect>
        <path d="M12,20 L25,8 L12,20 Z M12,20 L25,32 L12,20 Z"
              id="Combined-Shape"
              stroke="#FFFFFF"
              stroke-width="2"
              opacity="0.12"
              stroke-linecap="round"
              stroke-linejoin="round" fill-rule="nonzero"></path>
</svg>

[Code]
int main(int argc, char **argv)
{
   setenv("ECTOR_BACKEND", "default", 1);
   elm_init(argc, argv);

   Evas_Object *win = elm_win_util_standard_add(NULL, "test");
   evas_object_smart_callback_add(win, "delete,request", win_del, 0);
   elm_win_autodel_set(win, 1);

   Evas *evas = evas_object_evas_get(win);
   Evas_Object *vg = evas_object_vg_add(evas);
   evas_object_show(vg);
   Evas_Object *container = evas_vg_container_add(vg);
   evas_object_vg_root_node_set(vg, container);

   Evas_Object *svg = efl_add(EFL_CANVAS_VG_OBJECT_CLASS, container);
   efl_file_simple_load(svg, "./i_arrow_l_disable.svg", NULL);
   efl_gfx_entity_size_set(svg, EINA_SIZE2D(600, 600));
   efl_gfx_entity_visible_set(svg, EINA_TRUE);
   evas_object_size_hint_weight_set(svg, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
   evas_object_size_hint_align_set(svg, EVAS_HINT_FILL, EVAS_HINT_FILL);

   elm_win_resize_object_add(win, vg);
   evas_object_resize(win, 600, 600);
   evas_object_show(win);
   elm_run();
   elm_shutdown();

   return 0;
}

Reviewers: Hermet, smohanty, kimcinoo

Reviewed By: Hermet

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9620
2019-08-19 19:46:02 +09:00
subhransu mohanty dafd3dc7b8 edje/style: refactor to avoid creating temporary strings.
Summary: param_parse() was creating unnecessary 2 temporary string and destroying it.

Reviewers: ali.alzyod, cedric, Hermet, raster

Reviewed By: Hermet

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9610
2019-08-19 19:38:35 +09:00
subhransu mohanty a880a756cd edje/styles: avoid redundant style tag addition by providing extra checks.
Summary:
we should only add font_size tag if the new size is different.
we should only add font tag if there is a new font.

Reviewers: ali.alzyod, Hermet, cedric, raster

Reviewed By: Hermet

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9613
2019-08-19 19:33:56 +09:00
subhransu mohanty 1d930427a3 edje/styles: keep an escaped string of font_set. As eina_ecaped_string() creates a new string just make it once and use when needed.
Reviewers: Hermet, ali.alzyod

Reviewed By: Hermet

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9615
2019-08-19 19:21:47 +09:00
Hermet Park f10a3c9ee3 edje: fix compatibility issue.
Obviously previous edje object file set would try reload file
even though the file is already loaded.

This brings different result if the file data has been modified or changed.
2019-08-19 18:07:04 +09:00
Marcel Hollerbach 375f22931e meson: there is no need for checking ecore here
fix T7768

Differential Revision: https://phab.enlightenment.org/D9574
2019-08-19 09:44:26 +02:00
Felipe Magno de Almeida a6e679f830 eo-cxx: Add second NULL sentinel to avoid buffer overrun by efl_check.h
efl_check.h assumes at least one element exists when checking
parallelization and accesses the second element of the array without
checking its size first. Adding a second NULL sentinel fixes the problem.

T8141
Differential Revision: https://phab.enlightenment.org/D9588
2019-08-19 09:42:05 +02:00
Carsten Haitzler ae5fbe49ef elm slider - delete timers on destruction that should be deleted
also use safe free to set to null
2019-08-18 10:28:51 +01:00
Carsten Haitzler b2ab0a7788 evas - loader - rsvg generic - install svg symlink
svg loading broke as we didnt have the right symlink installed after a
binary file name change. this fixes that.
2019-08-18 09:57:42 +01:00
Carsten Haitzler 49602f7426 elm hoversel - avoid crash when items modified while popping down
this fixes a crash i saw with asan on pop down if items change at that
time. @fix
2019-08-18 00:25:39 +01:00
Daniel Kolesa 2f147f2725 eolian: rename is_class api for functions to is_static
Still needs restriction to classes only etc to be done later.

Ref https://phab.enlightenment.org/T8118
Ref https://phab.enlightenment.org/T7675
2019-08-16 16:33:37 +02:00
Daniel Kolesa 8a8a833837 eolian: rename @class on methods to @static
Ref https://phab.enlightenment.org/T8118
Ref https://phab.enlightenment.org/T7675
2019-08-16 16:27:00 +02:00
Felipe Magno de Almeida 491a9a5bf8 eolian-mono: Use correct allocator to free with free, and not delete
T8137
Differential Revision: https://phab.enlightenment.org/D9576
2019-08-16 16:01:38 +02:00
Daniel Kolesa 9f2e2f99c6 eolian: fix function pointer leak as reported by asan
Ref T8140.
2019-08-16 13:33:45 +02:00