Commit Graph

13 Commits

Author SHA1 Message Date
Mike Blumenkrantz bedb6df973 efl_ui/popup: remove anchor_popup class
Summary:
all functionality is now merged into the base popup class. this greatly
simplifies the codebase and deduplicates a lot of code

ref T7902
Depends on D9651

Reviewers: cedric

Reviewed By: cedric

Subscribers: herb, cedric, #reviewers, #committers

Tags: #efl_widgets

Maniphest Tasks: T7902

Differential Revision: https://phab.enlightenment.org/D9652
2019-08-21 10:42:04 -04:00
Mike Blumenkrantz 3aee9a96c0 efl_ui/popup: optimize popup sizing calcs slightly
ensure that scroll-based popups don't accidentally trigger a full
recalc and (wrong) size change during group_calc by hitting the base
popup size_set() implementation and setting the needs_calc flag or
by using the base popup calc code when it should not be used

this resolves a corner case sizing issue in the text_alert 2 popup
case in elm_test which seems to have been present for a long time

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9538
2019-08-09 10:25:26 -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
Jaehyun Cho 0722992790 efl_ui_popup: Code refactorying for elm_layout_sizing_eval
Use flags for group calculation, size calculation and align calculation.

If the flag for size calculation is set to be false, then size is not
calculated in the efl_canvas_group_calcualte().
(The flag for align calculation works the same way.)

Efl.Ui.Popup's sub classes can set the above flags false before they
call efl_canvas_group_calculate() with its super class not to calculate
size or align by its super class.
2017-12-14 13:58:06 +09:00
Jaehyun Cho 10761cf2f5 efl_ui_popup: Update size calculation logic
Instead of doing size calculation whenever elm_layout_sizing_eval() is
called, do size calculation when the object is rendered like
efl_ui_layout.
2017-12-11 13:33:12 +09:00
Jaehyun Cho c752d8fe6b efl_ui_popup: Make backwall efl part object of Efl.Ui.Popup 2017-11-28 17:15:42 +09:00
Jaehyun Cho 91df6723c9 efl_ui_popup: Rename bg_set with backwall_set
Since "background" is used as a basic part property, "backwall" is used
to indicate the area behind efl_ui_popup.
2017-11-28 17:15:42 +09:00
Jaehyun Cho b85cebdb96 efl_ui_popup: Code refactoring to replace legacy APIs 2017-11-28 17:15:42 +09:00
Taehyub Kim 8d315ce7aa efl_ui_popup: add timeout property
Summary: add timeout property

Test Plan:
1. run elementary_test -to efluipopup
2. after 3 seconds, popup will be delete

Reviewers: Jaehyun_Cho, jpeg, woohyun, thiepha, Blackmole, cedric

Reviewed By: Jaehyun_Cho

Differential Revision: https://phab.enlightenment.org/D5205
2017-11-28 17:15:42 +09:00
JinYong Park 0365bf1e13 efl_ui_popup: use efl_data_scope_get instead of using 'self' object
Summary:
Use efl_data_scope_get to get Efl_Ui_Popup_Data structure.
There is no reason using "self" object in Efl_Ui_Popup_Data.

Reviewers: Jaehyun_Cho, herb, thiepha, woohyun, jpeg, cedric

Reviewed By: cedric

Differential Revision: https://phab.enlightenment.org/D5128
2017-11-28 17:15:42 +09:00
Taehyub Kim 0005b3105e efl_ui_popup: add align and position properties
Summary:
add align feature and position properties (center, left, right, top, bottom)
efl_ui_popup_position_set should be seperated from evas_object_move
since evas_object_move can be called internally.

Test Plan: 1. run elementary_test -to efluipopup

Reviewers: Jaehyun_Cho, jpeg, cedric, thiepha, Blackmole, woohyun

Reviewed By: Jaehyun_Cho

Differential Revision: https://phab.enlightenment.org/D5105
2017-11-28 17:15:42 +09:00
JinYong Park bccd97bd62 efl_ui_popup: add bg_set and bg_repeat_events_set/get API
Summary:
add bg_set and bg_repeat_events_set/get API
bg_set enables user change popup's outside bg
bg_repeat_events_set enables popup's outside bg repeat events

Test Plan:
 1. run elementary_test -to efluipopup
 2. click outside area of popup
 3. click button in popup

Reviewers: Jaehyun_Cho, herb, thiepha, woohyun, cedric, jpeg, singh.amitesh

Reviewed By: Jaehyun_Cho

Subscribers: jpeg

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D5054
2017-11-28 17:15:42 +09:00
Taehyub Kim 996a975506 efl_ui_popup: add Efl.Ui.Popup class
Summary: add initial code for Efl.Ui.Popup class

Test Plan: 1. run elementary_test -to efluipopup

Reviewers: Jaehyun_Cho, Blackmole, thiepha, woohyun, cedric

Reviewed By: Jaehyun_Cho

Subscribers: bu5hm4n, cedric, jpeg

Differential Revision: https://phab.enlightenment.org/D5037
2017-11-28 17:15:42 +09:00