Override mode is not available in the unified api. That's because you
can't do it in Wayland.
I still think those types are stupid and should all die: Win subclasses
handle them for you. Odd types can't be used anyway.
Ref T5322
Unless it's implemented for Wayland as well, AND provides more
information than a NULL event_info, I see no point in this being an EO
event. Keep legacy as-is: a smart callback only.
Also, minor cleanups to the EO file.
Ref T5322
This reverts commit 574ef9a5e5.
this should be resolved by 863a6e159e99c5f69ecc7461106aba2102f1da11 and is
only a possible case when an unmapped surface was activated, something which
is prevented by spec and can only occur if bugs exist elsewhere
in the case where a connection was not actively rendering, there was nothing
which would trigger a display flush, leading to applications potentially
deadlocking
@fix
setting active for unmapped surfaces bypasses the expected path for
unsetting activate during surface unmap if the surface is destroyed
while active and unmapped
@fix
This fixes the example for Windows, where apparently it ran into a lot
of errors with spinlock. Note that on Linux we have such errors too
(both before and after the patch):
EINA ERROR: 'Invalid argument' on lock 0x7ffd218af410
EINA ERROR: 'Invalid argument' on unlock 0x7ffd218af410
Patch by @vtorri
For SW engine we need to verify that OSMesa is present. The patch
fb048e7312 broke the logic.
Tested by temporarily removing OSMesa from my system.
Fixes T6617 (again)
Summary:
This patch is taken from the tizen branch
1. Take care when the locale is different than POSIX.
See: strtod, strtol
2. Interpolate all the property of a shape.
Reviewers: jpeg
Subscribers: cedric, jpeg
Differential Revision: https://phab.enlightenment.org/D5740
This reverts commit 3d07b90461.
Some commits should address the issues mentioned in T6579
959571b995fe346d2ee2
But to be honest I am still not sure exactly what the issue was?
Ref T6579
Summary:
Even though elm_tooltip does not support EO API, for now,
Efl.Ui.Widget will support elm_tooltip-like feature.
This change group name compatible with new group name policy.
Reviewers: jpeg, woohyun, herdsman, zmike
Subscribers: cedric
Differential Revision: https://phab.enlightenment.org/D5739
Summary:
elm_datetime and Efl.Ui.Clock uses same module: clock_input_ctxpopup.
The module creates internal field object.
Use legay button for field object until Efl.Clock and datetime module
policy is fixed.
Reviewers: jpeg, CHAN, woohyun
Subscribers: cedric
Differential Revision: https://phab.enlightenment.org/D5725
If the selection manager is deleted before the drop objects
are deleted, we need to remove callbacks in its destructor.
Thank @herdsman for reporting this.
Summary:
focus_user and focus_object are similar classes. by merging them into
one mixin, we can maintain consistency.
Test Plan: make check
Reviewers: bu5hm4n
Subscribers: cedric, Jaehyun_Cho, woohyun, jpeg
Differential Revision: https://phab.enlightenment.org/D5734
As it is no longer necessary to pass unit when evaluating exprs,
it is not necessary to pass it here either. Convert all the APIs
to the new style and update all instances in our tree.
Summary:
Efl.Player interface simply provides play functions,
but another interface which indicates Efl.Player will play is also
needed.
Test Plan: Run elementary_test->Efl.Animation tests
Reviewers: woohyun, conr2d, Jaehyun_Cho, jpeg, cedric
Differential Revision: https://phab.enlightenment.org/D5662
The cache had a generation count, removing this check breaks eo suite.
EO is designed to tolerate init/shutdown cycles (as long as
dlopen/dlclose isn't involved).
Note: the ugly goto are useless as GCC -O2 understands EINA_(UN)LIKELY
and deals with it as expected (just look at the asm produced).
See 34d9f20706
This fixes some of the warnings generated by calling functions on NULL
objects. One of the main remaining points is to avoid unwanted warnings
on non-existing parts.
Ref T6326
This makes eo print a WRN message in case a function is called on NULL.
efl_del is an exception to this rule (implemented in a hackish way, I
admit). I don't know any language or object model where using a null
object doesn't result in an exception or crash, except EO. In any case,
calls to null are invalid.
The next commits will resolve most warnings for EFL.
Ref T6326
This allows to safely verify if a part exists, without triggering any
potential call to NULL object, or even requiring the efl_part() handle
to be created.
This is perfectly equivalent to edje_object_part_exists(), but
implemented by both edje object and elm layout.
Summary:
ecore_evas: remove debug
eina: unregister log level when done with
Fixes a constant memory leak.
eina: introduce EINA_HOT and EINA_COLD
These attributes respectivelly expand to __attribute__ ((hot)) and
__attribute__ ((cold)) when available. They allow to mark functions are
being hot/cold (frequently used or not) as well as to qualify labels
within a function (likely/unlikely branches).
eo: speed-up generated calls by removing call cache
The call cache needed to by thread-local, to avoid concurrency issues.
Problem with TLS is that is adds an extra overhead, which appears to be
greater than the optimization the cache provides.
Op is naturally atomic, because it is an unsigned integer. As such, it
cannot be tempered with while another thread is reading it. When
entering the generated function, the first operation done is reading
'op'. If we have concurrency, we will have access sequences returning
either EFL_NOOP or a VALID op, because 'op' is not set until the very
end of the function, when everything has been computed. As such, we now
use the 'op' atomic integer to instore a lock-free/wait-free mechanism,
which allows to drop the TLS nature of the cache, speeding up the access
to the cache, and therefore making functions execute faster.
We don't test anymore the generation count. This can be put as a
limitation. If means that if you call efl_object_shutdown() and
re-initialize it later with different data, opcodes will be invalid.
I am not sure there is any usecase for this to ever happen.
We could move all the caches in a dedicated section, that can be
overwritten after a call to efl_object_shutdown(), but I am not sure it
will be very portable.
Benchmark: mean over 3 executions of
ELM_TEST_AUTOBOUNCE=100 time elementary_test -to genlist
```
BEFORE AFTER
------------------------------------------------------------
time (ns) 11114111647.0 9147676220.0
frames 2872.3333333333335 2904.6666666666665
time per frame (ns) 3869364.6666666665 3149535.3333333335
user time (s) 11.096666666666666 9.22
cpu (%) 22.666666666666668 18.333333333333332
```
Ref T6580
Reviewers: raster, cedric
Subscribers: cedric, jpeg
Maniphest Tasks: T6580
Differential Revision: https://phab.enlightenment.org/D5738
this fixes a bug with scrollable panel not being blocked
when it is closed. scroll is blocked in _anim_stop_cb()
which is called after elm_interface_scrollable_region_bring_in().
but if panel content is already at the target position, _anim_stop_cb()
is not called. so there is a need to check content's position and
handle the exceptional case.
this fixes a bug with scrollable panel not being blocked
when it is closed. scroll is blocked in _anim_stop_cb(),
which is called after elm_interface_scrollable_region_bring_in().
but if panel content is already at the target position, _anim_stop_cb()
is not called. so there is a need to check content's position and
handle the exceptional case.
there is a need to check if callback functions already exist or not
before adding or deleting them, because they are added or deleted
at two points:
in _elm_panel_scrollable_set() and _elm_panel_elm_widget_disable().
Summary:
when the popup is deleted, some EVAS_CALLBACK_DEL callback functions
try to use already freed objects.
reorder free sequence to prevent it.
Test Plan:
1. elementary_test -to popup
2. check 'Enable popup scroll'
3. open several popup test and click Close button.
4. check that there are no error message
Reviewers: Jaehyun_Cho, bu5hm4n
Reviewed By: Jaehyun_Cho
Subscribers: cedric, jpeg, herb
Differential Revision: https://phab.enlightenment.org/D5730
The compiler is not to happy about having this tick in the warning
message. Switch to the more formal can not and be done with it.
menu_cxx_example_01.cc:3:26: warning: missing terminating ' character
If ecore_file_monitor_del is called inside the file monitor callback function,
eina_list found from monitor_hash would be freed. (You can check this inside
eina_hash_list_remove.)
Then, EINA_LIST_FOREACH makes one more for loop with invalid eina_list pointer.
EINA_LIST_FOREACH_SAFE can prevent from this problem.
Summary: This monitor window is just used to receive events when mutiple
monitors are available. it should not be managed by the ecore loop
(creation and destruction events), so initting it earlier means
ecore_win32 attaches less memory/overhead to it as it's just being
used for notifications for devices.
Test Plan: DrMemory to check used memory
Reviewers: cedric
Subscribers: jpeg
Differential Revision: https://phab.enlightenment.org/D5736
After a function pointer validation branch got enabled, it turned
out that people have been writing obviously incorrect eo files
all along.
So while I have no idea if this is logically fully correct, at
least EFL builds again now...
cc @thiepha
Gcc complains here due to _wl_default_seat_id_get not accepting a
'const' Evas_Object, so to avoid the warning just case it to a normal
Evas_Object when passing in.
Signed-off-by: Chris Michael <cp.michael@samsung.com>
otherwise we get a complaint for everty time some audio needs/wants to
play and that's just noisy and ugly, so only do it once - the first
time sndfile/pulse are being loaded and it fails.
Send visible/hidden signal when text/content are realized.
This feature is already implemented in genlist widget,
for reacting dynamically in item layout depending on their
text/content realizations.
we can't sensibly use things like massif to track memory if we bypass
itr with mmaping -1 fd anonymous memory... so if built with valgrind
support and running under valgrind, use malloc/calloc and free so
these tools actually do something useful for these bits of memory.
osmesa needs llvm. llvm apparently just by dlopening or linking to the
lib (libLLVM...) gets you 3.5mb of dirty pages just in this lib. that's
a whole lib entirely dirty pages. odd and horrible. in fact once i
stoppd dlopening OSMesa all the time on engine init (and only when gl
is needed)... the amount of dirty pages went from 17208 to 8860.
that's a whopping drop of 8mb! 8mb saved! in fact just dlopening
osmesa and doing the other gl init stuff led to more anonymuse
mappings with dirty pages. 2 of them (2072k and 2076k) which baffled
me as that didn't seem like heap or efl's own data. these disappeared
along with libLLVM-5.0.so (3520k + 60k dirty pages). we stopped
linking/loading libedit (12k dirty), libglapi (20k dirty),
libLLVM-5.0 (3580k dirty), libncursesw (72k dirty),
libOSMesa.so (260k dirty), libtinfo (20k dirty). ... or at least
stopped until absolutely needed. total 17208k of dirty pages went down
to 8860.
my test case was just launching terminology (and doing nothing with it).
@fix memory bloating
evas_canvas_default_device_get used here leads to an 'implicit
declaration of function warning'. Use evas_default_device_get instead
to remove warning.
@fix
Signed-off-by: Chris Michael <cp.michael@samsung.com>
remove thread code since osx is not happy with threads trapping
signals (or at least a thread setting up the handler and trapping
there with signal blocks...). this should now work universally.
Summary:
we can consider that the node is freed during focus_manager routine.
for example, efl_ui_focus_manager_redirect_set call edje event callbacks,
and a application can delete a object in the edje callback. if the object is
the focusable object of a node, focus_manager make the node freed.
the focus_manager is able to use freed node. (a good example is test_popup.c)
this prevent reusing freed pointers.
Test Plan:
1. elementary_test -to popup
2. popup-center-text + 1 button
3. Click the Close button
4. check that there is no erroe message
Reviewers: bu5hm4n
Reviewed By: bu5hm4n
Subscribers: cedric, woohyun, jpeg, Jaehyun_Cho
Differential Revision: https://phab.enlightenment.org/D5729
we used to do signals on main loop. keep doing. the pipes should work
in cleanly serializing the signals irrespective of when/where they are
caught (because we do into kernel and back out again). hoping this
makes osx work again. can't test as i have no osx box or vm. works on
linux and freebsd though.
Summary:
Short/middle term: use UTF-16 on Windows.
So I plan to remove most of external API (like dirent in Evil) and use only EFL to have less work later
Test Plan: compile and run elm_test
Reviewers: jpeg
Subscribers: raster, cedric
Differential Revision: https://phab.enlightenment.org/D5731
The platform check was added for systems (like ARM) that don't generally
have PCI graphics devices. However, now we pick a fallback device that
doesn't have a PCI constraint, so the platform check should no longer be
necessary.
Summary: This is a tweak to c264ef264f for D5712 . chosen_dev in the loop was only being set for DRM devices attached to PCI devices. While this is useful for determining if the device is the preferred boot_vga device, There is no apparent requirement (comparing to Weston) for all DRM devices to be attached to a PCI device. (This is considering USB DisplayLink devices. I am not sure how the parent device tree is with these...)
Reviewers: devilhorns, ManMower
Reviewed By: devilhorns, ManMower
Subscribers: cedric, jpeg, #efl
Tags: #efl
Differential Revision: https://phab.enlightenment.org/D5727
Triggered after (almost) complete destruction of the object.
Not called "deleted" because the other event is already "del".
I don't like "destruct" much but this follows the terminology of
"constructor" / "destructor".
@feature
If we are Not using Atomic/Hardware support for output rotations, we
should return all available rotations as these will still work in
software mode.
@fix
Signed-off-by: Chris Michael <cp.michael@samsung.com>
Commit 9d583b3fdb broke
ecore_drm2_output_enabled_set function due changing order of setting
output->enabled value. This patch fixes both issues by checking the
'enabled' variable being passed in.
@fix
Signed-off-by: Chris Michael <cp.michael@samsung.com>
Summary:
The default backend overrides this operation depending on the fill color
but the cairo backend dosen't hence cairo will always use bled mode while drwaing the vector.
Reviewers: jpeg
Subscribers: vtorri, cedric, jpeg
Differential Revision: https://phab.enlightenment.org/D5724
this willonly apply to the main loop, but to be able to see these
signals as callbacks, we have to expose them. term/quit/int are
already handled internally where the loop will terminate (efl will
enforce this) AND ... there is a terminate event already on the loop
to deal with this cleanup. other signals really arent applicable IMHO
except usr1/2 and hup.
so xine module plus 2 eina dbug threads didnt set up signal
blocking/masks correctly. xine use ssigprocmask not pthread_sigmask
and the other 2 didnt even bother at all. fix this so these threads
all block most of these commnly caught signals so these threads never
get them
In a multi-seat configuration it's quite likely that only one
seat will have a boot_vga device.
While we should use the boot_vga device if possible, we shouldn't
fail just because a seat's gpu isn't the boot_vga device. Fallback
to the last viable drm device we saw.
Reported-by: n3rdopolis
ref D5712
ref T6455
Added a new test "Focus 6", it's an not very
complex elm layout: a swallowed genlist and three
buttons in an edje box.
You should be able to navigate the layout with
just the keyboard, that is currently impossible.
With the help of the mouse click you can randomly
make the key navigation work again... this is
mostly random.
...should help to make progress on T6453
add efl_main_loop_steal() and efl_main_loop_release() for new efl
namespace versiosn of ecore_thread_main_loop_begin() and
ecore_thread_main_loop_end().
Summary:
clicked event will be called when alert popup's button is clicked.
But usually, clicked event means when object is clicked, not sub object is clicked.
So it is so ambiguous, event name change.
Test Plan:
1. elementary_test -to efl.ui.popup.alert
2. click button.
Reviewers: Jaehyun_Cho, herb, jpeg, cedric
Reviewed By: Jaehyun_Cho
Differential Revision: https://phab.enlightenment.org/D5722
see c8dcc4327b803e9b8ad2a0985e756c924946c442 - basicall evas depends
on ecore these days... thus requires ecore be initted THEN evas. ...
which in theory is an abi break for those using evas and ONLY evas
long ago from when efl was separate... but it''s how we're building
these days.
@fix
because as of... i don't know when, evas relies on ecore with
ecore_pipe_add to create the async fd... and if you init evas then
ecore this doesnt work. obviously. well now it isn't working. probably
due to new efl loop work. but the efl loop code is correct.
ecore_pipe_add should never work until you init ecore... it just
happesn to have managed to be gotten away with for a while.
@fix
Gcc issues a warning here that 'main' is usually a function, so just
rename the variable to avoid the warning.
NB: No funtional changes
Signed-off-by: Chris Michael <cp.michael@samsung.com>
Summary:
efl_ui_popup has needs_size_calc flag
to skip size calculation when it is not needed.
But efl_ui_popup_alert_text/scroll do size calc although that flag is FALSE
Test Plan:
1. elementary_test -to efl.ui.popup.alert.text
or elementary_test -to efl.ui.popup.alert.scroll
2. resize window
3. watch _sizing_eval call
Reviewers: Jaehyun_Cho, herb, jpeg, cedric
Reviewed By: Jaehyun_Cho
Differential Revision: https://phab.enlightenment.org/D5720
This reverts commit f910ba248e.
The scheduler is meant to be used only in C, not by bindings so there isn't really
a use for it in the loop class. Now this patch was triggered due to complexity in
using future/promise, so will do a follow up patch to improve that.
This is (in my mind) meant to replace the current elua generator.
Currently the generated output is pratically identical to the elua
one, just some little difference here and there, some for thecnical
reasons and some just for my preference.
I consider this work just a starting point, extending the
templates we can now easily improve our docs. Whithout the need
to touch a single line of code.
Really I think this is a great improvements, and this are some
numbers to prove it:
Current elua implementation:
4185 lines of code in 7 lua files
generation time: ~ 7 seconds
New generator:
115 lines of python + 513 lines of templates
generation time: ~ 8 seconds (can be optimizd ALOT)
To generate the full Efl.* docs just run "./gendoc.py -v" in this folder.
...will wait for reviews (in particular from @andy and @q66)
elsewhere in efl we moved to pthread_sigmask but eina debug didn't, so
mirror the changes here too. at this point in time when we are
initting eina debug this shouldnt really matter much as we're single
threaded until this pthread_Create is called. after that tough...
we're not. signals + threads is a nightmare though... horrible
horrible...
../src/benchmarks/eina/eina_bench_sort.c: In function ‘eina_bench_sort_eina’:
../src/benchmarks/eina/eina_bench_sort.c:52:10: warning: implicit declaration of function ‘time’ [-Wimplicit-function-declaration]
srand(time(NULL));
Found due to the nice quite build output in our meson feature branch.
This is a really powerfull tool that can be used to generate anything eolian
releted just providing a template file. You can then render the template
with the wanted scope (class, namespace, enum, etc)
For example give a try at this (from the src/srcipts/pyolian folder):
./generator.py test_gen_class.template --cls Efl.Loop.Timer
or ./generator.py -h for the full help
Next step: maybe generate the new efl API doc using this tool?
@andy I think this will make your life much easier :)
This are manually written ctype bindings for eolian, that means they
run on the standard python library (nothing to install) and can run
without any build step (in fact ctypes just open the so/dll file at runtime)
Next step will be (soon) a template based generator for eolian that will
be a lot of fun :)
also eina_procmis was not threadsafe so cannto use loops in different
threads at all until this was made safe. needed to disable the old
ecore_event using code in for ecore futures and create a new efl loop
message future and handler instead ... but now a quick experiment with
multiple loops in 10 threads plus mainloop have timers at least work.
i need to test more like fd handlers etc etc. but it's a step.
stop using the legacy ecore_loop_time_get() func when it should be
coming from the loop object's loop time. also ecore_time_get should
never fall back on ecore_loop_time_get for similar reasons.
part of making the ecore/efl loop a non-global instance (allow loops
in threads)
so loop object destruction was clearing out fd handlers but those may
be later deleted by destructors of child objects. so leave legacy
fdh's and just remove them from the list
This makes sure that duplicate method/part/etc checks are done on
every database update, removing the need for clunky toplevel
checks and improving reliability. It also sacrifices some
performance but it shouldn't be too bad (if a class is already
validated, some checks are avoided to speed things up).
This has been bugging me for some time but now we are triggering new errors internally
this is appearing to end users for problems they did not cause.
Additionally I was able to improve a couple of the errors by copying the
explanation from code comments into the error message.
Shorter error logs now too :)