yasirkula / UnitySimpleFileBrowser

A uGUI based runtime file browser for Unity 3D (draggable and resizable)
MIT License
874 stars 113 forks source link

Suggestion: accept full paths in filename input field #63

Closed artur-ag closed 2 years ago

artur-ag commented 2 years ago

In the native Windows file dialog, if you type a full path in the filename input field instead of just a filename, it will follow the full path and open the file. But in the current version of SimpleFileBrowser, if you do this, the field just turns red and nothing happens. I think this feature would be very useful, because it allows the user to copy a file's full path on Windows Explorer (Shift+Right Click, Copy as path), paste it directly on SimpleFileBrowser, and press Enter to open it right away.

Example of expected behavior:

The native Windows dialog goes even further, and if you write a dir path, it changes the current dir to that dir, and it even accepts relative paths. But I imagine that's more effort. There's also the question of what the behavior should be for PickMode.Folders, and FilesAndFolders. I would already be very thankful just for absolute paths in the Load dialog for .Files.

yasirkula commented 2 years ago

This is a good suggestion, thank you!