2017-01-31 12:17:58 -08:00
|
|
|
import eina_types;
|
|
|
|
|
2019-02-14 08:37:02 -08:00
|
|
|
class @beta Efl.Container_Model extends Efl.Loop_Model
|
2017-01-31 12:17:58 -08:00
|
|
|
{
|
|
|
|
[[
|
|
|
|
Class used to create data models from Eina containers.
|
|
|
|
|
2017-12-20 01:41:41 -08:00
|
|
|
Each container supplied represents a series of property values, each item
|
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-30 20:35:34 -08:00
|
|
|
being the property value for a child object (@Efl.Container_Model_Item).
|
2017-01-31 12:17:58 -08:00
|
|
|
|
|
|
|
The data in the given containers are copied and stored internally.
|
|
|
|
|
2017-12-20 01:41:41 -08:00
|
|
|
Several containers can be supplied and the number of allocated children is
|
|
|
|
based on the container of the largest size.
|
2017-01-31 12:17:58 -08:00
|
|
|
]]
|
|
|
|
methods {
|
|
|
|
child_property_value_type_get {
|
docs: Fix typos and some wrong expressions in Ecore, Ecore_Audio, Ecore_Cocoa, Ecore_Con, and Ector API reference doxygen.
Summary: I had fixed some typos and wrong expressions, such as capital letters, $simbols in .eo and singulars in Ecore, Ecore_Audio, Ecore_Cocoa, Ecore_Con, and Ector API reference doxygen.
Test Plan: Doxygen Revision
Reviewers: Jaehyun_Cho, stefan, jpeg, cedric, raster
Reviewed By: Jaehyun_Cho
Differential Revision: https://phab.enlightenment.org/D4943
2017-06-06 21:01:13 -07:00
|
|
|
[[Gets the type of the given property.]]
|
2017-01-31 12:17:58 -08:00
|
|
|
params {
|
|
|
|
name: string; [[Property name]]
|
|
|
|
}
|
2018-11-13 00:27:02 -08:00
|
|
|
return: ptr(const(Eina.Value_Type)); [[Property type]]
|
2017-01-31 12:17:58 -08:00
|
|
|
}
|
|
|
|
child_property_values_get {
|
docs: Fix typos and some wrong expressions in Ecore, Ecore_Audio, Ecore_Cocoa, Ecore_Con, and Ector API reference doxygen.
Summary: I had fixed some typos and wrong expressions, such as capital letters, $simbols in .eo and singulars in Ecore, Ecore_Audio, Ecore_Cocoa, Ecore_Con, and Ector API reference doxygen.
Test Plan: Doxygen Revision
Reviewers: Jaehyun_Cho, stefan, jpeg, cedric, raster
Reviewed By: Jaehyun_Cho
Differential Revision: https://phab.enlightenment.org/D4943
2017-06-06 21:01:13 -07:00
|
|
|
[[Gets the values for the given property.]]
|
2017-01-31 12:17:58 -08:00
|
|
|
params {
|
|
|
|
name: string; [[Property name]]
|
|
|
|
}
|
2017-09-15 07:51:37 -07:00
|
|
|
return: iterator<void_ptr> @owned @warn_unused;
|
2017-01-31 12:17:58 -08:00
|
|
|
[[The currently wrapped values]]
|
|
|
|
}
|
|
|
|
child_property_add {
|
docs: Fix typos and some wrong expressions in Ecore, Ecore_Audio, Ecore_Cocoa, Ecore_Con, and Ector API reference doxygen.
Summary: I had fixed some typos and wrong expressions, such as capital letters, $simbols in .eo and singulars in Ecore, Ecore_Audio, Ecore_Cocoa, Ecore_Con, and Ector API reference doxygen.
Test Plan: Doxygen Revision
Reviewers: Jaehyun_Cho, stefan, jpeg, cedric, raster
Reviewed By: Jaehyun_Cho
Differential Revision: https://phab.enlightenment.org/D4943
2017-06-06 21:01:13 -07:00
|
|
|
[[Adds the given property to child objects and supply the values.
|
2017-01-31 12:17:58 -08:00
|
|
|
|
|
|
|
Each item will represent the value of the given property in the
|
|
|
|
respective child within the data model.
|
|
|
|
|
|
|
|
New children objects are allocated as necessary.
|
|
|
|
|
|
|
|
Value type is required for compatibility with the @Efl.Model API.]]
|
|
|
|
params {
|
|
|
|
name: string; [[Property name]]
|
2018-11-13 00:27:02 -08:00
|
|
|
@cref type: Eina.Value_Type; [[Property type]]
|
2017-09-15 07:51:37 -07:00
|
|
|
values: iterator<const(void_ptr)> @owned; [[Values to be added]]
|
2017-01-31 12:17:58 -08:00
|
|
|
}
|
|
|
|
return: bool; [[$true on success, $false otherwise]]
|
|
|
|
}
|
|
|
|
}
|
|
|
|
implements {
|
|
|
|
Efl.Object.constructor;
|
|
|
|
Efl.Object.destructor;
|
|
|
|
Efl.Model.properties { get; }
|
2017-10-25 18:03:43 -07:00
|
|
|
Efl.Model.property { set; get; }
|
2017-01-31 12:17:58 -08:00
|
|
|
Efl.Model.child_add;
|
|
|
|
Efl.Model.child_del;
|
|
|
|
Efl.Model.children_slice_get;
|
2017-10-25 18:03:43 -07:00
|
|
|
Efl.Model.children_count { get; }
|
2017-01-31 12:17:58 -08:00
|
|
|
}
|
|
|
|
}
|