1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 18:27:35 +00:00

LibGUI: Let GUI applications create an inspectable EventLoop

GUI applications automatically have EventLoops created for them via
GUI::Application; however before this commit it was not possible to make
the application event loop inspectable. This exposes a third optional
argument to GUI::Application which allows one to make the application
event loop inspectable.
This commit is contained in:
sin-ack 2021-07-25 21:02:51 +00:00 committed by Ali Mohammad Pur
parent 2e3a5b884c
commit 6162e78c7f
2 changed files with 4 additions and 3 deletions

View file

@ -68,11 +68,11 @@ Application* Application::the()
return *s_the;
}
Application::Application(int argc, char** argv)
Application::Application(int argc, char** argv, Core::EventLoop::MakeInspectable make_inspectable)
{
VERIFY(!*s_the);
*s_the = *this;
m_event_loop = make<Core::EventLoop>();
m_event_loop = make<Core::EventLoop>(make_inspectable);
WindowServerConnection::the();
Clipboard::initialize({});
if (argc > 0)