summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Juyung Seo <seojuyung2@gmail.com>2014-01-21 23:53:48 +0900
committerDaniel Juyung Seo <seojuyung2@gmail.com>2014-01-21 23:53:48 +0900
commitb2842f5a940d0344ea2f8bf0cdb06dae981f9726 (patch)
treec24446ec6db4048342fc6707bb4b7da3ada81b2b
parent389ba85493c324fc0f5a9dbb75a34d5c589203aa (diff)
test, examples fileselector_entry: Changed the usage of deprecated APIs
to recommended APIs.
-rw-r--r--src/examples/fileselector_entry_example.c20
1 files changed, 10 insertions, 10 deletions
diff --git a/src/examples/fileselector_entry_example.c b/src/examples/fileselector_entry_example.c
index 0696492a6..2aa18ce22 100644
--- a/src/examples/fileselector_entry_example.c
+++ b/src/examples/fileselector_entry_example.c
@@ -44,8 +44,8 @@ _current_sel_toggle(void *data,
44 void *event_info) 44 void *event_info)
45{ 45{
46 Evas_Object *fs_entry = data; 46 Evas_Object *fs_entry = data;
47 Eina_Bool old_val = elm_fileselector_entry_is_save_get(fs_entry); 47 Eina_Bool old_val = elm_fileselector_is_save_get(fs_entry);
48 elm_fileselector_entry_is_save_set(fs_entry, !old_val); 48 elm_fileselector_is_save_set(fs_entry, !old_val);
49 49
50 printf("%s text entry with selected item's name\n", 50 printf("%s text entry with selected item's name\n",
51 old_val ? "Disabling" : "Enabling"); 51 old_val ? "Disabling" : "Enabling");
@@ -57,8 +57,8 @@ _folder_only_toggle(void *data,
57 void *event_info) 57 void *event_info)
58{ 58{
59 Evas_Object *fs_entry = data; 59 Evas_Object *fs_entry = data;
60 Eina_Bool old_val = elm_fileselector_entry_folder_only_get(fs_entry); 60 Eina_Bool old_val = elm_fileselector_folder_only_get(fs_entry);
61 elm_fileselector_entry_folder_only_set(fs_entry, !old_val); 61 elm_fileselector_folder_only_set(fs_entry, !old_val);
62 62
63 printf("Folder only mode set to: %s\n", old_val ? "false" : "true"); 63 printf("Folder only mode set to: %s\n", old_val ? "false" : "true");
64} 64}
@@ -69,8 +69,8 @@ _expandable_toggle(void *data,
69 void *event_info) 69 void *event_info)
70{ 70{
71 Evas_Object *fs_entry = data; 71 Evas_Object *fs_entry = data;
72 Eina_Bool old_val = elm_fileselector_entry_expandable_get(fs_entry); 72 Eina_Bool old_val = elm_fileselector_expandable_get(fs_entry);
73 elm_fileselector_entry_expandable_set(fs_entry, !old_val); 73 elm_fileselector_expandable_set(fs_entry, !old_val);
74 74
75 printf("Expandable folders mode set to: %s\n", old_val ? "false" : "true"); 75 printf("Expandable folders mode set to: %s\n", old_val ? "false" : "true");
76} 76}
@@ -98,7 +98,7 @@ elm_main(int argc,
98 /* file selector entry */ 98 /* file selector entry */
99 fs_entry = elm_fileselector_entry_add(win); 99 fs_entry = elm_fileselector_entry_add(win);
100 evas_object_size_hint_align_set(fs_entry, EVAS_HINT_FILL, 0); 100 evas_object_size_hint_align_set(fs_entry, EVAS_HINT_FILL, 0);
101 elm_fileselector_entry_path_set(fs_entry, "/tmp"); 101 elm_fileselector_path_set(fs_entry, "/tmp");
102 elm_object_text_set(fs_entry, "Select a file"); 102 elm_object_text_set(fs_entry, "Select a file");
103 elm_object_part_content_set(fs_entry, "button icon", ic); 103 elm_object_part_content_set(fs_entry, "button icon", ic);
104 104
@@ -119,7 +119,7 @@ elm_main(int argc,
119 119
120 ck = elm_check_add(win); 120 ck = elm_check_add(win);
121 elm_object_text_set(ck, "editable selection"); 121 elm_object_text_set(ck, "editable selection");
122 elm_check_state_set(ck, elm_fileselector_entry_is_save_get(fs_entry)); 122 elm_check_state_set(ck, elm_fileselector_is_save_get(fs_entry));
123 evas_object_smart_callback_add(ck, "changed", _current_sel_toggle, fs_entry); 123 evas_object_smart_callback_add(ck, "changed", _current_sel_toggle, fs_entry);
124 elm_box_pack_end(hbox, ck); 124 elm_box_pack_end(hbox, ck);
125 evas_object_show(ck); 125 evas_object_show(ck);
@@ -133,14 +133,14 @@ elm_main(int argc,
133 133
134 ck = elm_check_add(win); 134 ck = elm_check_add(win);
135 elm_object_text_set(ck, "folders only"); 135 elm_object_text_set(ck, "folders only");
136 elm_check_state_set(ck, elm_fileselector_entry_folder_only_get(fs_entry)); 136 elm_check_state_set(ck, elm_fileselector_folder_only_get(fs_entry));
137 evas_object_smart_callback_add(ck, "changed", _folder_only_toggle, fs_entry); 137 evas_object_smart_callback_add(ck, "changed", _folder_only_toggle, fs_entry);
138 elm_box_pack_end(hbox, ck); 138 elm_box_pack_end(hbox, ck);
139 evas_object_show(ck); 139 evas_object_show(ck);
140 140
141 ck = elm_check_add(win); 141 ck = elm_check_add(win);
142 elm_object_text_set(ck, "expandable"); 142 elm_object_text_set(ck, "expandable");
143 elm_check_state_set(ck, elm_fileselector_entry_expandable_get(fs_entry)); 143 elm_check_state_set(ck, elm_fileselector_expandable_get(fs_entry));
144 evas_object_smart_callback_add(ck, "changed", _expandable_toggle, fs_entry); 144 evas_object_smart_callback_add(ck, "changed", _expandable_toggle, fs_entry);
145 elm_box_pack_end(hbox, ck); 145 elm_box_pack_end(hbox, ck);
146 evas_object_show(ck); 146 evas_object_show(ck);