This removes an argument that was false only for a single widget:
naviframe. Hopefully this logic is now simpler, even though it involves
a small hack within naviframe itself.
Ref T5363
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
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
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
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.
If item pop was started without focus at a naviframe object
and the naviframe object got focus before finising item pop,
the naviframe object could give focus to its first object of prev item.
It could ruin focus orders and failed to restore previous focused
object in the item.
To keep consistency of focus policy, same logic will be applied to
item push scenario.
@fix
Change-Id: Ia74bdce3620bd59622ef32a0cedf5fbd84815400
Summary:
Elm.Widget.event_callback_add conflicts with Efl.Object.event_callback_add.
To solve this problem, "widget_" prefix is added to methods starting with
"event".
Reviewers: cedric, jpeg
Differential Revision: https://phab.enlightenment.org/D4521
Summary:
- In commit rEFL9f5e9ec7ca120242a92ac97fb20016263c152d8e
previous view is raised after item pop transition
so that current view's pop animation can be shown.
- But, previous view has to be in it's proper size
during transition because some of animation might
show previous view.
Reviewers: Jaehyun_Cho
Subscribers: cedric, conr2d, jpeg
Differential Revision: https://phab.enlightenment.org/D4535
Previously, previous view was raised immediately when item pop is
started so previous view covers current view when item pop is started.
Now, previous view is raised after item pop is finished so previous view
covers current view when item pop is finished.
Change-Id: I86f343e0b49f3801d00e553755896f0eb756daa0
Summary:
Naviframe manages items in the form of a stack, but deletion is happening
in FIFO manner, the deletion of items on widget deletion should also happen
in LIFO manner.
Use Case: Application allocates memory on first push and passes down the same
handle for all subsequent pushes, now on deletion as first item is deleted first
crash happens when the memory is accessed in second item on its deletion.
hence Naviframe should also delete items in LIFO manner.
@feature
Test Plan:
elementary_test->naviframe->push multiple pages
Now terminate the app, the items should be deleted in LIFO
manner.
Reviewers: Hermet, Jaehyun, Jaehyun_Cho
Reviewed By: Jaehyun_Cho
Subscribers: cedric, govi, rajeshps, jpeg
Differential Revision: https://phab.enlightenment.org/D4483
Application developer could rewrite accessible information of naviframe item.
But view object - VIEW(item) - is not accessible from application side.
So the accessible information should be set to widget item.
It is necessary to check atspi role before sending a object:state-changed:showing signal.
The signal is fired when _elm_widget_efl_gfx_visible_set is called.
Previously, previous view became visible before pop transition begins by
"elm,state,prev,popped" signal.
Now, previous view become visible when pop transition begins by
"elm,state,prev,popped" signal.
Previously, previous view became visible before pop transition begins by
"elm,state,prev,popped,deferred" signal.
Now, previous view become visible when pop transition begins by
"elm,state,prev,popped,deferred" signal.
These are some of the EO files that shouldn't be part of the public
EO API:
- elm_access (old)
- actionslider
- bubble
- diskselector
- flipselector (a fancy spinner)
- hoversel (use combobox instead)
- icon (use image instead)
- inwin
- naviframe (unreplaced for now)
- photo (use image)
- prefs
- segment control
- separator
- slideshow
- thumb (use image)
Note: This breaks the use of the elm_widget_xxx.h headers. Those
were internal headers anyway. Exposed because of a lack of
a proper inheritance API.
These should be just overrides of Efl.Gfx.visible.set. Many
widgets were handling smart show() and hide() manually, which
means this patch is quite large.
Hopefully this doesn't break anything, obviously. But here are
some widgets known to be problematic, as the old code flow was
really strange (sometimes not calling the efl_super function):
- window
- notify
"item,activated" smart callback is added to notice when an item is
activated.
"item,activated" smart callback is called as follows.
1. Item push is finished and the new item is activated.
2. Item pop is finished and the previous item is activated.
void *event_info in smart callback is the activated item pointer.
"push,finished" and "pop,finished" smart callbacks are added to notice
when push and pop operation is finished.
New smart callback signals are added as follows.
"push,finished,item,activated" : Called when item push is finished and
void *event_info in smart callback is activated item (new item).
"push,finished,item,deactivated" : Called when item push is finished and
void *event_info in smart callback is deactivated item (current item).
"pop,finished,item,activated" : Called when item pop is finished and
void *event_info in smart callback is activated item (previous item).
"pop,finished,item,deactivated" : Called when item pop is finished and
void *event_info in smart callback is deactivated item (current item).
Efl.Object.event_callback_call no longer calls legacy smart callbacks;
calling only event callbacks registered with the given event description
pointer.
Create the method Efl.Object.event_callback_legacy_call to inherit the old
behavior from Efl.Object.event_callback_call, calling both Efl.Object events
and legacy smart callbacks.
Update all other files accordingly in order to still supply legacy
callbacks while they are necessary.
This reverts commit 8a988717e1.
It seems we can't actually inherit from class more than once and neither eo
nor eolian will complain about it. You will just get random weird behavior.
This patch should come back once we have made an interface of edje.
Summary:
if trying to apply incorrect theme, widget apply default theme and return TRUE.
so there is no way to check it really apply correct theme.
To resolve this problem, _elm_theme_set return three type enum
* related history : 4ca3ef4514
* elm_object_style_set is public api, so I didn't change it.
* typedef name [ Theme_Apply ] is temporarily, please suggest better one.
@fix
Reviewers: singh.amitesh, herb, Hermet, cedric, jpeg, raster
Subscribers: cedric, jpeg
Differential Revision: https://phab.enlightenment.org/D4073
Previously, preserved content was shown unexpectedly after its naviframe
item was popped because the preserved content was not removed but was
unset from its naviframe item.
Since popped naviframe item becomes hidden on the screen, the preserved
content of the popped naviframe item should become hidden by default as
well.
This touches Edje and also Elementary where part names are used.
This commit blew up in size since now all content part APIs
(get, set, unset) require to use Efl.Part instead.
This is a big refactoring commit, but no logic should
have been changed. Fingers crossed.
This removes Efl.Pack_Named which had a terrible name,
removes Elm.Container which should have been renamed
Efl.Ui.Container anyway, and introduces an interface
Efl.Container instead.
The hierarchy tree is now changed as objects don't inherit
from Efl.Container (it's an interface, not a regular class)
but only implement it. Obviously it is very easy to
reintroduce an Efl.Ui.Container parent class if we need it,
but I guess it should have some actual logic. It's basically
part of what Elm.Widget already does.
Some function names have been modified to look better in C
with the efl_content prefix.
@feature