Commit Graph

89 Commits

Author SHA1 Message Date
Mike Blumenkrantz 01fc7eae35 elm: fix macro for group_calc function naming
this should be efl_canvas_group_group_calculate to match eolian function
naming

no functional changes

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9685
2019-08-23 07:33:52 +02:00
Mike Blumenkrantz 02f1ce8d54 elm/colorselector: go back to using elm_box internally
legacy widgets should not use efl_ui widgets internally and vice versa

reverts b11f371703

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9465
2019-07-31 14:00:15 -07:00
Mike Blumenkrantz 407a0aa367 elm/colorselector: directly use smart callback api here
this is not a mixed legacy+unified widget, so we don't need to use
efl api here

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9464
2019-07-31 14:00:13 -07:00
Mike Blumenkrantz 7e517e2a11 elm/efl_ui: remove elm_layout_sizing_eval implementations
Summary:
historically there have been two methods of calculating sizes in elm:
* elm_layout_sizing_eval
* evas_object_smart_calculate (now efl_canvas_group_calculate)

the former was used to set size hints on widgets, while the latter was
used to perform internal size calcs for the widget. for things to
work correctly, these functions had to be triggered in just the right
order at just the right time. many hard-to-fix bugs related to widget
sizing over the years have been the result of this split

this patch removes elm_layout_sizing_eval implementations so that all
widgets perform both internal size calcs and size hint setting all
in the same function, ensuring that these are always in sync

the result is that in the vast majority of cases, far fewer recalcs
happen for widgets, and they are quicker to achieve their final size

Depends on D9438

Reviewers: bu5hm4n

Reviewed By: bu5hm4n

Subscribers: bu5hm4n, cedric, #reviewers, #committers

Tags: #efl_widgets

Maniphest Tasks: T8059

Differential Revision: https://phab.enlightenment.org/D9439
2019-07-30 13:12:52 -04:00
WooHyun Jung 77e268e6ab efl_input_clickable: rename efl_ui_clickable to efl_input_clickable
Summary:
Renamed all efl_ui_clickable_XXX to efl_input_clickable_XXX based on
the discussion in T7847

ref T7847 T7976

Reviewers: zmike, bu5hm4n, segfaultxavi

Reviewed By: segfaultxavi

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Maniphest Tasks: T7976, T7847

Differential Revision: https://phab.enlightenment.org/D9427
2019-07-29 11:43:01 +02:00
Mike Blumenkrantz b265bb0e2b elm/colorselector: return early from theme apply if object is not yet finalized
Summary:
the remainder of this function cannot be handled until objects are set up
later in construction

@fix
Depends on D8955

Reviewers: devilhorns

Reviewed By: devilhorns

Subscribers: devilhorns, cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D8956
2019-05-29 12:29:03 -04:00
Xavi Artigas 38d7d33354 Rename Efl.Ui.Direction -> Efl.Ui.Layout_Orientation
Summary:
This clarifies a bit the whole Orientation vs. Direction confusion, at the
expense of longer names (Image_Orientation vs. Layout_Orientation).
Also, the interfaces are now adjectives (Orientable) and the enums have long
names (*_Orientation).

Pretty big patch, but no functional changes.

Relates to T7863

Test Plan:
Everything builds and passes tests.
Elementary_tests show same behavior, including the "inverted" widgets, which
are the only parts which received a bit of code changes.
Proof:
https://travis-ci.org/Enlightenment/efl/builds/536277282

Reviewers: zmike, bu5hm4n, cedric

Reviewed By: zmike

Subscribers: #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D8946
2019-05-24 12:30:32 -04:00
Marcel Hollerbach 41e1dadbf1 elementary: do not emit new events in legacy
Summary:
This commits prepares the tree in order to mess with the events in the
Efl.Ui.Clickable event. Events which have been emitted in a none legacy
widget, are now emitted either with evas, when the widget is legacy due
to inheritance. Or via the normal event and normal event functions.

In case the widget is a legacy only widget (not used at all in the new
api), then the events are for now emitted with
evas_object_smart_callback_call.

Cases where event handlers have been added to legacy widgets, smart
events are now used, and not the eo one anymore.

ref T7844

Depends on D8813

Reviewers: cedric, zmike, segfaultxavi

Reviewed By: zmike

Subscribers: #reviewers, #committers

Tags: #efl

Maniphest Tasks: T7844

Differential Revision: https://phab.enlightenment.org/D8816
2019-05-13 15:14:13 -04:00
Marcel Hollerbach d29edceade efl_ui_clickable: move repeat event
Summary:
the repeat event is only emitted by the implementations of
efl_ui_autorepeat. Additionally, the event should only be used by those
who implement this interface.

Depends on D8832

Reviewers: zmike, segfaultxavi, cedric

Reviewed By: zmike, segfaultxavi

Subscribers: jpeg, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D8813
2019-05-13 15:14:03 -04:00
Marcel Hollerbach 7aa9ea071a efl_pack: split algin and padding property
the pack interface is a general interface for how we pack things into a
container. the align and padding property has less to nothing to do with
this. Hence this commit splits the two properties into theire own
interface.

fix T7825

Reviewed-by: Xavi Artigas <xavierartigas@yahoo.es>
Differential Revision: https://phab.enlightenment.org/D8699
2019-04-26 12:06:02 +02:00
Yeongjong Lee 41136db8e8 ui.widget: remove elm_widget_sub_object_parent_add from each of widgets
since commit a1addad60e, To add myself as a sub object of parent object will be
done in Efl.Ui.Widget constructor.

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D8280
2019-04-18 11:01:19 +02:00
Mike Blumenkrantz 4e1ec2d3e9 elm_colorselector: remove all legacy usage from eo files
this takes the current generated output from eolian for legacy code in
efl and adds it to the tree, then removes legacy references from the
corresponding eo files. in the case where the entire eo file was for
a legacy object, that eo file has been removed from the tree

ref T7724

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D8161
2019-03-07 14:15:01 -08:00
Mike Blumenkrantz c5ae5f1d31 elm_color_item: remove all legacy usage from eo files
this takes the current generated output from eolian for legacy code in
efl and adds it to the tree, then removes legacy references from the
corresponding eo files. in the case where the entire eo file was for
a legacy object, that eo file has been removed from the tree

ref T7724

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D8160
2019-03-07 14:14:59 -08:00
Mike Blumenkrantz 9a361ac917 efl_access_object: remove all legacy usage from eo files
this takes the current generated output from eolian for legacy code in
evas and adds it to the tree, then removes legacy references from the
corresponding eo files. in the case where the entire eo file was for
a legacy object, that eo file has been removed from the tree

ref T7724

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D8131
2019-03-06 13:03:02 -08:00
Mike Blumenkrantz bb6caaa471 efl.ui: remove Efl.Ui.Theme_Apply_Error
Summary:
now that the error codes have been change to be compatible with eina_error,
this can be removed and will work through eina_error naturally

fix T7718

Depends on D8067

Reviewers: cedric

Reviewed By: cedric

Subscribers: cedric, #reviewers, #committers

Tags: #efl_api

Maniphest Tasks: T7718

Differential Revision: https://phab.enlightenment.org/D8068
2019-03-04 13:37:07 -05:00
Mike Blumenkrantz 644b771fe4 efl.ui: Efl.Ui.Theme_Apply_Result -> Efl.Ui.Theme_Apply_Error
Summary:
this swaps the values of "no error" and "error" in order to maintain
consistency with the rest of efl where the zero value means "no error"
Depends on D8060

Reviewers: cedric

Reviewed By: cedric

Subscribers: segfaultxavi, cedric, #reviewers, #committers

Tags: #efl_api

Differential Revision: https://phab.enlightenment.org/D8063
2019-03-04 13:36:41 -05:00
Mike Blumenkrantz f886941b11 api: efl.gfx.size_hints -> efl.gfx.hints
Summary:
these hints are not strictly size-related, so renaming them is more consistent
with their actual function

ref T7563

Depends on D7968

Reviewers: segfaultxavi, cedric, bu5hm4n

Subscribers: segfaultxavi, cedric, #reviewers, #committers

Tags: #efl

Maniphest Tasks: T7563

Differential Revision: https://phab.enlightenment.org/D7977
2019-02-21 18:43:12 +01: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
Carsten Haitzler bb9cec6d9e elm colorselector - fix unused param warn 2018-12-04 08:38:44 +00:00
Marcel Hollerbach 97ece33134 efl_ui_focus_object: introduce a new event for focus geometry changes
before the move and resize events have been used. However, this turned
out to not work well, because not all registered items are real
efl.gfx.entity objects, there is also a custom property for getting the
focus geometry, so now this property is completed with a event that is
emitted when the focus geometry changes. With this event we can
reintroduce relation caching. Since all events are marked correctly
dirty now.

Differential Revision: https://phab.enlightenment.org/D7347
2018-11-26 11:37:04 +01:00
Jaehyun Cho 4f9c8d524c efl_ui_theme: Introduce Efl.Ui.Theme class
Summary:
Efl.Ui.Theme class is required to support language bindings.
Efl.Ui.Theme works based on current elm_theme features.

This patch fixes T7357.

Reviewers: segfaultxavi, cedric, lauromoura, woohyun, zmike, SanghyeonLee

Reviewed By: segfaultxavi, SanghyeonLee

Subscribers: SanghyeonLee, herdsman, #reviewers, #committers

Tags: #efl

Maniphest Tasks: T7357

Differential Revision: https://phab.enlightenment.org/D7244
2018-11-20 13:56:37 +09:00
Marcel Hollerbach 9f758dc363 elm: update widgets that have documented focus and unfocused events
this emits focus and unfocus on those widgets.

fixes T7386

Depends on D7124

Differential Revision: https://phab.enlightenment.org/D7103
2018-11-15 13:55:37 +01:00
Mike Blumenkrantz 4a2b411287 elm_colorselector: fix improperly named API theme parts
Summary:
API parts require namespacing, these parts have been namespaced with
compatibility code added to handle legacy naming

Reviewers: cedric, Hermet, devilhorns, stephenmhouston

Subscribers: segfaultxavi, Hermet, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D6213
2018-06-20 11:57:26 -05:00
Mike Blumenkrantz 30197a488f elm_colorselector: avoid calling functions with null objects
Summary:
a number of calls during construction resulted in null object errors here

fix T7036

Depends on D6323

Reviewers: bu5hm4n, Hermet, woohyun, devilhorns

Reviewed By: bu5hm4n

Subscribers: cedric, #committers

Tags: #efl

Maniphest Tasks: T7036

Differential Revision: https://phab.enlightenment.org/D6324
2018-06-19 13:41:16 -04:00
Mike Blumenkrantz 209aca1654 elm_colorselector: avoid passing null to efl functions
Summary:
this check already existed in the function but was not applied to the
entire function

ref T7030
Depends on D6322

Reviewers: bu5hm4n, Hermet, woohyun, devilhorns

Reviewed By: bu5hm4n

Subscribers: cedric, #committers

Tags: #efl

Maniphest Tasks: T7030

Differential Revision: https://phab.enlightenment.org/D6323
2018-06-19 13:41:02 -04:00
Cedric BAIL 0fe3b7962d elementary: due to lifecycle difference between legacy object and unified object, we need to track their lifecycle more explicitely.
It is my understanding that some items view are created with efl_add directly
and manipulate VIEW directly with Eo new API. This clash with the inconsistent
behavior that evas_object_del expect. To work around this, we track object life
by explictely relying on efl_wref_add while holding the pointer to the object.
2018-05-24 16:02:19 -07:00
Cedric BAIL 2508c1a3ae elementary: colorselector item are created with efl_add, so they are dead when they reach the destructor.
Differential Revision: https://phab.enlightenment.org/D6103
2018-05-24 16:02:18 -07:00
Xavi Artigas 55bd097a3d Efl.Gfx.Entity (from Efl.Gfx)
Ref https://phab.enlightenment.org/T6847

Reviewed-by: Cedric Bail <cedric@osg.samsung.com>
2018-04-24 09:03:32 -07:00
Xavi Artigas 9dcc31ed4a Efl.Access.Object (from Efl.Access)
Ref https://phab.enlightenment.org/T6847

Reviewed-by: Cedric Bail <cedric@osg.samsung.com>
2018-04-24 09:03:24 -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 b0bb09ef7a Efl.Access: resolve more name conflicts
children -> access_children
type -> access_type
2018-02-15 13:28:45 -05:00
Mike Blumenkrantz b3bc06a5be elm_colorselector: "color" -> "picked_color" 2018-02-15 13:11:00 -05:00
Mike Blumenkrantz f45e972c8c Elm.Widget.Item: focus -> item_focus 2018-02-15 13:11:00 -05:00
Mike Blumenkrantz 8b7bbb2398 efl.access: name -> i18n_name 2018-02-15 13:11:00 -05:00
Amitesh Singh 44d3227beb widget: rename elm widget to Efl.Ui.Widget. 2018-01-08 21:28:10 +09:00
Amitesh Singh 54ae9cc18b edje: rename Edje.Object to Efl.Canvas.Layout 2017-12-06 13:12:29 +09:00
Amitesh Singh 10103b9b45 efl.gfx: move scale{} from efl.ui.base to efl.gfx 2017-12-04 14:38:39 +09:00
Amitesh Singh 29b47e0a07 focus: remove focus.get{} from widget.eo
This is taking care by focus manager now.
2017-11-29 19:25:14 +09:00
Jean-Philippe Andre e9ebe5c676 elm: Define and rename internal atspi struct in EO
This thing is used by only 2 EO APIs that are marked as @beta. I wonder
if the @beta tag or the ptr() expression made it work for eolian,
because it simply wasn't defined in EO.

I'm renaming it just so that it's more consistent with the new names
used by atspi (and EO API in general).
2017-11-16 12:00:18 +09:00
Lukasz Stanislawski c838e30a24 elm: Rename elm_interface_atspi_widget_action mixin
Reviewers: jpeg

Subscribers: jenkins, cedric, jpeg

Differential Revision: https://phab.enlightenment.org/D5400
2017-11-16 12:00:18 +09:00
Marcel Hollerbach 07cb2d2dcd efl_ui_focus_object: document the bahaviour of the manager property 2017-11-15 13:21:22 +01:00
Jean-Philippe Andre d39bbc1491 elm: Create legacy widgets with elm_legacy_add
This will be used to solve issues around style_set:
if the widget is legacy or pure eo we may need to select a different
style. So in the constructor we need to know whether we are legacy or
eo. Note that calling style_set in finalize only is too late as we would
lose information such as efl_text_set() called inside efl_add().
2017-11-07 14:50:31 +09:00
Jean-Philippe Andre 824792f09d elm: Major cleanup of EO files
This prevents legacy EO classes from being exposed through .eo.h headers
or .eo in share/eolian/includes. Also removes a slew of useless xxx_eo.h
intermediate headers.

Notes:
 - elm_systray has no proper API: it's not clear if the EO API should be
   released (in which case it needs to be renamed to efl_something) and
   there is no legacy API to create a systray object.
 - Some files have been placed in a "FIXME" section, as I believe they
   are necessary within EO land, but at the same time still don't
   conform to the interfaces (eg. name starts with elm_).
 - elm_interface_scrollable is required by photocam. This means photocam
   needs to be adapted to fit the EO scroller API (still to be
   completed, I believe).

Bugs:
 - This breaks most C++ examples. I KNOW. And I'm working on it.

Ref T5301
2017-11-01 21:23:31 +09:00
Jean-Philippe Andre 2f465e1fbb widget: Rename EO APIs to efl_ui_widget_xxx
This only changes the eo_prefix for APIs.

Ref T5363
2017-10-24 14:30:21 +09:00
Lukasz Stanislawski 57aefc53c1 elm: rename Elm_Interface_Atspi_Accessible interface
Subscribers: cedric, jpeg

Differential Revision: https://phab.enlightenment.org/D5341
2017-10-19 10:13:54 +09:00
Marcel Hollerbach 9790de4b0c elm: include those headers in Elementary.h 2017-10-11 09:51:33 +02:00
Marcel Hollerbach a112aaafbb elm_colorselector: migrate to composition! 2017-10-10 19:28:47 +02:00
Jean-Philippe Andre a72f3ec64e efl: Use Eina.Size2D for size hint combined min
For this patch I decided to add a pseudo legacy wrapper as the function
is called in a very large number of places. Fixing all those calls to
use the size2d form is a lot of work and a greater risk of b0rking
something.
2017-09-18 16:33:33 +09:00
Jean-Philippe Andre f3eff6eb3e efl: Introduce Eina.Rect and switch EO APIs to it
It's a complex struct but defined in EO as a simple struct. ABI-wise
it's equivalent to Eina_Rectangle. Some macros that use Eina_Rectangle
also work on Eina_Rect out of the box, most of the code dealing with
x,y,w,h will require no modifications either.

But Eina_Rect provides direct access to a size or position 2d component,
as well as the usual x,y,w,h. The field "rect" is provided as a
convenience for code dealing with both Eina_Rectangle and Eina_Rect. We
may or may not require it.

Note: Size2D could use unsigned values but I have spotted a few places
in the code that actually use -1 to indicate invalid size (as opposed to
0x0).

@feature
2017-09-18 13:22:52 +09:00
Lukasz Stanislawski 9cf8e75668 elm: rename Elm.Interface.Atspi.Component => Efl.Access.Component
Reviewers: jpeg, cedric

Differential Revision: https://phab.enlightenment.org/D5164
2017-09-12 15:49:29 +09:00