summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Juyung Seo <seojuyung2@gmail.com>2014-01-21 23:43:59 +0900
committerDaniel Juyung Seo <seojuyung2@gmail.com>2014-01-21 23:44:29 +0900
commitf272d437d5a3c11173f4222ef93f17fe11022d56 (patch)
tree91fe52bd1aed2f960c88593de092f0845b8bcca9
parent4c9f0bcbd842c8c9435fb2b0e1349a5ca48da992 (diff)
test, examples fileselector_button: Changed the usage of deprecated APIs to recommended
APIs.
-rw-r--r--src/bin/test_eio.c2
-rw-r--r--src/examples/fileselector_button_example.c20
2 files changed, 11 insertions, 11 deletions
diff --git a/src/bin/test_eio.c b/src/bin/test_eio.c
index 55f85b508..51118b7f1 100644
--- a/src/bin/test_eio.c
+++ b/src/bin/test_eio.c
@@ -223,7 +223,7 @@ test_eio(void *data EINA_UNUSED, Evas_Object *obj EINA_UNUSED, void *event_info
223 elm_object_text_set(fs_bt, "Select a dir"); 223 elm_object_text_set(fs_bt, "Select a dir");
224 elm_object_part_content_set(fs_bt, "icon", ic); 224 elm_object_part_content_set(fs_bt, "icon", ic);
225 elm_fileselector_button_inwin_mode_set(fs_bt, EINA_TRUE); 225 elm_fileselector_button_inwin_mode_set(fs_bt, EINA_TRUE);
226 elm_fileselector_button_folder_only_set(fs_bt, EINA_TRUE); 226 elm_fileselector_folder_only_set(fs_bt, EINA_TRUE);
227 227
228 elm_box_pack_end(hbox, fs_bt); 228 elm_box_pack_end(hbox, fs_bt);
229 elm_box_pack_end(vbox, hbox); 229 elm_box_pack_end(vbox, hbox);
diff --git a/src/examples/fileselector_button_example.c b/src/examples/fileselector_button_example.c
index 3b1f0bea1..e8133e105 100644
--- a/src/examples/fileselector_button_example.c
+++ b/src/examples/fileselector_button_example.c
@@ -46,8 +46,8 @@ _current_sel_toggle(void *data,
46 void *event_info) 46 void *event_info)
47{ 47{
48 Evas_Object *fs_bt = data; 48 Evas_Object *fs_bt = data;
49 Eina_Bool old_val = elm_fileselector_button_is_save_get(fs_bt); 49 Eina_Bool old_val = elm_fileselector_is_save_get(fs_bt);
50 elm_fileselector_button_is_save_set(fs_bt, !old_val); 50 elm_fileselector_is_save_set(fs_bt, !old_val);
51 51
52 printf("%s text entry with selected item's name\n", 52 printf("%s text entry with selected item's name\n",
53 old_val ? "Disabling" : "Enabling"); 53 old_val ? "Disabling" : "Enabling");
@@ -59,8 +59,8 @@ _folder_only_toggle(void *data,
59 void *event_info) 59 void *event_info)
60{ 60{
61 Evas_Object *fs_bt = data; 61 Evas_Object *fs_bt = data;
62 Eina_Bool old_val = elm_fileselector_button_folder_only_get(fs_bt); 62 Eina_Bool old_val = elm_fileselector_folder_only_get(fs_bt);
63 elm_fileselector_button_folder_only_set(fs_bt, !old_val); 63 elm_fileselector_folder_only_set(fs_bt, !old_val);
64 64
65 printf("Folder only mode set to: %s\n", old_val ? "false" : "true"); 65 printf("Folder only mode set to: %s\n", old_val ? "false" : "true");
66} 66}
@@ -71,8 +71,8 @@ _expandable_toggle(void *data,
71 void *event_info) 71 void *event_info)
72{ 72{
73 Evas_Object *fs_bt = data; 73 Evas_Object *fs_bt = data;
74 Eina_Bool old_val = elm_fileselector_button_expandable_get(fs_bt); 74 Eina_Bool old_val = elm_fileselector_expandable_get(fs_bt);
75 elm_fileselector_button_expandable_set(fs_bt, !old_val); 75 elm_fileselector_expandable_set(fs_bt, !old_val);
76 76
77 printf("Expandable folders mode set to: %s\n", old_val ? "false" : "true"); 77 printf("Expandable folders mode set to: %s\n", old_val ? "false" : "true");
78} 78}
@@ -99,7 +99,7 @@ elm_main(int argc,
99 99
100 /* file selector button */ 100 /* file selector button */
101 fs_bt = elm_fileselector_button_add(win); 101 fs_bt = elm_fileselector_button_add(win);
102 elm_fileselector_button_path_set(fs_bt, "/tmp"); 102 elm_fileselector_path_set(fs_bt, "/tmp");
103 elm_object_text_set(fs_bt, "Select a file"); 103 elm_object_text_set(fs_bt, "Select a file");
104 elm_object_part_content_set(fs_bt, "icon", ic); 104 elm_object_part_content_set(fs_bt, "icon", ic);
105 105
@@ -120,7 +120,7 @@ elm_main(int argc,
120 120
121 ck = elm_check_add(win); 121 ck = elm_check_add(win);
122 elm_object_text_set(ck, "editable selection"); 122 elm_object_text_set(ck, "editable selection");
123 elm_check_state_set(ck, elm_fileselector_button_is_save_get(fs_bt)); 123 elm_check_state_set(ck, elm_fileselector_is_save_get(fs_bt));
124 evas_object_smart_callback_add(ck, "changed", _current_sel_toggle, fs_bt); 124 evas_object_smart_callback_add(ck, "changed", _current_sel_toggle, fs_bt);
125 elm_box_pack_end(hbox, ck); 125 elm_box_pack_end(hbox, ck);
126 evas_object_show(ck); 126 evas_object_show(ck);
@@ -134,14 +134,14 @@ elm_main(int argc,
134 134
135 ck = elm_check_add(win); 135 ck = elm_check_add(win);
136 elm_object_text_set(ck, "folders only"); 136 elm_object_text_set(ck, "folders only");
137 elm_check_state_set(ck, elm_fileselector_button_folder_only_get(fs_bt)); 137 elm_check_state_set(ck, elm_fileselector_folder_only_get(fs_bt));
138 evas_object_smart_callback_add(ck, "changed", _folder_only_toggle, fs_bt); 138 evas_object_smart_callback_add(ck, "changed", _folder_only_toggle, fs_bt);
139 elm_box_pack_end(hbox, ck); 139 elm_box_pack_end(hbox, ck);
140 evas_object_show(ck); 140 evas_object_show(ck);
141 141
142 ck = elm_check_add(win); 142 ck = elm_check_add(win);
143 elm_object_text_set(ck, "expandable"); 143 elm_object_text_set(ck, "expandable");
144 elm_check_state_set(ck, elm_fileselector_button_expandable_get(fs_bt)); 144 elm_check_state_set(ck, elm_fileselector_expandable_get(fs_bt));
145 evas_object_smart_callback_add(ck, "changed", _expandable_toggle, fs_bt); 145 evas_object_smart_callback_add(ck, "changed", _expandable_toggle, fs_bt);
146 elm_box_pack_end(hbox, ck); 146 elm_box_pack_end(hbox, ck);
147 evas_object_show(ck); 147 evas_object_show(ck);