Commit Graph

2 Commits (kari/movedirsel)

Author SHA1 Message Date
kari-ts b3c6414ad8 android: move taildrop directory selector out of onboarding
-ShareFileHelper manages directory readiness; when a file is being shared to the device, it emits a signal to prompt the user to pick a directory
-Remove MDM auth key check; there is no longer any need to make assumptions about Taildrop usage, and we only show the directory selector when they are receiving a Taildropped file
-Listen for Taildrop receipt in application view model (formerly VpnViewModel, now renamed due to its expanded scope), since Taildrop can occur even without MainActivity, and move dir picker out of MainView
-Switch from StateFlow to SharedFlow since this is an event that only needs to be handled once rather than a persistent UI state.
-ShareFileHelper keeps track of Taildrop dir rather than the Taildrop extension managerOptions; this allows the correct directory to be used without having to send a new request or restart LocalBackend
-Don't restart LocalBackend on Taildrop dir selection because this is no longer necessary
Follow-up: implement resume Taildrop in SAF

Updates tailscale/corp#29211

Signed-off-by: kari-ts <kari@tailscale.com>
5 months ago
kari-ts bd5191363c
android: use SAF for storing Taildropped files (#632)
Use Android Storage Access Framework for receiving Taildropped files.

-Add a picker to allow users to select where Taildropped files go
-If no directory is selected, internal app storage is used
-Provide SAF API for Go to use when writing and renaming files
-Provide Android FileOps implementation

Updates tailscale/tailscale#15263

Signed-off-by: kari-ts <kari@tailscale.com>
7 months ago