Receive shares and serve file requests, so other apps can reach this one
The manifest had nothing but a LAUNCHER filter, so no other app could hand Plain Files anything. It now registers for ACTION_SEND and SEND_MULTIPLE (a bar over the browser: navigate to the folder, then Save here) and for GET_CONTENT and OPEN_DOCUMENT, where tapping a file hands it back through the existing FileProvider. Both reuse the browser instead of a second screen, because both are navigate-to-a-folder with a different verb at the end. data/ gains one port, IncomingSource, to keep a ContentResolver out of the ViewModel the way DeleteRequestFactory keeps one out of the delete path. Shared files are named from the sender OpenableColumns, allocated by the same NameAllocator a paste uses, and deleted again if they cannot be read rather than left as zero-byte stubs. While providing, a tap on a file chooses it but a tap on a folder still navigates, or the user could never reach the file. ACTION_VIEW is deliberately not registered: the app already hands files out through the system chooser, and registering as a viewer would offer Plain Files back to itself. No new permissions - the merged release manifest still declares no INTERNET.
This commit is contained in:
@@ -37,8 +37,8 @@ Android 16 (API 36) from 31 August 2026.
|
||||
app/src/main/java/de/softwareapp_hb/filemanager/
|
||||
├── core/ Pure-Kotlin engine (no Android imports!) — paths, sorting, formatting,
|
||||
│ search matching, copy/move planning, conflict policy
|
||||
├── data/ Storage backends (all-files access + SAF), volumes, bookmarks,
|
||||
│ file operations, archives, deletion
|
||||
├── data/ Storage backends (all-files access + SAF), volumes, shares coming in
|
||||
│ from other apps, file operations, archives, deletion
|
||||
├── domain/ Browser + operation controllers, models, permission state
|
||||
├── service/ Foreground service for long-running file operations
|
||||
├── ui/ Compose theme, browser screen, components, ViewModels
|
||||
@@ -139,8 +139,11 @@ UI.** Translated UI text has to be supplied in `values-<locale>/`.
|
||||
|
||||
## Known limitations
|
||||
|
||||
- **"Open with" and Share only work in the all-files mode.** A SAF path is relative to the
|
||||
- **Sharing a file *out* only works in the all-files mode.** A SAF path is relative to the
|
||||
granted tree rather than a filesystem path, so it cannot be handed to `FileProvider`.
|
||||
Receiving a share and being picked from another app's chooser work either way: the first
|
||||
needs no filesystem path, and the second falls back to `RESULT_CANCELED` rather than
|
||||
returning a URI the caller could not read.
|
||||
- **RAR, CAB, ISO and WIM are refused**, not supported — they need native code, which this
|
||||
project deliberately does not ship. (The Commons Compress jar contains no RAR classes at
|
||||
all.) **7z is different**: Commons Compress reads it in pure Java, so it *is* supported —
|
||||
|
||||
Reference in New Issue
Block a user