summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVitor Sousa <vitorsousasilva@gmail.com>2016-07-04 17:17:38 -0300
committerVitor Sousa <vitorsousasilva@gmail.com>2016-07-04 17:51:09 -0300
commitd4479b3f55e7008d212646102bcd209258800a12 (patch)
tree669583868ab24031b604097cb0fd048c1d42d1ec
parentf2bb08ba121efb27ede3a943de237331d727af1e (diff)
elementary/fileselector: Fix legacy path set/get of Fileselector.Entry
-rw-r--r--src/lib/elementary/elc_fileselector_button.c21
-rw-r--r--src/lib/elementary/elc_fileselector_entry.c6
-rw-r--r--src/lib/elementary/elm_interface_fileselector.h6
3 files changed, 25 insertions, 8 deletions
diff --git a/src/lib/elementary/elc_fileselector_button.c b/src/lib/elementary/elc_fileselector_button.c
index 38757fea6d..8ae9ecbd27 100644
--- a/src/lib/elementary/elc_fileselector_button.c
+++ b/src/lib/elementary/elc_fileselector_button.c
@@ -320,9 +320,8 @@ elm_fileselector_button_window_size_get(const Eo *obj, Evas_Coord *width, Evas_C
320 if (height) *height = sd->h; 320 if (height) *height = sd->h;
321} 321}
322 322
323EINA_DEPRECATED EAPI void 323void
324elm_fileselector_button_path_set(Evas_Object *obj, 324_elm_fileselector_button_path_set_internal(Evas_Object *obj, const char *path)
325 const char *path)
326{ 325{
327 ELM_FILESELECTOR_INTERFACE_CHECK(obj); 326 ELM_FILESELECTOR_INTERFACE_CHECK(obj);
328 ELM_FILESELECTOR_BUTTON_DATA_GET_OR_RETURN(obj, sd); 327 ELM_FILESELECTOR_BUTTON_DATA_GET_OR_RETURN(obj, sd);
@@ -343,6 +342,12 @@ elm_fileselector_button_path_set(Evas_Object *obj,
343 if (sd->fs) elm_interface_fileselector_selected_model_set(sd->fs, model, NULL); 342 if (sd->fs) elm_interface_fileselector_selected_model_set(sd->fs, model, NULL);
344} 343}
345 344
345EINA_DEPRECATED EAPI void
346elm_fileselector_button_path_set(Evas_Object *obj, const char *path)
347{
348 _elm_fileselector_button_path_set_internal(obj, path);
349}
350
346EOLIAN static void 351EOLIAN static void
347_elm_fileselector_button_elm_interface_fileselector_model_set(Eo *obj EINA_UNUSED, Elm_Fileselector_Button_Data *sd, Efl_Model *model) 352_elm_fileselector_button_elm_interface_fileselector_model_set(Eo *obj EINA_UNUSED, Elm_Fileselector_Button_Data *sd, Efl_Model *model)
348{ 353{
@@ -365,14 +370,20 @@ _elm_fileselector_button_elm_interface_fileselector_model_set(Eo *obj EINA_UNUSE
365 if (sd->fs) elm_interface_fileselector_selected_model_set(sd->fs, model, NULL); 370 if (sd->fs) elm_interface_fileselector_selected_model_set(sd->fs, model, NULL);
366} 371}
367 372
368EINA_DEPRECATED EAPI const char * 373const char *
369elm_fileselector_button_path_get(const Evas_Object *obj) 374_elm_fileselector_button_path_get_internal(const Evas_Object *obj)
370{ 375{
371 ELM_FILESELECTOR_INTERFACE_CHECK(obj, NULL); 376 ELM_FILESELECTOR_INTERFACE_CHECK(obj, NULL);
372 ELM_FILESELECTOR_BUTTON_DATA_GET_OR_RETURN_VAL(obj, sd, NULL); 377 ELM_FILESELECTOR_BUTTON_DATA_GET_OR_RETURN_VAL(obj, sd, NULL);
373 return sd->fsd.path; 378 return sd->fsd.path;
374} 379}
375 380
381EINA_DEPRECATED EAPI const char *
382elm_fileselector_button_path_get(const Evas_Object *obj)
383{
384 return _elm_fileselector_button_path_get_internal(obj);
385}
386
376EOLIAN static Efl_Model * 387EOLIAN static Efl_Model *
377_elm_fileselector_button_elm_interface_fileselector_model_get(Eo *obj EINA_UNUSED, Elm_Fileselector_Button_Data *sd) 388_elm_fileselector_button_elm_interface_fileselector_model_get(Eo *obj EINA_UNUSED, Elm_Fileselector_Button_Data *sd)
378{ 389{
diff --git a/src/lib/elementary/elc_fileselector_entry.c b/src/lib/elementary/elc_fileselector_entry.c
index 616c839b9b..a0edf250d8 100644
--- a/src/lib/elementary/elc_fileselector_entry.c
+++ b/src/lib/elementary/elc_fileselector_entry.c
@@ -401,7 +401,7 @@ elm_fileselector_entry_selected_set(Evas_Object *obj, const char *path)
401{ 401{
402 ELM_FILESELECTOR_INTERFACE_CHECK(obj); 402 ELM_FILESELECTOR_INTERFACE_CHECK(obj);
403 ELM_FILESELECTOR_ENTRY_DATA_GET_OR_RETURN(obj, sd); 403 ELM_FILESELECTOR_ENTRY_DATA_GET_OR_RETURN(obj, sd);
404 elm_fileselector_path_set(sd->button, path); 404 _elm_fileselector_button_path_set_internal(sd->button, path);
405} 405}
406 406
407EOLIAN static void 407EOLIAN static void
@@ -419,7 +419,7 @@ elm_fileselector_entry_selected_get(const Evas_Object *obj)
419{ 419{
420 ELM_FILESELECTOR_INTERFACE_CHECK(obj, NULL); 420 ELM_FILESELECTOR_INTERFACE_CHECK(obj, NULL);
421 ELM_FILESELECTOR_ENTRY_DATA_GET_OR_RETURN_VAL(obj, sd, NULL); 421 ELM_FILESELECTOR_ENTRY_DATA_GET_OR_RETURN_VAL(obj, sd, NULL);
422 return elm_fileselector_path_get(sd->button); 422 return _elm_fileselector_button_path_get_internal(sd->button);
423} 423}
424 424
425EOLIAN static Efl_Model * 425EOLIAN static Efl_Model *
@@ -475,7 +475,7 @@ elm_fileselector_entry_path_set(Evas_Object *obj,
475 free(s); 475 free(s);
476 } 476 }
477 477
478 elm_fileselector_path_set(sd->button, path); 478 _elm_fileselector_button_path_set_internal(sd->button, path);
479} 479}
480 480
481static void 481static void
diff --git a/src/lib/elementary/elm_interface_fileselector.h b/src/lib/elementary/elm_interface_fileselector.h
index 31b2bded5a..731dd517e4 100644
--- a/src/lib/elementary/elm_interface_fileselector.h
+++ b/src/lib/elementary/elm_interface_fileselector.h
@@ -12,4 +12,10 @@
12 return __VA_ARGS__; \ 12 return __VA_ARGS__; \
13 } 13 }
14 14
15void
16_elm_fileselector_button_path_set_internal(Evas_Object *obj, const char *path);
17
18const char *
19_elm_fileselector_button_path_get_internal(const Evas_Object *obj);
20
15#endif 21#endif