-
Notifications
You must be signed in to change notification settings - Fork 693
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
Fixes #1254 so that the current directory is not changed after the used picked files #1256
Fixes #1254 so that the current directory is not changed after the used picked files #1256
Conversation
Previously, on Windows, the current directory changed after picking a file. Turns out, there's an extra option to restore the current directory after picking a file or directory.
The class `_OpenSaveFileArgs` has been introduced in f56fac2. However, it wasn't used consistently throughout the whole Windows implementation as each field of `_OpenSaveFileArgs` was passed individually between functions. Consistenly using an instance of `_OpenSaveFileArgs` minifies function signatures and reduces the total lines of code by 50 lines.
Linter error: the import of 'dart:typed_data' is unnecessary because all of the used elements are also provided by the import of package:flutter/foundation.dart'.
Prompts the user for confirmation when selecting an already existing file on Ubuntu. This should have been committed in the previous file_picker version 5.2.7, but I totally forgot :/
c1b347f
to
178edb9
Compare
@philenius thank you for your effort. If you think it could add some value having the screenshots there, feel free to add so (in reasonable sizes). |
d94d2f3
to
41cc575
Compare
41cc575
to
3e6817f
Compare
@philenius I have merged to find that some of the readme images are broken now. I’m not sure if you were done with this PR but if not, feel free to add the missing changes and/or I’ll revert it back to the previous version ASAP. Sorry for any inconvenience. |
Sorry, my bad, I wasn't done with my PR. I should have marked the PR as a draft. |
Important changes:
saveFile()
dialog on Ubuntu/Kubuntu. This fix should have been committed in the previous version 5.2.7 but was forgotten. Now, when the user selects an already existing file, then Ubuntu prompts the user to confirm overwriting this file. This change finally makes the dialog behave the same on all desktop platforms (macOS, Linux, and Windows) (#989).Less important changes:
_OpenSaveFileArgs
.The class
_OpenSaveFileArgs
has been introduced in f56fac2. However, it wasn't used consistently throughout the whole Windows implementation as each field of_OpenSaveFileArgs
was passed individually between functions. Consistenly using an instance of_OpenSaveFileArgs
minifies function signatures and reduces the total lines of code by 50 lines.dialogTitle
,initialDirectory
,fileName
, andlockParentWindow
. Sorry for the many new files but they are part of Flutter apps for Windows / Linux and they are not part of the official Flutter.gitignore
.ℹ️ @miguelpruivo, if you you want me to put screenshots/videos from the updated example app into the README, then please let me know. Also, please note that I have not tested the updated example app on iOS because I don't have access to an iPhone.
Windows:
Linux:
linux.mp4
Android:
android.mp4