summaryrefslogtreecommitdiff
path: root/legacy/elementary/src
diff options
context:
space:
mode:
authorChunEon Park <hermet@hermet.pe.kr>2011-10-31 02:56:03 +0000
committerChunEon Park <hermet@hermet.pe.kr>2011-10-31 02:56:03 +0000
commitf856c0e9fefe98738cd030fc5692743f1a50ed86 (patch)
treebad0cb506649d173da0d7dc1cd88db66c1fe7217 /legacy/elementary/src
parent8e5a6ce75f2ffc0ad7f69703db7518ae7975b8a9 (diff)
elementary - slider, scroller, progressbar, radio
applied elm_object_content_set/get/unset APIs. SVN revision: 64542
Diffstat (limited to '')
-rw-r--r--legacy/elementary/src/bin/config.c4
-rw-r--r--legacy/elementary/src/bin/test_anchorblock.c2
-rw-r--r--legacy/elementary/src/bin/test_button.c2
-rw-r--r--legacy/elementary/src/bin/test_ctxpopup.c2
-rw-r--r--legacy/elementary/src/bin/test_factory.c2
-rw-r--r--legacy/elementary/src/bin/test_focus.c4
-rw-r--r--legacy/elementary/src/bin/test_launcher.c6
-rw-r--r--legacy/elementary/src/bin/test_photo.c2
-rw-r--r--legacy/elementary/src/bin/test_progressbar.c4
-rw-r--r--legacy/elementary/src/bin/test_radio.c8
-rw-r--r--legacy/elementary/src/bin/test_scroller.c9
-rw-r--r--legacy/elementary/src/bin/test_slider.c12
-rw-r--r--legacy/elementary/src/bin/test_thumb.c2
-rw-r--r--legacy/elementary/src/bin/test_win_inline.c2
-rw-r--r--legacy/elementary/src/edje_externals/elm_progressbar.c4
-rw-r--r--legacy/elementary/src/edje_externals/elm_radio.c4
-rw-r--r--legacy/elementary/src/edje_externals/elm_scroller.c6
-rw-r--r--legacy/elementary/src/edje_externals/elm_slider.c4
-rw-r--r--legacy/elementary/src/examples/progressbar_example.c4
-rw-r--r--legacy/elementary/src/examples/radio_example_01.c4
-rw-r--r--legacy/elementary/src/examples/scroller_example_01.c2
-rw-r--r--legacy/elementary/src/examples/slider_example.c4
-rw-r--r--legacy/elementary/src/lib/Elementary.h.in47
-rw-r--r--legacy/elementary/src/lib/elc_anchorview.c2
-rw-r--r--legacy/elementary/src/lib/elc_ctxpopup.c2
-rw-r--r--legacy/elementary/src/lib/elm_map.c2
-rw-r--r--legacy/elementary/src/lib/elm_progressbar.c85
-rw-r--r--legacy/elementary/src/lib/elm_radio.c84
-rw-r--r--legacy/elementary/src/lib/elm_scroller.c107
-rw-r--r--legacy/elementary/src/lib/elm_slider.c199
30 files changed, 377 insertions, 244 deletions
diff --git a/legacy/elementary/src/bin/config.c b/legacy/elementary/src/bin/config.c
index 4e662ea..35f38f4 100644
--- a/legacy/elementary/src/bin/config.c
+++ b/legacy/elementary/src/bin/config.c
@@ -1453,7 +1453,7 @@ _status_config_themes(Evas_Object *win,
1453 evas_object_show(sc); 1453 evas_object_show(sc);
1454 1454
1455 sample = _sample_theme_new(win); 1455 sample = _sample_theme_new(win);
1456 elm_scroller_content_set(sc, sample); 1456 elm_object_content_set(sc, sample);
1457 evas_object_show(sample); 1457 evas_object_show(sample);
1458 evas_object_data_set(win, "theme_preview", sample); 1458 evas_object_data_set(win, "theme_preview", sample);
1459 1459
@@ -2443,7 +2443,7 @@ _status_config_scrolling(Evas_Object *win,
2443 evas_object_size_hint_align_set(sc, EVAS_HINT_FILL, EVAS_HINT_FILL); 2443 evas_object_size_hint_align_set(sc, EVAS_HINT_FILL, EVAS_HINT_FILL);
2444 elm_scroller_bounce_set(sc, EINA_FALSE, EINA_TRUE); 2444 elm_scroller_bounce_set(sc, EINA_FALSE, EINA_TRUE);
2445 evas_object_show(sc); 2445 evas_object_show(sc);
2446 elm_scroller_content_set(sc, bx); 2446 elm_object_content_set(sc, bx);
2447 2447
2448 ck = elm_check_add(win); 2448 ck = elm_check_add(win);
2449 elm_object_tooltip_text_set(ck, "Set whether scrollers should bounce<br>" 2449 elm_object_tooltip_text_set(ck, "Set whether scrollers should bounce<br>"
diff --git a/legacy/elementary/src/bin/test_anchorblock.c b/legacy/elementary/src/bin/test_anchorblock.c
index 0f9818b..a94586c 100644
--- a/legacy/elementary/src/bin/test_anchorblock.c
+++ b/legacy/elementary/src/bin/test_anchorblock.c
@@ -230,7 +230,7 @@ test_anchorblock(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event
230 elm_box_pack_end(bx, bb); 230 elm_box_pack_end(bx, bb);
231 evas_object_show(bb); 231 evas_object_show(bb);
232 232
233 elm_scroller_content_set(sc, bx); 233 elm_object_content_set(sc, bx);
234 evas_object_show(bx); 234 evas_object_show(bx);
235 235
236 evas_object_show(sc); 236 evas_object_show(sc);
diff --git a/legacy/elementary/src/bin/test_button.c b/legacy/elementary/src/bin/test_button.c
index 95abab1..f2f1fb3 100644
--- a/legacy/elementary/src/bin/test_button.c
+++ b/legacy/elementary/src/bin/test_button.c
@@ -55,7 +55,7 @@ test_button(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event_info
55 55
56 bx = elm_box_add(win); 56 bx = elm_box_add(win);
57 evas_object_size_hint_weight_set(bx, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); 57 evas_object_size_hint_weight_set(bx, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
58 elm_scroller_content_set(scr, bx); 58 elm_object_content_set(scr, bx);
59 evas_object_show(bx); 59 evas_object_show(bx);
60 60
61 ic = elm_icon_add(win); 61 ic = elm_icon_add(win);
diff --git a/legacy/elementary/src/bin/test_ctxpopup.c b/legacy/elementary/src/bin/test_ctxpopup.c
index c856a9e..ac6d030 100644
--- a/legacy/elementary/src/bin/test_ctxpopup.c
+++ b/legacy/elementary/src/bin/test_ctxpopup.c
@@ -188,7 +188,7 @@ _list_item_cb5(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event_i
188 elm_object_text_set(btn, "Enlightenment"); 188 elm_object_text_set(btn, "Enlightenment");
189 evas_object_size_hint_min_set(btn, 140, 140); 189 evas_object_size_hint_min_set(btn, 140, 140);
190 190
191 elm_scroller_content_set(sc, btn); 191 elm_object_content_set(sc, btn);
192 192
193 elm_box_pack_end(bx, sc); 193 elm_box_pack_end(bx, sc);
194 194
diff --git a/legacy/elementary/src/bin/test_factory.c b/legacy/elementary/src/bin/test_factory.c
index bd66219..a6e96eb 100644
--- a/legacy/elementary/src/bin/test_factory.c
+++ b/legacy/elementary/src/bin/test_factory.c
@@ -178,7 +178,7 @@ test_factory(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event_inf
178 evas_object_size_hint_weight_set(sc, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); 178 evas_object_size_hint_weight_set(sc, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
179 elm_win_resize_object_add(win, sc); 179 elm_win_resize_object_add(win, sc);
180 180
181 elm_scroller_content_set(sc, bx); 181 elm_object_content_set(sc, bx);
182 evas_object_show(bx); 182 evas_object_show(bx);
183 183
184 evas_object_show(sc); 184 evas_object_show(sc);
diff --git a/legacy/elementary/src/bin/test_focus.c b/legacy/elementary/src/bin/test_focus.c
index 08f3713..f2df204 100644
--- a/legacy/elementary/src/bin/test_focus.c
+++ b/legacy/elementary/src/bin/test_focus.c
@@ -162,7 +162,7 @@ test_focus(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event_info
162 EVAS_HINT_FILL); 162 EVAS_HINT_FILL);
163 evas_object_size_hint_weight_set(bt, 0.0, 0.0); 163 evas_object_size_hint_weight_set(bt, 0.0, 0.0);
164 elm_object_event_callback_add(bt, _event, NULL); 164 elm_object_event_callback_add(bt, _event, NULL);
165 elm_scroller_content_set(sc, bt); 165 elm_object_content_set(sc, bt);
166 my_show(bt); 166 my_show(bt);
167 elm_object_event_callback_del(bt, _event, NULL); 167 elm_object_event_callback_del(bt, _event, NULL);
168 } 168 }
@@ -228,7 +228,7 @@ test_focus(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event_info
228 evas_object_size_hint_align_set(bx3, EVAS_HINT_FILL, 228 evas_object_size_hint_align_set(bx3, EVAS_HINT_FILL,
229 EVAS_HINT_FILL); 229 EVAS_HINT_FILL);
230 evas_object_size_hint_weight_set(bx3, 0.0, 0.0); 230 evas_object_size_hint_weight_set(bx3, 0.0, 0.0);
231 elm_scroller_content_set(sc, bx3); 231 elm_object_content_set(sc, bx3);
232 my_show(bx3); 232 my_show(bx3);
233 233
234 for (i = 5; i; i--) 234 for (i = 5; i; i--)
diff --git a/legacy/elementary/src/bin/test_launcher.c b/legacy/elementary/src/bin/test_launcher.c
index 250481c..1a96a4c 100644
--- a/legacy/elementary/src/bin/test_launcher.c
+++ b/legacy/elementary/src/bin/test_launcher.c
@@ -313,7 +313,7 @@ test_launcher(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event_in
313 elm_win_resize_object_add(win, bx2); 313 elm_win_resize_object_add(win, bx2);
314 evas_object_show(bx2); 314 evas_object_show(bx2);
315 315
316 elm_scroller_content_set(sc, bx); 316 elm_object_content_set(sc, bx);
317 evas_object_show(bx); 317 evas_object_show(bx);
318 318
319 elm_scroller_page_relative_set(sc, 1.0, 1.0); 319 elm_scroller_page_relative_set(sc, 1.0, 1.0);
@@ -440,7 +440,7 @@ test_launcher2(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event_i
440 evas_object_size_hint_weight_set(sc, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); 440 evas_object_size_hint_weight_set(sc, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
441 elm_win_resize_object_add(win, sc); 441 elm_win_resize_object_add(win, sc);
442 442
443 elm_scroller_content_set(sc, bx); 443 elm_object_content_set(sc, bx);
444 evas_object_show(bx); 444 evas_object_show(bx);
445 445
446 elm_scroller_page_relative_set(sc, 1.0, 1.0); 446 elm_scroller_page_relative_set(sc, 1.0, 1.0);
@@ -848,7 +848,7 @@ test_launcher3(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event_i
848 elm_win_resize_object_add(win, bx2); 848 elm_win_resize_object_add(win, bx2);
849 evas_object_show(bx2); 849 evas_object_show(bx2);
850 850
851 elm_scroller_content_set(sc, bx); 851 elm_object_content_set(sc, bx);
852 evas_object_show(bx); 852 evas_object_show(bx);
853 853
854 elm_scroller_page_relative_set(sc, 1.0, 1.0); 854 elm_scroller_page_relative_set(sc, 1.0, 1.0);
diff --git a/legacy/elementary/src/bin/test_photo.c b/legacy/elementary/src/bin/test_photo.c
index 1e3cf1d..4350510 100644
--- a/legacy/elementary/src/bin/test_photo.c
+++ b/legacy/elementary/src/bin/test_photo.c
@@ -82,7 +82,7 @@ test_photo(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event_info
82 evas_object_size_hint_weight_set(sc, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); 82 evas_object_size_hint_weight_set(sc, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
83 elm_win_resize_object_add(win, sc); 83 elm_win_resize_object_add(win, sc);
84 84
85 elm_scroller_content_set(sc, tb); 85 elm_object_content_set(sc, tb);
86 evas_object_show(tb); 86 evas_object_show(tb);
87 evas_object_show(sc); 87 evas_object_show(sc);
88 88
diff --git a/legacy/elementary/src/bin/test_progressbar.c b/legacy/elementary/src/bin/test_progressbar.c
index c4ed5f2..370347d 100644
--- a/legacy/elementary/src/bin/test_progressbar.c
+++ b/legacy/elementary/src/bin/test_progressbar.c
@@ -115,7 +115,7 @@ test_progressbar(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event
115 115
116 pb = elm_progressbar_add(win); 116 pb = elm_progressbar_add(win);
117 elm_object_text_set(pb, "Label"); 117 elm_object_text_set(pb, "Label");
118 elm_progressbar_icon_set(pb, ic1); 118 elm_object_content_set(pb, ic1);
119 elm_progressbar_inverted_set(pb, 1); 119 elm_progressbar_inverted_set(pb, 1);
120 elm_progressbar_unit_format_set(pb, "%1.1f units"); 120 elm_progressbar_unit_format_set(pb, "%1.1f units");
121 elm_progressbar_span_size_set(pb, 200); 121 elm_progressbar_span_size_set(pb, 200);
@@ -162,7 +162,7 @@ test_progressbar(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event
162 pb = elm_progressbar_add(win); 162 pb = elm_progressbar_add(win);
163 elm_progressbar_horizontal_set(pb, EINA_FALSE); 163 elm_progressbar_horizontal_set(pb, EINA_FALSE);
164 elm_object_text_set(pb, "Label"); 164 elm_object_text_set(pb, "Label");
165 elm_progressbar_icon_set(pb, ic2); 165 elm_object_content_set(pb, ic2);
166 elm_progressbar_inverted_set(pb, 1); 166 elm_progressbar_inverted_set(pb, 1);
167 elm_progressbar_unit_format_set(pb, "%1.2f%%"); 167 elm_progressbar_unit_format_set(pb, "%1.2f%%");
168 elm_progressbar_span_size_set(pb, 200); 168 elm_progressbar_span_size_set(pb, 200);
diff --git a/legacy/elementary/src/bin/test_radio.c b/legacy/elementary/src/bin/test_radio.c
index 2b91628..2d0351c 100644
--- a/legacy/elementary/src/bin/test_radio.c
+++ b/legacy/elementary/src/bin/test_radio.c
@@ -33,7 +33,7 @@ test_radio(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event_info
33 evas_object_size_hint_weight_set(rd, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); 33 evas_object_size_hint_weight_set(rd, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
34 evas_object_size_hint_align_set(rd, EVAS_HINT_FILL, 0.5); 34 evas_object_size_hint_align_set(rd, EVAS_HINT_FILL, 0.5);
35 elm_object_text_set(rd, "Icon sized to radio"); 35 elm_object_text_set(rd, "Icon sized to radio");
36 elm_radio_icon_set(rd, ic); 36 elm_object_content_set(rd, ic);
37 elm_box_pack_end(bx, rd); 37 elm_box_pack_end(bx, rd);
38 evas_object_show(rd); 38 evas_object_show(rd);
39 evas_object_show(ic); 39 evas_object_show(ic);
@@ -48,7 +48,7 @@ test_radio(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event_info
48 elm_radio_state_value_set(rd, 1); 48 elm_radio_state_value_set(rd, 1);
49 elm_radio_group_add(rd, rdg); 49 elm_radio_group_add(rd, rdg);
50 elm_object_text_set(rd, "Icon no scale"); 50 elm_object_text_set(rd, "Icon no scale");
51 elm_radio_icon_set(rd, ic); 51 elm_object_content_set(rd, ic);
52 elm_box_pack_end(bx, rd); 52 elm_box_pack_end(bx, rd);
53 evas_object_show(rd); 53 evas_object_show(rd);
54 evas_object_show(ic); 54 evas_object_show(ic);
@@ -76,7 +76,7 @@ test_radio(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event_info
76 rd = elm_radio_add(win); 76 rd = elm_radio_add(win);
77 elm_radio_state_value_set(rd, 4); 77 elm_radio_state_value_set(rd, 4);
78 elm_radio_group_add(rd, rdg); 78 elm_radio_group_add(rd, rdg);
79 elm_radio_icon_set(rd, ic); 79 elm_object_content_set(rd, ic);
80 elm_box_pack_end(bx, rd); 80 elm_box_pack_end(bx, rd);
81 evas_object_show(rd); 81 evas_object_show(rd);
82 evas_object_show(ic); 82 evas_object_show(ic);
@@ -89,7 +89,7 @@ test_radio(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event_info
89 rd = elm_radio_add(win); 89 rd = elm_radio_add(win);
90 elm_radio_state_value_set(rd, 5); 90 elm_radio_state_value_set(rd, 5);
91 elm_radio_group_add(rd, rdg); 91 elm_radio_group_add(rd, rdg);
92 elm_radio_icon_set(rd, ic); 92 elm_object_content_set(rd, ic);
93 elm_object_disabled_set(rd, 1); 93 elm_object_disabled_set(rd, 1);
94 elm_box_pack_end(bx, rd); 94 elm_box_pack_end(bx, rd);
95 evas_object_show(rd); 95 evas_object_show(rd);
diff --git a/legacy/elementary/src/bin/test_scroller.c b/legacy/elementary/src/bin/test_scroller.c
index 0776ebd..32c3928 100644
--- a/legacy/elementary/src/bin/test_scroller.c
+++ b/legacy/elementary/src/bin/test_scroller.c
@@ -81,11 +81,10 @@ test_scroller(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event_in
81 evas_object_size_hint_weight_set(sc, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); 81 evas_object_size_hint_weight_set(sc, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
82 elm_win_resize_object_add(win, sc); 82 elm_win_resize_object_add(win, sc);
83 83
84 elm_scroller_content_set(sc, tb); 84 elm_object_content_set(sc, tb);
85 evas_object_show(tb); 85 evas_object_show(tb);
86 86
87 elm_scroller_page_relative_set(sc, 1.0, 1.0); 87 elm_scroller_page_relative_set(sc, 1.0, 1.0);
88// elm_scroller_page_size_set(sc, 200, 200);
89 evas_object_show(sc); 88 evas_object_show(sc);
90 89
91 tb2 = elm_table_add(win); 90 tb2 = elm_table_add(win);
@@ -189,7 +188,7 @@ test_scroller2(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event_i
189 evas_object_show(bt); 188 evas_object_show(bt);
190 } 189 }
191 190
192 elm_scroller_content_set(sc, bx2); 191 elm_object_content_set(sc, bx2);
193 evas_object_show(bx2); 192 evas_object_show(bx2);
194 /* } */ 193 /* } */
195 194
@@ -237,7 +236,7 @@ test_scroller2(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event_i
237 } 236 }
238 } 237 }
239 238
240 elm_scroller_content_set(sc, tb2); 239 elm_object_content_set(sc, tb2);
241 evas_object_show(tb2); 240 evas_object_show(tb2);
242 /* } */ 241 /* } */
243 242
@@ -256,7 +255,7 @@ test_scroller2(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event_i
256 evas_object_size_hint_weight_set(sc, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); 255 evas_object_size_hint_weight_set(sc, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
257 elm_scroller_bounce_set(sc, 0, 1); 256 elm_scroller_bounce_set(sc, 0, 1);
258 elm_win_resize_object_add(win, sc); 257 elm_win_resize_object_add(win, sc);
259 elm_scroller_content_set(sc, bx); 258 elm_object_content_set(sc, bx);
260 evas_object_show(bx); 259 evas_object_show(bx);
261 evas_object_show(sc); 260 evas_object_show(sc);
262 261
diff --git a/legacy/elementary/src/bin/test_slider.c b/legacy/elementary/src/bin/test_slider.c
index 2b19f85..17497dc 100644
--- a/legacy/elementary/src/bin/test_slider.c
+++ b/legacy/elementary/src/bin/test_slider.c
@@ -39,7 +39,7 @@ test_slider(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event_info
39 sl = elm_slider_add(win); 39 sl = elm_slider_add(win);
40 sl1 = sl; 40 sl1 = sl;
41 elm_object_text_set(sl, "Horizontal"); 41 elm_object_text_set(sl, "Horizontal");
42 elm_slider_icon_set(sl, ic); 42 elm_object_content_part_set(sl, ELM_SLIDER_CONTENT_ICON, ic);
43 elm_slider_unit_format_set(sl, "%1.1f units"); 43 elm_slider_unit_format_set(sl, "%1.1f units");
44 elm_slider_span_size_set(sl, 120); 44 elm_slider_span_size_set(sl, 120);
45 evas_object_size_hint_align_set(sl, EVAS_HINT_FILL, 0.5); 45 evas_object_size_hint_align_set(sl, EVAS_HINT_FILL, 0.5);
@@ -56,7 +56,7 @@ test_slider(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event_info
56 56
57 sl = elm_slider_add(win); 57 sl = elm_slider_add(win);
58 elm_object_text_set(sl, "Disabled"); 58 elm_object_text_set(sl, "Disabled");
59 elm_slider_icon_set(sl, ic); 59 elm_object_content_part_set(sl, ELM_SLIDER_CONTENT_ICON, ic);
60 elm_slider_unit_format_set(sl, "%1.1f units"); 60 elm_slider_unit_format_set(sl, "%1.1f units");
61 elm_slider_span_size_set(sl, 120); 61 elm_slider_span_size_set(sl, 120);
62 elm_slider_min_max_set(sl, 50, 150); 62 elm_slider_min_max_set(sl, 50, 150);
@@ -75,7 +75,7 @@ test_slider(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event_info
75 75
76 sl = elm_slider_add(win); 76 sl = elm_slider_add(win);
77 elm_object_text_set(sl, "Horizontal inverted"); 77 elm_object_text_set(sl, "Horizontal inverted");
78 elm_slider_end_set(sl, ic); 78 elm_object_content_part_set(sl, ELM_SLIDER_CONTENT_END, ic);
79 elm_slider_span_size_set(sl, 80); 79 elm_slider_span_size_set(sl, 80);
80 evas_object_size_hint_align_set(sl, EVAS_HINT_FILL, 0.5); 80 evas_object_size_hint_align_set(sl, EVAS_HINT_FILL, 0.5);
81 evas_object_size_hint_weight_set(sl, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); 81 evas_object_size_hint_weight_set(sl, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
@@ -97,7 +97,7 @@ test_slider(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event_info
97 97
98 sl = elm_slider_add(win); 98 sl = elm_slider_add(win);
99 elm_object_text_set(sl, "Disabled inverted"); 99 elm_object_text_set(sl, "Disabled inverted");
100 elm_slider_end_set(sl, ic); 100 elm_object_content_part_set(sl, ELM_SLIDER_CONTENT_END, ic);
101 elm_slider_span_size_set(sl, 80); 101 elm_slider_span_size_set(sl, 80);
102 evas_object_size_hint_align_set(sl, EVAS_HINT_FILL, 0.5); 102 evas_object_size_hint_align_set(sl, EVAS_HINT_FILL, 0.5);
103 evas_object_size_hint_weight_set(sl, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); 103 evas_object_size_hint_weight_set(sl, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
@@ -140,7 +140,7 @@ test_slider(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event_info
140 evas_object_size_hint_aspect_set(ic, EVAS_ASPECT_CONTROL_HORIZONTAL, 1, 1); 140 evas_object_size_hint_aspect_set(ic, EVAS_ASPECT_CONTROL_HORIZONTAL, 1, 1);
141 141
142 sl = elm_slider_add(win); 142 sl = elm_slider_add(win);
143 elm_slider_icon_set(sl, ic); 143 elm_object_content_part_set(sl, ELM_SLIDER_CONTENT_ICON, ic);
144 elm_object_text_set(sl, "Vertical inverted"); 144 elm_object_text_set(sl, "Vertical inverted");
145 elm_slider_inverted_set(sl, EINA_TRUE); 145 elm_slider_inverted_set(sl, EINA_TRUE);
146 elm_slider_unit_format_set(sl, "units"); 146 elm_slider_unit_format_set(sl, "units");
@@ -178,7 +178,7 @@ test_slider(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event_info
178 evas_object_size_hint_aspect_set(ic, EVAS_ASPECT_CONTROL_HORIZONTAL, 1, 1); 178 evas_object_size_hint_aspect_set(ic, EVAS_ASPECT_CONTROL_HORIZONTAL, 1, 1);
179 179
180 sl = elm_slider_add(win); 180 sl = elm_slider_add(win);
181 elm_slider_icon_set(sl, ic); 181 elm_object_content_part_set(sl, ELM_SLIDER_CONTENT_ICON, ic);
182 elm_object_text_set(sl, "Disabled vertical"); 182 elm_object_text_set(sl, "Disabled vertical");
183 elm_slider_inverted_set(sl, EINA_TRUE); 183 elm_slider_inverted_set(sl, EINA_TRUE);
184 elm_slider_unit_format_set(sl, "units"); 184 elm_slider_unit_format_set(sl, "units");
diff --git a/legacy/elementary/src/bin/test_thumb.c b/legacy/elementary/src/bin/test_thumb.c
index 7f01f87..b6d7f62 100644
--- a/legacy/elementary/src/bin/test_thumb.c
+++ b/legacy/elementary/src/bin/test_thumb.c
@@ -62,7 +62,7 @@ test_thumb(void *data __UNUSED__, Evas_Object *obj __UNUSED__, void *event_info
62 evas_object_size_hint_weight_set(sc, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); 62 evas_object_size_hint_weight_set(sc, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
63 elm_win_resize_object_add(win, sc); 63 elm_win_resize_object_add(win, sc);
64 64
65 elm_scroller_content_set(sc, tb); 65 elm_object_content_set(sc, tb);
66 evas_object_show(tb); 66 evas_object_show(tb);
67 evas_object_show(sc); 67 evas_object_show(sc);
68 68
diff --git a/legacy/elementary/src/bin/test_win_inline.c b/legacy/elementary/src/bin/test_win_inline.c
index a51cd7d..e3b9ac5 100644
--- a/legacy/elementary/src/bin/test_win_inline.c
+++ b/legacy/elementary/src/bin/test_win_inline.c
@@ -128,7 +128,7 @@ fill(Evas_Object *win, Eina_Bool do_bg)
128 elm_box_pack_end(bx, bb); 128 elm_box_pack_end(bx, bb);
129 evas_object_show(bb); 129 evas_object_show(bb);
130 130
131 elm_scroller_content_set(sc, bx); 131 elm_object_content_set(sc, bx);
132 evas_object_show(bx); 132 evas_object_show(bx);
133 133
134 evas_object_show(sc); 134 evas_object_show(sc);
diff --git a/legacy/elementary/src/edje_externals/elm_progressbar.c b/legacy/elementary/src/edje_externals/elm_progressbar.c
index aa4338e..d32a7cb 100644
--- a/legacy/elementary/src/edje_externals/elm_progressbar.c
+++ b/legacy/elementary/src/edje_externals/elm_progressbar.c
@@ -28,7 +28,7 @@ external_progressbar_state_set(void *data __UNUSED__, Evas_Object *obj, const vo
28 if (p->label) 28 if (p->label)
29 elm_object_text_set(obj, p->label); 29 elm_object_text_set(obj, p->label);
30 if (p->icon) 30 if (p->icon)
31 elm_progressbar_icon_set(obj, p->icon); 31 elm_object_content_set(obj, p->icon);
32 if (p->span_exists) 32 if (p->span_exists)
33 elm_progressbar_span_size_set(obj, p->span); 33 elm_progressbar_span_size_set(obj, p->span);
34 if (p->value_exists) 34 if (p->value_exists)
@@ -58,7 +58,7 @@ external_progressbar_param_set(void *data __UNUSED__, Evas_Object *obj, const Ed
58 { 58 {
59 Evas_Object *icon = external_common_param_icon_get(obj, param); 59 Evas_Object *icon = external_common_param_icon_get(obj, param);
60 if ((strcmp(param->s, "")) && (!icon)) return EINA_FALSE; 60 if ((strcmp(param->s, "")) && (!icon)) return EINA_FALSE;
61 elm_progressbar_icon_set(obj, icon); 61 elm_object_content_set(obj, icon);
62 return EINA_TRUE; 62 return EINA_TRUE;
63 } 63 }
64 } 64 }
diff --git a/legacy/elementary/src/edje_externals/elm_radio.c b/legacy/elementary/src/edje_externals/elm_radio.c
index 7f4c600..839326b 100644
--- a/legacy/elementary/src/edje_externals/elm_radio.c
+++ b/legacy/elementary/src/edje_externals/elm_radio.c
@@ -22,7 +22,7 @@ external_radio_state_set(void *data __UNUSED__, Evas_Object *obj, const void *fr
22 if (p->label) 22 if (p->label)
23 elm_object_text_set(obj, p->label); 23 elm_object_text_set(obj, p->label);
24 if (p->icon) 24 if (p->icon)
25 elm_radio_icon_set(obj, p->icon); 25 elm_object_content_set(obj, p->icon);
26 if (p->value_exists) 26 if (p->value_exists)
27 elm_radio_state_value_set(obj, p->value); 27 elm_radio_state_value_set(obj, p->value);
28 if (p->group_name) 28 if (p->group_name)
@@ -50,7 +50,7 @@ external_radio_param_set(void *data __UNUSED__, Evas_Object *obj, const Edje_Ext
50 { 50 {
51 Evas_Object *icon = external_common_param_icon_get(obj, param); 51 Evas_Object *icon = external_common_param_icon_get(obj, param);
52 if ((strcmp(param->s, "")) && (!icon)) return EINA_FALSE; 52 if ((strcmp(param->s, "")) && (!icon)) return EINA_FALSE;
53 elm_radio_icon_set(obj, icon); 53 elm_object_content_set(obj, icon);
54 return EINA_TRUE; 54 return EINA_TRUE;
55 } 55 }
56 } 56 }
diff --git a/legacy/elementary/src/edje_externals/elm_scroller.c b/legacy/elementary/src/edje_externals/elm_scroller.c
index ccec362..2173e3c 100644
--- a/legacy/elementary/src/edje_externals/elm_scroller.c
+++ b/legacy/elementary/src/edje_externals/elm_scroller.c
@@ -22,7 +22,7 @@ static void external_scroller_state_set(void *data __UNUSED__,
22 else return; 22 else return;
23 23
24 if (p->content) { 24 if (p->content) {
25 elm_scroller_content_set(obj, p->content); 25 elm_object_content_set(obj, p->content);
26 } 26 }
27} 27}
28 28
@@ -35,7 +35,7 @@ static Eina_Bool external_scroller_param_set(void *data __UNUSED__,
35 Evas_Object *content = external_common_param_edje_object_get(obj, param); 35 Evas_Object *content = external_common_param_edje_object_get(obj, param);
36 if ((strcmp(param->s, "")) && (!content)) 36 if ((strcmp(param->s, "")) && (!content))
37 return EINA_FALSE; 37 return EINA_FALSE;
38 elm_scroller_content_set(obj, content); 38 elm_object_content_set(obj, content);
39 return EINA_TRUE; 39 return EINA_TRUE;
40 } 40 }
41 41
@@ -83,7 +83,7 @@ static Evas_Object *external_scroller_content_get(void *data __UNUSED__,
83 const Evas_Object *obj, const char *content) 83 const Evas_Object *obj, const char *content)
84{ 84{
85 if (!strcmp(content, "content")) 85 if (!strcmp(content, "content"))
86 return elm_scroller_content_get(obj); 86 return elm_object_content_get(obj);
87 87
88 ERR("unknown content '%s'", content); 88 ERR("unknown content '%s'", content);
89 return NULL; 89 return NULL;
diff --git a/legacy/elementary/src/edje_externals/elm_slider.c b/legacy/elementary/src/edje_externals/elm_slider.c
index a4c0156..1e1f88f 100644
--- a/legacy/elementary/src/edje_externals/elm_slider.c
+++ b/legacy/elementary/src/edje_externals/elm_slider.c
@@ -30,7 +30,7 @@ external_slider_state_set(void *data __UNUSED__, Evas_Object *obj, const void *f
30 if (p->label) 30 if (p->label)
31 elm_object_text_set(obj, p->label); 31 elm_object_text_set(obj, p->label);
32 if (p->icon) 32 if (p->icon)
33 elm_slider_icon_set(obj, p->icon); 33 elm_object_content_part_set(obj, ELM_SLIDER_CONTENT_ICON, p->icon);
34 if (p->span_exists) 34 if (p->span_exists)
35 elm_slider_span_size_set(obj, p->span); 35 elm_slider_span_size_set(obj, p->span);
36 if ((p->min_exists) && (p->max_exists)) 36 if ((p->min_exists) && (p->max_exists))
@@ -73,7 +73,7 @@ external_slider_param_set(void *data __UNUSED__, Evas_Object *obj, const Edje_Ex
73 { 73 {
74 Evas_Object *icon = external_common_param_icon_get(obj, param); 74 Evas_Object *icon = external_common_param_icon_get(obj, param);
75 if ((strcmp(param->s, "")) && (!icon)) return EINA_FALSE; 75 if ((strcmp(param->s, "")) && (!icon)) return EINA_FALSE;
76 elm_slider_icon_set(obj, icon); 76 elm_object_content_part_set(obj, ELM_SLIDER_CONTENT_ICON, icon);
77 return EINA_TRUE; 77 return EINA_TRUE;
78 } 78 }
79 } 79 }
diff --git a/legacy/elementary/src/examples/progressbar_example.c b/legacy/elementary/src/examples/progressbar_example.c
index af1fb37..81f9216 100644
--- a/legacy/elementary/src/examples/progressbar_example.c
+++ b/legacy/elementary/src/examples/progressbar_example.c
@@ -143,7 +143,7 @@ elm_main(int argc __UNUSED__,
143 /* pb with label, icon, custom unit label and span size set */ 143 /* pb with label, icon, custom unit label and span size set */
144 pb = elm_progressbar_add(win); 144 pb = elm_progressbar_add(win);
145 elm_object_text_set(pb, "Label"); 145 elm_object_text_set(pb, "Label");
146 elm_progressbar_icon_set(pb, ic1); 146 elm_object_content_set(pb, ic1);
147 elm_progressbar_inverted_set(pb, EINA_TRUE); 147 elm_progressbar_inverted_set(pb, EINA_TRUE);
148 elm_progressbar_unit_format_set(pb, "%1.1f units"); 148 elm_progressbar_unit_format_set(pb, "%1.1f units");
149 elm_progressbar_span_size_set(pb, 200); 149 elm_progressbar_span_size_set(pb, 200);
@@ -192,7 +192,7 @@ elm_main(int argc __UNUSED__,
192 pb = elm_progressbar_add(win); 192 pb = elm_progressbar_add(win);
193 elm_progressbar_horizontal_set(pb, EINA_FALSE); 193 elm_progressbar_horizontal_set(pb, EINA_FALSE);
194 elm_object_text_set(pb, "Label"); 194 elm_object_text_set(pb, "Label");
195 elm_progressbar_icon_set(pb, ic2); 195 elm_object_content_set(pb, ic2);
196 elm_progressbar_inverted_set(pb, EINA_TRUE); 196 elm_progressbar_inverted_set(pb, EINA_TRUE);
197 elm_progressbar_unit_format_set(pb, "%1.2f%%"); 197 elm_progressbar_unit_format_set(pb, "%1.2f%%");
198 elm_progressbar_span_size_set(pb, 200); 198 elm_progressbar_span_size_set(pb, 200);
diff --git a/legacy/elementary/src/examples/radio_example_01.c b/legacy/elementary/src/examples/radio_example_01.c
index e82a64d..78fa010 100644
--- a/legacy/elementary/src/examples/radio_example_01.c
+++ b/legacy/elementary/src/examples/radio_example_01.c
@@ -37,7 +37,7 @@ elm_main(int argc, char **argv)
37 elm_radio_value_pointer_set(radio, &val); 37 elm_radio_value_pointer_set(radio, &val);
38 ic = elm_icon_add(win); 38 ic = elm_icon_add(win);
39 elm_icon_standard_set(ic, "home"); 39 elm_icon_standard_set(ic, "home");
40 elm_radio_icon_set(radio, ic); 40 elm_object_content_set(radio, ic);
41 elm_box_pack_end(bx, radio); 41 elm_box_pack_end(bx, radio);
42 evas_object_size_hint_weight_set(radio, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); 42 evas_object_size_hint_weight_set(radio, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
43 evas_object_size_hint_align_set(radio, EVAS_HINT_FILL, EVAS_HINT_FILL); 43 evas_object_size_hint_align_set(radio, EVAS_HINT_FILL, EVAS_HINT_FILL);
@@ -51,7 +51,7 @@ elm_main(int argc, char **argv)
51 elm_radio_group_add(radio, group); 51 elm_radio_group_add(radio, group);
52 ic = elm_icon_add(win); 52 ic = elm_icon_add(win);
53 elm_icon_standard_set(ic, "file"); 53 elm_icon_standard_set(ic, "file");
54 elm_radio_icon_set(radio, ic); 54 elm_object_content_set(radio, ic);
55 elm_box_pack_end(bx, radio); 55 elm_box_pack_end(bx, radio);
56 evas_object_size_hint_weight_set(radio, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); 56 evas_object_size_hint_weight_set(radio, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
57 evas_object_size_hint_align_set(radio, EVAS_HINT_FILL, EVAS_HINT_FILL); 57 evas_object_size_hint_align_set(radio, EVAS_HINT_FILL, EVAS_HINT_FILL);
diff --git a/legacy/elementary/src/examples/scroller_example_01.c b/legacy/elementary/src/examples/scroller_example_01.c
index 6e5cd9b..3f31efe 100644
--- a/legacy/elementary/src/examples/scroller_example_01.c
+++ b/legacy/elementary/src/examples/scroller_example_01.c
@@ -127,7 +127,7 @@ elm_main(int argc, char **argv)
127 scroller = elm_scroller_add(win); 127 scroller = elm_scroller_add(win);
128 elm_win_resize_object_add(win, scroller); 128 elm_win_resize_object_add(win, scroller);
129 evas_object_show(scroller); 129 evas_object_show(scroller);
130 elm_scroller_content_set(scroller, label); 130 elm_object_content_set(scroller, label);
131 elm_scroller_bounce_set(scroller, EINA_TRUE, EINA_FALSE); 131 elm_scroller_bounce_set(scroller, EINA_TRUE, EINA_FALSE);
132 elm_scroller_policy_set(scroller, ELM_SCROLLER_POLICY_ON, ELM_SCROLLER_POLICY_ON); 132 elm_scroller_policy_set(scroller, ELM_SCROLLER_POLICY_ON, ELM_SCROLLER_POLICY_ON);
133 elm_scroller_propagate_events_set(scroller, EINA_TRUE); 133 elm_scroller_propagate_events_set(scroller, EINA_TRUE);
diff --git a/legacy/elementary/src/examples/slider_example.c b/legacy/elementary/src/examples/slider_example.c
index 5e0b79c..53568cd 100644
--- a/legacy/elementary/src/examples/slider_example.c
+++ b/legacy/elementary/src/examples/slider_example.c
@@ -85,12 +85,12 @@ elm_main(int argc __UNUSED__, char **argv __UNUSED__)
85 ic = elm_icon_add(win); 85 ic = elm_icon_add(win);
86 elm_icon_standard_set(ic, "home"); 86 elm_icon_standard_set(ic, "home");
87 elm_icon_scale_set(ic, EINA_FALSE, EINA_FALSE); 87 elm_icon_scale_set(ic, EINA_FALSE, EINA_FALSE);
88 elm_slider_icon_set(sl, ic); 88 elm_object_content_part_set(sl, ELM_SLIDER_CONTENT_ICON, ic);
89 89
90 ic = elm_icon_add(win); 90 ic = elm_icon_add(win);
91 elm_icon_standard_set(ic, "folder"); 91 elm_icon_standard_set(ic, "folder");
92 elm_icon_scale_set(ic, EINA_FALSE, EINA_FALSE); 92 elm_icon_scale_set(ic, EINA_FALSE, EINA_FALSE);
93 elm_slider_end_set(sl, ic); 93 elm_object_content_part_set(sl, ELM_SLIDER_CONTENT_END, ic);
94 94
95 evas_object_size_hint_align_set(sl, EVAS_HINT_FILL, 0.5); 95 evas_object_size_hint_align_set(sl, EVAS_HINT_FILL, 0.5);
96 evas_object_size_hint_weight_set(sl, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); 96 evas_object_size_hint_weight_set(sl, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
diff --git a/legacy/elementary/src/lib/Elementary.h.in b/legacy/elementary/src/lib/Elementary.h.in
index d36dfe5..3486e23 100644
--- a/legacy/elementary/src/lib/Elementary.h.in
+++ b/legacy/elementary/src/lib/Elementary.h.in
@@ -7017,6 +7017,9 @@ extern "C" {
7017 * @note When Elementary is in desktop mode the thumbscroll(a.k.a. 7017 * @note When Elementary is in desktop mode the thumbscroll(a.k.a.
7018 * fingerscroll) won't work. 7018 * fingerscroll) won't work.
7019 * 7019 *
7020 * Default contents parts of the scroller widget that you can use for are:
7021 * @li "elm.swallow.content" - A content of the scroller
7022 *
7020 * In @ref tutorial_scroller you'll find an example of how to use most of 7023 * In @ref tutorial_scroller you'll find an example of how to use most of
7021 * this API. 7024 * this API.
7022 * @{ 7025 * @{
@@ -7050,7 +7053,7 @@ extern "C" {
7050 * If you want to keep that old content object, use the 7053 * If you want to keep that old content object, use the
7051 * elm_scroller_content_unset() function. 7054 * elm_scroller_content_unset() function.
7052 */ 7055 */
7053 EAPI void elm_scroller_content_set(Evas_Object *obj, Evas_Object *child) EINA_ARG_NONNULL(1); 7056 EINA_DEPRECATED EAPI void elm_scroller_content_set(Evas_Object *obj, Evas_Object *child) EINA_ARG_NONNULL(1);
7054 /** 7057 /**
7055 * @brief Get the content of the scroller widget 7058 * @brief Get the content of the scroller widget
7056 * 7059 *
@@ -7061,7 +7064,7 @@ extern "C" {
7061 * 7064 *
7062 * @see elm_scroller_content_set() 7065 * @see elm_scroller_content_set()
7063 */ 7066 */
7064 EAPI Evas_Object *elm_scroller_content_get(const Evas_Object *obj) EINA_ARG_NONNULL(1); 7067 EINA_DEPRECATED EAPI Evas_Object *elm_scroller_content_get(const Evas_Object *obj) EINA_ARG_NONNULL(1);
7065 /** 7068 /**
7066 * @brief Unset the content of the scroller widget 7069 * @brief Unset the content of the scroller widget
7067 * 7070 *
@@ -7072,7 +7075,7 @@ extern "C" {
7072 * 7075 *
7073 * @see elm_scroller_content_set() 7076 * @see elm_scroller_content_set()
7074 */ 7077 */
7075 EAPI Evas_Object *elm_scroller_content_unset(Evas_Object *obj) EINA_ARG_NONNULL(1); 7078 EINA_DEPRECATED EAPI Evas_Object *elm_scroller_content_unset(Evas_Object *obj) EINA_ARG_NONNULL(1);
7076 /** 7079 /**
7077 * @brief Set custom theme elements for the scroller 7080 * @brief Set custom theme elements for the scroller
7078 * 7081 *
@@ -7334,7 +7337,6 @@ extern "C" {
7334 * @see elm_scroller_propagate_events_set() 7337 * @see elm_scroller_propagate_events_set()
7335 */ 7338 */
7336 EAPI Eina_Bool elm_scroller_propagate_events_get(const Evas_Object *obj) EINA_ARG_NONNULL(1); 7339 EAPI Eina_Bool elm_scroller_propagate_events_get(const Evas_Object *obj) EINA_ARG_NONNULL(1);
7337
7338 /** 7340 /**
7339 * @brief Set scrolling gravity on a scroller 7341 * @brief Set scrolling gravity on a scroller
7340 * 7342 *
@@ -17280,10 +17282,17 @@ extern "C" {
17280 * Available styles for it: 17282 * Available styles for it:
17281 * - @c "default" 17283 * - @c "default"
17282 * 17284 *
17285 * Default contents parts of the slider widget that you can use for are:
17286 * @li "elm.swallow.icon" - A icon of the slider
17287 * @li "elm.swallow.end" - A end part content of the slider
17288 *
17283 * Here is an example on its usage: 17289 * Here is an example on its usage:
17284 * @li @ref slider_example 17290 * @li @ref slider_example
17285 */ 17291 */
17286 17292
17293#define ELM_SLIDER_CONTENT_ICON "elm.swallow.icon"
17294#define ELM_SLIDER_CONTENT_END "elm.swallow.end"
17295
17287 /** 17296 /**
17288 * @addtogroup Slider 17297 * @addtogroup Slider
17289 * @{ 17298 * @{
@@ -17342,7 +17351,7 @@ extern "C" {
17342 * 17351 *
17343 * @ingroup Slider 17352 * @ingroup Slider
17344 */ 17353 */
17345 EAPI void elm_slider_icon_set(Evas_Object *obj, Evas_Object *icon) EINA_ARG_NONNULL(1); 17354 EINA_DEPRECATED EAPI void elm_slider_icon_set(Evas_Object *obj, Evas_Object *icon) EINA_ARG_NONNULL(1);
17346 17355
17347 /** 17356 /**
17348 * Unset an icon set on a given slider widget. 17357 * Unset an icon set on a given slider widget.
@@ -17362,7 +17371,7 @@ extern "C" {
17362 * 17371 *
17363 * @ingroup Slider 17372 * @ingroup Slider
17364 */ 17373 */
17365 EAPI Evas_Object *elm_slider_icon_unset(Evas_Object *obj) EINA_ARG_NONNULL(1); 17374 EINA_DEPRECATED EAPI Evas_Object *elm_slider_icon_unset(Evas_Object *obj) EINA_ARG_NONNULL(1);
17366 17375
17367 /** 17376 /**
17368 * Retrieve the icon object set for a given slider widget. 17377 * Retrieve the icon object set for a given slider widget.
@@ -17379,7 +17388,7 @@ extern "C" {
17379 * 17388 *
17380 * @ingroup Slider 17389 * @ingroup Slider
17381 */ 17390 */
17382 EAPI Evas_Object *elm_slider_icon_get(const Evas_Object *obj) EINA_ARG_NONNULL(1); 17391 EINA_DEPRECATED EAPI Evas_Object *elm_slider_icon_get(const Evas_Object *obj) EINA_ARG_NONNULL(1);
17383 17392
17384 /** 17393 /**
17385 * Set the end object of the slider object. 17394 * Set the end object of the slider object.
@@ -17399,7 +17408,7 @@ extern "C" {
17399 * 17408 *
17400 * @ingroup Slider 17409 * @ingroup Slider
17401 */ 17410 */
17402 EAPI void elm_slider_end_set(Evas_Object *obj, Evas_Object *end) EINA_ARG_NONNULL(1); 17411 EINA_DEPRECATED EAPI void elm_slider_end_set(Evas_Object *obj, Evas_Object *end) EINA_ARG_NONNULL(1);
17403 17412
17404 /** 17413 /**
17405 * Unset an end object set on a given slider widget. 17414 * Unset an end object set on a given slider widget.
@@ -17419,7 +17428,7 @@ extern "C" {
17419 * 17428 *
17420 * @ingroup Slider 17429 * @ingroup Slider
17421 */ 17430 */
17422 EAPI Evas_Object *elm_slider_end_unset(Evas_Object *obj) EINA_ARG_NONNULL(1); 17431 EINA_DEPRECATED EAPI Evas_Object *elm_slider_end_unset(Evas_Object *obj) EINA_ARG_NONNULL(1);
17423 17432
17424 /** 17433 /**
17425 * Retrieve the end object set for a given slider widget. 17434 * Retrieve the end object set for a given slider widget.
@@ -17436,7 +17445,7 @@ extern "C" {
17436 * 17445 *
17437 * @ingroup Slider 17446 * @ingroup Slider
17438 */ 17447 */
17439 EAPI Evas_Object *elm_slider_end_get(const Evas_Object *obj) EINA_ARG_NONNULL(1); 17448 EINA_DEPRECATED EAPI Evas_Object *elm_slider_end_get(const Evas_Object *obj) EINA_ARG_NONNULL(1);
17440 17449
17441 /** 17450 /**
17442 * Set the (exact) length of the bar region of a given slider widget. 17451 * Set the (exact) length of the bar region of a given slider widget.
@@ -19805,6 +19814,9 @@ extern "C" {
19805 * @li changed - This is called whenever the user changes the state of one of 19814 * @li changed - This is called whenever the user changes the state of one of
19806 * the radio objects within the group of radio objects that work together. 19815 * the radio objects within the group of radio objects that work together.
19807 * 19816 *
19817 * Default contents parts of the radio widget that you can use for are:
19818 * @li "elm.swallow.content" - A icon of the radio
19819 *
19808 * @ref tutorial_radio show most of this API in action. 19820 * @ref tutorial_radio show most of this API in action.
19809 * @{ 19821 * @{
19810 */ 19822 */
@@ -19843,7 +19855,7 @@ extern "C" {
19843 * want to keep that old content object, use the elm_radio_icon_unset() 19855 * want to keep that old content object, use the elm_radio_icon_unset()
19844 * function. 19856 * function.
19845 */ 19857 */
19846 EAPI void elm_radio_icon_set(Evas_Object *obj, Evas_Object *icon) EINA_ARG_NONNULL(1); 19858 EINA_DEPRECATED EAPI void elm_radio_icon_set(Evas_Object *obj, Evas_Object *icon) EINA_ARG_NONNULL(1);
19847 /** 19859 /**
19848 * @brief Get the icon object of the radio object 19860 * @brief Get the icon object of the radio object
19849 * 19861 *
@@ -19852,7 +19864,7 @@ extern "C" {
19852 * 19864 *
19853 * @see elm_radio_icon_set() 19865 * @see elm_radio_icon_set()
19854 */ 19866 */
19855 EAPI Evas_Object *elm_radio_icon_get(const Evas_Object *obj) EINA_ARG_NONNULL(1); 19867 EINA_DEPRECATED EAPI Evas_Object *elm_radio_icon_get(const Evas_Object *obj) EINA_ARG_NONNULL(1);
19856 /** 19868 /**
19857 * @brief Unset the icon used for the radio object 19869 * @brief Unset the icon used for the radio object
19858 * 19870 *
@@ -19863,7 +19875,7 @@ extern "C" {
19863 * 19875 *
19864 * @see elm_radio_icon_set() 19876 * @see elm_radio_icon_set()
19865 */ 19877 */
19866 EAPI Evas_Object *elm_radio_icon_unset(Evas_Object *obj) EINA_ARG_NONNULL(1); 19878 EINA_DEPRECATED EAPI Evas_Object *elm_radio_icon_unset(Evas_Object *obj) EINA_ARG_NONNULL(1);
19867 /** 19879 /**
19868 * @brief Add this radio to a group of other radio objects 19880 * @brief Add this radio to a group of other radio objects
19869 * 19881 *
@@ -20944,6 +20956,9 @@ extern "C" {
20944 * - @c "wheel" (simple style, no text, no progression, only 20956 * - @c "wheel" (simple style, no text, no progression, only
20945 * "pulse" effect is available) 20957 * "pulse" effect is available)
20946 * 20958 *
20959 * Default contents parts of the progressbar widget that you can use for are:
20960 * @li "elm.swallow.content" - A icon of the progressbar
20961 *
20947 * Here is an example on its usage: 20962 * Here is an example on its usage:
20948 * @li @ref progressbar_example 20963 * @li @ref progressbar_example
20949 */ 20964 */
@@ -21083,7 +21098,7 @@ extern "C" {
21083 * 21098 *
21084 * @ingroup Progressbar 21099 * @ingroup Progressbar
21085 */ 21100 */
21086 EAPI void elm_progressbar_icon_set(Evas_Object *obj, Evas_Object *icon) EINA_ARG_NONNULL(1); 21101 EINA_DEPRECATED EAPI void elm_progressbar_icon_set(Evas_Object *obj, Evas_Object *icon) EINA_ARG_NONNULL(1);
21087 21102
21088 /** 21103 /**
21089 * Retrieve the icon object set for a given progress bar widget 21104 * Retrieve the icon object set for a given progress bar widget
@@ -21096,7 +21111,7 @@ extern "C" {
21096 * 21111 *
21097 * @ingroup Progressbar 21112 * @ingroup Progressbar
21098 */ 21113 */
21099 EAPI Evas_Object *elm_progressbar_icon_get(const Evas_Object *obj) EINA_ARG_NONNULL(1); 21114 EINA_DEPRECATED EAPI Evas_Object *elm_progressbar_icon_get(const Evas_Object *obj) EINA_ARG_NONNULL(1);
21100 21115
21101 /** 21116 /**
21102 * Unset an icon set on a given progress bar widget 21117 * Unset an icon set on a given progress bar widget
@@ -21112,7 +21127,7 @@ extern "C" {
21112 * 21127 *
21113 * @ingroup Progressbar 21128 * @ingroup Progressbar
21114 */ 21129 */
21115 EAPI Evas_Object *elm_progressbar_icon_unset(Evas_Object *obj) EINA_ARG_NONNULL(1); 21130 EINA_DEPRECATED EAPI Evas_Object *elm_progressbar_icon_unset(Evas_Object *obj) EINA_ARG_NONNULL(1);
21116 21131
21117 /** 21132 /**
21118 * Set the (exact) length of the bar region of a given progress bar 21133 * Set the (exact) length of the bar region of a given progress bar
diff --git a/legacy/elementary/src/lib/elc_anchorview.c b/legacy/elementary/src/lib/elc_anchorview.c
index 3288808..16994c7 100644
--- a/legacy/elementary/src/lib/elc_anchorview.c
+++ b/legacy/elementary/src/lib/elc_anchorview.c
@@ -227,7 +227,7 @@ elm_anchorview_add(Evas_Object *parent)
227 elm_entry_editable_set(wd->entry, 0); 227 elm_entry_editable_set(wd->entry, 0);
228 evas_object_size_hint_weight_set(wd->entry, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND); 228 evas_object_size_hint_weight_set(wd->entry, EVAS_HINT_EXPAND, EVAS_HINT_EXPAND);
229 evas_object_size_hint_align_set(wd->entry, EVAS_HINT_FILL, EVAS_HINT_FILL); 229 evas_object_size_hint_align_set(wd->entry, EVAS_HINT_FILL, EVAS_HINT_FILL);
230 elm_scroller_content_set(wd->scroller, wd->entry); 230 elm_object_content_set(wd->scroller, wd->entry);
231 evas_object_show(wd->entry); 231 evas_object_show(wd->entry);
232 232
233 evas_object_event_callback_add(wd->entry, EVAS_CALLBACK_CHANGED_SIZE_HINTS, 233 evas_object_event_callback_add(wd->entry, EVAS_CALLBACK_CHANGED_SIZE_HINTS,
diff --git a/legacy/elementary/src/lib/elc_ctxpopup.c b/legacy/elementary/src/lib/elc_ctxpopup.c
index 9733cbc..1268dd9 100644
--- a/legacy/elementary/src/lib/elc_ctxpopup.c
+++ b/legacy/elementary/src/lib/elc_ctxpopup.c
@@ -1051,7 +1051,7 @@ _list_new(Evas_Object *obj)
1051 evas_object_size_hint_weight_set(wd->box, EVAS_HINT_EXPAND, 1051 evas_object_size_hint_weight_set(wd->box, EVAS_HINT_EXPAND,
1052 EVAS_HINT_EXPAND); 1052 EVAS_HINT_EXPAND);
1053 1053
1054 elm_scroller_content_set(wd->scr, wd->box); 1054 elm_object_content_set(wd->scr, wd->box);
1055 elm_ctxpopup_horizontal_set(obj, wd->horizontal); 1055 elm_ctxpopup_horizontal_set(obj, wd->horizontal);
1056} 1056}
1057 1057
diff --git a/legacy/elementary/src/lib/elm_map.c b/legacy/elementary/src/lib/elm_map.c
index 73af091..60ccc7c 100644
--- a/legacy/elementary/src/lib/elm_map.c
+++ b/legacy/elementary/src/lib/elm_map.c
@@ -2554,7 +2554,7 @@ _group_bubble_content_update(Marker_Group *group)
2554 elm_box_horizontal_set(group->bx, EINA_TRUE); 2554 elm_box_horizontal_set(group->bx, EINA_TRUE);
2555 evas_object_show(group->bx); 2555 evas_object_show(group->bx);
2556 2556
2557 elm_scroller_content_set(group->sc, group->bx); 2557 elm_object_content_set(group->sc, group->bx);
2558 2558
2559 evas_object_event_callback_add(group->sc, EVAS_CALLBACK_CHANGED_SIZE_HINTS, 2559 evas_object_event_callback_add(group->sc, EVAS_CALLBACK_CHANGED_SIZE_HINTS,
2560 _bubble_sc_hints_changed_cb, group); 2560 _bubble_sc_hints_changed_cb, group);
diff --git a/legacy/elementary/src/lib/elm_progressbar.c b/legacy/elementary/src/lib/elm_progressbar.c
index e601662..a44c5f3 100644
--- a/legacy/elementary/src/lib/elm_progressbar.c
+++ b/legacy/elementary/src/lib/elm_progressbar.c
@@ -197,6 +197,54 @@ _elm_progressbar_label_get(const Evas_Object *obj, const char *item)
197 return wd->label; 197 return wd->label;
198} 198}
199 199
200static void
201_content_set_hook(Evas_Object *obj, const char *part __UNUSED__, Evas_Object *content)
202{
203 ELM_CHECK_WIDTYPE(obj, widtype);
204 Widget_Data *wd = elm_widget_data_get(obj);
205 if (!wd) return;
206 if (wd->icon == content) return;
207 if (wd->icon) evas_object_del(wd->icon);
208 wd->icon = content;
209 if (content)
210 {
211 elm_widget_sub_object_add(obj, content);
212 evas_object_event_callback_add(content,
213 EVAS_CALLBACK_CHANGED_SIZE_HINTS,
214 _changed_size_hints, obj);
215 edje_object_part_swallow(wd->progressbar, "elm.swallow.content", content);
216 edje_object_signal_emit(wd->progressbar, "elm,state,icon,visible", "elm");
217 edje_object_message_signal_process(wd->progressbar);
218 }
219 _sizing_eval(obj);
220}
221
222static Evas_Object *
223_content_get_hook(const Evas_Object *obj, const char *part __UNUSED__)
224{
225 ELM_CHECK_WIDTYPE(obj, widtype) NULL;
226 Widget_Data *wd = elm_widget_data_get(obj);
227 if (!wd) return NULL;
228 return wd->icon;
229}
230
231static Evas_Object *
232_content_unset_hook(Evas_Object *obj, const char *part __UNUSED__)
233{
234 ELM_CHECK_WIDTYPE(obj, widtype) NULL;
235 Widget_Data *wd = elm_widget_data_get(obj);
236 if (!wd) return NULL;
237 if (!wd->icon) return NULL;
238 Evas_Object *icon = wd->icon;
239 elm_widget_sub_object_del(obj, wd->icon);
240 evas_object_event_callback_add(icon, EVAS_CALLBACK_CHANGED_SIZE_HINTS,
241 _changed_size_hints, obj);
242 edje_object_part_unswallow(wd->progressbar, wd->icon);
243 wd->icon = NULL;
244 return icon;
245}
246
247
200EAPI Evas_Object * 248EAPI Evas_Object *
201elm_progressbar_add(Evas_Object *parent) 249elm_progressbar_add(Evas_Object *parent)
202{ 250{
@@ -215,6 +263,9 @@ elm_progressbar_add(Evas_Object *parent)
215 elm_widget_can_focus_set(obj, EINA_FALSE); 263 elm_widget_can_focus_set(obj, EINA_FALSE);
216 elm_widget_text_set_hook_set(obj, _elm_progressbar_label_set); 264 elm_widget_text_set_hook_set(obj, _elm_progressbar_label_set);
217 elm_widget_text_get_hook_set(obj, _elm_progressbar_label_get); 265 elm_widget_text_get_hook_set(obj, _elm_progressbar_label_get);
266 elm_widget_content_set_hook_set(obj, _content_set_hook);
267 elm_widget_content_get_hook_set(obj, _content_get_hook);
268 elm_widget_content_unset_hook_set(obj, _content_unset_hook);
218 269
219 wd->horizontal = EINA_TRUE; 270 wd->horizontal = EINA_TRUE;
220 wd->inverted = EINA_FALSE; 271 wd->inverted = EINA_FALSE;
@@ -315,47 +366,19 @@ elm_progressbar_label_get(const Evas_Object *obj)
315EAPI void 366EAPI void
316elm_progressbar_icon_set(Evas_Object *obj, Evas_Object *icon) 367elm_progressbar_icon_set(Evas_Object *obj, Evas_Object *icon)
317{ 368{
318 ELM_CHECK_WIDTYPE(obj, widtype); 369 _content_set_hook(obj, NULL, icon);
319 Widget_Data *wd = elm_widget_data_get(obj);
320 if (!wd) return;
321 if (wd->icon == icon) return;
322 if (wd->icon) evas_object_del(wd->icon);
323 wd->icon = icon;
324 if (icon)
325 {
326 elm_widget_sub_object_add(obj, icon);
327 evas_object_event_callback_add(icon, EVAS_CALLBACK_CHANGED_SIZE_HINTS,
328 _changed_size_hints, obj);
329 edje_object_part_swallow(wd->progressbar, "elm.swallow.content", icon);
330 edje_object_signal_emit(wd->progressbar, "elm,state,icon,visible", "elm");
331 edje_object_message_signal_process(wd->progressbar);
332 }
333 _sizing_eval(obj);
334} 370}
335 371
336EAPI Evas_Object * 372EAPI Evas_Object *
337elm_progressbar_icon_get(const Evas_Object *obj) 373elm_progressbar_icon_get(const Evas_Object *obj)
338{ 374{
339 ELM_CHECK_WIDTYPE(obj, widtype) NULL; 375 return _content_get_hook(obj, NULL);
340 Widget_Data *wd = elm_widget_data_get(obj);
341 if (!wd) return NULL;
342 return wd->icon;
343} 376}
344 377
345EAPI Evas_Object * 378EAPI Evas_Object *
346elm_progressbar_icon_unset(Evas_Object *obj) 379elm_progressbar_icon_unset(Evas_Object *obj)
347{ 380{
348 ELM_CHECK_WIDTYPE(obj, widtype) NULL; 381 return _content_unset_hook(obj, NULL);
349 Widget_Data *wd = elm_widget_data_get(obj);
350 if (!wd) return NULL;
351 if (!wd->icon) return NULL;
352 Evas_Object *icon = wd->icon;
353 elm_widget_sub_object_del(obj, wd->icon);
354 evas_object_event_callback_del_full(wd->icon, EVAS_CALLBACK_CHANGED_SIZE_HINTS,
355 _changed_size_hints, obj);
356 edje_object_part_unswallow(wd->progressbar, wd->icon);
357 wd->icon = NULL;
358 return icon;
359} 382}
360 383
361EAPI void 384EAPI void
diff --git a/legacy/elementary/src/lib/elm_radio.c b/legacy/elementary/src/lib/elm_radio.c
index 83e2e74..0c3224d 100644
--- a/legacy/elementary/src/lib/elm_radio.c
+++ b/legacy/elementary/src/lib/elm_radio.c
@@ -298,6 +298,53 @@ _access_state_cb(void *data __UNUSED__, Evas_Object *obj, Elm_Widget_Item *item
298 return strdup(E_("State: Off")); 298 return strdup(E_("State: Off"));
299} 299}
300 300
301static void
302_content_set_hook(Evas_Object *obj, const char *part __UNUSED__, Evas_Object *content)
303{
304 ELM_CHECK_WIDTYPE(obj, widtype);
305 Widget_Data *wd = elm_widget_data_get(obj);
306 if (!wd) return;
307 if (wd->icon == content) return;
308 if (wd->icon) evas_object_del(wd->icon);
309 wd->icon = content;
310 if (content)
311 {
312 elm_widget_sub_object_add(obj, content);
313 evas_object_event_callback_add(content,
314 EVAS_CALLBACK_CHANGED_SIZE_HINTS,
315 _changed_size_hints, obj);
316 edje_object_part_swallow(wd->radio, "elm.swallow.content", content);
317 edje_object_signal_emit(wd->radio, "elm,state,icon,visible", "elm");
318 edje_object_message_signal_process(wd->radio);
319 }
320 _sizing_eval(obj);
321}
322
323static Evas_Object *
324_content_get_hook(const Evas_Object *obj, const char *part __UNUSED__)
325{
326 ELM_CHECK_WIDTYPE(obj, widtype) NULL;
327 Widget_Data *wd = elm_widget_data_get(obj);
328 if (!wd) return NULL;
329 return wd->icon;
330}
331
332static Evas_Object *
333_content_unset_hook(Evas_Object *obj, const char *part __UNUSED__)
334{
335 ELM_CHECK_WIDTYPE(obj, widtype) NULL;
336 Widget_Data *wd = elm_widget_data_get(obj);
337 if (!wd) return NULL;
338 if (!wd->icon) return NULL;
339 Evas_Object *icon = wd->icon;
340 elm_widget_sub_object_del(obj, wd->icon);
341 evas_object_event_callback_del_full(wd->icon, EVAS_CALLBACK_CHANGED_SIZE_HINTS,
342 _changed_size_hints, obj);
343 edje_object_part_unswallow(wd->radio, wd->icon);
344 wd->icon = NULL;
345 return icon;
346}
347
301EAPI Evas_Object * 348EAPI Evas_Object *
302elm_radio_add(Evas_Object *parent) 349elm_radio_add(Evas_Object *parent)
303{ 350{
@@ -320,6 +367,9 @@ elm_radio_add(Evas_Object *parent)
320 elm_widget_event_hook_set(obj, _event_hook); 367 elm_widget_event_hook_set(obj, _event_hook);
321 elm_widget_text_set_hook_set(obj, _elm_radio_label_set); 368 elm_widget_text_set_hook_set(obj, _elm_radio_label_set);
322 elm_widget_text_get_hook_set(obj, _elm_radio_label_get); 369 elm_widget_text_get_hook_set(obj, _elm_radio_label_get);
370 elm_widget_content_set_hook_set(obj, _content_set_hook);
371 elm_widget_content_get_hook_set(obj, _content_get_hook);
372 elm_widget_content_unset_hook_set(obj, _content_unset_hook);
323 373
324 wd->radio = edje_object_add(e); 374 wd->radio = edje_object_add(e);
325 _elm_theme_object_set(obj, wd->radio, "radio", "base", "default"); 375 _elm_theme_object_set(obj, wd->radio, "radio", "base", "default");
@@ -366,47 +416,19 @@ elm_radio_label_get(const Evas_Object *obj)
366EAPI void 416EAPI void
367elm_radio_icon_set(Evas_Object *obj, Evas_Object *icon) 417elm_radio_icon_set(Evas_Object *obj, Evas_Object *icon)
368{ 418{
369 ELM_CHECK_WIDTYPE(obj, widtype); 419 _content_set_hook(obj, NULL, icon);
370 Widget_Data *wd = elm_widget_data_get(obj);
371 if (!wd) return;
372 if (wd->icon == icon) return;
373 if (wd->icon) evas_object_del(wd->icon);
374 wd->icon = icon;
375 if (icon)
376 {
377 elm_widget_sub_object_add(obj, icon);
378 evas_object_event_callback_add(icon, EVAS_CALLBACK_CHANGED_SIZE_HINTS,
379 _changed_size_hints, obj);
380 edje_object_part_swallow(wd->radio, "elm.swallow.content", icon);
381 edje_object_signal_emit(wd->radio, "elm,state,icon,visible", "elm");
382 edje_object_message_signal_process(wd->radio);
383 }
384 _sizing_eval(obj);
385} 420}
386 421
387EAPI Evas_Object * 422EAPI Evas_Object *
388elm_radio_icon_get(const Evas_Object *obj) 423elm_radio_icon_get(const Evas_Object *obj)
389{ 424{
390 ELM_CHECK_WIDTYPE(obj, widtype) NULL; 425 return _content_get_hook(obj, NULL);
391 Widget_Data *wd = elm_widget_data_get(obj);
392 if (!wd) return NULL;
393 return wd->icon;
394} 426}
395 427
396EAPI Evas_Object * 428EAPI Evas_Object *
397elm_radio_icon_unset(Evas_Object *obj) 429elm_radio_icon_unset(Evas_Object *obj)
398{ 430{
399 ELM_CHECK_WIDTYPE(obj, widtype) NULL; 431 return _content_unset_hook(obj, NULL);
400 Widget_Data *wd = elm_widget_data_get(obj);
401 if (!wd) return NULL;
402 if (!wd->icon) return NULL;
403 Evas_Object *icon = wd->icon;
404 elm_widget_sub_object_del(obj, wd->icon);
405 evas_object_event_callback_del_full(wd->icon, EVAS_CALLBACK_CHANGED_SIZE_HINTS,
406 _changed_size_hints, obj);
407 edje_object_part_unswallow(wd->radio, wd->icon);
408 wd->icon = NULL;
409 return icon;
410} 432}
411 433
412EAPI void 434EAPI void
diff --git a/legacy/elementary/src/lib/elm_scroller.c b/legacy/elementary/src/lib/elm_scroller.c
index 8392e96..9c64860 100644
--- a/legacy/elementary/src/lib/elm_scroller.c
+++ b/legacy/elementary/src/lib/elm_scroller.c
@@ -413,6 +413,65 @@ _scroll_drag_stop(void *data, Evas_Object *obj __UNUSED__, void *event_info __UN
413 evas_object_smart_callback_call(data, SIG_SCROLL_DRAG_STOP, NULL); 413 evas_object_smart_callback_call(data, SIG_SCROLL_DRAG_STOP, NULL);
414} 414}
415 415
416Evas_Object *
417_elm_scroller_edje_object_get(Evas_Object *obj)
418{
419 ELM_CHECK_WIDTYPE(obj, widtype) NULL;
420 Widget_Data *wd = elm_widget_data_get(obj);
421 if (!wd) return NULL;
422 return elm_smart_scroller_edje_object_get(wd->scr);
423}
424
425static void
426_content_set_hook(Evas_Object *obj, const char *part __UNUSED__, Evas_Object *content)
427{
428 ELM_CHECK_WIDTYPE(obj, widtype);
429 Widget_Data *wd = elm_widget_data_get(obj);
430 if (!wd) return;
431 if (wd->content == content) return;
432 if (wd->content) evas_object_del(wd->content);
433 wd->content = content;
434 if (content)
435 {
436 elm_widget_on_show_region_hook_set(content, _show_region_hook, obj);
437 elm_widget_sub_object_add(obj, content);
438 if (wd->scr)
439 elm_smart_scroller_child_set(wd->scr, content);
440 evas_object_event_callback_add(content,
441 EVAS_CALLBACK_CHANGED_SIZE_HINTS,
442 _changed_size_hints, obj);
443 }
444 _sizing_eval(obj);
445}
446
447static Evas_Object *
448_content_get_hook(const Evas_Object *obj, const char *part __UNUSED__)
449{
450 ELM_CHECK_WIDTYPE(obj, widtype) NULL;
451 Widget_Data *wd = elm_widget_data_get(obj);
452 if (!wd) return NULL;
453 return wd->content;
454}
455
456static Evas_Object *
457_content_unset_hook(Evas_Object *obj, const char *part __UNUSED__)
458{
459 ELM_CHECK_WIDTYPE(obj, widtype) NULL;
460 Widget_Data *wd = elm_widget_data_get(obj);
461 Evas_Object *content;
462 if (!wd) return NULL;
463 if (!wd->content) return NULL;
464 content = wd->content;
465 elm_widget_sub_object_del(obj, wd->content);
466 evas_object_event_callback_del_full(wd->content,
467 EVAS_CALLBACK_CHANGED_SIZE_HINTS,
468 _changed_size_hints, obj);
469 edje_object_part_unswallow(elm_smart_scroller_edje_object_get(wd->scr),
470 wd->content);
471 wd->content = NULL;
472 return content;
473}
474
416EAPI Evas_Object * 475EAPI Evas_Object *
417elm_scroller_add(Evas_Object *parent) 476elm_scroller_add(Evas_Object *parent)
418{ 477{
@@ -437,6 +496,9 @@ elm_scroller_add(Evas_Object *parent)
437 elm_widget_can_focus_set(obj, EINA_TRUE); 496 elm_widget_can_focus_set(obj, EINA_TRUE);
438 elm_widget_event_hook_set(obj, _event_hook); 497 elm_widget_event_hook_set(obj, _event_hook);
439 elm_widget_focus_region_hook_set(obj, _focus_region_hook); 498 elm_widget_focus_region_hook_set(obj, _focus_region_hook);
499 elm_widget_content_set_hook_set(obj, _content_set_hook);
500 elm_widget_content_get_hook_set(obj, _content_get_hook);
501 elm_widget_content_unset_hook_set(obj, _content_unset_hook);
440 502
441 wd->widget_name = eina_stringshare_add("scroller"); 503 wd->widget_name = eina_stringshare_add("scroller");
442 wd->widget_base = eina_stringshare_add("base"); 504 wd->widget_base = eina_stringshare_add("base");
@@ -477,61 +539,22 @@ elm_scroller_add(Evas_Object *parent)
477 return obj; 539 return obj;
478} 540}
479 541
480Evas_Object *
481_elm_scroller_edje_object_get(Evas_Object *obj)
482{
483 ELM_CHECK_WIDTYPE(obj, widtype) NULL;
484 Widget_Data *wd = elm_widget_data_get(obj);
485 if (!wd) return NULL;
486 return elm_smart_scroller_edje_object_get(wd->scr);
487}
488
489EAPI void 542EAPI void
490elm_scroller_content_set(Evas_Object *obj, Evas_Object *content) 543elm_scroller_content_set(Evas_Object *obj, Evas_Object *content)
491{ 544{
492 ELM_CHECK_WIDTYPE(obj, widtype); 545 _content_set_hook(obj, NULL, content);
493 Widget_Data *wd = elm_widget_data_get(obj);
494 if (!wd) return;
495 if (wd->content == content) return;
496 if (wd->content) evas_object_del(wd->content);
497 wd->content = content;
498 if (content)
499 {
500 elm_widget_on_show_region_hook_set(content, _show_region_hook, obj);
501 elm_widget_sub_object_add(obj, content);
502 if (wd->scr)
503 elm_smart_scroller_child_set(wd->scr, content);
504 evas_object_event_callback_add(content, EVAS_CALLBACK_CHANGED_SIZE_HINTS,
505 _changed_size_hints, obj);
506 }
507 _sizing_eval(obj);
508} 546}
509 547
510EAPI Evas_Object * 548EAPI Evas_Object *
511elm_scroller_content_get(const Evas_Object *obj) 549elm_scroller_content_get(const Evas_Object *obj)
512{ 550{
513 ELM_CHECK_WIDTYPE(obj, widtype) NULL; 551 return _content_get_hook(obj, NULL);
514 Widget_Data *wd = elm_widget_data_get(obj);
515 if (!wd) return NULL;
516 return wd->content;
517} 552}
518 553
519EAPI Evas_Object * 554EAPI Evas_Object *
520elm_scroller_content_unset(Evas_Object *obj) 555elm_scroller_content_unset(Evas_Object *obj)
521{ 556{
522 ELM_CHECK_WIDTYPE(obj, widtype) NULL; 557 return _content_unset_hook(obj, NULL);
523 Widget_Data *wd = elm_widget_data_get(obj);
524 Evas_Object *content;
525 if (!wd) return NULL;
526 if (!wd->content) return NULL;
527 content = wd->content;
528 elm_widget_sub_object_del(obj, wd->content);
529 evas_object_event_callback_del_full(wd->content,
530 EVAS_CALLBACK_CHANGED_SIZE_HINTS,
531 _changed_size_hints, obj);
532 edje_object_part_unswallow(elm_smart_scroller_edje_object_get(wd->scr), wd->content);
533 wd->content = NULL;
534 return content;
535} 558}
536 559
537EAPI void 560EAPI void
diff --git a/legacy/elementary/src/lib/elm_slider.c b/legacy/elementary/src/lib/elm_slider.c
index cc634ca..e721dab 100644
--- a/legacy/elementary/src/lib/elm_slider.c
+++ b/legacy/elementary/src/lib/elm_slider.c
@@ -494,6 +494,122 @@ _elm_slider_label_get(const Evas_Object *obj, const char *item)
494 return wd->label; 494 return wd->label;
495} 495}
496 496
497static void
498_icon_set(Evas_Object *obj, Evas_Object *icon)
499{
500 Widget_Data *wd = elm_widget_data_get(obj);
501 if (!wd) return;
502 if (wd->icon == icon) return;
503 if (wd->icon) evas_object_del(wd->icon);
504 wd->icon = icon;
505 if (icon)
506 {
507 elm_widget_sub_object_add(obj, icon);
508 evas_object_event_callback_add(icon, EVAS_CALLBACK_CHANGED_SIZE_HINTS,
509 _changed_size_hints, obj);
510 edje_object_part_swallow(wd->slider, "elm.swallow.icon", icon);
511 edje_object_signal_emit(wd->slider, "elm,state,icon,visible", "elm");
512 edje_object_message_signal_process(wd->slider);
513 }
514 _sizing_eval(obj);
515}
516
517static Evas_Object *
518_icon_unset(Evas_Object *obj)
519{
520 Widget_Data *wd = elm_widget_data_get(obj);
521 Evas_Object *ret = NULL;
522 if (!wd) return NULL;
523 if (wd->icon)
524 {
525 elm_widget_sub_object_del(obj, wd->icon);
526 evas_object_event_callback_del_full(wd->icon,
527 EVAS_CALLBACK_CHANGED_SIZE_HINTS,
528 _changed_size_hints, obj);
529 ret = wd->icon;
530 edje_object_part_unswallow(wd->slider, wd->icon);
531 edje_object_signal_emit(wd->slider, "elm,state,icon,hidden", "elm");
532 wd->icon = NULL;
533 _sizing_eval(obj);
534 }
535 return ret;
536}
537
538static void
539_end_set(Evas_Object *obj, Evas_Object *end)
540{
541 Widget_Data *wd = elm_widget_data_get(obj);
542 if (!wd) return;
543 if (wd->end == end) return;
544 if (wd->end) evas_object_del(wd->end);
545 wd->end = end;
546 if (end)
547 {
548 elm_widget_sub_object_add(obj, end);
549 evas_object_event_callback_add(end, EVAS_CALLBACK_CHANGED_SIZE_HINTS,
550 _changed_size_hints, obj);
551 edje_object_part_swallow(wd->slider, "elm.swallow.end", end);
552 edje_object_signal_emit(wd->slider, "elm,state,end,visible", "elm");
553 edje_object_message_signal_process(wd->slider);
554 }
555 _sizing_eval(obj);
556}
557
558static Evas_Object *
559_end_unset(Evas_Object *obj)
560{
561 Widget_Data *wd = elm_widget_data_get(obj);
562 Evas_Object *ret = NULL;
563 if (!wd) return NULL;
564 if (wd->end)
565 {
566 elm_widget_sub_object_del(obj, wd->end);
567 evas_object_event_callback_del_full(wd->end,
568 EVAS_CALLBACK_CHANGED_SIZE_HINTS,
569 _changed_size_hints, obj);
570 ret = wd->end;
571 edje_object_part_unswallow(wd->slider, wd->end);
572 edje_object_signal_emit(wd->slider, "elm,state,end,hidden", "elm");
573 wd->end = NULL;
574 _sizing_eval(obj);
575 }
576 return ret;
577}
578
579static void
580_content_set_hook(Evas_Object *obj, const char *part, Evas_Object *content)
581{
582 ELM_CHECK_WIDTYPE(obj, widtype);
583 if ((!part) || (!strcmp(part, "elm.swallow.icon")))
584 _icon_set(obj, content);
585 else if (!strcmp(part, "elm.swallow.end"))
586 _end_set(obj, content);
587}
588
589static Evas_Object *
590_content_get_hook(const Evas_Object *obj, const char *part __UNUSED__)
591{
592 ELM_CHECK_WIDTYPE(obj, widtype) NULL;
593 Widget_Data *wd = elm_widget_data_get(obj);
594 if (!wd) return NULL;
595 if ((!part) || (!strcmp(part, "elm.swallow.icon")))
596 return wd->icon;
597 else if (!strcmp(part, "elm.swallow.end"))
598 return wd->end;
599 return NULL;
600}
601
602static Evas_Object *
603_content_unset_hook(Evas_Object *obj, const char *part __UNUSED__)
604{
605 ELM_CHECK_WIDTYPE(obj, widtype) NULL;
606 if ((!part) || (!strcmp(part, "elm.swallow.icon")))
607 return _icon_unset(obj);
608 else if (!strcmp(part, "elm.swallow.end"))
609 return _end_unset(obj);
610 return NULL;
611}
612
497EAPI Evas_Object * 613EAPI Evas_Object *
498elm_slider_add(Evas_Object *parent) 614elm_slider_add(Evas_Object *parent)
499{ 615{
@@ -515,6 +631,9 @@ elm_slider_add(Evas_Object *parent)
515 elm_widget_event_hook_set(obj, _event_hook); 631 elm_widget_event_hook_set(obj, _event_hook);
516 elm_widget_text_set_hook_set(obj, _elm_slider_label_set); 632 elm_widget_text_set_hook_set(obj, _elm_slider_label_set);
517 elm_widget_text_get_hook_set(obj, _elm_slider_label_get); 633 elm_widget_text_get_hook_set(obj, _elm_slider_label_get);
634 elm_widget_content_set_hook_set(obj, _content_set_hook);
635 elm_widget_content_get_hook_set(obj, _content_get_hook);
636 elm_widget_content_unset_hook_set(obj, _content_unset_hook);
518 637
519 wd->horizontal = EINA_TRUE; 638 wd->horizontal = EINA_TRUE;
520 wd->indicator_show = EINA_TRUE; 639 wd->indicator_show = EINA_TRUE;
@@ -565,53 +684,19 @@ elm_slider_label_get(const Evas_Object *obj)
565EAPI void 684EAPI void
566elm_slider_icon_set(Evas_Object *obj, Evas_Object *icon) 685elm_slider_icon_set(Evas_Object *obj, Evas_Object *icon)
567{ 686{
568 ELM_CHECK_WIDTYPE(obj, widtype); 687 _content_set_hook(obj, NULL, icon);
569 Widget_Data *wd = elm_widget_data_get(obj);
570 if (!wd) return;
571 if (wd->icon == icon) return;
572 if (wd->icon) evas_object_del(wd->icon);
573 wd->icon = icon;
574 if (icon)
575 {
576 elm_widget_sub_object_add(obj, icon);
577 evas_object_event_callback_add(icon, EVAS_CALLBACK_CHANGED_SIZE_HINTS,
578 _changed_size_hints, obj);
579 edje_object_part_swallow(wd->slider, "elm.swallow.icon", icon);
580 edje_object_signal_emit(wd->slider, "elm,state,icon,visible", "elm");
581 edje_object_message_signal_process(wd->slider);
582 }
583 _sizing_eval(obj);
584} 688}
585 689
586EAPI Evas_Object * 690EAPI Evas_Object *
587elm_slider_icon_unset(Evas_Object *obj) 691elm_slider_icon_unset(Evas_Object *obj)
588{ 692{
589 ELM_CHECK_WIDTYPE(obj, widtype) NULL; 693 return _content_unset_hook(obj, NULL);
590 Widget_Data *wd = elm_widget_data_get(obj);
591 Evas_Object *ret = NULL;
592 if (!wd) return NULL;
593 if (wd->icon)
594 {
595 elm_widget_sub_object_del(obj, wd->icon);
596 evas_object_event_callback_del_full(wd->icon,
597 EVAS_CALLBACK_CHANGED_SIZE_HINTS,
598 _changed_size_hints, obj);
599 ret = wd->icon;
600 edje_object_part_unswallow(wd->slider, wd->icon);
601 edje_object_signal_emit(wd->slider, "elm,state,icon,hidden", "elm");
602 wd->icon = NULL;
603 _sizing_eval(obj);
604 }
605 return ret;
606} 694}
607 695
608EAPI Evas_Object * 696EAPI Evas_Object *
609elm_slider_icon_get(const Evas_Object *obj) 697elm_slider_icon_get(const Evas_Object *obj)
610{ 698{
611 ELM_CHECK_WIDTYPE(obj, widtype) NULL; 699 return _content_get_hook(obj, NULL);
612 Widget_Data *wd = elm_widget_data_get(obj);
613 if (!wd) return NULL;
614 return wd->icon;
615} 700}
616 701
617EAPI void 702EAPI void
@@ -818,53 +903,19 @@ elm_slider_units_format_function_set(Evas_Object *obj, const char *(*func)(doubl
818EAPI void 903EAPI void
819elm_slider_end_set(Evas_Object *obj, Evas_Object *end) 904elm_slider_end_set(Evas_Object *obj, Evas_Object *end)
820{ 905{
821 ELM_CHECK_WIDTYPE(obj, widtype); 906 _content_set_hook(obj, "elm.swallow.end", end);
822 Widget_Data *wd = elm_widget_data_get(obj);
823 if (!wd) return;
824 if (wd->end == end) return;
825 if (wd->end) evas_object_del(wd->end);
826 wd->end = end;
827 if (end)
828 {
829 elm_widget_sub_object_add(obj, end);
830 evas_object_event_callback_add(end, EVAS_CALLBACK_CHANGED_SIZE_HINTS,
831 _changed_size_hints, obj);
832 edje_object_part_swallow(wd->slider, "elm.swallow.end", end);
833 edje_object_signal_emit(wd->slider, "elm,state,end,visible", "elm");
834 edje_object_message_signal_process(wd->slider);
835 }
836 _sizing_eval(obj);
837} 907}
838 908
839EAPI Evas_Object * 909EAPI Evas_Object *
840elm_slider_end_unset(Evas_Object *obj) 910elm_slider_end_unset(Evas_Object *obj)
841{ 911{
842 ELM_CHECK_WIDTYPE(obj, widtype) NULL; 912 return _content_unset_hook(obj, "elm.swallow.end");
843 Widget_Data *wd = elm_widget_data_get(obj);
844 Evas_Object *ret = NULL;
845 if (!wd) return NULL;
846 if (wd->end)
847 {
848 elm_widget_sub_object_del(obj, wd->end);
849 evas_object_event_callback_del_full(wd->end,
850 EVAS_CALLBACK_CHANGED_SIZE_HINTS,
851 _changed_size_hints, obj);
852 ret = wd->end;
853 edje_object_part_unswallow(wd->slider, wd->end);
854 edje_object_signal_emit(wd->slider, "elm,state,end,hidden", "elm");
855 wd->end = NULL;
856 _sizing_eval(obj);
857 }
858 return ret;
859} 913}
860 914
861EAPI Evas_Object * 915EAPI Evas_Object *
862elm_slider_end_get(const Evas_Object *obj) 916elm_slider_end_get(const Evas_Object *obj)
863{ 917{
864 ELM_CHECK_WIDTYPE(obj, widtype) NULL; 918 return _content_get_hook(obj, "elm.swallow.end");
865 Widget_Data *wd = elm_widget_data_get(obj);
866 if (!wd) return NULL;
867 return wd->end;
868} 919}
869 920
870EAPI void 921EAPI void