| 1352 | } |
| 1353 | |
| 1354 | nfdresult_t NFD_SaveDialogN(nfdnchar_t** outPath, |
| 1355 | const nfdnfilteritem_t* filterList, |
| 1356 | nfdfiltersize_t filterCount, |
| 1357 | const nfdnchar_t* defaultPath, |
| 1358 | const nfdnchar_t* defaultName) { |
| 1359 | DBusMessage* msg; |
| 1360 | { |
| 1361 | const nfdresult_t res = |
| 1362 | NFD_DBus_SaveFile(msg, filterList, filterCount, defaultPath, defaultName); |
| 1363 | if (res != NFD_OKAY) { |
| 1364 | return res; |
| 1365 | } |
| 1366 | } |
| 1367 | DBusMessage_Guard msg_guard(msg); |
| 1368 | |
| 1369 | #ifdef NFD_APPEND_EXTENSION |
| 1370 | const char* uri; |
| 1371 | const char* extn; |
| 1372 | { |
| 1373 | const nfdresult_t res = ReadResponseUrisSingleAndCurrentExtension(msg, uri, extn); |
| 1374 | if (res != NFD_OKAY) { |
| 1375 | return res; |
| 1376 | } |
| 1377 | } |
| 1378 | |
| 1379 | return AllocAndCopyFilePathWithExtn(uri, extn, *outPath); |
| 1380 | #else |
| 1381 | const char* uri; |
| 1382 | { |
| 1383 | const nfdresult_t res = ReadResponseUrisSingle(msg, uri); |
| 1384 | if (res != NFD_OKAY) { |
| 1385 | return res; |
| 1386 | } |
| 1387 | } |
| 1388 | |
| 1389 | return AllocAndCopyFilePath(uri, *outPath); |
| 1390 | #endif |
| 1391 | } |
| 1392 | |
| 1393 | nfdresult_t NFD_PickFolderN(nfdnchar_t** outPath, const nfdnchar_t* defaultPath) { |
| 1394 | (void)defaultPath; // Default path not supported for portal backend |
nothing calls this directly
no test coverage detected