mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-11-22 23:50:19 +00:00
Ports: Unbreak SDL2 by using GUI::Application::create()
Commit 1a97382
introduced the fallible GUI::Application::create() and
removed GUI::Application::construct() breaking the SDL2 port, let's
update it to use the fallible version.
This commit is contained in:
parent
cf52542fcf
commit
4c17f22735
Notes:
sideshowbarker
2024-07-17 06:51:10 +09:00
Author: https://github.com/kennethmyhra Commit: https://github.com/SerenityOS/serenity/commit/4c17f22735 Pull-request: https://github.com/SerenityOS/serenity/pull/18665 Reviewed-by: https://github.com/LucasChollet ✅ Reviewed-by: https://github.com/gmta ✅
1 changed files with 2 additions and 1 deletions
|
@ -921,6 +921,7 @@ index 0000000000000000000000000000000000000000..f26040845dd05f425ba464af385e133c
|
|||
+# include <LibGUI/Widget.h>
|
||||
+# include <LibGUI/Window.h>
|
||||
+# include <LibGfx/Bitmap.h>
|
||||
+# include <LibMain/Main.h>
|
||||
+# include <dlfcn.h>
|
||||
+
|
||||
+static SDL_Scancode scancode_map[] = {
|
||||
|
@ -1125,7 +1126,7 @@ index 0000000000000000000000000000000000000000..f26040845dd05f425ba464af385e133c
|
|||
+ dbgln("{}: Initialising SDL application", __FUNCTION__);
|
||||
+
|
||||
+ if (!g_app) {
|
||||
+ g_app = GUI::Application::construct(0, nullptr);
|
||||
+ g_app = MUST(GUI::Application::create(Main::Arguments {}));
|
||||
+ g_app->set_quit_when_last_window_deleted(false);
|
||||
+ }
|
||||
+
|
||||
|
|
Loading…
Reference in a new issue