From a0ef6554516029605d743880c78e674c1546640b Mon Sep 17 00:00:00 2001 From: Mustafa Quraish Date: Mon, 22 Nov 2021 18:56:43 -0500 Subject: [PATCH] LibGUI: Let Application constructor accept in Main::Arguments Instead of manually passing in `arguments.argc` and `arguments.argv`, we can now just pass in the arguments directly. --- Userland/Libraries/LibGUI/Application.h | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/Userland/Libraries/LibGUI/Application.h b/Userland/Libraries/LibGUI/Application.h index 31c4a421a9..09b1f50a22 100644 --- a/Userland/Libraries/LibGUI/Application.h +++ b/Userland/Libraries/LibGUI/Application.h @@ -16,6 +16,7 @@ #include #include #include +#include namespace GUI { @@ -85,6 +86,10 @@ public: private: Application(int argc, char** argv, Core::EventLoop::MakeInspectable = Core::EventLoop::MakeInspectable::No); + Application(Main::Arguments const& arguments, Core::EventLoop::MakeInspectable inspectable = Core::EventLoop::MakeInspectable::No) + : Application(arguments.argc, arguments.argv, inspectable) + { + } virtual void event(Core::Event&) override;