mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 21:58:12 +00:00
PDFViewer: Port to Core::Stream::File
This commit is contained in:
parent
7826cb2556
commit
d4367f42ba
3 changed files with 11 additions and 11 deletions
|
@ -47,10 +47,10 @@ ErrorOr<int> serenity_main(Main::Arguments arguments)
|
|||
window->set_icon(app_icon.bitmap_for_size(16));
|
||||
|
||||
if (file_path) {
|
||||
auto response = FileSystemAccessClient::Client::the().try_request_file_read_only_approved_deprecated(window, file_path);
|
||||
auto response = FileSystemAccessClient::Client::the().request_file_read_only_approved(window, file_path);
|
||||
if (response.is_error())
|
||||
return 1;
|
||||
pdf_viewer_widget->open_file(*response.value());
|
||||
pdf_viewer_widget->open_file(response.value().filename(), response.value().release_stream());
|
||||
}
|
||||
|
||||
return app->exec();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue