mirror of
https://github.com/wolfpld/tracy.git
synced 2026-10-24 01:30:47 +00:00
Use extended-params version of NFD functions.
This commit is contained in:
@@ -77,7 +77,11 @@ static bool OpenFileImpl( const char* ext, const char* desc, const std::function
|
||||
# else
|
||||
nfdu8filteritem_t filter = { desc, ext };
|
||||
nfdu8char_t* fn;
|
||||
const auto res = NFD_OpenDialogU8( &fn, &filter, 1, nullptr );
|
||||
const nfdopendialogu8args_t args = {
|
||||
.filterList = &filter,
|
||||
.filterCount = 1,
|
||||
};
|
||||
const auto res = NFD_OpenDialogU8_With( &fn, &args );
|
||||
if( res == NFD_OKAY )
|
||||
{
|
||||
callback( (const char*)fn );
|
||||
@@ -98,7 +102,11 @@ static bool SaveFileImpl( const char* ext, const char* desc, const std::function
|
||||
#if !defined TRACY_NO_FILESELECTOR && !defined __EMSCRIPTEN__
|
||||
nfdu8filteritem_t filter = { desc, ext };
|
||||
nfdu8char_t* fn;
|
||||
const auto res = NFD_SaveDialogU8( &fn, &filter, 1, nullptr, nullptr );
|
||||
const nfdsavedialogu8args_t args = {
|
||||
.filterList = &filter,
|
||||
.filterCount = 1,
|
||||
};
|
||||
const auto res = NFD_SaveDialogU8_With( &fn, &args );
|
||||
if( res == NFD_OKAY )
|
||||
{
|
||||
callback( (const char*)fn );
|
||||
|
||||
Reference in New Issue
Block a user