mirror of
https://github.com/CTCaer/RetroArch.git
synced 2025-01-18 17:04:34 +00:00
[nk] implement extension filtering
This commit is contained in:
parent
2667289d45
commit
d8890b486a
@ -57,7 +57,7 @@ static void nk_menu_main(nk_menu_handle_t *nk)
|
||||
if (nk->window[NK_WND_SETTINGS].open)
|
||||
nk_wnd_settings(nk);
|
||||
if (nk->window[NK_WND_FILE_PICKER].open)
|
||||
nk_wnd_file_picker(nk, NULL, NULL, NULL);
|
||||
nk_wnd_file_picker(nk, settings->directory.menu_content, NULL, ".zip");
|
||||
if (nk->window[NK_WND_SHADER_PARAMETERS].open)
|
||||
nk_wnd_shader_parameters(nk);
|
||||
if (nk->window[NK_WND_MAIN].open)
|
||||
|
@ -81,7 +81,7 @@ bool nk_wnd_file_picker(nk_menu_handle_t *nk, const char* in, const char* out, c
|
||||
{
|
||||
RARCH_LOG("beep\n");
|
||||
strlcpy(path, in, sizeof(path));
|
||||
files = dir_list_new(path, NULL, true, true);
|
||||
files = dir_list_new(path, filter, true, true);
|
||||
}
|
||||
|
||||
if (!assets_loaded)
|
||||
@ -100,7 +100,7 @@ bool nk_wnd_file_picker(nk_menu_handle_t *nk, const char* in, const char* out, c
|
||||
{
|
||||
fill_pathname_join(path, "/",
|
||||
"", sizeof(path));
|
||||
files = dir_list_new(path, NULL, true, true);
|
||||
files = dir_list_new(path, filter, true, true);
|
||||
}
|
||||
}
|
||||
else
|
||||
@ -112,7 +112,7 @@ bool nk_wnd_file_picker(nk_menu_handle_t *nk, const char* in, const char* out, c
|
||||
{
|
||||
fill_pathname_join(path, drives->list[i].path,
|
||||
"", sizeof(path));
|
||||
files = dir_list_new(path, NULL, true, true);
|
||||
files = dir_list_new(path, filter, true, true);
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -128,7 +128,7 @@ bool nk_wnd_file_picker(nk_menu_handle_t *nk, const char* in, const char* out, c
|
||||
{
|
||||
strlcpy (path, files->elems[i].data, sizeof(path));
|
||||
if (path_is_directory (path))
|
||||
files = dir_list_new(path, NULL, true, true);
|
||||
files = dir_list_new(path, filter, true, true);
|
||||
else
|
||||
RARCH_LOG ("File: %s selected\n", path);
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user