mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-09-11 21:37:58 +03:00
WidgetGallery: Use the non-deprecated API of LibFileSystemAccessClient
The patch is tiny as WidgetGallery is only using `LibFSAC` for its file picker.
This commit is contained in:
parent
01db302a33
commit
c0ada49a24
Notes:
sideshowbarker
2024-07-17 01:39:32 +09:00
Author: https://github.com/LucasChollet Commit: https://github.com/SerenityOS/serenity/commit/c0ada49a24 Pull-request: https://github.com/SerenityOS/serenity/pull/17025 Reviewed-by: https://github.com/AtkinsSJ ✅
@ -108,10 +108,10 @@ GalleryWidget::GalleryWidget()
|
||||
m_file_button->set_icon(Gfx::Bitmap::try_load_from_file("/res/icons/16x16/open.png"sv).release_value_but_fixme_should_propagate_errors());
|
||||
|
||||
m_file_button->on_click = [&](auto) {
|
||||
auto response = FileSystemAccessClient::Client::the().try_open_file_deprecated(window());
|
||||
auto response = FileSystemAccessClient::Client::the().open_file(window());
|
||||
if (response.is_error())
|
||||
return;
|
||||
m_text_editor->set_text(response.release_value()->filename());
|
||||
m_text_editor->set_text(response.release_value().filename());
|
||||
};
|
||||
|
||||
m_input_button = basics_tab->find_descendant_of_type_named<GUI::Button>("input_button");
|
||||
|
Loading…
Reference in New Issue
Block a user