mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 05:18:12 +00:00
LibWeb: Move Timer from DOM directory & namespace to HTML
Timers are part of the HTML spec. :^) https://html.spec.whatwg.org/multipage/timers-and-user-prompts.html#timers
This commit is contained in:
parent
1422bd45eb
commit
0706f0d487
6 changed files with 15 additions and 15 deletions
|
@ -15,7 +15,6 @@
|
|||
#include <LibWeb/DOM/Document.h>
|
||||
#include <LibWeb/DOM/Event.h>
|
||||
#include <LibWeb/DOM/EventDispatcher.h>
|
||||
#include <LibWeb/DOM/Timer.h>
|
||||
#include <LibWeb/HTML/BrowsingContext.h>
|
||||
#include <LibWeb/HTML/EventLoop/EventLoop.h>
|
||||
#include <LibWeb/HTML/MessageEvent.h>
|
||||
|
@ -23,6 +22,7 @@
|
|||
#include <LibWeb/HTML/Scripting/ClassicScript.h>
|
||||
#include <LibWeb/HTML/Scripting/ExceptionReporter.h>
|
||||
#include <LibWeb/HTML/Storage.h>
|
||||
#include <LibWeb/HTML/Timer.h>
|
||||
#include <LibWeb/HTML/Window.h>
|
||||
#include <LibWeb/HighResolutionTime/Performance.h>
|
||||
#include <LibWeb/Layout/InitialContainingBlock.h>
|
||||
|
@ -174,7 +174,7 @@ void Window::clear_interval(i32 id)
|
|||
m_timers.remove(id);
|
||||
}
|
||||
|
||||
void Window::deallocate_timer_id(Badge<DOM::Timer>, i32 id)
|
||||
void Window::deallocate_timer_id(Badge<Timer>, i32 id)
|
||||
{
|
||||
m_timer_id_allocator.deallocate(id);
|
||||
}
|
||||
|
@ -262,7 +262,7 @@ i32 Window::run_timer_initialization_steps(Bindings::TimerHandler handler, i32 t
|
|||
};
|
||||
|
||||
// 13. Run steps after a timeout given global, "setTimeout/setInterval", timeout, completionStep, and id.
|
||||
auto timer = DOM::Timer::create(*this, timeout, move(completion_step), id);
|
||||
auto timer = Timer::create(*this, timeout, move(completion_step), id);
|
||||
m_timers.set(id, timer);
|
||||
timer->start();
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue