Removed unused code 07/144807/1
authorRahul Dadhich <r.dadhich@samsung.com>
Fri, 18 Aug 2017 04:44:53 +0000 (10:14 +0530)
committerRahul Dadhich <r.dadhich@samsung.com>
Fri, 18 Aug 2017 04:44:53 +0000 (10:14 +0530)
Change-Id: If8b3b2a63c183c69e081a242317b541b4afc24d4
Signed-off-by: Rahul Dadhich <r.dadhich@samsung.com>
20 files changed:
inc/2dview/gl-albums.h
inc/2dview/gl-thumbs-edit.h
inc/2dview/gl-thumbs.h
inc/data/gl-data-type.h
inc/util/gl-file-util.h
inc/util/gl-fs.h
inc/util/gl-ui-util.h
inc/util/gl-util.h
inc/widget/gl-editfield.h
src/2dview/gl-albums.c
src/2dview/gl-thumbs-edit.c
src/2dview/gl-thumbs.c
src/2dview/gl-timeline.c
src/data/gl-data-type.c
src/util/gl-file-util.c
src/util/gl-fs.c
src/util/gl-ui-util.c
src/util/gl-util.c
src/widget/gl-editfield.c
widget/src/gl_widget_create.c

index e950308d741ca726d7f7e716ec7bf72e322d7669..cfb417666bb6e95045708aa4803b06771bd9d753 100644 (file)
@@ -36,7 +36,6 @@ int _gl_albums_clear_cbs(Evas_Object * view);
 int gl_albums_open_album(gl_cluster * album_item);
 Evas_Object *_gl_albums_add_gengrid(void *data, Evas_Object * parent);
 Evas_Object *_gl_albums_add_view(void *data, Evas_Object * parent);
-Evas_Object *_gl_albums_sel_add_view(void *data, Evas_Object * parent);
 void __gl_albums_new_album_sel(void *data, Evas_Object * obj, void *ei);
 int _gl_albums_create_items(void *data, Evas_Object * parent);
 int _gl_split_albums_create_items(void *data, Evas_Object * parent);
index a69128151baebf09a33f101a528ad0f8462ca7d7..6265b2ce80c426f5cb24ea9325bb6812291daef5 100644 (file)
@@ -23,7 +23,6 @@
 int _gl_thumbs_edit_add_btns(void *data, Evas_Object * parent,
                                                         Elm_Object_Item * nf_it);
 int _gl_thumbs_edit_create_view(void *data);
-int _gl_thumbs_edit_update_view(void *data);
 int _gl_thumbs_edit_pop_view(void *data);
 int _gl_thumbs_edit_update_lang(void *data);
 int _gl_thumbs_edit_disable_btns(void *data, bool b_disable);
index 7d50981c56bd380b897a3a96f2d52c4cf362289f..4e847041df592b9724e7006740cc2064d478320e 100644 (file)
@@ -38,7 +38,6 @@ typedef enum _gl_thumbs_edit_mode_t {
 } gl_thumbs_edit_e;
 
 Eina_Bool _gl_thumbs_append_items(void *data);
-int _gl_thumbs_update_realized_items(void *data);
 Evas_Object *_gl_thumbs_get_content(void *data, Evas_Object * parent,
                                                                        gl_item * gitem, int w, int h);
 int _gl_thumbs_add_btns(void *data);
index 205c2dc45b3a6ab9540ba0a658d68b05e0c1c164..b8675a05a5f3f3917c36a6920c53a15620470b46 100644 (file)
@@ -121,7 +121,6 @@ extern "C" {
                int bookmarks;                  /*whether exist bookmarks */
        };
 
-       int _gl_data_type_new_media(gl_media_s ** item);
        int _gl_data_type_new_album(gl_album_s ** album);
 
        int _gl_data_type_free_glitem(void **item);
index c688eadc03cd594d58ec1ba3a128494c990980e4..aafc5fc2b95001834cc9b8aa07538e825dc161e7 100644 (file)
@@ -40,16 +40,10 @@ extern "C" {
 
        int gl_file_dir_is_empty(const char *path);
 
-       Eina_List *gl_file_ls(const char *dir);
-
        int gl_file_recursive_rm(const char *dir);
 
-       char *gl_file_dir_get(const char path[]);
-
        int gl_file_mkpath(const char *path);
 
-       int gl_file_mv(const char *src, const char *dst);
-
 #ifdef __cplusplus
 }
 #endif
index dac8e8f05bf778deff371698f74a9f3ef37ec475..f9e212418300574b58835dcb9adee197b2fccd5c 100644 (file)
@@ -58,7 +58,6 @@ extern "C" {
                                                                                   char *default_name,
                                                                                   char **new_name);
        bool _gl_fs_validate_name(const char *new_name);
-       bool _gl_fs_validate_character(const char name_char);
        bool _gl_fs_mkdir(const char *path);
 
 #ifdef __cplusplus
index 39c15c2129a98175f5780251a424b1cac224169c..851d263ba16ec0027dc0f407c6a42c5a2a07591f 100644 (file)
@@ -25,10 +25,6 @@ extern "C" {
 #endif
 
 #define _EDJ(o)         elm_layout_edje_get(o)
-#define _GET_ICON(_path) \
-               ((1 == gl_file_exists(_path) && (gl_file_size(_path) > 0)) ? _path : GL_ICON_NO_THUMBNAIL)
-#define _GET_APP_ICON(_path) \
-               ((1 == gl_file_exists(_path) && (gl_file_size(_path) > 0)) ? _path : GL_ICON_DEFAULT)
 
 /* Signals used in Gallery's views */
 #define GL_SIGNAL_GESTURE_DEFAULT "elm,gesture,state,default"
@@ -71,9 +67,7 @@ extern "C" {
        Evas_Object *gl_ui_load_edj(Evas_Object * parent, const char *file,
                                                                const char *group);
        int _gl_ui_clear_btns(void *data);
-       int _gl_ui_set_conform_overlap(Evas_Object * naviframe);
        int _gl_ui_disable_btn(Evas_Object * btn);
-       int _gl_ui_enable_btn(Evas_Object * btn);
        int _gl_ui_disable_menu(Elm_Object_Item * nf_it, bool b_disabled);
        Evas_Object *_gl_ui_get_btn(void *data, Elm_Object_Item * nf_it,
                                                                const char *part);
@@ -91,14 +85,8 @@ extern "C" {
        int _gl_ui_set_translate_str(Evas_Object * obj, const char *str);
        int _gl_ui_set_translatable_item(Elm_Object_Item * nf_it,
                                                                         const char *str);
-       int _gl_ui_set_translatable_item_part(Elm_Object_Item * nf_it,
-                                                                                 const char *part,
-                                                                                 const char *str);
        int _gl_ui_set_translate_part_str(Evas_Object * obj, const char *part,
                                                                          const char *str);
-       int _gl_ui_change_title(Elm_Object_Item * nf_it, const char *text);
-       int _gl_ui_update_label_text(Elm_Object_Item * nf_it, int sel_cnt,
-                                                                bool b_lang);
        int _gl_ui_change_navi_title(Elm_Object_Item * nf_it, char *text,
                                                                 bool b_dropdown);
        int _gl_ui_update_navi_title_text(Elm_Object_Item * nf_it, int sel_cnt,
index bb60c1f1911c5dc27dfb2e3e0561f1cfd039ad66..4880b4633c279cc0d3948661b647ee328dc3834f 100644 (file)
@@ -175,11 +175,7 @@ extern "C" {
        int _gl_move_media_thumb_by_id(void *data, const char *uuid,
                                                                   char *new_dir_name, int *popup_op,
                                                                   int mc_mode);
-       int _gl_move_media(gl_item * gitem, char *new_dir_name,
-                                          bool is_full_path);
        int gl_move_copy_to_album(void *data);
-       int gl_move_root_album(void *data, gl_cluster * cur_album,
-                                                  char *dest_path);
        int gl_del_medias(void *data);
        int _gl_del_media_by_id(void *data, const char *uuid);
        int gl_check_mmc_state(void *data, char *dest_folder);
@@ -203,7 +199,6 @@ extern "C" {
        char *_gl_str(char *str_id);
        bool _gl_is_str_id(const char *str_id);
        double _gl_get_win_factor(Evas_Object * win, int *width, int *height);
-       int _gl_get_font_size(void);
        int _gl_reg_storage_state_change_notify(void *data);
        int _gl_dereg_storage_state_change_notify(void *data);
        int _gl_set_file_op_cbs(void *data, void *op_cb, void *del_item_cb,
index 21d3d3f8767d4459139894de08a3d104df678e64..1523a4087a8ad6a346c919198e90a30e80c380ed 100644 (file)
@@ -26,7 +26,6 @@ extern "C" {
        int _gl_editfield_hide_imf(void *data);
        int _gl_editfield_show_imf(void *data);
        int _gl_editfield_destroy_imf(void *data);
-       int _gl_editfield_change_navi_title(void *data, int r);
        Evas_Object *_gl_editfield_get_entry(void *data);
        int __gl_editfield_set_entry(void *data, Evas_Object * layout,
                                                                 Evas_Object * entry, char *default_label);
index c71e78f8b6e8a475a8d657f33ba47db3c0361275..41c7a75855bc8655da7722913eb1e2e105cc1060 100644 (file)
@@ -1389,57 +1389,6 @@ Evas_Object *_gl_albums_create_album_sel_gengrid(void *data)
        return layout_inner;
 }
 
-Evas_Object *_gl_albums_sel_add_view(void *data, Evas_Object * parent)
-{
-       GL_CHECK_NULL(parent);
-       GL_CHECK_NULL(data);
-       gl_appdata *ad = (gl_appdata *) data;
-       GL_CHECK_NULL(ad->albuminfo.elist);
-       gl_dbg("");
-
-       ad->albuminfo.albums_cnt = 0;
-
-       Evas_Object *grid = _gl_albums_create_album_sel_gengrid(data);
-       GL_CHECK_NULL(grid);
-       int ret = _gl_albums_create_items(ad, grid);
-
-       int view_mode = gl_get_view_mode(ad);
-       gl_dbg("view_mode: %d", view_mode);
-       if (view_mode == GL_VIEW_ALBUMS_SELECT) {
-               if (ad->albuminfo.albums_cnt == 0) {
-                       gl_dbgE("None albums!");
-                       evas_object_del(grid);
-                       grid = NULL;
-               } else {
-                       evas_object_show(grid);
-               }
-               return grid;
-       }
-
-       /* show no contents if none albums appended or none album exists */
-       if (ret < 0 || gl_check_gallery_empty(ad)) {
-               _gl_ui_del_scroller_pos(grid);
-               evas_object_del(grid);
-               grid = NULL;
-               _gl_del_popup(data);
-               Evas_Object *noc =
-                       _gl_nocontents_create(ad->ctrlinfo.ctrlbar_view_ly);
-               evas_object_show(noc);
-               ad->albuminfo.nocontents = noc;
-               elm_naviframe_item_title_enabled_set(ad->ctrlinfo.nf_it, EINA_TRUE,
-                                                                                        EINA_TRUE);
-
-               return noc;
-       } else {
-               ad->albuminfo.nocontents = NULL;
-               elm_naviframe_item_title_enabled_set(ad->ctrlinfo.nf_it, EINA_TRUE,
-                                                                                        EINA_TRUE);
-       }
-
-       gl_dbg("done");
-       return grid;
-}
-
 /* Add albums view and doesn't push it to naviframe */
 Evas_Object *_gl_albums_add_view(void *data, Evas_Object * parent)
 {
index 0b05a63053dad098a13d4e9a8ecf8de7c0fea8b2..f49d94caceca6a78e10223b93de4d7969e1d749e 100644 (file)
@@ -281,26 +281,6 @@ int _gl_thumbs_edit_create_view(void *data)
        return 0;
 }
 
-/* Get new data and refresh view */
-int _gl_thumbs_edit_update_view(void *data)
-{
-       GL_CHECK_VAL(data, -1);
-       gl_appdata *ad = (gl_appdata *) data;
-       gl_sdbg("grid_type: %d", ad->gridinfo.grid_type);
-
-       switch (ad->gridinfo.grid_type) {
-       case GL_GRID_T_LOCAL:
-       case GL_GRID_T_ALLALBUMS:
-               /* Albums list should be updated first */
-               _gl_thumbs_update_items(ad);
-               break;
-       default:
-               gl_dbgE("Wrong grid type!");
-               return -1;
-       }
-       return 0;
-}
-
 int _gl_thumbs_edit_pop_view(void *data)
 {
        GL_CHECK_VAL(data, -1);
index 390830446091882af4eaef7e53154aba7448141a..5f5ab23976a5ff6ea0a30da391c132248366938c 100644 (file)
@@ -1139,21 +1139,6 @@ Elm_Gengrid_Item_Class *_gl_thumbs_new_item_style(Evas_Object * parent)
        return gic;
 }
 
-int _gl_thumbs_update_realized_items(void *data)
-{
-       GL_CHECK_VAL(data, -1);
-       gl_appdata *ad = (gl_appdata *) data;
-
-       /* Clear old view */
-       evas_object_smart_callback_del(ad->gridinfo.view, "unrealized",
-                                                                  __gl_thumbs_unrealized);
-       _gl_thumbs_set_size(ad, NULL);
-       elm_gengrid_realized_items_update(ad->gridinfo.view);
-       evas_object_smart_callback_add(ad->gridinfo.view, "unrealized",
-                                                                  __gl_thumbs_unrealized, ad);
-       return 0;
-}
-
 Evas_Object *_gl_thumbs_get_content(void *data, Evas_Object * parent,
                                                                        gl_item * gitem, int w, int h)
 {
index 463eb4a9b864ab0f98c0400b37209995daab7651..ab8d64bffdc8f1858b0fb6cc1b2a6fdfb7cdbb35 100644 (file)
@@ -1107,21 +1107,6 @@ int _gl_timeline_thumb_set_size(void *data, Evas_Object * view,
        return 0;
 }
 
-Evas_Object *_gl_grid_layout_add(Evas_Object * parent)
-{
-       Evas_Object *layout = NULL;
-       layout = elm_layout_add(parent);
-       char *path = _gl_get_edje_path();
-       GL_CHECK_NULL(path);
-       elm_layout_file_set(layout, path, "timeline_gridview");
-       free(path);
-       evas_object_size_hint_align_set(layout, EVAS_HINT_FILL,
-                                                                       EVAS_HINT_FILL);
-       evas_object_show(layout);
-
-       return layout;
-}
-
 Evas_Object *_gl_grid_add(Evas_Object * parent)
 {
        GL_CHECK_NULL(parent);
@@ -1578,16 +1563,6 @@ int _gl_timeline_create_grid_view(gl_timeline_s * timeline_d,
        return 0;
 }
 
-Evas_Object *_gl_box_add(Evas_Object * parent)
-{
-       Evas_Object *box = NULL;
-       box = elm_box_add(parent);
-       elm_box_align_set(box, 0.0, 0.0);
-       evas_object_show(box);
-
-       return box;
-}
-
 static void __gl_timeline_genlist_move_cb(void *data, Evas_Object * obj,
                                                                                  void *ei)
 {
@@ -2197,42 +2172,6 @@ static void __gl_timeline_del_cb(void *data, Evas_Object * obj, void *ei)
 
 }
 
-int _gl_timeline_update_realized_grid_ck(Evas_Object * view,
-                                                                                Eina_Bool state)
-{
-       GL_CHECK_VAL(view, -1);
-       Eina_List *grid = NULL;
-       Eina_List *l = NULL;
-       Elm_Object_Item *it = NULL;
-
-       grid = elm_gengrid_realized_items_get(view);
-       GL_CHECK_VAL(grid, -1);
-
-       EINA_LIST_FOREACH(grid, l, it) {
-               if (it == NULL) {
-                       gl_dbgE("Invalid item!");
-                       continue;
-               }
-               Evas_Object *ck = NULL;
-
-               ck = elm_object_item_part_content_get(it, GL_THUMB_CHECKBOX);
-               gl_media_s *data = (gl_media_s *) elm_object_item_data_get(it);
-               if (!ck) {
-                       gl_dbgE("Invalid checkbox!");
-                       return -1;
-               }
-
-               if (elm_check_state_get(ck) != state) {
-                       elm_check_state_set(ck, state);
-                       gl_timeline_s *td = evas_object_data_get(ck, "data");
-                       GL_CHECK_VAL(td, -1);
-                       __gl_timeline_thumb_check_op(td, ck, data);
-               }
-       }
-
-       return 0;
-}
-
 /* Select-all checkbox selected/deselected */
 static void __gl_timeline_thumb_edit_selall_cb(void *data,
                                                                                           Evas_Object * obj, void *ei)
index 5b625555be0bfd5371fb4ac22bbf09704e173197..e852d33e17d18df764a9357acd3fe28bbd48a766 100644 (file)
 #include "gl-data-type.h"
 #include "gl-debug.h"
 
-int _gl_data_type_new_media(gl_media_s ** item)
-{
-       GL_CHECK_VAL(item, -1);
-       gl_media_s *tmp_item = (gl_media_s *) calloc(1, sizeof(gl_media_s));
-       GL_CHECK_VAL(tmp_item, -1);
-       tmp_item->gtype = GL_TYPE_MEDIA;
-       *item = tmp_item;
-       return 0;
-}
-
 int _gl_data_type_new_album(gl_album_s ** album)
 {
        GL_CHECK_VAL(album, -1);
index 23dfcb577586c7a974e4a7c93d8f9acfbecbcfd5..6ade25535a2937ccec88d02d44f2ca0709157cc0 100644 (file)
 static mode_t default_mode =
        S_IRUSR | S_IWUSR | S_IXUSR | S_IRGRP | S_IXGRP | S_IROTH | S_IXOTH;
 
-char *gl_file_dir_get(const char path[])
-{
-       char *p = NULL;
-       char buf[256] = { 0, };
-       struct stat info = { 0, };
-
-       if (stat(path, &info) == 0) {
-               strncpy(buf, path, 256);
-               buf[256 - 1] = 0;
-               p = dirname(buf);
-               return strdup(p);
-       } else {
-               return "";
-       }
-}
-
 int gl_file_exists(const char *path)
 {
        struct stat info = { 0, };
@@ -162,34 +146,6 @@ int gl_file_rmdir(const char *filename)
        }
 }
 
-Eina_List *gl_file_ls(const char *dir)
-{
-       char *f;
-       DIR *dirp = NULL;
-       struct dirent *dp = NULL;
-       Eina_List *list = NULL;
-       struct dirent ent_struct;
-
-       dirp = opendir(dir);
-       if (!dirp) {
-               return NULL;
-       }
-
-       while ((readdir_r(dirp, &ent_struct, &dp) == 0) && dp) {
-               if ((strcmp(dp->d_name, ".")) && (strcmp(dp->d_name, ".."))) {
-                       f = strdup(dp->d_name);
-                       list = eina_list_append(list, f);
-               }
-       }
-       closedir(dirp);
-
-       list =
-               eina_list_sort(list, eina_list_count(list),
-                                          EINA_COMPARE_CB(strcoll));
-
-       return list;
-}
-
 int gl_file_recursive_rm(const char *dir)
 {
        char buf[PATH_MAX] = { 0, };
@@ -268,26 +224,3 @@ int gl_file_cp(const char *src, const char *dst)
 
        return ret;
 }
-
-int gl_file_mv(const char *src, const char *dst)
-{
-       struct stat info = { 0, };
-       if (stat(dst, &info) == 0) {
-               return 0;
-       }
-
-       if (rename(src, dst)) {
-               memset(&info, 0x00, sizeof(struct stat));
-               if (stat(src, &info) == 0) {
-                       if (S_ISREG(info.st_mode)) {
-                               gl_file_cp(src, dst);
-                               int val = chmod(dst, info.st_mode);
-                               gl_dbg("return value is : %d", val);
-                               unlink(src);
-                               return 1;
-                       }
-               }
-               return 0;
-       }
-       return 1;
-}
index f0cbf79c39e806298f0f5fd0c2abb77eefd4b94d..ebcffd7e483a9d949ca37702a4e05a77c5f925ee 100644 (file)
@@ -592,23 +592,6 @@ bool _gl_fs_validate_name(const char *new_name)
        return true;
 }
 
-bool _gl_fs_validate_character(const char name_char)
-{
-       char invalid_chars[] = { '/', '\\', ':', '*', '?', '"', '<', '>', '|', '\0' };
-       char *ptr = invalid_chars;
-
-       gl_dbg("character is %c", name_char);
-       while (*ptr != '\0') {
-               if (name_char == *ptr) {
-                       gl_dbg("invalid character is %c", *ptr);
-                       return false;
-               }
-               ++ptr;
-       }
-
-       return true;
-}
-
 bool _gl_fs_mkdir(const char *path)
 {
        GL_CHECK_FALSE(path);
index 748a2d33300c90b4e32f59a407cad295711f5f62..1ef3307b1e717434b895f4b2046cdd0be615152d 100644 (file)
@@ -60,21 +60,6 @@ Evas_Object *gl_ui_load_edj(Evas_Object * parent, const char *file,
        return eo;
 }
 
-int _gl_ui_set_conform_overlap(Evas_Object * naviframe)
-{
-       GL_CHECK_VAL(naviframe, -1);
-       Evas_Object *conform = NULL;
-
-       /* Get conformant */
-       conform = (Evas_Object *) evas_object_data_get(naviframe,
-                                                                                                  GL_NAVIFRAME_OBJ_DATA_KEY);
-       GL_CHECK_VAL(conform, -1);
-       /* Modify to start content from 0,0 */
-       elm_object_signal_emit(conform, "elm,state,indicator,overlap", "");
-       evas_object_data_set(conform, "overlap", (void *) EINA_TRUE);
-       return 0;
-}
-
 int _gl_ui_disable_btn(Evas_Object * btn)
 {
        if (btn) {
@@ -83,14 +68,6 @@ int _gl_ui_disable_btn(Evas_Object * btn)
        return 0;
 }
 
-int _gl_ui_enable_btn(Evas_Object * btn)
-{
-       if (btn) {
-               elm_object_disabled_set(btn, EINA_FALSE);
-       }
-       return 0;
-}
-
 /* Set button more */
 int _gl_ui_disable_menu(Elm_Object_Item * nf_it, bool b_disabled)
 {
@@ -264,17 +241,6 @@ int _gl_ui_set_translatable_item(Elm_Object_Item * nf_it, const char *str)
        return 0;
 }
 
-int _gl_ui_set_translatable_item_part(Elm_Object_Item * nf_it,
-                                                                         const char *part, const char *str)
-{
-       GL_CHECK_VAL(str, -1);
-       GL_CHECK_VAL(nf_it, -1);
-       char *domain = GL_STR_DOMAIN_LOCAL;
-       elm_object_item_domain_part_text_translatable_set(nf_it, part, domain,
-                                                                                                         EINA_TRUE);
-       return 0;
-}
-
 int _gl_ui_set_translate_part_str(Evas_Object * obj, const char *part,
                                                                  const char *str)
 {
@@ -287,38 +253,6 @@ int _gl_ui_set_translate_part_str(Evas_Object * obj, const char *part,
        return 0;
 }
 
-/* Change naviframe item title text */
-int _gl_ui_change_title(Elm_Object_Item * nf_it, const char *text)
-{
-       GL_CHECK_VAL(text, -1);
-       GL_CHECK_VAL(nf_it, -1);
-       elm_object_item_text_set(nf_it, text);
-       _gl_ui_set_translatable_item(nf_it, text);
-       return 0;
-}
-
-/* Update the label text for selected item showed in naviframe title  */
-int _gl_ui_update_label_text(Elm_Object_Item * nf_it, int sel_cnt,
-                                                        bool b_lang)
-{
-       GL_CHECK_VAL(nf_it, -1);
-       gl_dbg("Count: %d, lang: %d", sel_cnt, b_lang);
-       char *pd_selected = GL_STR_PD_SELECTED;
-
-       /* Update the label text */
-       if (sel_cnt > 0) {
-               char *text = NULL;
-               text = g_strdup_printf(_gl_str(pd_selected), sel_cnt);
-               elm_object_item_text_set(nf_it, text);
-               GL_GFREEIF(text);
-       } else if (!b_lang) {
-               /* Don't need to update text if it's called by language_changed_cb */
-               elm_object_item_text_set(nf_it, GL_STR_ID_SELECT_ITEM);
-               _gl_ui_set_translatable_item(nf_it, GL_STR_ID_SELECT_ITEM);
-       }
-       return 0;
-}
-
 /* Change naviframe item title text */
 int _gl_ui_change_navi_title(Elm_Object_Item * nf_it, char *text,
                                                         bool b_dropdown)
index 63d7ccb62f6d39d85f667b6c9814f53c9a11d125..be7a883cc2ca8616b429bc8f9a24a0571f92d731 100644 (file)
@@ -657,68 +657,6 @@ int _gl_move_media_thumb_by_id(void *data, const char *uuid,
        }
 }
 
-/* Used for move file to new dest */
-int _gl_move_media(gl_item * gitem, char *new_dir_name, bool is_full_path)
-{
-       gl_dbg("Move media START>>>");
-       char new_path[GL_FILE_PATH_LEN_MAX] = { 0, };
-       char ext[GL_FILE_EXT_LEN_MAX] = { 0, };
-       char new_path_noext[GL_FILE_PATH_LEN_MAX] = { 0, };
-       if (!gitem || !gitem->item) {
-               gl_dbgE("Invalid gitem!");
-               return -1;
-       }
-
-       if (is_full_path) {
-               if (!gitem->item->file_url || !strlen(gitem->item->file_url) ||
-                       !gitem->item->display_name) {
-                       gl_dbgE("file url or name is invalid!");
-                       return -1;
-               }
-               snprintf(new_path, sizeof(new_path), "%s/%s",
-                                new_dir_name, (char *) (gitem->item->display_name));
-               gl_dbg("New path : %s", new_path);
-
-               if (!g_strcmp0(new_path, gitem->item->file_url)) {
-                       gl_dbgW("File exists!");
-                       return 0;
-               } else if (gl_file_exists(new_path)) {
-                       _gl_fs_get_path_without_ext(new_path, ext, new_path_noext);
-                       char *final_path = NULL;
-                       final_path = _gl_fs_get_unique_full_path(new_path_noext, ext);
-                       if (final_path == NULL) {
-                               return -1;
-                       }
-                       gl_dbg("Created unique path: %s", final_path);
-                       memset(new_path, 0x00, GL_FILE_PATH_LEN_MAX);
-                       g_strlcpy(new_path, final_path, GL_FILE_PATH_LEN_MAX);
-                       GL_FREE(final_path);
-               }
-       } else {
-               char *default_images_path =
-                       _gl_get_directory_path(STORAGE_DIRECTORY_IMAGES);
-               GL_CHECK_VAL(default_images_path, -1);
-               snprintf(new_path, GL_FILE_PATH_LEN_MAX, "%s/%s/%s",
-                                default_images_path, new_dir_name,
-                                (char *) (gitem->item->display_name));
-               GL_FREE(default_images_path);
-       }
-
-       new_path[strlen(new_path)] = '\0';
-
-       if (!_gl_fs_move(app_data, gitem->item->file_url, new_path)) {
-               gl_dbg("Move media OVER<<<");
-               return -1;
-       } else {
-               if (_gl_local_data_add_media(new_path, NULL) < 0) {
-                       gl_dbgE("Move media thumbnail failed!");
-                       return EINA_FALSE;
-               }
-               gl_dbg("Move media OVER<<<");
-               return 0;
-       }
-}
-
 /**
 * Check if there is any media in Gallery.
 *
@@ -1365,48 +1303,6 @@ int _gl_update_albums_list(void *data)
        return _gl_refresh_albums_list(data, false, false);
 }
 
-/**
-* Move files under root album [/opt/media or /opt/storage/sdcard] to a newly created album.
-* Used in 'Rename' album case.
-*/
-int gl_move_root_album(void *data, gl_cluster * cur_album, char *dest_path)
-{
-       GL_CHECK_VAL(data, -1);
-       GL_CHECK_VAL(cur_album, -1);
-       GL_CHECK_VAL(cur_album->cluster, -1);
-       gl_appdata *ad = (gl_appdata *) data;
-       Eina_List *medias_elist = NULL;
-
-       /* Get all medias of current album */
-       _gl_data_get_items_album(ad, cur_album, GL_GET_ALL_RECORDS,
-                                                        GL_GET_ALL_RECORDS, &medias_elist);
-       GL_CHECK_VAL(medias_elist, -1);
-
-       Eina_List *l = NULL;
-       gl_item *gitem = NULL;
-       int popup_op = GL_POPUP_OP_NONE;
-
-       /* Move medias of album to dest folder */
-       EINA_LIST_FOREACH(medias_elist, l, gitem) {
-               if (gitem && gitem->item) {
-                       gl_sdbg("Move [%s]", gitem->item->file_url);
-                       if (_gl_move_media_thumb
-                               (data, gitem, dest_path, true, &popup_op,
-                                GL_MC_MOVE) != 0) {
-                               gl_dbgW("Failed to move this item");
-                       }
-
-                       gitem = NULL;
-               } else {
-                       gl_dbgE("Invalid item!");
-               }
-       }
-
-       /* Free item list */
-       _gl_data_util_clear_item_list(&(medias_elist));
-       return 0;
-}
-
 /* 'Move medias' is only available in tab Albums */
 static int __gl_move_copy_op(void *data)
 {
@@ -1848,29 +1744,6 @@ double _gl_get_win_factor(Evas_Object * win, int *width, int *height)
        return factor;
 }
 
-/**
- * @brief font size
- *
- * 0 : small
- * 1 : normal
- * 2 : large
- * 3 : huge
- * 4 : giant
- */
-int _gl_get_font_size(void)
-{
-       int mode = -1;
-       int retcode =
-               system_settings_get_value_int(SYSTEM_SETTINGS_KEY_FONT_SIZE,
-                                                                         &mode);
-       gl_dbg("mode: %d", mode);
-       if (retcode != SYSTEM_SETTINGS_ERROR_NONE) {
-               gl_dbgE("Failed to get font size!");
-               return -1;
-       }
-       return mode;
-}
-
 int _gl_reg_storage_state_change_notify(void *data)
 {
        __gl_reg_db_noti(data);
index 8ac31a4bd6f2a2778ebd37e3b999d07ad9cffc83..e6ed497f8ba7c1b36fcc63a15972962973f3edd1 100644 (file)
@@ -221,41 +221,6 @@ int _gl_editfield_destroy_imf(void *data)
        return 0;
 }
 
-int _gl_editfield_change_navi_title(void *data, int r)
-{
-       GL_CHECK_VAL(data, -1);
-       gl_appdata *ad = (gl_appdata *) data;
-       if (ad->entryinfo.nf_it) {
-               gl_dbg("entryinfo.nf_it created");
-               if (!ad->entryinfo.b_hide_sip) {
-                       gl_dbg("SIP is hided, no need hide the title");
-                       return 0;
-               }
-       } else {
-               gl_dbg("entryinfo.nf_it not created");
-               return -1;
-       }
-       GL_CHECK_VAL(ad->maininfo.naviframe, -1);
-       Elm_Object_Item *navi_it =
-               elm_naviframe_top_item_get(ad->maininfo.naviframe);
-       GL_CHECK_VAL(navi_it, -1);
-       switch (r) {
-       case APP_DEVICE_ORIENTATION_0:
-       case APP_DEVICE_ORIENTATION_180:
-               elm_naviframe_item_title_enabled_set(navi_it, EINA_TRUE,
-                                                                                        EINA_FALSE);
-               break;
-       case APP_DEVICE_ORIENTATION_90:
-       case APP_DEVICE_ORIENTATION_270:
-               elm_naviframe_item_title_enabled_set(navi_it, EINA_FALSE,
-                                                                                        EINA_FALSE);
-               break;
-       default:
-               break;
-       }
-       return 0;
-}
-
 Evas_Object *_gl_editfield_get_entry(void *data)
 {
        GL_CHECK_NULL(data);
index bb09fcaee9d16145b87e3ef4565ded294f6b3ad7..fa5b334ef6ee4d00cd9931cb6ef8b15cef765955 100644 (file)
@@ -103,30 +103,12 @@ char *_gl_get_downloads_folder_path(_widget_data * widget_data)
                                                          STORAGE_DIRECTORY_DOWNLOADS);
 }
 
-
-void gl_widget_win_del_cb(void *data, Evas * evas, Evas_Object * obj,
-                                                 void *event_info)
-{
-       ecore_timer_del(data);
-}
-
 void gl_widget_key_down_cb(void *data, Evas * evas, Evas_Object * obj,
                                                   void *event_info)
 {
        elm_exit();
 }
 
-void gl_widget_app_get_resource(const char *edj_file_in,
-                                                               char *edj_path_out, int edj_path_max)
-{
-       char *res_path = app_get_resource_path();
-       if (res_path) {
-               snprintf(edj_path_out, edj_path_max, "%s%s", res_path,
-                                edj_file_in);
-               free(res_path);
-       }
-}
-
 int gl_widget_file_exists(const char *path)
 {
        struct stat info = { 0, };