Commit Graph

61218 Commits

Author SHA1 Message Date
Mike Blumenkrantz 335936e79d efl.ui.layout: split into abstract and real class
Summary:
most widgets inherit from layout to provide implementations for common
functionality such as content/text/theme get+set.

one of the things that layout also brings into its inheritance hierarchy
is efl.file and implementations for its methods. this becomes a problem
when the widget which inherits layout also wants to provide implementations
for efl.file methods (e.g., entry, which uses efl.file to load text files)
as it will result in calling all of the efl.file implementations up the
chain.

in the case of entry, this could result in the 'file' property eventually being
set to the current theme file in use by the entry's layout object, and then the
entry will attempt to autosave its content to the default theme file when it is
destroyed, corrupting the theme file and breaking everything

to solve this:

* efl.ui.layout remains an instantiable class which implements efl.file
* efl.ui.layout_base is the abstract class which provides all the methods of layout
  but should be inherited by all widgets which want to implement efl.file functionality

Depends on D8018

Reviewers: bu5hm4n, segfaultxavi

Reviewed By: segfaultxavi

Subscribers: cedric, #reviewers, #committers

Tags: #efl_api

Differential Revision: https://phab.enlightenment.org/D8032
2019-02-27 13:17:16 -05:00
Mike Blumenkrantz 6326e18b3f efl.file: improve api a bit
Summary:
the previous implementation/api had a number of issues:
* "file" property contained both "file" and "key" values
  - also performed file loading operation
* "load_error" property which was specific to image objects
* no methods for controlling file loading/unloading

this patch attempts the following changes:
* split "file" property into "file" and "key" properties
  - also remove "key" from existing "mmap" property
* remove "load_error"
* directly return error codes from operations
* add "load" and "unload" methods for directly controlling load state
* add implicit file loading if file/mmap is set during construction
* rewrite all efl.file implementations to move file loading into load() method
* rewrite all usage of efl.file api based on these changes
* add C extension functions to mimic previous behavior

ref T7577

Reviewers: segfaultxavi, bu5hm4n, cedric

Reviewed By: segfaultxavi

Subscribers: vitor.sousa, #reviewers, #committers

Tags: #efl_api

Maniphest Tasks: T7577

Differential Revision: https://phab.enlightenment.org/D8018
2019-02-27 13:17:10 -05:00
Daniel Kolesa 7924660d54 elua tests: fix distcheck
The elua tests need to create a temporary file, so chdir'ing
first will not work, as the tests source dir is immutable during
distcheck. Therefore, only chdir once absolutely necessary, and
before that make sure that all file accesses are to temporary
ones.
2019-02-27 18:40:10 +01:00
Stefan Schmidt 300b1993d8 meson: edje: setup edje_codegen for cross-builds as well
We had it all setup for edje_cc, but missed edje_codegen which is used
in the examples.

Reviewed-by: Marcel Hollerbach <marcel-hollerbach@t-online.de>
Differential Revision: https://phab.enlightenment.org/D7963
2019-02-27 11:31:46 +01:00
Hermet Park 25470a56d3 eio: fix not to overflow data by performing arithmetic. 2019-02-27 19:20:29 +09:00
Hermet Park 7c8210d8a6 evas vg: don't access a dangling pointer. 2019-02-27 19:13:18 +09:00
Mike Blumenkrantz 1cce37f6f5 edje: free more data descriptors on shutdown
Summary: fix some leaks

Reviewers: devilhorns

Reviewed By: devilhorns

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D8022
2019-02-26 14:49:53 -05:00
Christopher Michael 930f57b703 examples/graphical: Mark unused parameters with EINA_UNUSED 2019-02-26 14:40:07 -05:00
Christopher Michael f40a3851f1 examples/camera_light: Mark unused parameters with EINA_UNUSED 2019-02-26 14:39:02 -05:00
Christopher Michael d60df09808 examples/sphere_hunter: Mark unused parameters with EINA_UNUSED 2019-02-26 14:37:07 -05:00
Christopher Michael 42fe36efa5 examples/performance: Mark unused parameters with EINA_UNUSED 2019-02-26 14:35:47 -05:00
Christopher Michael 92d16b1c22 examples/location_example: Mark unused parameters with EINA_UNUSED 2019-02-26 14:28:22 -05:00
Christopher Michael 68f18f98d6 examples/efl_canvas_layout_text: Mark unused parameter with EINA_UNUSED 2019-02-26 14:25:00 -05:00
Christopher Michael f7472f066f examples/efl_ui_list: Mark unused parameters with EINA_UNUSED 2019-02-26 14:16:58 -05:00
Christopher Michael 1c4c43ceb5 examples/filemvc: Mark unused parameter with EINA_UNUSED 2019-02-26 14:13:53 -05:00
Hosang Kim 493b095add efl_ui_scroller: apply handling focus.
Summary: Focus manager is applied to process key events.

Test Plan: elementary_test -> efl.ui.scroller

Reviewers: SanghyeonLee, YOhoho, marcelhollerbach, bu5hm4n

Reviewed By: bu5hm4n

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

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D7776
2019-02-26 16:53:13 +09:00
Lauro Moura 27c848c35a efl-csharp: Use proper conversion functions.
Summary:
PtrToStringAuto may switch between ANSI and UTF16 encodings in a not so
clear way, leading to decoding errors when getting messages from DBus.

Reviewers: vitor.sousa

Reviewed By: vitor.sousa

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D8023
2019-02-25 19:29:19 -03:00
Lauro Moura 401f695644 efl-csharp: Remove legacy Evas bindings.
Summary: Pave the way to correct beta classes handling.

Reviewers: vitor.sousa, segfaultxavi, bu5hm4n

Reviewed By: vitor.sousa, bu5hm4n

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D8004
2019-02-25 19:21:04 -03:00
Mike Blumenkrantz e7ebf92c92 eina: free vpath hash on shutdown
Summary: this resolves a considerable number of leaks in unit tests

Reviewers: bu5hm4n

Reviewed By: bu5hm4n

Subscribers: segfaultxavi, cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D8020
2019-02-25 17:12:57 -05:00
Michaël Bouchaud (yoz) 5f85e61f6a elm_map: Make more robust elm_map
Summary:
Make more robust elm_map even if the user wipe is cache directory
or import an already filled tile cache.

@fix T7443

Reviewers: zmike, cedric

Reviewed By: zmike

Subscribers: thierry1970, cedric, #reviewers, #committers

Tags: #efl

Maniphest Tasks: T7443

Differential Revision: https://phab.enlightenment.org/D7617
2019-02-25 14:00:21 -05:00
Mike Blumenkrantz 5da43b2aa7 efl.gfx.entity: combine show/hide events into visibility,changed
Summary:
this requires some internal hackery to preserve legacy compatibility
and correctly translate the single new event into two legacy events

ref T7558

Depends on D8018

Reviewers: segfaultxavi, bu5hm4n

Reviewed By: segfaultxavi

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

Tags: #efl_api

Maniphest Tasks: T7558

Differential Revision: https://phab.enlightenment.org/D8019
2019-02-25 14:00:14 -05:00
Mike Blumenkrantz d16adf8d82 efl.canvas.scene: rename "smart" methods to "group" methods
Summary:
"group" is the name used for interfaces api, so be consistent by using
that naming here too

ref T7584
Depends on D8019

Reviewers: segfaultxavi

Reviewed By: segfaultxavi

Subscribers: segfaultxavi, cedric, #reviewers, #committers

Tags: #efl

Maniphest Tasks: T7584

Differential Revision: https://phab.enlightenment.org/D8021
2019-02-25 14:00:14 -05:00
SangHyeon Jade Lee 4ef00bb819 genlist: fix wrong returns in window tooltip set.
Summary:
tooltip_window_mode_set returns input disable value not a successibility of API actions.
when user set window_mode to false, it must return false regardless of item view existence.

Reviewers: Hermet, woohyun, eagleeye, cedric, zmike

Subscribers: zmike, cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D7912
2019-02-25 08:00:58 -05:00
Marcel Hollerbach d0709d6110 eolian: validate betaness
Summary:
if there is a none beta class, then this class should not depend on beta
classes in parameters / event types / return types, parent inherits.
This adds this validation, so we can start to slowly to unbeta more and
more classes.

Reviewers: q66, zmike, cedric, segfaultxavi

Reviewed By: q66

Subscribers: #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D7999
2019-02-25 14:00:28 +01:00
Marcel Hollerbach 8d2d5ae3b8 build: test eo fallback add
Summary:
this enables tests with the fallback implementation of EO.
Depends on D7924

Reviewers: stefan_schmidt, cedric, zmike, segfaultxavi

Reviewed By: zmike

Subscribers: #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D7931
2019-02-25 07:59:13 -05:00
Mike Blumenkrantz f8c4011458 efl.content: add event for when content is changed containing content as data
Summary: ref T7588

Reviewers: cedric, segfaultxavi

Reviewed By: cedric, segfaultxavi

Subscribers: bu5hm4n, cedric, #reviewers, #committers

Tags: #efl

Maniphest Tasks: T7588

Differential Revision: https://phab.enlightenment.org/D7907
2019-02-25 07:58:44 -05:00
Xavi Artigas 2367deb446 docs: Assorted fixes
Summary:
- Fix multiple doxygen-style references:
Doxygen docs refer to types with #foo whereas Eolian uses @foo.
In lots of places the old Doxygen docs have been just copied into eo files
without properly translating references.

- Add some missing descriptions:
Empty doc tags like [[]] should not be used. Please try at least to provide
a single-line comment, and we can improve that later.
There are still lots of empty doc tags, and their authors will be notified.

Test Plan: Only docs change. make doc and DocFX still work.

Reviewers: zmike, cedric, bu5hm4n

Reviewed By: zmike

Subscribers: #reviewers, foo, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D7976
2019-02-25 07:45:25 -05:00
Hosang Kim f92eb7f54c efl_ui_scrollable: add step size property
Summary: The step size property determines amount of scroll by arrow key event.

Test Plan: elementary_test -> efl.ui.scroller

Reviewers: bu5hm4n, woohyun, cedric

Reviewed By: bu5hm4n, cedric

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D7916
2019-02-25 21:23:23 +09:00
Marcel Hollerbach 5235f1da85 efl_ui_widget: remove focused_item
focused_item is only used in item containers. This API is now moved into
a widget item container, which *can* have a focused item.

ref T7553

Reviewed-by: WooHyun Jung <woohyun0705@gmail.com>
Differential Revision: https://phab.enlightenment.org/D8013
2019-02-25 10:37:44 +01:00
Marcel Hollerbach ddb3bd7d21 efl_canvas_object: remove event_freeze
this is now done via Efl.Object.event_freeze / Efl.Object.event_thaw.

ref T7555

Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Differential Revision: https://phab.enlightenment.org/D8011
2019-02-25 10:37:43 +01:00
Marcel Hollerbach a25444f0d5 efl_canvas_object: make is_frame_object internal
it was decided that this property should be internal. So now it is
internal.

ref T7555

Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Differential Revision: https://phab.enlightenment.org/D8010
2019-02-25 10:37:42 +01:00
Marcel Hollerbach 422ee8d323 efl_canvas_object: get rid of event_animation set/get
the API is a little bit problematic. The API takes events as an
parameter. However, only the hide and show events can be used, because
move for example is not intercepted, which leads to a situation that you
cannot attach a translation animation to the event. Further more,
handling the animations directory instead of pipeing them through events
seems to be a little bit easier as the case study of the previous events
have shown. Further more, we should never ever overwrite the
callback_call function of a eo base object, those methods are an
incredible hotpath, by the time we would have 1-2 animations on a
object, the event submission would be significetly slowned down.

ref T7555

Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Differential Revision: https://phab.enlightenment.org/D8009
2019-02-25 10:37:40 +01:00
Marcel Hollerbach f1ad1559b7 efl_ui_stack: use direct events instead of event_animation
event_animation of efl_canvas_object, is a little problem, we need to
explictly turn it off, to do a visual state manipulation, just to attach
the animation again. Further more, the animation objects are stored in
static fields, which are not bound to the object. Which means, when two
Efl.Ui.Stack objects are running in parrallel, the animation will look a
little bit wacky, since the object is detached before the animation is
ended.

ref T7555

Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Differential Revision: https://phab.enlightenment.org/D8008
2019-02-25 10:37:39 +01:00
Marcel Hollerbach 4ccbf201fb efl_ui_slack: remove explicit animation removings
it appears that this is a bit unnessesery. Setting an animator to NULL
only causes the animation to be stopped. However, in all cases of these
removed calls, a new animator is setted anyways in one of the next
calls. Which means, the old animator is going to be stopped and removed
anyways. Thus these calls are unnessesery

Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Differential Revision: https://phab.enlightenment.org/D8007
2019-02-25 10:37:38 +01:00
Marcel Hollerbach 005c39b39c efl_ui_stack: refactor code
there has been a lot of duplications, they are removed now.
The 5 new APIs are there to either show[1] or hide[2] content without animations, show[4] or hide[5] content with animations. The last new function[3] is there to announce the events after content has been removed.

1: _show_content_without_anim
2: _hide_content_without_anim
3: _announce_hiding
4:_show_content_with_anim
5:_hide_content_with_anim

Reviewed-by: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Differential Revision: https://phab.enlightenment.org/D8006
2019-02-25 10:37:37 +01:00
Youngbok Shin 45b475d9d4 elm textpath: reduces differences between actual pos and modified pos
Summary:
In a previous patch, textpath was modified to use differences between
prev/next values to decide next position. Actually, it improved rendering
quality. But, the modified position could have a big difference from actual position.
It caused a distortion problem.
So, this patch was made for reducing that differences.
@fix

Test Plan:
I'll attach some screenshots of before/after.

1. Modify text in text_ui_textpath.c to see distortion of text. ex) "―――――――――――――――――――..."
2. Build and install.
3. Run
   "ELM_SCALE=0.8 ELM_ACCEL=gl elementary_test -to efl.ui.textpath"

Reviewers: Hermet, raster, cedric

Reviewed By: Hermet

Subscribers: #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D7418
2019-02-25 15:27:00 +09:00
WooHyun Jung a2cfa9340a efl_ui_widget: remove "moved" event
Summary:
This "moved" event is only used by elm_gengrid now.
And it's not something common for all widget classes,
because the event is giving notification when the legacy
item is reordered.

ref T7553

Test Plan: elementary_test "GenGrid"

Reviewers: bu5hm4n, YOhoho, Jaehyun_Cho

Reviewed By: bu5hm4n, YOhoho

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Maniphest Tasks: T7553

Differential Revision: https://phab.enlightenment.org/D8005
2019-02-25 13:13:53 +09:00
Cedric BAIL 12778084d7 efl: improve Efl.Container_Model test to have proper lifecycle.
Summary: Depends on D7865

Reviewers: felipealmeida, segfaultxavi, SanghyeonLee, zmike, bu5hm4n

Reviewed By: segfaultxavi

Subscribers: #reviewers, #committers

Tags: #efl

Maniphest Tasks: T7528

Differential Revision: https://phab.enlightenment.org/D7866
2019-02-23 08:58:07 -05:00
Cedric BAIL 301b05502c eio: enforce proper lifecycle for all Efl.Io_Model and fix discovered lifecycle bugs.
Summary:
This make sure that the object returned by children_slice_get are properly
destroyed when the refcount drop to only the parent holding a reference on
it. This make it clear that the user of the api can rely on efl_ref/efl_unref
to actually manage its use of the returned object.

Additionnaly we are cleaning up the created object that we are using to build our own
request inside the Efl.Io.Model and avoid internal leak.

Depends on D7864

Reviewers: felipealmeida, segfaultxavi, SanghyeonLee, zmike, bu5hm4n

Reviewed By: zmike

Subscribers: #reviewers, #committers

Tags: #efl

Maniphest Tasks: T7528

Differential Revision: https://phab.enlightenment.org/D7865
2019-02-23 08:57:48 -05:00
Cedric BAIL 790fc1b8c5 ecore: enforce proper lifecycle for all Efl.Composite_Model children.
Summary:
This make sure that the object returned by children_slice_get are properly
destroyed when the refcount drop to only the parent holding a reference on
it. This make it clear that the user of the api can rely on efl_ref/efl_unref
to actually manage its use of the returned object.

Reviewers: felipealmeida, segfaultxavi, SanghyeonLee, zmike, bu5hm4n

Reviewed By: segfaultxavi, zmike

Subscribers: #reviewers, #committers

Tags: #efl

Maniphest Tasks: T7528

Differential Revision: https://phab.enlightenment.org/D7864
2019-02-23 08:57:10 -05:00
Lauro Moura 7943a69b0d efl-csharp: Add support for containers in events.
Summary: Using a simple wrapper as event parameters are not ownable.

Reviewers: vitor.sousa

Reviewed By: vitor.sousa

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D7981
2019-02-22 14:07:24 -03:00
Xavi Artigas 329147a26a examples: fixes after Efl.Gfx.Hint rename 2019-02-22 17:42:31 +01:00
Lauro Moura 3076808a33 examples: Fix cxx examples compilation.
Summary: After Efl.Gfx.Hint changes.

Reviewers: segfaultxavi, vitor.sousa

Reviewed By: segfaultxavi

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D8003
2019-02-22 17:23:18 +01:00
Daniel Kolesa dc492b1586 eolian: introduce typed slice types
Summary:
This adds two new complex types, slice<T> and rw_slice<T>. This
is necessary to make the type useful to bindings, as Eina_Slice
on its own says nothing about what it's carrying and that prevents
useful code from being generated outside of C.

@feature

Reviewers: bu5hm4n, segfaultxavi, lauromoura, cedric

Reviewed By: cedric

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D7980
2019-02-22 16:18:49 +01:00
Marcel Hollerbach 45b46781a2 docs: Polish focus documentation.
Summary: Depends on D7994

Reviewers: bu5hm4n

Reviewed By: bu5hm4n

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D7998
2019-02-22 15:58:03 +01:00
Marcel Hollerbach a6d256cb6a build: fix macos build
Summary:
it the .pc file of luajit carries linker flags that causes compilation
fails on macos, thus we need to split up the .pc file into our own
dependency, and use it with causion

Reviewers: zmike, cedric, segfaultxavi

Reviewed By: zmike

Subscribers: #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D7995
2019-02-22 08:53:20 -05:00
Mike Blumenkrantz 11e80c7327 evas_callbacks: redo legacy smart object events for recently changed event names
Summary:
this makes it more obvious which events are legacy and makes them easier to remove
in the future

Reviewers: bu5hm4n

Reviewed By: bu5hm4n

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D8002
2019-02-22 08:50:07 -05:00
Mike Blumenkrantz 421bf2d0a3 api: add bool data to efl.io.reader/writer 'changed' events
Summary:
changed events should always be triggered with the accompanying changed
data to reduce function calls

ref T7600, T7599

Reviewers: cedric

Reviewed By: cedric

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Maniphest Tasks: T7600, T7599

Differential Revision: https://phab.enlightenment.org/D7984
2019-02-22 08:50:02 -05:00
Marcel Hollerbach 89b62fd225 efl_ui_focus_object: rename API
these API names have been considered a better choice.

ref T7571

Reviewed-by: Xavi Artigas <xavierartigas@yahoo.es>
Differential Revision: https://phab.enlightenment.org/D7994
2019-02-22 14:00:33 +01:00
Marcel Hollerbach 229dc576e6 efl_ui_focus_object: rename events
the event now math the pattern of <property-name>,changed.

ref T7571

Reviewed-by: Xavi Artigas <xavierartigas@yahoo.es>
Differential Revision: https://phab.enlightenment.org/D7989
2019-02-22 14:00:32 +01:00