Skip to content

Commit bb10f2c

Browse files
committed
Fix an issue with file paths containing spaces (due to using Uri before, which was URL-encoding them)
1 parent a38c92c commit bb10f2c

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

StudioZDR.UI.Avalonia/Framework/AvaloniaFileBrowser.cs

+2-2
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ public class AvaloniaFileBrowser(WindowContext windowContext) : IFileBrowser
2525

2626
var file = files.Single();
2727

28-
return file.Path.AbsolutePath;
28+
return file.TryGetLocalPath();
2929
}
3030

3131
public async Task<string?> OpenFolderAsync(string? title = null)
@@ -34,7 +34,7 @@ public class AvaloniaFileBrowser(WindowContext windowContext) : IFileBrowser
3434
var folders = await StorageProvider.OpenFolderPickerAsync(options);
3535
var folder = folders.SingleOrDefault();
3636

37-
return folder?.Path.AbsolutePath;
37+
return folder?.TryGetLocalPath();
3838
}
3939

4040
private static FilePickerFileType ToAvaloniaFilter(FileDialogFilter filter)

0 commit comments

Comments
 (0)