Commit Graph

13 Commits

Author SHA1 Message Date
Cedric BAIL 652533e27d ecore: remove the composited children from the source of an Efl.CompositeModel.
The composite model was erroneously giving the reference to a children composited model
instead of the origianl children which made it impossible for the composited model
to delete the right child.

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D10631
2019-11-13 21:16:14 +01:00
Cedric Bail 6e49752712 ecore: correctly handle children removal in Efl.Composite_Model by updating all required index.
Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D10032
2019-09-24 09:18:42 +02:00
SangHyeon Jade Lee 4e379f5db4 Efl_Ui: Move elementary and change namespace Ui for ui related models
Summary:
Select and View is ui characteristic features,
so Efl_Select_Model and Efl_View_Model move to elementary from ecore
seems more natural.

namespace also should changed to Efl.Ui as it's right place.

Test Plan: run the test while building it

Reviewers: cedric, felipealmeida, bu5hm4n, zmike, lauromoura

Reviewed By: zmike

Subscribers: #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D9820
2019-09-04 11:07:37 -04:00
Cedric BAIL fce5645d80 efl: use eina_streq for all property operation in model to avoid crash on NULL property name.
Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D9266
2019-07-10 21:10:23 +02:00
Cedric BAIL c96c9a5b83 ecore: enable property reflection support in Efl.CompositeModel.
Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D8754
2019-05-29 11:17:02 -07:00
Cedric BAIL dac867bb24 ecore: refactor Efl.CompositeModel to provide child allocation to other internal Model.
Reviewed-by: SangHyeon Jade Lee <sh10233.lee@samsung.com>
Differential Revision: https://phab.enlightenment.org/D8796
2019-05-09 09:33:31 -07:00
Cedric BAIL 7b7ad5380a ecore: property handle allocation error in Efl.CompositeModel.
Reviewed-by: SangHyeon Jade Lee <sh10233.lee@samsung.com>
Differential Revision: https://phab.enlightenment.org/D8795
2019-05-09 09:33:29 -07:00
Cedric BAIL 78563a395e ecore: properly handle CHILD_ADDED and CHILD_REMOVED from source for Efl.CompositeModel
Before this patch we were directly sending this event on the Efl.CompositeModel, but they
actually might contain an Efl.Model in the event child field. That Efl.Model wouldn't have
been converted before to an Efl.CompositeModel exposing incoherence from the user of
the object point of view. This patch fix that behavior.

Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D8661
2019-04-26 11:32:55 -07:00
Cedric BAIL 13b230029d ecore: use new infrastructure for Efl.CompositeModel to only have one Model object represent its data at any point in time.
Reviewed-by: Marcel Hollerbach <mail@marcel-hollerbach.de>
Differential Revision: https://phab.enlightenment.org/D8660
2019-04-26 11:32:52 -07:00
Cedric BAIL 3730447f0c ecore: move property string definition to shared headers for Efl.Composite_Model.
Reviewed-by: SangHyeon Jade Lee <sh10233.lee@samsung.com>
Reviewed-by: Xavi Artigas <xavierartigas@yahoo.es>
Differential Revision: https://phab.enlightenment.org/D8568
2019-04-18 15:26:39 -07:00
Cedric BAIL 7bd3942e23 ecore: prevent duplication of children for Efl.Composite_Model and enable dummy object.
This patch allow Efl.Composite_Model to return always the same object for the same index.
This way, it make it easier for the Model to always be in sync even if there is multiple
user at any time. The support for dummy object allow the Composite_Model to host more
object than what the source model provide. This dummy model will only have the property
of the Composite_Model and none of the Source model ofcourse.

Reviewed-by: Vitor Sousa da Silva <vitorsousa@expertisesolutions.com.br>
Differential Revision: https://phab.enlightenment.org/D8045
2019-02-28 11:39:46 -08:00
Cedric BAIL 790fc1b8c5 ecore: enforce proper lifecycle for all Efl.Composite_Model children.
Summary:
This make sure that the object returned by children_slice_get are properly
destroyed when the refcount drop to only the parent holding a reference on
it. This make it clear that the user of the api can rely on efl_ref/efl_unref
to actually manage its use of the returned object.

Reviewers: felipealmeida, segfaultxavi, SanghyeonLee, zmike, bu5hm4n

Reviewed By: segfaultxavi, zmike

Subscribers: #reviewers, #committers

Tags: #efl

Maniphest Tasks: T7528

Differential Revision: https://phab.enlightenment.org/D7864
2019-02-23 08:57:10 -05:00
SangHyeon Jade Lee 5525c89a3d efl_model : rename all efl_model based classes.
Summary:
As the result of discussion in T7458,
we need to rename all efl_model based classes with efl_XXX_Model sequence.
I've run few vote for this, see V42, V43
few classes are totally renamed as our consideration of misnaming.

| Efl.Model_Loop | Efl.Loop_Model |
| Efl.Model_Item | Efl.Generic_Model |
| Efl.Model_Container | Efl.Container_Model |
| Efl.Model_Container_Item | Efl.Container_Model_Item |
| Efl.Model_Composite | Efl.Composite_Model |
| Efl.Model_Composite_Boolean | Efl.Boolean_Model |
| Efl.Model_Composite_Boolean_Chlidren | Efl.Boolean_Model_Item |
| Efl.Model_Composite_Selection | Efl.Select_Model |
| Efl.Model_Composite_Selection_Chlidren | Efl.Select_Model_Item |
| Efl.Model_View | Efl.View_Model |
| Eio.Model | Efl.Io.Model |
| Efl.Ui.Model_State | Efl.Ui.State_Model |
| Efl.Ui.Model_Size | Efl.Ui.Size_Model |
| Efl.Ui.Model_Exact | Efl.Ui.Exact_Model |
| Efl.Ui.Model_Average | Efl.Ui.Average_Model |
| Efl.Ui.Model_Homogeneous | Efl.Ui.Homogeneous_Model |

I worried about Efl.Io.Model changes, cause it is widely used,
but as I tested, there is no issue found yet.

Eldbus.Model also may can changed Efl.Dbus.Model,
but I cannot found any class who using Efl.Dbus namespace,
so I left it future work.

Test Plan:
Run the Make Test,
it works well except Efl test about selection.
there are class inheritance problem exist in select_model,
I reported it and will fix it in another patch.

Reviewers: cedric, felipealmeida, woohyun, Hermet

Reviewed By: cedric

Subscribers: lauromoura

Tags: #efl, #do_not_merge

Differential Revision: https://phab.enlightenment.org/D7533
2019-01-31 14:59:37 +09:00