1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-31 10:28:10 +00:00

Userland: Make GUI::Window construction non-fallible

This commit is contained in:
Tim Ledbetter 2023-09-16 12:51:33 +01:00 committed by Andrew Kaster
parent b6b2c6f3e2
commit 0d7b13edac
55 changed files with 60 additions and 60 deletions

View file

@ -36,7 +36,7 @@ ErrorOr<int> serenity_main(Main::Arguments arguments)
u32 high_score = Config::read_i32("FlappyBug"sv, "Game"sv, "HighScore"sv, 0);
auto window = TRY(GUI::Window::try_create());
auto window = GUI::Window::construct();
window->resize(FlappyBug::Game::game_width, FlappyBug::Game::game_height);
auto app_icon = TRY(GUI::Icon::try_create_default_icon("app-flappybug"sv));
window->set_icon(app_icon.bitmap_for_size(16));