mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 19:38:12 +00:00
FileSystemAccessServer: Add service for accessing veiled files nicely
Adds new service FileSystemAccessServer which allows programs to request a file descriptor for any file on the file system. The user can be prompted to choose the path with a FilePicker, or the path can be provided by the application which will show a MessageBox showing the pid and name of the calling process and allows the user to approve or deny the request.
This commit is contained in:
parent
5e823d3de0
commit
41ce2debda
8 changed files with 246 additions and 0 deletions
|
@ -0,0 +1,9 @@
|
|||
#include <AK/URL.h>
|
||||
#include <LibCore/IODevice.h>
|
||||
|
||||
endpoint FileSystemAccessServer
|
||||
{
|
||||
request_file(String path, Core::OpenMode requested_access) => (i32 error, Optional<IPC::File> fd)
|
||||
prompt_open_file(String path_to_view, Core::OpenMode requested_access) => (i32 error, Optional<IPC::File> fd, Optional<String> chosen_file)
|
||||
prompt_save_file(String title, String ext, String path_to_view, Core::OpenMode requested_access) => (i32 error, Optional<IPC::File> fd, Optional<String> chosen_file)
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue