mirror of
https://github.com/libretro/RetroArch
synced 2025-01-30 03:32:46 +00:00
Create dir_get_size
This commit is contained in:
parent
6d821ad6a4
commit
849ce80c50
35
dirs.c
35
dirs.c
@ -197,24 +197,27 @@ bool dir_is_empty(enum rarch_dir_type type)
|
|||||||
|
|
||||||
/* get size functions */
|
/* get size functions */
|
||||||
|
|
||||||
size_t dir_get_system_size(void)
|
size_t dir_get_size(enum rarch_dir_type type)
|
||||||
{
|
{
|
||||||
return sizeof(dir_system);
|
switch (type)
|
||||||
}
|
{
|
||||||
|
case RARCH_DIR_SYSTEM:
|
||||||
|
return sizeof(dir_system);
|
||||||
|
case RARCH_DIR_SAVESTATE:
|
||||||
|
return sizeof(dir_savestate);
|
||||||
|
case RARCH_DIR_CURRENT_SAVESTATE:
|
||||||
|
return sizeof(current_savestate_dir);
|
||||||
|
case RARCH_DIR_SAVEFILE:
|
||||||
|
return sizeof(dir_savefile);
|
||||||
|
case RARCH_DIR_CURRENT_SAVEFILE:
|
||||||
|
return sizeof(current_savefile_dir);
|
||||||
|
case RARCH_DIR_OSK_OVERLAY:
|
||||||
|
return sizeof(dir_osk_overlay);
|
||||||
|
case RARCH_DIR_NONE:
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
size_t dir_get_savestate_size(void)
|
return 0;
|
||||||
{
|
|
||||||
return sizeof(dir_savestate);
|
|
||||||
}
|
|
||||||
|
|
||||||
size_t dir_get_savefile_size(void)
|
|
||||||
{
|
|
||||||
return sizeof(dir_savefile);
|
|
||||||
}
|
|
||||||
|
|
||||||
size_t dir_get_osk_overlay_size(void)
|
|
||||||
{
|
|
||||||
return sizeof(dir_osk_overlay);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/* clear functions */
|
/* clear functions */
|
||||||
|
10
dirs.h
10
dirs.h
@ -54,15 +54,7 @@ void dir_clear(enum rarch_dir_type type);
|
|||||||
|
|
||||||
void dir_clear_all(void);
|
void dir_clear_all(void);
|
||||||
|
|
||||||
/* get size functions */
|
size_t dir_get_size(enum rarch_dir_type type);
|
||||||
|
|
||||||
size_t dir_get_osk_overlay_size(void);
|
|
||||||
|
|
||||||
size_t dir_get_system_size(void);
|
|
||||||
|
|
||||||
size_t dir_get_savestate_size(void);
|
|
||||||
|
|
||||||
size_t dir_get_savefile_size(void);
|
|
||||||
|
|
||||||
/* get ptr functions */
|
/* get ptr functions */
|
||||||
|
|
||||||
|
@ -6503,7 +6503,7 @@ static bool setting_append_list(
|
|||||||
CONFIG_DIR(
|
CONFIG_DIR(
|
||||||
list, list_info,
|
list, list_info,
|
||||||
dir_get_osk_overlay_ptr(),
|
dir_get_osk_overlay_ptr(),
|
||||||
dir_get_osk_overlay_size(),
|
dir_get_size(RARCH_DIR_OSK_OVERLAY),
|
||||||
msg_hash_to_str(MENU_ENUM_LABEL_OSK_OVERLAY_DIRECTORY),
|
msg_hash_to_str(MENU_ENUM_LABEL_OSK_OVERLAY_DIRECTORY),
|
||||||
msg_hash_to_str(MENU_ENUM_LABEL_VALUE_OSK_OVERLAY_DIRECTORY),
|
msg_hash_to_str(MENU_ENUM_LABEL_VALUE_OSK_OVERLAY_DIRECTORY),
|
||||||
g_defaults.dir.osk_overlay,
|
g_defaults.dir.osk_overlay,
|
||||||
@ -6579,7 +6579,7 @@ static bool setting_append_list(
|
|||||||
CONFIG_DIR(
|
CONFIG_DIR(
|
||||||
list, list_info,
|
list, list_info,
|
||||||
dir_get_savefile_ptr(),
|
dir_get_savefile_ptr(),
|
||||||
dir_get_savefile_size(),
|
dir_get_size(RARCH_DIR_SAVEFILE),
|
||||||
msg_hash_to_str(MENU_ENUM_LABEL_SAVEFILE_DIRECTORY),
|
msg_hash_to_str(MENU_ENUM_LABEL_SAVEFILE_DIRECTORY),
|
||||||
msg_hash_to_str(MENU_ENUM_LABEL_VALUE_SAVEFILE_DIRECTORY),
|
msg_hash_to_str(MENU_ENUM_LABEL_VALUE_SAVEFILE_DIRECTORY),
|
||||||
"",
|
"",
|
||||||
@ -6594,7 +6594,7 @@ static bool setting_append_list(
|
|||||||
CONFIG_DIR(
|
CONFIG_DIR(
|
||||||
list, list_info,
|
list, list_info,
|
||||||
dir_get_savestate_ptr(),
|
dir_get_savestate_ptr(),
|
||||||
dir_get_savestate_size(),
|
dir_get_size(RARCH_DIR_SAVESTATE),
|
||||||
msg_hash_to_str(MENU_ENUM_LABEL_SAVESTATE_DIRECTORY),
|
msg_hash_to_str(MENU_ENUM_LABEL_SAVESTATE_DIRECTORY),
|
||||||
msg_hash_to_str(MENU_ENUM_LABEL_VALUE_SAVESTATE_DIRECTORY),
|
msg_hash_to_str(MENU_ENUM_LABEL_VALUE_SAVESTATE_DIRECTORY),
|
||||||
"",
|
"",
|
||||||
|
Loading…
x
Reference in New Issue
Block a user