mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-08-01 13:49:16 +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
Notes:
sideshowbarker
2024-07-17 05:18:04 +09:00
Author: https://github.com/awesomekling
Commit: 3c548adf9c
Pull-request: https://github.com/SerenityOS/serenity/pull/15672
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