-
Notifications
You must be signed in to change notification settings - Fork 2.2k
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
Scoped Storage on Android - new and remaining issues #17683
Comments
This handles some cases better that I don't really see how they can happen, but who knows. Intended to help #17683
I added some more logging and debug messages, and this shows up on the user's problematic device (Poco 4): Note that the "result code" -1 actually means success That's just bizarre? It's like parseInt failed silently and didn't write the result to lastRequestId for no good reason, when parsing the request number from the params string: https://github.com/hrydgard/ppsspp/blob/master/android/src/org/ppsspp/ppsspp/NativeActivity.java#L1389C10-L1389C10 We set it before spawning the dialog that in turn will end up calling onActivityResult. So it's like the value is either not written - or reset somehow.. |
To protect against disappearing activities or whatever is causing the lost value, I could make it static, but instead I just pack the two values together into the requestCode. Will hopefully help the main issue from #17683
The Poco F4 issue is solved - I stored temporary data in the Android activity for the dialogs, and that didn't work since somehow the activity was destroyed in the background. Fixed that, but still don't know why the user kept losing the activity, oh well. |
@hrydgard SAF is not supported on Android TV by design (on purpose, not a bug). Therefore not only file picker is missing, but file.uri, required by most emulators, is not supported. The workaround would be to have a fallback to manually enter the uri as it was prior to v.1.11. For example I am currently using PPSSPP on CWGTV (Chromecast with Google TV) which is Android 12 and I am using v.1.10.3 successfully. All I do is enter the path to the SD card manually and done! Similar workaround is used for Retroarch. So it shouldn't be too much work for you to support this either by graceful fallback on these systems, or if you ask me even better to have 2 buttons - 1) Browse 2)Enter uri. Regards and keep up the excellent work. |
Made a slightly disconcerting discovery that could explain some reported data loss. Removing a directory on scoped storage works whether there are files in the directory or not. My memstick directory moving algorithm relied on being unable to delete a directory with files in it to make sure we don't delete data without having moved it. Will fix that (and also optimize removing of directory trees to a single call, due to this ability, which will speed up app uninstalls probably...) |
#18744 will help prevent data loss when moving the memstick folder. moving any further work on this to future versions. |
Gotten a bunch of reports recently that the "browse folder" action isn't completing properly, on a bunch of devices.
Additionally, on Android TV this is fairly common because for whatever reason, the device makers don't bother including this dialog, which basically ruins things for us: #16865
It would be possible to get things working without the folder browser:
So we should probably implement that as a fallback.
Also, getting user reports on random failures when loading from the Downloads folder on Samsung A22, apparently sometimes it works (1.15.4, it's possible it's since been fixed):
We should at least improve the error message..
The text was updated successfully, but these errors were encountered: