-
Notifications
You must be signed in to change notification settings - Fork 97
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Provide an option for overriding default folder behavior on Windows #151
Comments
Screenshot showing the issue in NavKit: In this case, the |
Yes, I agree that a way to use Note that the "correct" way to have dialogs for different purposes on Windows is to call |
Interesting, I wasn't aware of this option. Perhaps that can be exposed through the library as a way for at least each Windows dialog to maintain its own recent folder. |
I kinda think that if we are to expose setting the GUID for Windows only, then NFDe users will likely end up writing extra macOS- and Linux-specific code to do it manually on those platforms, since if they really need per-GUID recent folders on Windows, then they probably can't live with the default behaviour on macOS and Linux either. So I think NFDe will likely have to come with a manual implementation on those platforms. |
Closed by #152. |
Issue description:
When a program has multiple file / folder dialogs that are for different purposes (for instance different file types), defaulting to the most recent folder on Windows forces the user to have to manually navigate to different folders, even when the program is manually setting different default paths for each dialog type.
nativefiledialog-extended/src/nfd_win.cpp
Line 255 in 79ebd33
Here it mentions that the
dialog->SetDefaultFolder
call can be changed todialog->SetFolder
to override this behavior, however this change must be manually made to the underlying library code. When pulling in nativefiledialog-extended via vcpkg, this method is unavailable, and the code must be manually imported and modified.Suggested Change:
I think it would be beneficial to allow an option to allow overriding this default behavior, either in the args structs or in functions as an optional parameter.
Maybe something like
bool overrideRecentPathWithDefault
.The text was updated successfully, but these errors were encountered: