mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-07-29 04:09:13 +00:00
LibJS+LibWeb: Let Realm store a plain Object for [[GlobalObject]]
This removes the requirement of having a global object that actually inherits from JS::GlobalObject, which is now a perfectly valid scenario. With the upcoming removal of wrapper objects in LibWeb, the HTML::Window object will inherit from DOM::EventTarget, which means it cannot also inherit from JS::GlobalObject.
This commit is contained in:
parent
72730422bb
commit
52543fc771
Notes:
sideshowbarker
2024-07-17 07:39:33 +09:00
Author: https://github.com/linusg
Commit: 52543fc771
Pull-request: https://github.com/SerenityOS/serenity/pull/15057
8 changed files with 20 additions and 20 deletions
|
@ -79,7 +79,7 @@ struct EnvironmentSettingsObject
|
|||
virtual CanUseCrossOriginIsolatedAPIs cross_origin_isolated_capability() = 0;
|
||||
|
||||
JS::Realm& realm();
|
||||
JS::GlobalObject& global_object();
|
||||
JS::Object& global_object();
|
||||
EventLoop& responsible_event_loop();
|
||||
|
||||
RunScriptDecision can_run_script();
|
||||
|
@ -121,12 +121,12 @@ private:
|
|||
|
||||
EnvironmentSettingsObject& incumbent_settings_object();
|
||||
JS::Realm& incumbent_realm();
|
||||
JS::GlobalObject& incumbent_global_object();
|
||||
JS::Object& incumbent_global_object();
|
||||
EnvironmentSettingsObject& current_settings_object();
|
||||
JS::GlobalObject& current_global_object();
|
||||
JS::Object& current_global_object();
|
||||
JS::Realm& relevant_realm(JS::Object const&);
|
||||
EnvironmentSettingsObject& relevant_settings_object(JS::Object const&);
|
||||
EnvironmentSettingsObject& relevant_settings_object(DOM::Node const&);
|
||||
JS::GlobalObject& relevant_global_object(JS::Object const&);
|
||||
JS::Object& relevant_global_object(JS::Object const&);
|
||||
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue