diff options
author | Pedro Pereira <pmh.pereira@gmail.com> | 2021-11-24 00:38:12 +0000 |
---|---|---|
committer | Andreas Kling <kling@serenityos.org> | 2021-11-24 13:51:07 +0100 |
commit | 92e9b447f4815548744a8a66ff91306971593647 (patch) | |
tree | ff24dc1dae690e81f77c58b6a61ee30d0cf1c603 | |
parent | 5b33ee20df1cd9553022b1c9eb1265359ddd6ebf (diff) | |
download | serenity-92e9b447f4815548744a8a66ff91306971593647.zip |
Breakout: Replace construct() with TRY(try_create()) pattern
-rw-r--r-- | Userland/Games/Breakout/main.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Userland/Games/Breakout/main.cpp b/Userland/Games/Breakout/main.cpp index 7017e2e12d..4f4c9e7794 100644 --- a/Userland/Games/Breakout/main.cpp +++ b/Userland/Games/Breakout/main.cpp @@ -18,14 +18,14 @@ ErrorOr<int> serenity_main(Main::Arguments arguments) { TRY(Core::System::pledge("stdio recvfd sendfd rpath unix", nullptr)); - auto app = GUI::Application::construct(arguments); + auto app = TRY(GUI::Application::try_create(arguments)); TRY(Core::System::pledge("stdio recvfd sendfd rpath", nullptr)); TRY(Core::System::unveil("/res", "r")); TRY(Core::System::unveil(nullptr, nullptr)); - auto window = GUI::Window::construct(); + auto window = TRY(GUI::Window::try_create()); window->resize(Breakout::Game::game_width, Breakout::Game::game_height); window->set_resizable(false); window->set_double_buffering_enabled(false); |