diff options
author | David Walter Seikel | 2016-03-13 19:59:59 +1000 |
---|---|---|
committer | David Walter Seikel | 2016-03-13 19:59:59 +1000 |
commit | bb128645efa19772a5c1a039df9c46213feb4426 (patch) | |
tree | 87bb9931b4effd3dc1db4ee607d69367cc19a9c6 /src/extantz/files.c | |
parent | Introducing Rough Hir, the new default avatar. At least, when we get avatars. (diff) | |
download | SledjHamr-bb128645efa19772a5c1a039df9c46213feb4426.zip SledjHamr-bb128645efa19772a5c1a039df9c46213feb4426.tar.gz SledjHamr-bb128645efa19772a5c1a039df9c46213feb4426.tar.bz2 SledjHamr-bb128645efa19772a5c1a039df9c46213feb4426.tar.xz |
Update to new eo_* syntax.
Diffstat (limited to '')
-rw-r--r-- | src/extantz/files.c | 76 |
1 files changed, 37 insertions, 39 deletions
diff --git a/src/extantz/files.c b/src/extantz/files.c index 535e250..216e696 100644 --- a/src/extantz/files.c +++ b/src/extantz/files.c | |||
@@ -153,11 +153,9 @@ winFang *filesAdd(globals *ourGlobals, char *path, Eina_Bool multi, Eina_Bool sa | |||
153 | wid->data = ourGlobals; | 153 | wid->data = ourGlobals; |
154 | wid->on_del = _on_fs_del; | 154 | wid->on_del = _on_fs_del; |
155 | me->data = fs; | 155 | me->data = fs; |
156 | eo_do(fs, | 156 | elm_obj_fileselector_buttons_ok_cancel_set(fs, EINA_FALSE); |
157 | elm_obj_fileselector_buttons_ok_cancel_set(EINA_FALSE), | 157 | elm_interface_fileselector_expandable_set(fs, EINA_TRUE); |
158 | elm_interface_fileselector_expandable_set(EINA_TRUE), | 158 | elm_interface_fileselector_folder_only_set(fs, EINA_FALSE); |
159 | elm_interface_fileselector_folder_only_set(EINA_FALSE) | ||
160 | ); | ||
161 | 159 | ||
162 | elm_fileselector_path_set(fs, path); | 160 | elm_fileselector_path_set(fs, path); |
163 | elm_fileselector_is_save_set(fs, save); | 161 | elm_fileselector_is_save_set(fs, save); |
@@ -177,36 +175,36 @@ winFang *filesAdd(globals *ourGlobals, char *path, Eina_Bool multi, Eina_Bool sa | |||
177 | evas_object_smart_callback_add(fs, "activated", my_fileselector_activated, me); | 175 | evas_object_smart_callback_add(fs, "activated", my_fileselector_activated, me); |
178 | 176 | ||
179 | hbox = eo_add(ELM_BOX_CLASS, me->win, | 177 | hbox = eo_add(ELM_BOX_CLASS, me->win, |
180 | elm_obj_box_homogeneous_set(EINA_FALSE), | 178 | elm_obj_box_homogeneous_set(eoid, EINA_FALSE), |
181 | elm_obj_box_horizontal_set(EINA_TRUE), | 179 | elm_obj_box_horizontal_set(eoid, EINA_TRUE), |
182 | evas_obj_size_hint_align_set(EVAS_HINT_FILL, EVAS_HINT_FILL) | 180 | evas_obj_size_hint_align_set(eoid, EVAS_HINT_FILL, EVAS_HINT_FILL) |
183 | ); | 181 | ); |
184 | 182 | ||
185 | hoversel = eo_add(ELM_HOVERSEL_CLASS, hbox, | 183 | hoversel = eo_add(ELM_HOVERSEL_CLASS, hbox, |
186 | elm_obj_hoversel_hover_parent_set(me->win), | 184 | elm_obj_hoversel_hover_parent_set(eoid, me->win), |
187 | eo_key_data_set("fileselector", fs), | 185 | eo_key_data_set(eoid, "fileselector", fs), |
188 | elm_obj_hoversel_item_add("name(asc)", NULL, ELM_ICON_NONE, _sort_selected_cb, (const void *) ELM_FILESELECTOR_SORT_BY_FILENAME_ASC), | 186 | elm_obj_hoversel_item_add(eoid, "name(asc)", NULL, ELM_ICON_NONE, _sort_selected_cb, (const void *) ELM_FILESELECTOR_SORT_BY_FILENAME_ASC), |
189 | elm_obj_hoversel_item_add("name(desc)", NULL, ELM_ICON_NONE, _sort_selected_cb, (const void *) ELM_FILESELECTOR_SORT_BY_FILENAME_DESC), | 187 | elm_obj_hoversel_item_add(eoid, "name(desc)", NULL, ELM_ICON_NONE, _sort_selected_cb, (const void *) ELM_FILESELECTOR_SORT_BY_FILENAME_DESC), |
190 | elm_obj_hoversel_item_add("type(asc)", NULL, ELM_ICON_NONE, _sort_selected_cb, (const void *) ELM_FILESELECTOR_SORT_BY_TYPE_ASC), | 188 | elm_obj_hoversel_item_add(eoid, "type(asc)", NULL, ELM_ICON_NONE, _sort_selected_cb, (const void *) ELM_FILESELECTOR_SORT_BY_TYPE_ASC), |
191 | elm_obj_hoversel_item_add("type(desc)", NULL, ELM_ICON_NONE, _sort_selected_cb, (const void *) ELM_FILESELECTOR_SORT_BY_TYPE_DESC), | 189 | elm_obj_hoversel_item_add(eoid, "type(desc)", NULL, ELM_ICON_NONE, _sort_selected_cb, (const void *) ELM_FILESELECTOR_SORT_BY_TYPE_DESC), |
192 | elm_obj_hoversel_item_add("size(asc)", NULL, ELM_ICON_NONE, _sort_selected_cb, (const void *) ELM_FILESELECTOR_SORT_BY_SIZE_ASC), | 190 | elm_obj_hoversel_item_add(eoid, "size(asc)", NULL, ELM_ICON_NONE, _sort_selected_cb, (const void *) ELM_FILESELECTOR_SORT_BY_SIZE_ASC), |
193 | elm_obj_hoversel_item_add("size(desc)", NULL, ELM_ICON_NONE, _sort_selected_cb, (const void *) ELM_FILESELECTOR_SORT_BY_SIZE_DESC), | 191 | elm_obj_hoversel_item_add(eoid, "size(desc)", NULL, ELM_ICON_NONE, _sort_selected_cb, (const void *) ELM_FILESELECTOR_SORT_BY_SIZE_DESC), |
194 | elm_obj_hoversel_item_add("time(asc)", NULL, ELM_ICON_NONE, _sort_selected_cb, (const void *) ELM_FILESELECTOR_SORT_BY_MODIFIED_ASC), | 192 | elm_obj_hoversel_item_add(eoid, "time(asc)", NULL, ELM_ICON_NONE, _sort_selected_cb, (const void *) ELM_FILESELECTOR_SORT_BY_MODIFIED_ASC), |
195 | elm_obj_hoversel_item_add("time(desc)", NULL, ELM_ICON_NONE, _sort_selected_cb, (const void *) ELM_FILESELECTOR_SORT_BY_MODIFIED_DESC), | 193 | elm_obj_hoversel_item_add(eoid, "time(desc)", NULL, ELM_ICON_NONE, _sort_selected_cb, (const void *) ELM_FILESELECTOR_SORT_BY_MODIFIED_DESC), |
196 | efl_gfx_visible_set(EINA_TRUE) | 194 | efl_gfx_visible_set(eoid, EINA_TRUE) |
197 | ); | 195 | ); |
198 | elm_object_text_set(hoversel, "sorting"); | 196 | elm_object_text_set(hoversel, "sorting"); |
199 | elm_box_pack_end(hbox, hoversel); | 197 | elm_box_pack_end(hbox, hoversel); |
200 | 198 | ||
201 | hoversel = eo_add(ELM_HOVERSEL_CLASS, hbox, | 199 | hoversel = eo_add(ELM_HOVERSEL_CLASS, hbox, |
202 | elm_obj_hoversel_hover_parent_set(me->win), | 200 | elm_obj_hoversel_hover_parent_set(eoid, me->win), |
203 | eo_key_data_set("fileselector", fs), | 201 | eo_key_data_set(eoid, "fileselector", fs), |
204 | elm_obj_hoversel_item_add("tiny", NULL, ELM_ICON_NONE, _tiny_icon_clicked, fs), | 202 | elm_obj_hoversel_item_add(eoid, "tiny", NULL, ELM_ICON_NONE, _tiny_icon_clicked, fs), |
205 | elm_obj_hoversel_item_add("small", NULL, ELM_ICON_NONE, _small_icon_clicked, fs), | 203 | elm_obj_hoversel_item_add(eoid, "small", NULL, ELM_ICON_NONE, _small_icon_clicked, fs), |
206 | elm_obj_hoversel_item_add("medium", NULL, ELM_ICON_NONE, _middle_icon_clicked, fs), | 204 | elm_obj_hoversel_item_add(eoid, "medium", NULL, ELM_ICON_NONE, _middle_icon_clicked, fs), |
207 | elm_obj_hoversel_item_add("big", NULL, ELM_ICON_NONE, _big_icon_clicked, fs), | 205 | elm_obj_hoversel_item_add(eoid, "big", NULL, ELM_ICON_NONE, _big_icon_clicked, fs), |
208 | efl_gfx_visible_set(EINA_TRUE) | 206 | efl_gfx_visible_set(eoid, EINA_TRUE) |
209 | ); | 207 | ); |
210 | elm_object_text_set(hoversel, "size"); | 208 | elm_object_text_set(hoversel, "size"); |
211 | elm_box_pack_end(hbox, hoversel); | 209 | elm_box_pack_end(hbox, hoversel); |
212 | // Make sure it starts off as small, works around "hitting grid mode before hitting size not showing anything" bug. | 210 | // Make sure it starts off as small, works around "hitting grid mode before hitting size not showing anything" bug. |
@@ -214,17 +212,17 @@ winFang *filesAdd(globals *ourGlobals, char *path, Eina_Bool multi, Eina_Bool sa | |||
214 | 212 | ||
215 | 213 | ||
216 | bt = eo_add(ELM_CHECK_CLASS, hbox, | 214 | bt = eo_add(ELM_CHECK_CLASS, hbox, |
217 | elm_obj_check_state_set(elm_fileselector_hidden_visible_get(fs)), | 215 | elm_obj_check_state_set(eoid, elm_fileselector_hidden_visible_get(fs)), |
218 | efl_gfx_visible_set(EINA_TRUE) | 216 | efl_gfx_visible_set(eoid, EINA_TRUE) |
219 | ); | 217 | ); |
220 | elm_object_text_set(bt, "hidden"); | 218 | elm_object_text_set(bt, "hidden"); |
221 | evas_object_smart_callback_add(bt, "changed", _hidden_clicked, fs); | 219 | evas_object_smart_callback_add(bt, "changed", _hidden_clicked, fs); |
222 | elm_box_pack_end(hbox, bt); | 220 | elm_box_pack_end(hbox, bt); |
223 | 221 | ||
224 | rdg = rd = eo_add(ELM_RADIO_CLASS, hbox, | 222 | rdg = rd = eo_add(ELM_RADIO_CLASS, hbox, |
225 | elm_obj_radio_state_value_set(ELM_FILESELECTOR_GRID), | 223 | elm_obj_radio_state_value_set(eoid, ELM_FILESELECTOR_GRID), |
226 | efl_gfx_visible_set(EINA_TRUE) | 224 | efl_gfx_visible_set(eoid, EINA_TRUE) |
227 | ); | 225 | ); |
228 | elm_object_text_set(rd, "grid"); | 226 | elm_object_text_set(rd, "grid"); |
229 | elm_box_pack_end(hbox, rd); | 227 | elm_box_pack_end(hbox, rd); |
230 | evas_object_smart_callback_add(rd, "changed", _mode_changed_cb, fs); | 228 | evas_object_smart_callback_add(rd, "changed", _mode_changed_cb, fs); |
@@ -232,23 +230,23 @@ winFang *filesAdd(globals *ourGlobals, char *path, Eina_Bool multi, Eina_Bool sa | |||
232 | _mode_changed_cb(fs, rd, NULL); | 230 | _mode_changed_cb(fs, rd, NULL); |
233 | 231 | ||
234 | rd = eo_add(ELM_RADIO_CLASS, hbox, | 232 | rd = eo_add(ELM_RADIO_CLASS, hbox, |
235 | elm_obj_radio_state_value_set(ELM_FILESELECTOR_LIST), | 233 | elm_obj_radio_state_value_set(eoid, ELM_FILESELECTOR_LIST), |
236 | efl_gfx_visible_set(EINA_TRUE) | 234 | efl_gfx_visible_set(eoid, EINA_TRUE) |
237 | ); | 235 | ); |
238 | elm_radio_group_add(rd, rdg); | 236 | elm_radio_group_add(rd, rdg); |
239 | elm_object_text_set(rd, "list"); | 237 | elm_object_text_set(rd, "list"); |
240 | elm_box_pack_end(hbox, rd); | 238 | elm_box_pack_end(hbox, rd); |
241 | evas_object_smart_callback_add(rd, "changed", _mode_changed_cb, fs); | 239 | evas_object_smart_callback_add(rd, "changed", _mode_changed_cb, fs); |
242 | 240 | ||
243 | bt = eo_add(ELM_BUTTON_CLASS, me->win, | 241 | bt = eo_add(ELM_BUTTON_CLASS, me->win, |
244 | efl_gfx_visible_set(EINA_TRUE) | 242 | efl_gfx_visible_set(eoid, EINA_TRUE) |
245 | ); | 243 | ); |
246 | elm_object_text_set(bt, "OK"); | 244 | elm_object_text_set(bt, "OK"); |
247 | evas_object_smart_callback_add(bt, "clicked", _OK_clicked, me); | 245 | evas_object_smart_callback_add(bt, "clicked", _OK_clicked, me); |
248 | elm_box_pack_end(hbox, bt); | 246 | elm_box_pack_end(hbox, bt); |
249 | 247 | ||
250 | bt = eo_add(ELM_BUTTON_CLASS, me->win, | 248 | bt = eo_add(ELM_BUTTON_CLASS, me->win, |
251 | efl_gfx_visible_set(EINA_TRUE) | 249 | efl_gfx_visible_set(eoid, EINA_TRUE) |
252 | ); | 250 | ); |
253 | elm_object_text_set(bt, "CANCEL"); | 251 | elm_object_text_set(bt, "CANCEL"); |
254 | evas_object_smart_callback_add(bt, "clicked", _CANCEL_clicked, me); | 252 | evas_object_smart_callback_add(bt, "clicked", _CANCEL_clicked, me); |