Commit Graph

198 Commits

Author SHA1 Message Date
Marcel Hollerbach 34efdfb1b1 efl: convert all classes to the new eolian syntax
ref T7459

Reviewed-by: Daniel Kolesa <daniel@octaforge.org>
Reviewed-by: Xavi Artigas <xavierartigas@yahoo.es>
Differential Revision: https://phab.enlightenment.org/D7684
2019-01-18 16:31:26 +01:00
Cedric BAIL 563f91eaf9 ecore: remove data parameters of Efl.Loop_Consumer.promise_new to reduce the risk of inadvertently using the wrong data.
If you need data, use a efl_future_then as done in every case here to get the same feature.

Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Differential Revision: https://phab.enlightenment.org/D7577
2019-01-16 14:33:26 -08:00
Carsten Haitzler 318d16846f Revert "Revert "ecore: make efl_loop_promise_new a function of Efl.Loop_Consumer.""
This reverts commit 42e886d8d6.
2018-12-26 17:50:09 +00:00
Marcel Hollerbach 42e886d8d6 Revert "ecore: make efl_loop_promise_new a function of Efl.Loop_Consumer."
This reverts commit 9b5155c9f1.

For now lets revert this, this breaks copy and paste, further more it
has the potential to break a lot more things, as eio_model tends to use
efl_loop_promise new, and then eina_promise_data_set, which is
explicitly forbidden.

This fixes crashing terminology instances.
2018-12-26 12:31:08 +01:00
Cedric BAIL 9b5155c9f1 ecore: make efl_loop_promise_new a function of Efl.Loop_Consumer.
I am not sure this is the right way to do it as binding would have to likely
to bind it manually.

Reviewed-by: Lauro Neto <Lauro Moura <lauromoura@expertisesolutions.com.br>>
Differential Revision: https://phab.enlightenment.org/D7492
2018-12-20 12:42:34 -08:00
Marcel Hollerbach e43f090265 cmake: remove!
This build was never complete and also was not maintained probebly.

It is also dropped in favour of meson which is cool, merged, works & is fast.

Differential Revision: https://phab.enlightenment.org/D7010
2018-12-20 20:07:26 +01:00
Carsten Haitzler 03f9cfb0b2 eldbus model - remove unused vars warn 2018-12-04 08:33:46 +00:00
Carsten Haitzler 0ebc6c6a8c eldbus model - fix signed compare warn 2018-12-04 08:33:28 +00:00
Marcel Hollerbach c1dd57d210 meson: use eolian_gen with -S
this ensures that eolian does not parse installed .eo files

Differential Revision: https://phab.enlightenment.org/D7405
2018-12-03 19:00:26 +01:00
Cedric BAIL f9958821e9 eldbus: simplify code by using helper that create future directly.
The new helper help replace call to eina_future_resolved and eina_future_rejected with
a scheduler lookup to just one function call.

Reviewed-by: Xavi Artigas <xavierartigas@yahoo.es>
Reviewed-by: Vitor Sousa da Silva <vitorsousa@expertisesolutions.com.br>
Differential Revision: https://phab.enlightenment.org/D7340
2018-11-30 14:58:22 -08:00
Cedric BAIL 6a8d4d8159 eldbus: simplify code by using proper helper.
efl_loop_promise_new is a helper function that does automatically figure out an
available scheduler and create a promise from it. Basically replacing the call to
eina_promise_new(efl_loop_future_scheduler_get(o), ...).

Reviewed-by: Xavi Artigas <xavierartigas@yahoo.es>
Reviewed-by: Vitor Sousa da Silva <vitorsousa@expertisesolutions.com.br>
Differential Revision: https://phab.enlightenment.org/D7335
2018-11-30 14:58:10 -08:00
Yeongjong Lee e93dbf21a2 eldbus: add brackets
Summary: assignment expression is always true.

Test Plan: make

Reviewers: cedric, devilhorns

Reviewed By: devilhorns

Subscribers: #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D7357
2018-11-29 07:05:23 -05:00
Cedric BAIL 5de51f84fb eo: rename efl_future_Eina_FutureXXX_then in efl_future_then as this has been available for some time.
Reviewed-by: Vitor Sousa da Silva <vitorsousa@expertisesolutions.com.br>
Differential Revision: https://phab.enlightenment.org/D7327
2018-11-23 11:39:43 -08:00
Cedric BAIL da01f169d0 eldbus: switch Eldbus.Model to inherit from Efl.Model_Loop.
Reviewed-by: Vitor Sousa da Silva <vitorsousa@expertisesolutions.com.br>
Differential Revision: https://phab.enlightenment.org/D7326
2018-11-23 11:39:41 -08:00
Cedric BAIL d4d44d76f3 efl: make Efl.Model.properties_get return an Iterator<string>.
Reviewed-by: Vitor Sousa da Silva <vitorsousa@expertisesolutions.com.br>
Differential Revision: https://phab.enlightenment.org/D7289
2018-11-23 10:13:58 -08:00
Carsten Haitzler 64975b1e95 eldbus- fix warning by casting through void
so eldbus does silly things like use a cb ptr with a different type of
cb - very explicitly. so it casts but warnigns don't like it and
assume it maybe a bug, so use void *'s so have some silence for this
bit of evil.
2018-11-09 11:43:59 +00:00
Daniel Kolesa 5a3d79d383 meson: add eolian custom dependencies support
This uses the meson/ninja depfile functionality + eolian to make
sure proper dependencies between generated files and .eo files
are managed, to ensure consistent re-generation of all generated
files that are affected upon .eo file modification.

For custom rules with multiple outputs, Ninja currently does not
support depfiles. Therefore, split those into two custom rules
so that the depfiles functionality can be enabled. While this
is ugly and slows down the process a little by having to invoke
Eolian twice instead of once, it has to be done and it's still
better than what we had in Autotools anyway.

Differential revision: D7187

Fixes T6700.
2018-10-24 12:02:55 +02:00
Hosang Kim 53b8174fbf eldbus: remove unreachable code.
Coverity doesn't like this unreachable code.
Differential Revision: https://phab.enlightenment.org/D7120
2018-10-10 12:55:21 +02:00
Marcel Hollerbach 46d464e5bf here comes meson
a new shiny buildtool that currently completes in the total of ~ 4 min..
1 min. conf time
2:30 min. build time
Where autotools takes:
1:50 min. conf time
3:40 min. build time.

meson was taken because it went quite good for enlightenment, and is a traction gaining system that is also used by other mayor projects. Additionally, the DSL that is defined my meson makes the configuration of the builds a lot easier to read.

Further informations can be gathered from the README.meson

Right now, bindings & windows support are missing.

It is highly recommented to use meson 0.48 due to optimizations in meson
that reduced the time the meson call would need.

Co-authored-by: Mike Blumenkrantz <zmike@samsung.com>

Differential Revision: https://phab.enlightenment.org/D7012
Depends on D7011
2018-10-02 17:22:50 +02:00
Cedric Bail 6e078edaa9 eldbus: manage death of children during invalidate.
Differential Revision: https://phab.enlightenment.org/D6091
2018-05-24 16:02:18 -07:00
Xavi Artigas 35bbedc96f efl: Add missing event types
Summary:
All events must have a type now, otherwise bindings don't know how to handle
the event_info field.
Most of the missing event types were actually "void" (no event_info present).
Some struct definitions had to be moved to eo instead of h files, so they
are available to bindings. Some have not, and are marked with FIXME.
Some namespaces have been fixed (like Efl_Event_Cb -> Efl.Event_Cb).

In general, there are hundreds of changed files, but mostly to add a type which
was not present before, so there's no harm done.
Also, A lot of FIXMEs have been added which should be, like, fixed.
For example, some events can send different types of event_info, which is
very inconvenient (and error prone).

Test Plan: make with c# bindings works, make check and make examples work too.

Reviewers: cedric, q66, lauromoura

Subscribers: zmike

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D6169
2018-05-19 01:42:26 +02:00
Daniel Kolesa 577c00789a eolian: second batch of unused import removals
This fixes all remaining occurences introduced by false negatives
in 6bcd70f01d. The rest was already
fixed in 6be3809c04.
2018-05-13 18:13:12 +02:00
Daniel Kolesa 6be3809c04 eolian: first batch of unused import removals
Initial results of our static analysis showed a bunch of unused
imports or imports used only for documentation references. In the
first case, remove entirely, in the second case, change to 'parse'
in order to keep references working.

The static analysis is not perfect and yields false negatives for
certain cases, so there will be a second batch later.
2018-05-13 17:28:47 +02:00
Cedric BAIL 8e107c991c efl: update Efl.Model to properly propagate EFL_MODEL_EVENT_CHILDREN_COUNT_CHANGED. 2018-05-01 10:39:01 -07:00
Cedric BAIL 0c3508c2a2 eldbus: make sure we do not destroy our log domain until we shutoff eina. 2018-05-01 10:39:01 -07:00
Cedric BAIL 9e2493760b ecore: move efl_model_list_value_get to be an internal function. 2018-04-30 14:21:12 -07:00
Cedric Bail 3edb4ca697 eldbus: migrate and refactor eldbus.model to new efl.model API. 2018-04-30 14:21:11 -07:00
Cedric Bail ddcf8d8b97 eldbus: refactor model code. 2018-04-30 14:21:11 -07:00
Daniel Kolesa fcae7cab27 eolian gen: enable constness generation on property getter impls
This changes a lot of things all across the EFL. Previously,
methods tagged @const had both their external prototype and
internal impl generated with const on object, while property
getters only had const on the external API. This is now changed
and it all has const everywhere.

Ref T6859.
2018-04-17 20:31:55 +02:00
Mike Blumenkrantz e9eb96e097 eldbus: call ecore_init in eldbus_init
eldbus requires ecore and cannot run without it

@fix

Reviewed-by: Stefan Schmidt <stefan@osg.samsung.com>
2018-04-05 11:10:26 +02:00
Cedric BAIL 3f5ac71ad6 eldbus: ensure the lifetime of the eldbus object path is monitored for proxies
the object is instantly destroyed when connection is lost

Signed-off-by: Mike Blumenkrantz <zmike@osg.samsung.com>
2018-03-19 13:00:25 -07:00
Cedric BAIL 67b135ab87 eldbus: use efl_del when clearing the model connection child list
it is an error to delete an object with an existing parent

Signed-off-by: Mike Blumenkrantz <zmike@osg.samsung.com>
2018-03-19 13:00:25 -07:00
Mike Blumenkrantz eda0c85910 eldbus: rename conflicting "name" properties for some classes 2018-02-15 13:11:00 -05:00
Mike Blumenkrantz fcfd832ce5 eldbus: rename custom constructor methods
"constructor" conflicts with the base efl object constructor

some of the params for these should maybe be refactored into properties
and use finalize?
2018-02-15 13:11:00 -05:00
Mike Blumenkrantz 95a339733a eldbus: make connections fork-safe
after a fork, any existing connection objects can no longer be used,
but it's up to the user to destroy them. internally, this prevents
existing connections from ever being returned as valid connections
and creates new ones after a fork

also destroy fd handlers for connections to ensure that no data is
accidentally clobbered before the connections are cleaned up
2018-02-02 16:59:44 -05:00
Mike Blumenkrantz aaf3659faf eldbus: do not require error return when adding/removing signal matches
this forces the functions to be synchronous and blocks (potentially forever)
2018-02-02 16:59:44 -05:00
Vincent Torri f5b01ac5ce all: Simplify definition of EAPI
This will help in the transition from Autotools to Meson. This has been
tested on Windows for which EFL_XXX_BUILD were first introduced.
2018-01-18 18:04:03 +09:00
Daniel Kolesa 4f5b72a3ed eo files: convert various to use @cref 2017-11-02 16:41:01 +01:00
Jaehyun Cho 73baa73972 eldbus_message: Add description to fix doxygen warning
Change-Id: Id85f85de352019b29268cfa3d6e70df7cd8e84ee
2017-10-26 15:28:43 +09:00
Jaehyun Cho 5ef408f49b eldbus_connection: Add description of parameters to fix doxygen warning
Change-Id: I3be25d4b7c8bdb69c23c1c5071fac8ac1420d87d
2017-10-26 15:16:12 +09:00
JinYong Park b7359e7ff5 eldbus signal handler: add param, return type description for doxygen
Summary: Add omitted description to eldbus signal handler for doxygen warning

Test Plan: API Doxygen Revision

Reviewers: raster, cedric, jpeg, myoungwoon, Jaehyun_Cho

Differential Revision: https://phab.enlightenment.org/D5379
2017-10-26 12:17:41 +09:00
JinYong Park 157daefd5b eldbus-service: add parameters and return type description for doxygen
Summary: Add omitted descriptions for doxygen warning

Test Plan: API Doxygen Revision

Reviewers: raster, cedric, jpeg, myoungwoon, Jaehyun_Cho

Differential Revision: https://phab.enlightenment.org/D5378
2017-10-26 12:17:41 +09:00
Carsten Haitzler fd52344b03 eldbus - make file local func added in fix static
better to keep the func local unless needed elsewhere too
2017-08-01 11:23:20 +09:00
Shinwoo Kim a238272f00 eldbus: check message serial before using
Summary:
Whatever the dbus_connection_send_with_reply returns, the serial value
should be checked, because if the seral value is invalid a process could be aborted.

There is backtrace as below.

The dbus_connection_send_with_reply could return TRUE
even though it has a problem. Please refer to following comment:

   /* Refuse to send fds on a connection that cannot handle
      them. Unfortunately we cannot return a proper error here, so
      the best we can do is return TRUE but leave *pending_return
      as NULL. */

Test Plan:
There is not a exact reproduce step. If the Tizen login manager is relaunched
repeatedly, then the dbus and other service processes are relaunched.
If a service process tries to use dbus when the dbus has problem as above,
then it could be possilbe to get above backtrace.

Reviewers: raster, zehortigoza

Subscribers: cedric, jpeg

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

@fix
2017-07-31 15:53:58 +09:00
Carsten Haitzler 3de08599bf eldbus lower error print levesl from ER to WRN in get all props
this is generally unnecessary noise as the majority of the time i see
this it's because the message was canceled by the caller... thats not
an error though then... it's intended. less debug noise to sift through.
2017-07-30 23:04:35 +09:00
Stefan Schmidt c56bb560d0 eldbus: check return of dbus_signature_iter_next()
CID: 1341856
2017-04-26 14:49:37 +02:00
Gustavo Sverzut Barbieri 2ba33b8ff0 cmake: add eldbus. 2017-01-26 16:16:15 -02:00
Daniel Kolesa fe45965e07 eldbus: use new property impl syntax 2016-12-27 16:39:52 +01:00
Jean-Philippe Andre 10eb4c9a6b eldbus: change to idle_enterer from idler
Summary:
This patch set changes eldbus to use idle_enterer from idler.
If an application does not give idle time, then the eldbus cannot have chance to work.

Reviewers: raster, cedric

Subscribers: jpeg

Differential Revision: https://phab.enlightenment.org/D4443
2016-12-06 12:02:32 +09:00
Stefan Schmidt 55ee0d8fe8 docs: eldbus: add docs for new eldbus enum 2016-11-07 11:43:20 +01:00