mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 08:48:11 +00:00
LibWeb: Create and hook up a WindowProxy for each BrowsingContext
All the machinery for this was already in place, we just never created the actual WindowProxy and installed it.
This commit is contained in:
parent
738e770fce
commit
3c548adf9c
5 changed files with 46 additions and 22 deletions
|
@ -20,9 +20,8 @@
|
|||
namespace Web::HTML {
|
||||
|
||||
// 7.4 The WindowProxy exotic object, https://html.spec.whatwg.org/multipage/window-object.html#the-windowproxy-exotic-object
|
||||
WindowProxy::WindowProxy(JS::Realm& realm, Window& window)
|
||||
WindowProxy::WindowProxy(JS::Realm& realm)
|
||||
: JS::Object(realm, nullptr)
|
||||
, m_window(window)
|
||||
{
|
||||
}
|
||||
|
||||
|
@ -256,4 +255,9 @@ void WindowProxy::visit_edges(JS::Cell::Visitor& visitor)
|
|||
visitor.visit(m_window.ptr());
|
||||
}
|
||||
|
||||
void WindowProxy::set_window(Badge<BrowsingContext>, JS::NonnullGCPtr<Window> window)
|
||||
{
|
||||
m_window = window;
|
||||
}
|
||||
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue