summaryrefslogtreecommitdiff
path: root/Userland/Libraries/LibWeb/DOM/Document.cpp
diff options
context:
space:
mode:
authorPrestonLTaylor <95388976+PrestonLTaylor@users.noreply.github.com>2023-05-30 21:05:49 +0100
committerAndreas Kling <kling@serenityos.org>2023-06-03 05:58:00 +0200
commitb322abd8d0881003fcf84bed9c1fe6c30fcff191 (patch)
tree06c5682ec72dba82c17491daefe5f37fb92d2820 /Userland/Libraries/LibWeb/DOM/Document.cpp
parent31d536912c86702cc76d5dfe3ca6b20f3eece377 (diff)
downloadserenity-b322abd8d0881003fcf84bed9c1fe6c30fcff191.zip
LibWeb: Add document_fully_loaded event to DocumentObserver
SVGUseElement needs to be able to query the fully loaded document for its referenced element.
Diffstat (limited to 'Userland/Libraries/LibWeb/DOM/Document.cpp')
-rw-r--r--Userland/Libraries/LibWeb/DOM/Document.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/Userland/Libraries/LibWeb/DOM/Document.cpp b/Userland/Libraries/LibWeb/DOM/Document.cpp
index 3ed261fd9d..fcb2cff399 100644
--- a/Userland/Libraries/LibWeb/DOM/Document.cpp
+++ b/Userland/Libraries/LibWeb/DOM/Document.cpp
@@ -1679,6 +1679,11 @@ void Document::completely_finish_loading()
container->dispatch_event(DOM::Event::create(container->realm(), HTML::EventNames::load).release_value_but_fixme_should_propagate_errors());
});
}
+
+ for (auto& document_observer : m_document_observers) {
+ if (document_observer->document_fully_loaded)
+ document_observer->document_fully_loaded();
+ }
}
DeprecatedString Document::cookie(Cookie::Source source)