mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 00:57:43 +00:00
LibWeb: Implement document ready state
This commit is contained in:
parent
8aabec1c94
commit
124c52b3b5
5 changed files with 49 additions and 0 deletions
|
@ -41,6 +41,7 @@
|
|||
#include <LibWeb/DOM/DocumentType.h>
|
||||
#include <LibWeb/DOM/Element.h>
|
||||
#include <LibWeb/DOM/ElementFactory.h>
|
||||
#include <LibWeb/DOM/Event.h>
|
||||
#include <LibWeb/DOM/Text.h>
|
||||
#include <LibWeb/DOM/Window.h>
|
||||
#include <LibWeb/HTML/AttributeNames.h>
|
||||
|
@ -522,4 +523,10 @@ void Document::set_focused_element(Element* element)
|
|||
m_layout_root->set_needs_display();
|
||||
}
|
||||
|
||||
void Document::set_ready_state(const String& ready_state)
|
||||
{
|
||||
m_ready_state = ready_state;
|
||||
dispatch_event(Event::create("readystatechange"));
|
||||
}
|
||||
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue