mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 10:57:35 +00:00
KeyboardMapper: Port to Core::Stream
Port KeyboardMapperWidget to use the new Core::Stream instead of the old IODevice. If you can't beat 'em, join 'em.
This commit is contained in:
parent
9678ff15a8
commit
c00014fa54
3 changed files with 12 additions and 9 deletions
|
@ -1,5 +1,6 @@
|
|||
/*
|
||||
* Copyright (c) 2020, Hüseyin Aslıtürk <asliturk@hotmail.com>
|
||||
* Copyright (c) 2021, Rasmus Nylander <RasmusNylander.SerenityOS@gmail.com>
|
||||
*
|
||||
* SPDX-License-Identifier: BSD-2-Clause
|
||||
*/
|
||||
|
@ -48,7 +49,8 @@ ErrorOr<int> serenity_main(Main::Arguments arguments)
|
|||
auto open_action = GUI::CommonActions::make_open_action(
|
||||
[&](auto&) {
|
||||
Optional<String> path = GUI::FilePicker::get_open_filepath(window, "Open", "/res/keymaps/");
|
||||
if (!path.has_value()) return;
|
||||
if (!path.has_value())
|
||||
return;
|
||||
|
||||
ErrorOr<void> error_or = keyboard_mapper_widget->load_map_from_file(path.value());
|
||||
if (error_or.is_error())
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue