mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-06-10 18:10:56 +09:00
PDFViewer: Open CLI files through FileSystemAccessServer without prompt
Use `request_file_read_only_approved()` for the file (if any) is specified through a command line argument.
This commit is contained in:
parent
ecb3f882a3
commit
63ff5873d8
Notes:
sideshowbarker
2024-07-18 04:20:10 +09:00
Author: https://github.com/mustafaquraish
Commit: 63ff5873d8
Pull-request: https://github.com/SerenityOS/serenity/pull/9854
Reviewed-by: https://github.com/IdanHo
Reviewed-by: https://github.com/alimpfard
1 changed files with 1 additions and 1 deletions
|
@ -45,7 +45,7 @@ int main(int argc, char** argv)
|
|||
window->set_icon(app_icon.bitmap_for_size(16));
|
||||
|
||||
if (argc >= 2) {
|
||||
auto response = FileSystemAccessClient::Client::the().request_file(window->window_id(), argv[1], Core::OpenMode::ReadOnly);
|
||||
auto response = FileSystemAccessClient::Client::the().request_file_read_only_approved(window->window_id(), argv[1]);
|
||||
|
||||
if (response.error != 0) {
|
||||
if (response.error != -1)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue