Commit Graph

27 Commits

Author SHA1 Message Date
Daniel Kolesa 1cd30eec90 efl_ui_layout, elm_layout_legacy: add missing/remove unused include
The efl_ui_layout.eo.h header was incorrectly not included in
Elementary.h, which resulted in build failures after the legacy
and otherwise unused efl_ui_layout.eo.legacy.h include was removed.
2019-04-18 15:35:49 +02:00
Carsten Haitzler afe26b831d Revert "elementary,evas: remove obsolete legacy includes"
This reverts commit c876ac52d9.

This is not safe to remove - this breaks enlightenment. perhaps test
with the reason efl exists in the first place before delcaring it
safe? specifically this removed some function symbols in
efl_canvas_event_grabber_eo.legacy.c ...
2019-03-09 15:59:10 +00:00
Daniel Kolesa c876ac52d9 elementary,evas: remove obsolete legacy includes
Summary:
Since the removal of legacy interfaces from eo files, these files
contain nothing useful, and can safely be removed. One exception
is `efl_ui_layout.eo.legacy.h`, which will require more involved
work to remove, since a lot of things seem to depend on the
Efl_Ui_Layout typedef being present, wrongly (i suspect this
will break everything with `EFL_NOLEGACY_API_SUPPORT`).

Reviewers: cedric, zmike, bu5hm4n

Reviewed By: zmike

Subscribers: #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D8251
2019-03-08 09:02:00 -05:00
Jaehyun Cho 2d460e52e4 elementary: remove Efl.Ui.Layout namespace
Summary:
Efl.Ui.Layout namespace is removed to keep consistency with other
widgets.
Consequently, "Efl.Ui.Layout.Object" is renamed to "Efl.Ui.Layout" and
"Efl.Ui.Layout." is renamed to "Efl.Ui.Layout_".

Reviewers: segfaultxavi, bu5hm4n, cedric

Reviewed By: segfaultxavi

Subscribers: #reviewers, #committers, SanghyeonLee, woohyun

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D7291
2018-11-16 11:11:13 +01:00
Xavi Artigas 6a98b84cd7 Efl.Ui.Layout.Object (from Efl.Ui.Layout)
Ref https://phab.enlightenment.org/T6847

Reviewed-by: Cedric Bail <cedric@osg.samsung.com>
2018-04-24 09:03:54 -07:00
Woochan Lee eb865ab537 elementary: add missed type for legacy.
Summary:
We've been missed type of class name.

Add legacy class name to maintain compatibility.

@fix

Reviewers: jpeg, woohyun, Jaehyun_Cho

Subscribers: cedric, jpeg

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

Signed-off-by: Cedric Bail <cedric@osg.samsung.com>
2018-03-06 19:05:57 -08:00
Pawel Aksiutowicz 59a573fabb elementary: fixed single typos in few modules
Reviewers: stanluk, lukasz.stanislawski

Reviewed By: lukasz.stanislawski

Subscribers: cedric, jpeg

Differential Revision: https://phab.enlightenment.org/D5534
2017-11-27 17:36:58 +09:00
Jean-Philippe Andre dee61f4097 elm: Cleanup theme and style set functions
This makes efl_ui_layout_theme_set() return a Theme_Apply error
code. The type is now public as Efl.Ui.Theme.Apply.

Ref T5329
Ref T5363
2017-08-09 17:08:24 +09:00
Jean-Philippe Andre 9a2d4928f0 elm: Rename elm_layout to Efl.Ui.Layout
Some names have not been changed, hopefully making a distinction
between legacy APIs and internal code (elm_layout_blah) and valid EO
usages.

This means many internal functions are still elm_layout_ as their
sole purpose is to support the legacy API.

Ref T5315
2017-08-08 13:25:58 +09:00
Jean-Philippe Andre 6864495c99 elm: Move elm_layout_sizing_eval to legacy
elm_layout_sizing_eval() marks an object as requiring recalc.

Unfortunately, it's been massively abused by various widgets into
actually doing the calc, or the min calc. So we end up with one API
that has 3 different definitions depending on the widget type:
1. Mark as requiring recalc (correct, respects doc, elm_layout)
2. Calculate min size and other size hints
3. Actually do some geometry modification

I believe we need to clarify these 3 requirements into 3 very clear
and specific APIs in elementary. Right now we have similar functions
in evas for 1 (evas_object_smart_changed) and 3 (smart_calculate).
But their exact definition also isn't necessarily what we want for
elementary.

Another clear problem is that layout_eval does not do any calculation
(in theory), so the "eval" word is a bit of a stretch here.

Once we're sure about the exact API we want, we can add this back to
EO and make it work across our EO widgets. For now let's just keep
the legacy API, and its EO overrides, as is.

Ref T5315
2017-08-08 11:10:56 +09:00
Jean-Philippe Andre 63f0dcc5fc layout: Fix compilation break
Oooops! This broke external apps!
2017-08-04 12:31:14 +09:00
Jean-Philippe Andre 4c8f87974c layout: Implement data_get from edje
This also implements size_min and size_max get.

Ref T5315
2017-08-04 11:52:17 +09:00
Jean-Philippe Andre 3e5cfb83c0 elm: Remove custom layout signal APIs
This merges them with the now standard interface:
  Efl.Canvas.Layout_Signal

Some wrapping work was required for legacy API which
takes no user_data in del() but instead returns it. The
new EO function, while harder to use, is more correct
(you can't delete the invalid callback by accident, and
this follows EO events design).

Another crazy wrapping was done in entry/text in order
to add the callbacks to 2 objects instead of just one,
and still return the user data.

As for Naviframe and Popup, those two widgets override
signal_emit to forward the call to another object than
the resize object, but not callback_add/del. So they
are definitely broken.

Ref T5315
2017-08-04 11:52:16 +09:00
Jean-Philippe Andre 82e6100322 layout: Move Part_Alias struct to legacy
Part aliases need to be handled differently in EO.

Ref T5315
2017-08-04 11:52:16 +09:00
Jean-Philippe Andre f0730f6f4c layout: Move edje_get to legacy only
Here's the reasoning:
 1. We will expose as many edje APIs as possible (and meaningful)
    through the elm layout class.
 2. Access to internal objects is usually risky, as it allows apps
    to bypass EFL in some ways, leading to potentially undefined
    behaviours.
 3. If the need arises we can still add a similar API back to EO,
    later.

Back to #1, it seems that the need for edje_get() was mostly to
call manual sizing functions, or the missing message_send(). I will
make sure these are accessible from the layout itself.

Ref T5315
2017-08-04 11:52:16 +09:00
Jean-Philippe Andre 7ba0ab5182 layout: Implement freeze and thaw from interface
This implements part of the interface
  Efl.Canvas.Layout_Calc
2017-08-04 11:52:16 +09:00
Jean-Philippe Andre a4c3929894 layout: Implement cursor part APIs with efl_part
This makes layout parts implement Efl.Ui.Cursor.
This also adds the missing bool returns from that interface.

This removes 7 APIs from Elm.Layout.

Ref T5315
2017-08-04 11:52:16 +09:00
Jean-Philippe Andre f63a564817 layout: Move edje_object_can_access to legacy
This is an API enabling accessibility on text(block) parts
in a layout. But it is said to have many issues. I can already
see that it only changes a flag but doesn't trigger any code
to create the appropriate objects, so definitely not fully
working.

According to @kimcinoo this may remain in legacy land for now.
2017-08-04 11:52:16 +09:00
Daniel Zaoui 08db4a6caf Layout/legacy: rename object type
Enlightenment and terminology compilations fail because Elm_Layout is
not known.
2017-06-05 11:49:08 +03:00
Daniel Hirt 3eb649b180 Elm layout: replace 'text' property with 'efl_part' interface
The expected usage is efl_text_set(efl_part(layout, part), text);
Same for text_get.

Also, added an example how to make API easier with providing
efl_text_set/get for the widget itself, in efl_ui_button. Please see
this example.
2017-06-05 02:08:03 +03:00
Jean-Philippe Andre 1ce8c1c3d1 Revert "elm_layout: Implement Efl.Text"
This reverts commit 584e17ae84.

After talking to @herdsman (before xmas) we concluded that we
didn't necessarily want a generic version of efl_text_set/get
for elm_layout. Instead, each widget that should have a default
text part should implement text_set/get themselves (very simple).

Note that Efl.Ui.Text somehow does not "implement" efl_text when
looking at the eolian files. It works by composition.
2017-01-05 10:37:19 +09:00
Jean-Philippe Andre 584e17ae84 elm_layout: Implement Efl.Text
This implements support for efl_text_set() for the default
part (NULL). This also adds support for efl_text_set(efl_part())
for layouts. This should cover a LOT of widgets :)

The next step is to remove Elm.Layout.text but it's used in too
many places at the moment. @herdsman!!
2016-12-16 18:53:33 +09:00
Andrii Kroitor 595ae821ba elm_layout: add mmap support
Reviewers: cedric, Hermet, raster, NikaWhite

Subscribers: jpeg, reutskiy.v.v

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

Signed-off-by: Cedric BAIL <cedric@osg.samsung.com>
2016-11-07 14:42:07 -08:00
Hermet Park 4afcd85168 elementary/layout: changed to Evas_Object * from Elm_Layout * in legacy header.
if EFL_EO_API_SUPPORT is not defined in user side, this will break the build.
because Elm_Layout type is defined in eo header file.

Just keep using Evas_Object * in legacy yet.
2016-06-28 13:15:56 +09:00
Jee-Yong Um 8a988717e1 elementary/layout: attach edje object API with eo compositing
Test Plan: make check

Reviewers: Hermet, jpeg, cedric

Subscribers: slotus.lee

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

Signed-off-by: Cedric Bail <cedric@osg.samsung.com>
2016-06-27 11:18:05 -07:00
Jean-Philippe Andre e7f0b64860 Elm.Layout: Replace box & table part API by fake object
This moves the part_box and part_table APIs to a fake object
like was done in Edje Object.

This also adds support a few new APIs to those containers,
so they behave exactly like Edje.Object.

This is another implementation bit of "eo_part".
2016-04-26 14:16:32 +09:00
Cedric BAIL c2a1c49ab2 elementary: move all legacy files to their expected new location. 2016-03-23 13:24:41 -07:00