summaryrefslogtreecommitdiff
path: root/src/examples/elementary
diff options
context:
space:
mode:
authorSangHyeon Jade Lee <sh10233.lee@samsung.com>2019-01-31 11:59:19 +0000
committerCedric BAIL <cedric.bail@free.fr>2019-02-11 11:06:13 -0800
commit053146598c346aa7c200aee55093a5e463d255de (patch)
tree44c1acdd0761d0ed48a4ac70121d686504a24a4d /src/examples/elementary
parent9277586fd8244826bdfbbc7625c3a08be71f5e06 (diff)
efl_ui : rename model connect and factory connect to bind property and factory.
As we discussed in T7469 with V40, efl_ui_model_connect efl_ui_factory_model_connect need to be renamed to efl_ui_bind_property efl_ui_bind_factory for this work, Efl.Ui.Model.Connect interface is changed as Efl.Ui.Bind, and bind_property and bind_factory both method is supported by this interface. bind_factory need Efl.Ui.Factory, and Efl.Ui.Factory inheritted Efl.Ui.Bind, so I little bit concerned about circular referencing, but so far, it works well. Reviewed-by: Cedric BAIL <cedric.bail@free.fr> Differential Revision: https://phab.enlightenment.org/D7529
Diffstat (limited to 'src/examples/elementary')
-rw-r--r--src/examples/elementary/.gitignore2
-rw-r--r--src/examples/elementary/efl_ui_list_view_example_1.c6
-rw-r--r--src/examples/elementary/efl_ui_list_view_example_2.c6
-rw-r--r--src/examples/elementary/efl_ui_list_view_example_3.c12
-rw-r--r--src/examples/elementary/layout_property_bind.c (renamed from src/examples/elementary/layout_model_connect.c)0
5 files changed, 13 insertions, 13 deletions
diff --git a/src/examples/elementary/.gitignore b/src/examples/elementary/.gitignore
index 54d71c14a0..11544b23ee 100644
--- a/src/examples/elementary/.gitignore
+++ b/src/examples/elementary/.gitignore
@@ -58,7 +58,7 @@
58/layout_example_01 58/layout_example_01
59/layout_example_02 59/layout_example_02
60/layout_example_03 60/layout_example_03
61/layout_model_connect 61/layout_property_bind
62/list_example_01 62/list_example_01
63/list_example_02 63/list_example_02
64/list_example_03 64/list_example_03
diff --git a/src/examples/elementary/efl_ui_list_view_example_1.c b/src/examples/elementary/efl_ui_list_view_example_1.c
index 635a603a35..597d6c3ed1 100644
--- a/src/examples/elementary/efl_ui_list_view_example_1.c
+++ b/src/examples/elementary/efl_ui_list_view_example_1.c
@@ -87,9 +87,9 @@ elm_main(int argc EINA_UNUSED, char **argv EINA_UNUSED)
87 ); 87 );
88 88
89 factory = efl_add(EFL_UI_LAYOUT_FACTORY_CLASS, win); 89 factory = efl_add(EFL_UI_LAYOUT_FACTORY_CLASS, win);
90 efl_ui_model_connect(factory, "signal/efl,state,%v", "odd_style"); 90 efl_ui_property_bind(factory, "signal/efl,state,%v", "odd_style");
91 efl_ui_model_connect(factory, "signal/efl,state,%{selected;unselected}", "selected"); 91 efl_ui_property_bind(factory, "signal/efl,state,%{selected;unselected}", "selected");
92 efl_ui_model_connect(factory, "efl.text", "name"); 92 efl_ui_property_bind(factory, "efl.text", "name");
93 efl_ui_layout_factory_theme_config(factory, "list_item", NULL, "default"); 93 efl_ui_layout_factory_theme_config(factory, "list_item", NULL, "default");
94 94
95 li = efl_add(EFL_UI_LIST_VIEW_CLASS, win 95 li = efl_add(EFL_UI_LIST_VIEW_CLASS, win
diff --git a/src/examples/elementary/efl_ui_list_view_example_2.c b/src/examples/elementary/efl_ui_list_view_example_2.c
index 50f0706a0d..8721342fd6 100644
--- a/src/examples/elementary/efl_ui_list_view_example_2.c
+++ b/src/examples/elementary/efl_ui_list_view_example_2.c
@@ -33,7 +33,7 @@ elm_main(int argc EINA_UNUSED, char **argv EINA_UNUSED)
33 33
34 model = efl_add(EFL_IO_MODEL_CLASS, win, efl_io_model_path_set(efl_added, dirname)); 34 model = efl_add(EFL_IO_MODEL_CLASS, win, efl_io_model_path_set(efl_added, dirname));
35 factory = efl_add(EFL_UI_LAYOUT_FACTORY_CLASS, win); 35 factory = efl_add(EFL_UI_LAYOUT_FACTORY_CLASS, win);
36 efl_ui_model_connect(factory, "efl.text", "filename"); 36 efl_ui_property_bind(factory, "efl.text", "filename");
37 efl_ui_layout_factory_theme_config(factory, "list_item", NULL, "default"); 37 efl_ui_layout_factory_theme_config(factory, "list_item", NULL, "default");
38 38
39 li = efl_add(EFL_UI_LIST_VIEW_CLASS, win); 39 li = efl_add(EFL_UI_LIST_VIEW_CLASS, win);
@@ -45,8 +45,8 @@ elm_main(int argc EINA_UNUSED, char **argv EINA_UNUSED)
45 45
46 46
47 imgf = efl_add(EFL_UI_IMAGE_FACTORY_CLASS, win); 47 imgf = efl_add(EFL_UI_IMAGE_FACTORY_CLASS, win);
48 efl_ui_model_connect(imgf, "", "path"); //connect to "path" property 48 efl_ui_property_bind(imgf, "", "path"); //connect to "path" property
49 efl_ui_factory_model_connect(factory, "efl.icon", imgf); 49 efl_ui_factory_bind(factory, "efl.icon", imgf);
50 50
51 elm_win_resize_object_add(win, li); 51 elm_win_resize_object_add(win, li);
52 52
diff --git a/src/examples/elementary/efl_ui_list_view_example_3.c b/src/examples/elementary/efl_ui_list_view_example_3.c
index 633c6e1c0d..47718a83d4 100644
--- a/src/examples/elementary/efl_ui_list_view_example_3.c
+++ b/src/examples/elementary/efl_ui_list_view_example_3.c
@@ -150,8 +150,8 @@ _realized_1_cb(void *data EINA_UNUSED, const Efl_Event *event)
150 150
151 evas_object_size_hint_weight_set(ie->layout, EVAS_HINT_EXPAND, 0); 151 evas_object_size_hint_weight_set(ie->layout, EVAS_HINT_EXPAND, 0);
152 evas_object_size_hint_align_set(ie->layout, EVAS_HINT_FILL, EVAS_HINT_FILL); 152 evas_object_size_hint_align_set(ie->layout, EVAS_HINT_FILL, EVAS_HINT_FILL);
153 efl_ui_model_connect(ie->layout, "efl.text", "name"); 153 efl_ui_property_bind(ie->layout, "efl.text", "name");
154 efl_ui_model_connect(ie->layout, "signal/efl,state,%v", "odd_style"); 154 efl_ui_property_bind(ie->layout, "signal/efl,state,%v", "odd_style");
155} 155}
156 156
157static void 157static void
@@ -163,7 +163,7 @@ _realized_2_cb(void *data EINA_UNUSED, const Efl_Event *event)
163 elm_object_focus_allow_set(ie->layout, EINA_TRUE); 163 elm_object_focus_allow_set(ie->layout, EINA_TRUE);
164 evas_object_size_hint_weight_set(ie->layout, EVAS_HINT_EXPAND, 0); 164 evas_object_size_hint_weight_set(ie->layout, EVAS_HINT_EXPAND, 0);
165 evas_object_size_hint_align_set(ie->layout, EVAS_HINT_FILL, EVAS_HINT_FILL); 165 evas_object_size_hint_align_set(ie->layout, EVAS_HINT_FILL, EVAS_HINT_FILL);
166 efl_ui_model_connect(ie->layout, "efl.text", "occupation"); 166 efl_ui_property_bind(ie->layout, "efl.text", "occupation");
167} 167}
168 168
169static Efl_Model* 169static Efl_Model*
@@ -222,7 +222,7 @@ elm_main(int argc EINA_UNUSED, char **argv EINA_UNUSED)
222 222
223 priv->model = _make_model(); 223 priv->model = _make_model();
224 factory = efl_add(EFL_UI_LAYOUT_FACTORY_CLASS, win); 224 factory = efl_add(EFL_UI_LAYOUT_FACTORY_CLASS, win);
225 efl_ui_model_connect(factory, "efl.text", "filename"); 225 efl_ui_property_bind(factory, "efl.text", "filename");
226 efl_ui_layout_factory_theme_config(factory, "list_item", NULL, "default"); 226 efl_ui_layout_factory_theme_config(factory, "list_item", NULL, "default");
227 227
228 priv->list1 = efl_add(EFL_UI_LIST_VIEW_CLASS, win, efl_ui_view_model_set(efl_added, priv->model)); 228 priv->list1 = efl_add(EFL_UI_LIST_VIEW_CLASS, win, efl_ui_view_model_set(efl_added, priv->model));
@@ -233,8 +233,8 @@ elm_main(int argc EINA_UNUSED, char **argv EINA_UNUSED)
233 efl_ui_list_view_layout_factory_set(priv->list1, factory); 233 efl_ui_list_view_layout_factory_set(priv->list1, factory);
234 234
235 factory = efl_add(EFL_UI_LAYOUT_FACTORY_CLASS, win); 235 factory = efl_add(EFL_UI_LAYOUT_FACTORY_CLASS, win);
236 efl_ui_model_connect(factory, "efl.text", "filename"); 236 efl_ui_property_bind(factory, "efl.text", "filename");
237 efl_ui_model_connect(factory, "signal/efl,state,%v", "selected"); 237 efl_ui_property_bind(factory, "signal/efl,state,%v", "selected");
238 efl_ui_layout_factory_theme_config(factory, "list_item", NULL, "default"); 238 efl_ui_layout_factory_theme_config(factory, "list_item", NULL, "default");
239 priv->list2 = efl_add(EFL_UI_LIST_VIEW_CLASS, win, efl_ui_view_model_set(efl_added, priv->model)); 239 priv->list2 = efl_add(EFL_UI_LIST_VIEW_CLASS, win, efl_ui_view_model_set(efl_added, priv->model));
240 efl_event_callback_add(priv->list2, EFL_UI_LIST_VIEW_EVENT_ITEM_REALIZED, _realized_2_cb, priv->list2); 240 efl_event_callback_add(priv->list2, EFL_UI_LIST_VIEW_EVENT_ITEM_REALIZED, _realized_2_cb, priv->list2);
diff --git a/src/examples/elementary/layout_model_connect.c b/src/examples/elementary/layout_property_bind.c
index 65103d49d4..65103d49d4 100644
--- a/src/examples/elementary/layout_model_connect.c
+++ b/src/examples/elementary/layout_property_bind.c