mirror of
https://github.com/love2d/love.git
synced 2026-08-20 04:30:09 +02:00
Don't canonicalize paths fom SDL file dialog callbacks.
If love.filesystem.openNativeFile can't open them, then it's SDL issue, not LOVE. This is also needed because Android returns content:// URIs instead of regular paths.
This commit is contained in:
@@ -1525,12 +1525,7 @@ static void SDLCALL fileDialogCallbackSDL(void *userdata, const char *const *fil
|
|||||||
{
|
{
|
||||||
// SDL's file list only lasts until the end of the callback, so we copy it.
|
// SDL's file list only lasts until the end of the callback, so we copy it.
|
||||||
for (int i = 0; filelist[i] != nullptr; i++)
|
for (int i = 0; filelist[i] != nullptr; i++)
|
||||||
{
|
state->files.push_back(filelist[i]);
|
||||||
std::string file(filelist[i]);
|
|
||||||
if (fs != nullptr)
|
|
||||||
file = fs->canonicalizeRealPath(file);
|
|
||||||
state->files.push_back(file);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user