Commit Graph

63665 Commits

Author SHA1 Message Date
Cedric Bail 892c26f906 efl: simplify logic for widget created by factory.
In an attempt to make things more complex than they should have been,
I tried to change the inheritance tree on the fly and assume widget would
rely on autodeleting its children. This is way more complex of a solution
than to let the View actually release all the child manually and just set
the window as the default parent.h

Co-authored-by: Marcel Hollerbach <mail@marcel-hollerbach.de>

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9953
2019-09-24 09:18:49 +02:00
Marcel Hollerbach 759ac54e7f efl: split Efl.Ui.Factory.create stage into constructing and building
constructing is called during construction time, building is called
after finalize. This is usefull for theme related properties that can
only be set after the theme is applied, which happens during finalize.
Being event allow the user of the factory to add more initialization
without needing to implement any new class.

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9952
2019-09-24 09:18:47 +02:00
Cedric BAIL 3c0b496ad3 elementary: Efl.Ui.Layout_Factory bind property during widget creation.
In the same vain as previous patch this will initialize more of the widget during its
creation and reduce unecessary recalc.

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Reviewed-by: SangHyeon Jade Lee <sh10233.lee@samsung.com>
Differential Revision: https://phab.enlightenment.org/D9951
2019-09-24 09:18:46 +02:00
Cedric BAIL af3f1b070f elementary: Efl.Ui.Image_Factory bind property also during widget creation.
In the same vain as previous patch this will initialize more of the widget during its
creation and reduce unecessary recalc.

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Reviewed-by: SangHyeon Jade Lee <sh10233.lee@samsung.com>
Differential Revision: https://phab.enlightenment.org/D9950
2019-09-24 09:18:45 +02:00
Cedric Bail 23c24b36a1 ecore: update Efl.Boolean_Model to handle children removal and shifting all necessary boolean and index.
Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D10033
2019-09-24 09:18:43 +02:00
Cedric Bail 6e49752712 ecore: correctly handle children removal in Efl.Composite_Model by updating all required index.
Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D10032
2019-09-24 09:18:42 +02:00
junsu choi 06d328ffd1 efl_gfx_path: Add optimized path command
Summary:
If 'L' is removed due to optimization, it should be supported like 3b1f7be
If the previous command is 'M', use 'L'.

Test Plan: N/A

Reviewers: Hermet, smohanty, kimcinoo

Reviewed By: Hermet

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D10104
2019-09-24 11:52:30 +09:00
Hermet Park 44d362e1ef evas vg: fix gradient stroke fill memory leaks.
There were continous creation of gradient objects,
We can stop it by caching it properly,

Also, fix mismatched ref/unref counts.
2019-09-24 11:49:10 +09:00
junsu choi 3b1f7bea75 efl_gfx_path: Support 'l' command for optimized path.
Summary:
If there is no 'l' command for path optimization, refer to the previous cmd.
If the previous command is 'm', use 'l'.

Test Plan:
[Example SVG]
'''
<svg xmlns="http://www.w3.org/2000/svg" version="1.1" viewBox="0 0 40 40">
<g fill="none" fill-rule="evenodd">
<rect width="40" height="40" fill="#f00" opacity="0"/>
<path d="m12 20 13-12-13 12zm0 0 13 12-13-12z" fill-rule="nonzero" opacity=".12" stroke="#fff" stroke-linecap="round" stroke-linejoin="round" stroke-width="2"/>
</g>
</svg>
'''

Reviewers: Hermet, smohanty, kimcinoo

Reviewed By: Hermet

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D10074
2019-09-24 10:20:43 +09:00
Bruno da Silva Belo 15897cd9c3 efl-mono: Additional blank line between all methods.
Summary:
For better indentation, adding a blank line in the end of
methods.

Test Plan:
using efl_ui_layout.eo.cs, efl_access_object.eo.cs, efl_part.eo.cs and efl_ui_factory_bind.eo.cs as references,
apply changes to the code then check the diffs of after and before of the references files

Reviewers: lauromoura, felipealmeida

Reviewed By: lauromoura

Subscribers: cedric, felipealmeida, lauromoura

Tags: PHID-PROJ-uhnmnvlvunw6jgoqdnd4, #efl_language_bindings, #refactoring

Maniphest Tasks: T8167

Differential Revision: https://phab.enlightenment.org/D9712
2019-09-23 21:28:14 -03:00
Xavi Artigas 7dcce72eb7 docs: Add documentation for Efl.Ui.Scroller
Summary:
These docs were missing.
Ref T7891

Test Plan: Only docs changed

Reviewers: zmike, woohyun, bu5hm4n

Reviewed By: zmike

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Maniphest Tasks: T7891

Differential Revision: https://phab.enlightenment.org/D10019
2019-09-23 16:51:30 -04:00
Carsten Haitzler 88888a00a6 osx - require full opengl for gl support on osx
the default still is gl-es as documented. you need to explicitly turn
on full opengl to get gl support on osx because thats all the engine
does. document this exception for osx (having gl magically being full
on osx and gle-es elsewhere is another option but then we need
different os specific defaults for this which is kind of bad in other
ways).
2019-09-23 21:22:22 +01:00
Xavi Artigas 5de77bd005 theme: add 'required' to efl/tab_pager group parts
Summary: ref T8231

Reviewers: zmike, cedric

Reviewed By: zmike

Subscribers: #reviewers, #committers

Tags: #efl

Maniphest Tasks: T8231

Differential Revision: https://phab.enlightenment.org/D10087
2019-09-23 16:15:44 -04:00
Marcel Hollerbach 6714c821f7 efl_ui_pack: allow NULL as existing parameter in after and before
Summary:
with this commit all implementations of Efl.Pack_Linear to permit NULL
as existing parameter, this is verified with a spec test unit.

fixes T8210

Reviewers: zmike, segfaultxavi

Reviewed By: zmike

Subscribers: woohyun, Jaehyun_Cho, YOhoho, segfaultxavi, zmike, cedric, #reviewers, #committers

Tags: #efl

Maniphest Tasks: T8210

Differential Revision: https://phab.enlightenment.org/D10023
2019-09-23 16:15:44 -04:00
Mike Blumenkrantz 0c0db1650a doc: wrap comment for EFL_UI_CLICKABLE_PART_BIND docs in edc
Reviewers: segfaultxavi

Reviewed By: segfaultxavi

Subscribers: segfaultxavi, cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D10089
2019-09-23 22:09:42 +02:00
Carsten Haitzler 04ce5058c1 ci - osx - switch to full gl option on osx 2019-09-23 20:55:05 +01:00
Xavi Artigas b90bcbd3b5 theme: add 'required' to efl/button:anchor group parts
Summary: ref T8231

Reviewers: zmike, cedric

Reviewed By: zmike

Subscribers: #reviewers, #committers

Tags: #efl

Maniphest Tasks: T8231

Differential Revision: https://phab.enlightenment.org/D10086
2019-09-23 15:50:28 -04:00
Lauro Moura 5f5f62d6bd tests: Initialize variables and quiet warning.
Summary: The switch does not cover all Align enum values.

Reviewers: zmike

Reviewed By: zmike

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D10085
2019-09-23 15:50:28 -04:00
Xavi Artigas 84dd06aa66 theme: add 'required' to efl/spin_button group parts
Summary: ref T8231

Reviewers: zmike, cedric

Reviewed By: zmike

Subscribers: #reviewers, #committers

Tags: #efl

Maniphest Tasks: T8231

Differential Revision: https://phab.enlightenment.org/D10084
2019-09-23 15:50:28 -04:00
Xavi Artigas 27ec3c7c67 theme: add 'required' to efl/timepicker parts
Summary: ref T8231

Reviewers: zmike, cedric

Reviewed By: zmike

Subscribers: #reviewers, #committers

Tags: #efl

Maniphest Tasks: T8231

Differential Revision: https://phab.enlightenment.org/D10083
2019-09-23 15:50:28 -04:00
Cedric Bail 059e48ff0e efl: improve test in checking the return value during Eina_Value get operation.
Summary: Depends on D10061

Reviewers: zmike, bu5hm4n, SanghyeonLee, segfaultxavi, felipealmeida, lauromoura

Reviewed By: bu5hm4n

Subscribers: #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D10062
2019-09-23 15:50:28 -04:00
Xavi Artigas b5e5117992 docs: Clarify behavior of NULL in Efl.Pack_Linear.
Summary: Depends on D10023

Reviewers: zmike, bu5hm4n

Reviewed By: bu5hm4n

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Maniphest Tasks: T8210

Differential Revision: https://phab.enlightenment.org/D10024
2019-09-23 15:50:28 -04:00
Carsten Haitzler e65ebc61fa build - update README and meson options to match echother in defaults
update some defaults like move to gl-es by default, tslib off by
default as this really makes efl simpler to confgure ... by default
with less things to change to get stuff working.
2019-09-23 19:03:54 +01:00
Mike Blumenkrantz 40b22d644d theme: add 'required' to efl/bg group parts
ref T8231

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D10056
2019-09-23 10:33:27 -07:00
Mike Blumenkrantz db71c07646 theme: add 'required' to efl/popup (and related group) parts
ref T8231

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D10057
2019-09-23 10:33:25 -07:00
Mike Blumenkrantz c4f87b46a6 theme: add 'required' to efl/scroller group parts
ref T8231

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D10058
2019-09-23 10:33:23 -07:00
Mike Blumenkrantz acad0bd163 theme: add 'required' to efl/datepicker parts
ref T8231

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D10059
2019-09-23 10:33:21 -07:00
Marcel Hollerbach 534021632c efl_ui_position_manager: review cache accesses
in position manager grid and list, there are caches for the sizes, so
the access within placing the item is faster. The cache sometimes is
invalidated, which means, it must be rebuild before accessing it.

This commit is the result of reviewing all the accesses, that the
correct item is available.

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D10065
2019-09-23 10:33:19 -07:00
Marcel Hollerbach 63ebd0e9cc efl_ui_focus_managr_sub: fix a err message
with this commit there are a few errors less, for the case a object is
destroyed while registered as a border element in the sub manager.
This adds a few more callbacks to the list of callbacks, however, i
could not messure a big performance impact.

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D10067
2019-09-23 10:33:17 -07:00
Woochanlee 802f414b25 ecore_thread: Fix arguments to match with the function call.
see the _eina_thread_internal() function

r = c->func((void*) c->data, eina_thread_self());

The second param has been missed in ecore_thread_worker, ecore_direct_worker functions.

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D10073
2019-09-23 10:33:15 -07:00
Mike Blumenkrantz 1260333ae5 build: fix EFL_VERSION_MICRO define
this was never pulled in from the build system and thus was never actually
defined

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D10078
2019-09-23 10:33:13 -07:00
Mike Blumenkrantz 74cfe457c3 efl_ui/layout: move 'frozen' struct member to be a bool bitflag
this is already handled by edje, all we really want here is a flag
to avoid more eo lookups internally when calling canvas_group_change

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D10079
2019-09-23 10:33:11 -07:00
Lauro Moura 03da60997e cxx: Fix some warnings from -Wextra
Summary:
- As we don't have C++17's [[fallthrough]], rely on GCC'd detection
  of fallthrough comments.

  See https://developers.redhat.com/blog/2017/03/10/wimplicit-fallthrough-in-gcc-7/

- Replaced some copy constructors with typecast operators.

  Previously, a constructor with remove_const/remove_cv were used
  to allow const iterators to be constructed from non-const iterators.
  This had the side effect of making these constructors actual copy
  constructors for non const lists. As we did not define other
  special constructors/operators, the rule of 5 were violated for these
  cases.

  This commit replaces these constructors with actual typecast operators
  that promote non const iterators to their const counterparts.

- Cast a Eina_Bool/bool narrowing conversion

- Add a missing break statement from D10050

Reviewers: zmike, brunobelo, felipealmeida

Reviewed By: brunobelo

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9934
2019-09-23 13:58:01 -03:00
Xavi Artigas 883ef612b7 docs: Efl.Ui.Widget_Scroller_Content updated docs
Summary: Ref T8254

Reviewers: zmike

Reviewed By: zmike

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Maniphest Tasks: T8254

Differential Revision: https://phab.enlightenment.org/D10082
2019-09-23 18:30:21 +02:00
Vincent Torri e79d6bd0af eina_array: do not mix declaration and definition
fix warning when used in C90 code.

Reviewed-by: Stefan Schmidt <stefan@datenfreihafen.org>
Differential Revision: https://phab.enlightenment.org/D10077
2019-09-23 16:43:54 +02:00
Wonki Kim f18201749c gesture: fix it not to lose information by dividing
division of integer by integer results integer.
this patch fix the case to make a division result more precise.

Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Differential Revision: https://phab.enlightenment.org/D10039
2019-09-23 15:52:30 +02:00
Mike Blumenkrantz 659e0fc00c theme: efl/photocam -> efl/image_zoomable
the theme group for a class should match its class name

ref T8231

Reviewed-by: Xavi Artigas <xavierartigas@yahoo.es>
Differential Revision: https://phab.enlightenment.org/D10052
2019-09-23 15:52:29 +02:00
Mike Blumenkrantz 527ca2e6c0 theme: remove dead popup theme groups
these widgets were removed

ref T8231

Reviewed-by: Xavi Artigas <xavierartigas@yahoo.es>
Differential Revision: https://phab.enlightenment.org/D10054
2019-09-23 15:52:28 +02:00
Marcel Hollerbach b6c713c937 eina_log: ensure that we do not spam journald with our intree binaries
EFL_RUN_IN_TREE is set for all binaries that are executed during build
time, and test suites. With this commit we are ensuring that we are not
sending messages during that time to journald, otherwise we would waste
a lot of time + we would create a lot of unneccessary log messages.

(eina test suite runtime with journald hook: 11.21s without journald
hook: 0.57s)

Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Differential Revision: https://phab.enlightenment.org/D10076
2019-09-23 15:52:27 +02:00
Daniel Kolesa 74becf76c0 eolian: allow read-only stringshare in events
While the type cannot be moved to the callee, it at least provides
a hint that it's a stringshare, leeting people ref it instead of
copying.
2019-09-23 15:26:23 +02:00
Mike Blumenkrantz 8b2cae5b07 ci: add back target to do out-of-tree test build
this is necessary in order to ensure that our headers are usable

ref T8228

Reviewed-by: Stefan Schmidt <stefan@datenfreihafen.org>
Differential Revision: https://phab.enlightenment.org/D10036
2019-09-23 14:16:22 +02:00
Jaehyun Cho 98c2a75bda elementary: unref objects when memory allocation fails in factory
The objects referenced are unreferenced when memory allocation fails in
elementary factory.

Differential Revision: https://phab.enlightenment.org/D9968
2019-09-23 14:15:41 +02:00
Hermet Park eb2c1311ae ector engine: +null checking.
Null pixels is allowed when drawing region is 0,

In that case, the pixel buffer can be destroyed earlier by vg.

@fix
2019-09-23 21:15:28 +09:00
Jaehyun Cho dd5e7c7019 efl_ui_tab_pager: fix infinite selected calls
Since tab_pager's _select() and tab_bar's _selection_change_cb() cause
calling each other infinitely.
2019-09-23 20:08:32 +09:00
Mike Blumenkrantz 696627ffcd elm_test: mark image_zoomable test as non-legacy
Reviewers: segfaultxavi

Reviewed By: segfaultxavi

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D10053
2019-09-23 12:57:22 +02:00
Marcel Hollerbach 5ff0c3cc15 eina_log: do not fallback to INFO when we run with systemd support
INFO is a way too verbose log domain, this lead to the fact that we
spammed journald before the first frame with ~200-300 messages
(depending on the setup) which is quite a lot. Additionally, this also
lead to the fact that we often TIMEOUT our own tests.

Reviewed-by: Stefan Schmidt <stefan@datenfreihafen.org>
Differential Revision: https://phab.enlightenment.org/D10075
2019-09-23 11:50:43 +02:00
Stefan Schmidt a819a954bf elementary_codegen: check before use to avoid use after free
These might or might not have been freed already, depending on the
breaks form the above loop. Before we are having a use after free here
better check on it before free'ing another time.

Coverity IDs: 1402671, 1402701

Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Differential Revision: https://phab.enlightenment.org/D10047
2019-09-23 11:16:38 +02:00
Stefan Schmidt 885d5b5b68 efl_ui_exact_model: fix always true condition
The tbuf binbuffer has already been freed the line above, which means
this condition would always be true as !tbuf would always result in true.
As a result the rest of the function has never been executed.

Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Differential Revision: https://phab.enlightenment.org/D10046
2019-09-23 11:16:37 +02:00
Stefan Schmidt 87c8e2718c efl_ui_selection_manager: free allocated memory after local use
This temporary allocation is only used in this block and goes out of
scope when leaving. Make sure we free the resource before this happens.

Coverity ID: 1402653

Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Differential Revision: https://phab.enlightenment.org/D10045
2019-09-23 11:16:36 +02:00
Stefan Schmidt c02dcf6966 efl_ui_textpath: make sure variables are not uses uninitialized
First and last could have been uninitialized for their first use in some
cases. Make sure we set the x y coordinates to 0 to begin with.

Coverity IDs: 1401458, 1404747

Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Differential Revision: https://phab.enlightenment.org/D10044
2019-09-23 11:16:35 +02:00