mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-08-01 21:59:07 +00:00
LibCore: Move deferred_invoke() implementation out of line
This commit is contained in:
parent
411d36719e
commit
029f5b0dad
Notes:
sideshowbarker
2024-07-17 02:42:21 +09:00
Author: https://github.com/awesomekling
Commit: 029f5b0dad
Pull-request: https://github.com/SerenityOS/serenity/pull/18493
Reviewed-by: https://github.com/FireFox317
2 changed files with 13 additions and 10 deletions
|
@ -847,4 +847,15 @@ void EventLoop::wake()
|
|||
}
|
||||
}
|
||||
|
||||
void EventLoop::deferred_invoke(Function<void()> invokee)
|
||||
{
|
||||
auto context = DeferredInvocationContext::construct();
|
||||
post_event(context, make<Core::DeferredInvocationEvent>(context, move(invokee)));
|
||||
}
|
||||
|
||||
void deferred_invoke(Function<void()> invokee)
|
||||
{
|
||||
EventLoop::current().deferred_invoke(move(invokee));
|
||||
}
|
||||
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue