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

LibWeb: Add basic <object> element support

This patch implements a simple <object> element with fallback content.
If the URL from the data attribute fails to load (including 404),
we render the DOM tree inside the <object> as fallback content.

This works by generating a different layout tree for the <object>
depending on the state and success of the data load. Since we cannot
currently do incremental layout tree updates, we have to force a
complete layout tree rebuild when the resource load finishes/fails.
This commit is contained in:
Andreas Kling 2020-06-13 22:24:49 +02:00
parent 95d70addd8
commit 3cc0c477db
5 changed files with 146 additions and 1 deletions

View file

@ -52,6 +52,7 @@ set(SOURCES
DOM/HTMLIFrameElement.cpp
DOM/HTMLImageElement.cpp
DOM/HTMLInputElement.cpp
DOM/HTMLObjectElement.cpp
DOM/HTMLLinkElement.cpp
DOM/HTMLScriptElement.cpp
DOM/HTMLStyleElement.cpp
@ -95,6 +96,7 @@ set(SOURCES
Layout/LineBoxFragment.cpp
LayoutTreeModel.cpp
Loader/FrameLoader.cpp
Loader/ImageLoader.cpp
Loader/ImageResource.cpp
Loader/Resource.cpp
Loader/ResourceLoader.cpp