Page MenuHomePhabricator

efl: add an event for the View to know if someone did bound a property.
ClosedPublic

Authored by cedric on Feb 13 2019, 10:51 AM.

Diff Detail

Repository
rEFL core/efl
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.
cedric created this revision.Feb 13 2019, 10:51 AM
cedric updated this revision to Diff 19783.Feb 27 2019, 1:39 PM

Rebase.

cedric updated this revision to Diff 19867.Mar 1 2019, 10:38 AM

Rebase.

cedric updated this revision to Diff 20053.Mar 6 2019, 3:41 PM

Rebase.

vitor.sousa requested changes to this revision.Mar 7 2019, 11:33 AM
vitor.sousa added a subscriber: vitor.sousa.
vitor.sousa added inline comments.
src/lib/elementary/efl_ui_layout_factory.c
133

The other ones are called after object state change, this one is called before.
Is there a convention about events in EFL regarding this matter?
Or, can we choose the call site in order to avoid code duplication?

src/lib/elementary/efl_ui_widget_factory.c
124

I think a stringshare outliving an eina_shutdown may be a problem if eina_init is called again.

This revision now requires changes to proceed.Mar 7 2019, 11:33 AM
cedric planned changes to this revision.Mar 7 2019, 11:38 AM
cedric added inline comments.
src/lib/elementary/efl_ui_layout_factory.c
133

Hum, I think you spotted a real potential problem. I think it makes more sense to have the callback triggered after the change otherwise any "get" function will just return the old information which would be weird, I think. What do you think?

src/lib/elementary/efl_ui_widget_factory.c
124

Good point, will fix.

vitor.sousa added inline comments.Mar 7 2019, 12:01 PM
src/lib/elementary/efl_ui_layout_factory.c
133

I agree with you.
I think I would prefer receiving the object already updated if handling such event.

cedric updated this revision to Diff 20272.Mar 7 2019, 4:00 PM

Rebase and fix reported issue.

vitor.sousa accepted this revision.Mar 8 2019, 7:09 AM
This revision is now accepted and ready to land.Mar 8 2019, 7:09 AM
cedric updated this revision to Diff 20340.Mar 8 2019, 1:57 PM

Rebase.

This revision was automatically updated to reflect the committed changes.