-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
Bug in dialog.NewFolderOpen() with custom repositories #5200
Comments
Thanks for the careful analysis - I agree with the proposed fix. Would you like to place that into a PR so it gets associated with your account? :). (plus Hacktoberfest credits!) |
PR == Merge Request?? Can you point me to documentation for your development process? I assume you want me to check into a branch off of main on Github. Is there any naming convention you use? |
PR = Pull Request, you would fork the repo, make a branch from That said if it's a tiny change you might get away with the GitHub "edit file" feature which automates a lot of that for you. |
Created the pull request: |
Thanks so much for the fix :) |
Checklist
Describe the bug
Register a new repository with a new scheme. I used the scheme "httpfile". Then set the folder location for dialog.NewFolderOpen() with the following code:
The resulting file dialog uses the default directory (without returning an error) instead of the URI in listableURI.
func (f *FileDialog) effectiveStartingDir() fyne.ListableURI in fyne.io\fyne\v2@v2.5.2\dialog\file.go has incorrect logic at the beginning.
I have already found the code causing this issue and fixed it. Here is the code causing this issue in: fyne.io\fyne\v2@v2.5.2\dialog\file.go
Here is the fix:
Add return f.startingLocation to the end of the above code segment.
How to reproduce
Register a new repository with a new scheme. I used the scheme "httpfile". Then set the folder location for dialog.NewFolderOpen() with the following code:
The resulting file dialog uses the default directory (without returning an error) instead of the URI in listableURI.
func (f *FileDialog) effectiveStartingDir() fyne.ListableURI in fyne.io\fyne\v2@v2.5.2\dialog\file.go has incorrect logic at the beginning.
Screenshots
No response
Example code
Fyne version
2.5.2
Go compiler version
1.23.1
Operating system and version
Windows 11
Additional Information
I have already implemented the fix in my copy of fyne. See above for the fix. Works fyne now.
The text was updated successfully, but these errors were encountered: