From 5ea923030b41373822c1cfb426bc0fe4bdab387e Mon Sep 17 00:00:00 2001 From: twinaphex Date: Sat, 11 Jun 2016 19:55:27 +0200 Subject: [PATCH] Rename functions/enums --- file_path_special.c | 20 ++++++++++---------- file_path_special.h | 14 +++++++------- menu/drivers/materialui.c | 8 ++++---- menu/drivers/xmb.c | 20 ++++++++++---------- 4 files changed, 31 insertions(+), 31 deletions(-) diff --git a/file_path_special.c b/file_path_special.c index 54aa3921ac..98a831b6e8 100644 --- a/file_path_special.c +++ b/file_path_special.c @@ -265,17 +265,17 @@ void fill_pathname_application_path(char *s, size_t len) const char *xmb_theme_ident(void); #endif -void fill_pathname_application_directory(char *s, size_t len, enum application_directory type) +void fill_pathname_application_special(char *s, size_t len, enum application_special_type type) { switch (type) { - case APPLICATION_DIRECTORY_ASSETS_XMB_ICONS: + case APPLICATION_SPECIAL_DIRECTORY_ASSETS_XMB_ICONS: #ifdef HAVE_XMB { char s1[PATH_MAX_LENGTH] = {0}; char s2[PATH_MAX_LENGTH] = {0}; - fill_pathname_application_directory(s1, sizeof(s1), - APPLICATION_DIRECTORY_ASSETS_XMB); + fill_pathname_application_special(s1, sizeof(s1), + APPLICATION_SPECIAL_DIRECTORY_ASSETS_XMB); fill_pathname_join(s2, s1, "png", sizeof(s2)); fill_pathname_slash(s2, sizeof(s2)); @@ -283,7 +283,7 @@ void fill_pathname_application_directory(char *s, size_t len, enum application_d } #endif break; - case APPLICATION_DIRECTORY_ASSETS_XMB: + case APPLICATION_SPECIAL_DIRECTORY_ASSETS_XMB: #ifdef HAVE_XMB { char s1[PATH_MAX_LENGTH] = {0}; @@ -301,7 +301,7 @@ void fill_pathname_application_directory(char *s, size_t len, enum application_d } #endif break; - case APPLICATION_DIRECTORY_ASSETS_MATERIALUI: + case APPLICATION_SPECIAL_DIRECTORY_ASSETS_MATERIALUI: #ifdef HAVE_MATERIALUI { settings_t *settings = config_get_ptr(); @@ -314,20 +314,20 @@ void fill_pathname_application_directory(char *s, size_t len, enum application_d } #endif break; - case APPLICATION_DIRECTORY_ASSETS_MATERIALUI_ICONS: + case APPLICATION_SPECIAL_DIRECTORY_ASSETS_MATERIALUI_ICONS: #ifdef HAVE_MATERIALUI { char s1[PATH_MAX_LENGTH] = {0}; settings_t *settings = config_get_ptr(); - fill_pathname_application_directory(s1, - sizeof(s1), APPLICATION_DIRECTORY_ASSETS_MATERIALUI); + fill_pathname_application_special(s1, + sizeof(s1), APPLICATION_SPECIAL_DIRECTORY_ASSETS_MATERIALUI); fill_pathname_slash(s1, sizeof(s1)); strlcpy(s, s1, len); } #endif break; - case APPLICATION_DIRECTORY_NONE: + case APPLICATION_SPECIAL_NONE: default: break; } diff --git a/file_path_special.h b/file_path_special.h index b43dcf1685..daac5a591a 100644 --- a/file_path_special.h +++ b/file_path_special.h @@ -22,17 +22,17 @@ #include -enum application_directory +enum application_special_type { - APPLICATION_DIRECTORY_NONE = 0, - APPLICATION_DIRECTORY_ASSETS_MATERIALUI, - APPLICATION_DIRECTORY_ASSETS_MATERIALUI_ICONS, - APPLICATION_DIRECTORY_ASSETS_XMB, - APPLICATION_DIRECTORY_ASSETS_XMB_ICONS + APPLICATION_SPECIAL_NONE = 0, + APPLICATION_SPECIAL_DIRECTORY_ASSETS_MATERIALUI, + APPLICATION_SPECIAL_DIRECTORY_ASSETS_MATERIALUI_ICONS, + APPLICATION_SPECIAL_DIRECTORY_ASSETS_XMB, + APPLICATION_SPECIAL_DIRECTORY_ASSETS_XMB_ICONS }; bool fill_pathname_application_data(char *s, size_t len); -void fill_pathname_application_directory(char *s, size_t len, enum application_directory type); +void fill_pathname_application_special(char *s, size_t len, enum application_special_type type); #endif diff --git a/menu/drivers/materialui.c b/menu/drivers/materialui.c index 9cfeab28ae..4bac873765 100644 --- a/menu/drivers/materialui.c +++ b/menu/drivers/materialui.c @@ -149,8 +149,8 @@ static void mui_context_reset_textures(mui_handle_t *mui) unsigned i; char iconpath[PATH_MAX_LENGTH] = {0}; - fill_pathname_application_directory(iconpath, sizeof(iconpath), - APPLICATION_DIRECTORY_ASSETS_MATERIALUI_ICONS); + fill_pathname_application_special(iconpath, sizeof(iconpath), + APPLICATION_SPECIAL_DIRECTORY_ASSETS_MATERIALUI_ICONS); for (i = 0; i < MUI_TEXTURE_LAST; i++) { @@ -1010,8 +1010,8 @@ static void mui_font(void) settings_t *settings = config_get_ptr(); int font_size = menu_display_get_font_size(); - fill_pathname_application_directory(mediapath, sizeof(mediapath), - APPLICATION_DIRECTORY_ASSETS_MATERIALUI); + fill_pathname_application_special(mediapath, sizeof(mediapath), + APPLICATION_SPECIAL_DIRECTORY_ASSETS_MATERIALUI); fill_pathname_join(fontpath, mediapath, "Roboto-Regular.ttf", sizeof(fontpath)); diff --git a/menu/drivers/xmb.c b/menu/drivers/xmb.c index 3197b5e38e..dff932ede0 100644 --- a/menu/drivers/xmb.c +++ b/menu/drivers/xmb.c @@ -389,8 +389,8 @@ static void xmb_fill_default_background_path(xmb_handle_t *xmb, char iconpath[PATH_MAX_LENGTH] = {0}; settings_t *settings = config_get_ptr(); - fill_pathname_application_directory(iconpath, sizeof(iconpath), - APPLICATION_DIRECTORY_ASSETS_XMB_ICONS); + fill_pathname_application_special(iconpath, sizeof(iconpath), + APPLICATION_SPECIAL_DIRECTORY_ASSETS_XMB_ICONS); fill_pathname_join(path, iconpath, "bg.png", size); @@ -1334,8 +1334,8 @@ static void xmb_context_reset_horizontal_list( size_t list_size = xmb_list_get_size(xmb, MENU_LIST_HORIZONTAL); char themepath[PATH_MAX_LENGTH] = {0}; - fill_pathname_application_directory(themepath, sizeof(themepath), - APPLICATION_DIRECTORY_ASSETS_XMB); + fill_pathname_application_special(themepath, sizeof(themepath), + APPLICATION_SPECIAL_DIRECTORY_ASSETS_XMB); xmb->categories.x_pos = xmb->icon.spacing.horizontal * -(float)xmb->categories.selection_ptr; @@ -1373,8 +1373,8 @@ static void xmb_context_reset_horizontal_list( strlcpy(sysname, path, sizeof(sysname)); path_remove_extension(sysname); - fill_pathname_application_directory(iconpath, sizeof(iconpath), - APPLICATION_DIRECTORY_ASSETS_XMB_ICONS); + fill_pathname_application_special(iconpath, sizeof(iconpath), + APPLICATION_SPECIAL_DIRECTORY_ASSETS_XMB_ICONS); fill_pathname_join(texturepath, iconpath, sysname, sizeof(texturepath)); @@ -2280,8 +2280,8 @@ static void xmb_font(xmb_handle_t *xmb) settings_t *settings = config_get_ptr(); int font_size = menu_display_get_font_size(); - fill_pathname_application_directory(themepath, sizeof(themepath), - APPLICATION_DIRECTORY_ASSETS_XMB); + fill_pathname_application_special(themepath, sizeof(themepath), + APPLICATION_SPECIAL_DIRECTORY_ASSETS_XMB); if (string_is_empty(settings->menu.xmb_font)) fill_pathname_join(fontpath, themepath, "font.ttf", sizeof(fontpath)); @@ -2796,8 +2796,8 @@ static void xmb_context_reset(void *data) xmb_fill_default_background_path(xmb, xmb->background_file_path, sizeof(xmb->background_file_path)); - fill_pathname_application_directory(iconpath, sizeof(iconpath), - APPLICATION_DIRECTORY_ASSETS_XMB_ICONS); + fill_pathname_application_special(iconpath, sizeof(iconpath), + APPLICATION_SPECIAL_DIRECTORY_ASSETS_XMB_ICONS); xmb_layout(xmb); xmb_font(xmb);