Commit Graph

60864 Commits

Author SHA1 Message Date
Christopher Michael bc43982949 elm_config: Free data returned from eet_read
Summary:
This patch fixes a memory leak in _elm_config_profile_name_get() where
the data returned from eet_read is not being free'd, causing valgrind
to spit out:

```
==11610== 9 bytes in 1 blocks are definitely lost in loss record 16 of
572
==11610==    at 0x483777F: malloc (vg_replace_malloc.c:299)
==11610==    by 0x4D9DE5B: eina_strbuf_common_string_steal
(eina_strbuf_common.c:828)
==11610==    by 0x4D5BC31: eina_binbuf_string_steal
(eina_binbuf_template_c.x:187)
==11610==    by 0x58646A1: eet_read_cipher (eet_lib.c:1991)
==11610==    by 0x5864775: eet_read (eet_lib.c:2022)
==11610==    by 0x49CD4D2: _elm_config_profile_name_get
(elm_config.c:2207)
==11610==    by 0x49CD5F8: _elm_config_profile_save (elm_config.c:2237)
==11610==    by 0x49D2F6E: _elm_config_sub_init (elm_config.c:4467)
==11610==    by 0x4AC0B7D: elm_quicklaunch_sub_init (elm_main.c:840)
==11610==    by 0x4ABFE3A: elm_init (elm_main.c:409)
==11610==    by 0x138143: main (test.c:1379)
```

@fix

Reviewers: raster, cedric, ManMower

Reviewed By: raster

Subscribers: #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D7646
2019-01-16 11:07:07 -05:00
Marcel Hollerbach 5a11fd8587 eolian_gen: void out keys depending on how they are setted
this avoid warings about keys not beeing used in the fallback function.

Reviewed-by: Daniel Kolesa <daniel@octaforge.org>
Differential Revision: https://phab.enlightenment.org/D7630
2019-01-16 14:40:13 +01:00
Marcel Hollerbach 2b1285c9db eolian: add free functions for the array and future.
It appears that NULL is not really usefull here, as this will lead to
errors later on. (void) will force the free function to just do nothing
and be later converted to a NOP.

Reviewed-by: Daniel Kolesa <daniel@octaforge.org>
Differential Revision: https://phab.enlightenment.org/D7629
2019-01-16 14:34:34 +01:00
Marcel Hollerbach 77cfb1299c eolian: there is no eina_inlist_free
Reviewed-by: Daniel Kolesa <daniel@octaforge.org>
Differential Revision: https://phab.enlightenment.org/D7628
2019-01-16 14:34:33 +01:00
Marcel Hollerbach 66824da950 efl_mono: move Eina.Error.Init() to a static constructor
this removes the need for the calling a Init function.

Reviewed-by: Felipe Magno de Almeida <felipe@expertisesolutions.com.br>
Differential Revision: https://phab.enlightenment.org/D7556
2019-01-16 14:24:12 +01:00
Marcel Hollerbach 1e2faf8527 efl_mono: move Eina.Log.Init to class consturctor
Summary:
This removes the need to explicitly init the log class.
Depends on D7495

Reviewers: felipealmeida, lauromoura, segfaultxavi

Reviewed By: felipealmeida, segfaultxavi

Subscribers: segfaultxavi, cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D7555
2019-01-16 14:16:01 +01:00
Mike Blumenkrantz 4cac97675e tests: use test namespace for elm_layout unit test function names
Reviewed-by: Stefan Schmidt <stefan@datenfreihafen.org>
Differential Revision: https://phab.enlightenment.org/D7604
2019-01-16 13:28:58 +01:00
Marcel Hollerbach 6a7c273ec7 csharp: add a interface to start apps
Summary:
until to today you had to call init functions and a run function which
were static function in a class called Efl.Ui.Config.

However, calling those init functions there is not really OOP style.
Right now things have changed into a manner where you are defining you
application class with inheriting from the Application /
SimpleApplication abstract.

This enables you to call launch() on your application class, calling
launch there leads to a call to the args function, you can call and use
the Efl classes in there, everything is booted up.
Option parsing and dependency start can still be done in the main method
or application constructor, just ensure that you never call any efl
class / function outside the launch function.

A commit that demonstrates the usage can be found at

ref T7204

https://git.enlightenment.org/tools/examples.git/log/?h=devs/bu5hm4n/POC

Reviewers: felipealmeida, segfaultxavi, Jaehyun_Cho, cedric

Reviewed By: segfaultxavi

Subscribers: zmike, woohyun, akanad, lauromoura, #reviewers, #committers

Tags: #efl_language_bindings

Maniphest Tasks: T7204

Differential Revision: https://phab.enlightenment.org/D7495
2019-01-16 12:49:47 +01:00
Stefan Schmidt 1a6679da8b emotion: gstreamer: fix deprecation warning for g_type_class_add_private
Summary:
Since glib 2.58 g_type_class_add_private is deprecated and this throws
an ugly warning in our build. Not being a glib expert I based this on
patch in freeverb which solves the same issue for them:
90625953f2

Videos in rage are still playing fine for me, but double checking during
review would be appreciated.

Reviewers: raster

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D7638
2019-01-16 11:23:44 +00:00
Yeongjong Lee 78ae9c0ae0 gfx: Add size hint fill (EO)
Summary:
If widget use both hint_align(HINT_FILL) and hint_max together, there is no way
to set to hint_align. See, elementary_test -to 'efl.ui.box' -
"Button with a quite long text." button. you can control button position
using "Box align" slider, but this is not proper implementation. When there are
two widget which have hint_align(HINT_FILL) and hint_max, those positions are
determined by box_align rather than hint_align. it means widget align cannot be
set individually.
To solve this problem, this patch add hint_fill property. in order to avoid
conflict with legacy API named evas_object_size_hint_fill_set(), it only works
for EO widgets(made by efl_add).
Also, EFL_GFX_SIZE_HINT_FILL is removed.

@feature

Test Plan:
elementary_test -to 'efl.ui.box'
elementary_test -to 'efl.ui.table'

Reviewers: jpeg, Hermet, Jaehyun_Cho, raster, barbieri

Reviewed By: Jaehyun_Cho

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Maniphest Tasks: T3912

Differential Revision: https://phab.enlightenment.org/D7409
2019-01-16 16:47:51 +09:00
Felipe Magno de Almeida 4858d9eb81 efl-mono: Remove trailings from template file
Summary: The trailings end up in the final version, which causes it to create a invalid XML file.

Reviewers: bu5hm4n, woohyun, segfaultxavi

Reviewed By: bu5hm4n

Subscribers: cedric, segfaultxavi, woohyun, #reviewers, bu5hm4n, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D7613
2019-01-16 11:57:54 +09:00
Carsten Haitzler c233d6523b elm config - add back i var to build again 2019-01-15 20:48:39 +00:00
Carsten Haitzler fe6ea2314c Revert "elm_config: remove profile name reading logic from data dir"
This reverts commit 6c4e49d970.

Hell no - this removes loading of system config profile. the entire
premise of the patch is wrong. it isn't reading the code at all... how
this got through review is rather amazing...
2019-01-15 20:43:18 +00:00
Derek Foreman 5f207d79e3 focus_manager: fix memory leaks
_set_a_without_b() makes a list clone internally, so cloning the list
first will leak a copy.

Signed-off-by: Derek Foreman <derek.foreman.samsung@gmail.com>
Reviewed-by: Marcel Hollerbach <marcel-hollerbach@t-online.de>
Differential Revision: https://phab.enlightenment.org/D7622
2019-01-15 13:47:21 -06:00
Derek Foreman 1933580efb edje: Remove _edje_animators list
I guess this used to do something...

Now it's a list that we never add anything to but frequently try to remove
things from.

Signed-off-by: Derek Foreman <derek.foreman.samsung@gmail.com>
Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Reviewed-by: Chris Michael <cp.michael@samsung.com>
Differential Revision: https://phab.enlightenment.org/D7621
2019-01-15 13:47:20 -06:00
Derek Foreman 0aa73f5365 evas_render: Remove some list walks
Not that these deletes ever walk long lists, but it's trivial to stop
doing it entirely.

Signed-off-by: Derek Foreman <derek.foreman.samsung@gmail.com>
Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Reviewed-by: Chris Michael <cp.michael@samsung.com>
Differential Revision: https://phab.enlightenment.org/D7611
2019-01-15 13:47:18 -06:00
Derek Foreman be3020b0ab ecore_wl2: Convert frame callbacks to inlist
They're only ever on a single list, and never counted.  inlist makes
more sense.

Signed-off-by: Derek Foreman <derek.foreman.samsung@gmail.com>
Reviewed-by: Chris Michael <cp.michael@samsung.com>
Differential Revision: https://phab.enlightenment.org/D7610
2019-01-15 13:47:17 -06:00
Derek Foreman 625955a597 ecore_evas: Don't walk mice list twice
We know the item is in there, so we can remove it directly.

Signed-off-by: Derek Foreman <derek.foreman.samsung@gmail.com>
Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D7609
2019-01-15 13:47:16 -06:00
Marcel Hollerbach ea9ff9f547 evas: make efl_canvas_animation abstract
it seems that this class does not have a meaning when created just like
this. Other classes using it are even abstract, which means, this class
should also be abstract. This is done in order to support that a
abstract class should only contain abstract

ref T7240

Reviewed-by: Xavi Artigas <xavierartigas@yahoo.es>
Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D7601
2019-01-15 17:37:42 +01:00
Marcel Hollerbach ae65c64b8d evas: make efl_canvas_group abstract
the efl_canvas_group should be abstract in order to support other
classes which are inheriting from it, which are abstract. This is done
in order to support only abstract parents from abstract classes.

ref T7240

Reviewed-by: Xavi Artigas <xavierartigas@yahoo.es>
Differential Revision: https://phab.enlightenment.org/D7600
2019-01-15 17:37:40 +01:00
Marcel Hollerbach afa5368f31 ecore: make efl_loop_consumer abstract
There is no point in having the object instancable. However, in order to
support bindings, we need to ensure that every abstract does have only
abstracts as inherit-parents, thus making this class abstract.

ref T7240

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D7599
2019-01-15 17:37:39 +01:00
Carsten Haitzler 3511b96448 emile+ tgv saver - stop using deprecated lz4 functions to remove warnings 2019-01-15 12:39:21 +00:00
Carsten Haitzler ae6a26b8ed efreet - fix warnings on windows to do with size casting
no actual bug - just warnings
2019-01-15 12:26:42 +00:00
Lauro Moura e2589e3b48 efl-mono: Only raise exception for managed errors.
Summary:
Previously, any unhandled Eina_Error would cause an exception
to be thrown when the control returned to C#.

This commit changes this behavior to only raise it when an exception
went unhandled from a C# callback back to C, like in an event handler,
for example.

Test Plan: run tests

Reviewers: segfaultxavi, Jaehyun_Cho, felipealmeida

Reviewed By: Jaehyun_Cho

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D7537
2019-01-15 17:51:20 +09:00
Xavi Artigas 130fe0bf78 efl-mono: Fix autotools make check
This adds autotools support for files added in 49d4d44926
Fixes D7538
2019-01-14 16:14:19 +01:00
Lauro Moura ede219c453 efl-mono: Fix marshalling of struct in event data.
Summary:
Previously, we just converted through PtrToStructure, which didn't have
the full marshalling info converting from the internal one to the
external.

This fixes the usage of the Efl.Loop.arguments event.

Also renamed the ToExternal methods to ToManaged, to make clearer that
the output struct is the one intended to be used from the managed code.

Also fixed a minor styling in the generated code (making it easier to be
inspected).

Depends on D7538

Reviewers: segfaultxavi, felipealmeida, bu5hm4n

Reviewed By: bu5hm4n

Subscribers: bu5hm4n, cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D7539
2019-01-14 16:18:05 +09:00
Lauro Moura 49d4d44926 efl-mono: Share test data among other files.
Summary: Will make easier running/compiling tests in isolation.

Reviewers: segfaultxavi, felipealmeida, bu5hm4n

Reviewed By: bu5hm4n

Subscribers: bu5hm4n, cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D7538
2019-01-14 16:16:18 +09:00
Jaehyun Cho 81317305e0 efl_mono: remove '_' from type for C# naming convention
Summary:
"type" in .eo is converted to "struct" in .eo.cs.
Since the type name in .eo is the same with the struct name .eo.cs,
'_' is removed from the converted struct in .eo.cs for C# naming
convention.

For example, Efl.Callback_Priority is defined in efl_object.eo and
the name is converted to Efl.CallbackPriority in efl_object.eo.cs.

Efl.Access.StateSet in workaround.cs causes duplicated definition
with this patch so Efl.Access.StateSet in workaround.cs is removed.

Test Plan: Compile with autogen.sh --enable-csharp-bindings

Reviewers: lauromoura, segfaultxavi, felipealmeida

Reviewed By: felipealmeida

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

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D7597
2019-01-14 15:36:14 +09:00
Carsten Haitzler f90c5b7376 elm - dnd - restore to working as drop targets
so drop taregts liek rage stopped working - something was wrong with
type handling and fetching selections at all and so on... i've kicked
it back into working again. it's not perfect but it's improved. at
least simple thgins like being a dnd target for dnd from a filemanager
work again which is probably the biggest use case.

@fix
2019-01-12 14:44:03 +00:00
Carsten Haitzler 1e6d77af90 efl net - connman - fix correct param for promise cancel
the consumer is the obj and the obj is not the pending - it is the
promise data, so warning pointed out an actual bug waiting to happen.
2019-01-12 01:52:38 +00:00
Christopher Michael b4f8315e1a elementary: Add missing EINA_UNUSED for efl_ui_image_factory_connect
Eo *obj is unused in this function, so mark it as such
2019-01-11 09:27:53 -05:00
Michael Bouchaud (yoz) 61179964c3 elm_map: Add new overlay content to the list of smart members of wigdget
Summary: Without this a new overlay content aren't displayed into the map widget.

Reviewers: zmike, devilhorns

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D7457
2019-01-11 09:21:19 -05:00
Christopher Michael e676c989d1 ecore_fb: Add missing tslib dependency
If EFL is built with tslib support, which is used by ecore_fb, then we
need to add a dependency on tslib else the build will fail to compile
(undefined reference to ts_open function).
2019-01-11 09:20:07 -05:00
Christopher Michael f85c261509 elementary: Add missing EINA_UNUSED for efl_ui_layout_factory_connect
Eo *obj is unused in this function, so mark it as such
2019-01-11 09:20:07 -05:00
Xavi Artigas 48b303eeb5 efl-mono: Add extra constructors to Eina.Value
Summary:
new Eina.Value(0) is a special case. The 0 is silently converted
to an enum (Eina.ValueType) and therefore the call is ambiguous
with the 0 being first converted to an Eina.Value via the implicit
conversion operator (calling the Eina.Value deep copy constructor).
Adding constructors for all supported types solves the problem because
they have higher priority. Also, they avoid one deep copy of the
Eina.Value.

Includes test case to catch this problem in the future. This was discovered
in the tutorials, where new Eina.Value(0) is being used.

Test Plan:
The src/efl_reference_core_event.exe example from the examples repo was
not compiling before, and now it is.
make check and make examples still work as expected.

Reviewers: lauromoura

Reviewed By: lauromoura

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D7598
2019-01-11 14:51:22 +01:00
Marcel Hollerbach 3ddd577fb0 efl: refactor all mixins
Differential Revision: https://phab.enlightenment.org/D7585
2019-01-11 12:37:27 +01:00
Marcel Hollerbach 455dedd49d eolian: introduce the keyword required
This introduces a new keyword called required. It only works on mixins.
You can specify a list of regular/abstract classes in there.
Classes specified after the required keyword are later used to verify
the usage of the mixin. With this feature a mixin can define a list of
types that the inheriting object (the object that inherits from a mixin)
needs to fullfill, if one class that is required is not in the
implemented classes, then eolian will bail out.

Differential Revision: https://phab.enlightenment.org/D7584
2019-01-11 12:37:27 +01:00
Lauro Moura c998af19fc efl-csharp: Temporarily blacklist forwarder function.
Depends on support for constants that will come with T7506
Differential Revision: https://phab.enlightenment.org/D7596
2019-01-11 11:40:35 +01:00
Larry Lira 54287d67d4 Efl.Ui.List_View: precise layout async
Summary:
fixed precise layouter to work with create asynchronous
fixed example theme signal

Reviewers: cedric, felipealmeida, SanghyeonLee, lauromoura

Reviewed By: SanghyeonLee

Subscribers: #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D7476
2019-01-11 17:21:19 +09:00
Jaehyun Cho 766f8151fc evas textblock update calculation - account for clipped color changes
if clipped color changed and not object color on textblock objects, then
the updates could be missed. This bug seems to have been here a while
unnoticed.

This patch refers the patch 4e044fd9c2.
2019-01-11 11:19:59 +09:00
Daniel Zaoui bc6b9ff935 meson: correct option description
Copy-paste has done its work here :-)
2019-01-10 21:51:01 +02:00
Cedric BAIL b8e352cde7 eo: improve documentation for event forwarder.
Reviewed-by: Xavi Artigas <xavierartigas@yahoo.es>
Differential Revision: https://phab.enlightenment.org/D7532
2019-01-10 11:13:49 -08:00
Ali Alzyod f78ef852da optimize glyph images data copy into 4 byte aligned images
Differential Revision: https://phab.enlightenment.org/D7461
2019-01-10 13:05:17 -06:00
Youngbok Shin 9201fc5a65 evas: remove memory leaks from deleted Textblock objects
Even if a object is deleted, its render_pre function could be called.
Especially, Evas Textblock is calling relayout() function if there are
any changes. In relayout() function, it creates at least one paragraph
and one line. Normally, all of paragraphs and its line should be removed
when Evas Textblock object is deleted. But, paragraphs and lines which are
created after deleting its object never be free'd.

@fix
Differential Revision: https://phab.enlightenment.org/D7427
2019-01-10 13:05:17 -06:00
Shinwoo Kim b447a37ed8 efl_ui_win: make win work for evas_norender
The evas_norender updates the canvas internal objects.
But efl_ui_win does not evaluate its internal objects, when evas_norender is
called before showing, after resizing as below.

   evas_object_resize(win, 300, 600);
   evas_norender(evas_object_evas_get(win));
   evas_object_show(win);

This problem could be verified by checking if a resize function of internal
object is called or not.

minw,h is 0 in _elm_win_resize_objects_eval but deferred_resize_job is TRUE.

   evas_norender -> _window_layout_stack ->  _elm_win_resize_objects_eval

So if _elm_win_resize_objects_eval does not return if deferred_resize_job is
TRUE even if minw,h is 0, and calls _elm_win_resize_job, then it will work.

   _elm_win_resize_objects_eval -> _elm_win_resize_job ->
   evas_object_geometry_set  -> _efl_canvas_group_group_need_recalculate_set ->
   _window_layout_stack -> evas_object_geometry_set -> resize function.

I have checked this behavior without elementary. It seems that evas_norender
works between resize and show in this case. Let me share examples.

   ecore_evas_resize(ee, 100, 100);
   evas_norender(evas);
   ecore_evas_show(ee);
Differential Revision: https://phab.enlightenment.org/D7425
2019-01-10 13:05:17 -06:00
Wonki Kim b73a5ed704 meson: add a option to config the base directory name for elm data
There is a option(--with-elementary-base-dir) on autotools
this patch provides the exactly same thing that autotools does on meson
Differential Revision: https://phab.enlightenment.org/D7580
2019-01-10 19:44:01 +01:00
Wonki Kim 3376e7cbd2 meson: Add a option for hyphen dictionaries directory
this patch provides a way to config hyphen dictionaries dir on meson.
Differential Revision: https://phab.enlightenment.org/D7581
2019-01-10 19:44:01 +01:00
Wonki Kim 15620ecc7c meson: define HAVE_TSLIB once tslib option is set
Nowhere refers to the tslib option
This patch provides a way to set HAVE_TSLIB
Differential Revision: https://phab.enlightenment.org/D7582
2019-01-10 19:44:01 +01:00
Stefan Schmidt edfa0f44fd meson: elm: add pie and fPIC cflags and ldflags to elm binaries
My use case here is having elementary_test being loaded by exactness.
That has been working fine with our autotools based build system but no
longer with meson.

Bringing fPIC and pie back as options allows exactness to dlopen the
binary and work again.

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

Signed-off-by: Stefan Schmidt <s.schmidt@samsung.com>
2019-01-10 19:44:01 +01:00
Marcel Hollerbach abf3fcf261 efl_loop: remove FIXME that is done
Summary:
ref T7514

Depends on D7508

Reviewers: zmike, segfaultxavi, cedric

Reviewed By: zmike

Subscribers: #reviewers, #committers

Tags: #efl

Maniphest Tasks: T7514

Differential Revision: https://phab.enlightenment.org/D7509
2019-01-10 13:04:31 +01:00