mirror of
https://github.com/LadybirdBrowser/ladybird
synced 2026-05-03 13:02:09 +02:00
LibJS: Turn initialize_global_object() into a regular initialize()
There's nothing special about global object initialization anymore, this can just work the same way as for any other object now.
This commit is contained in:
Notes:
sideshowbarker
2024-07-17 07:39:44 +09:00
Author: https://github.com/linusg Commit: https://github.com/SerenityOS/serenity/commit/cfa5885855 Pull-request: https://github.com/SerenityOS/serenity/pull/15057
@@ -194,15 +194,14 @@ public:
|
||||
: JS::GlobalObject(realm)
|
||||
{
|
||||
}
|
||||
|
||||
virtual void initialize(JS::Realm&) override;
|
||||
virtual ~TestRunnerGlobalObject() override = default;
|
||||
|
||||
virtual void initialize_global_object(JS::Realm&) override;
|
||||
};
|
||||
|
||||
inline void TestRunnerGlobalObject::initialize_global_object(JS::Realm& realm)
|
||||
inline void TestRunnerGlobalObject::initialize(JS::Realm& realm)
|
||||
{
|
||||
Base::initialize_global_object(realm);
|
||||
Base::initialize(realm);
|
||||
|
||||
define_direct_property("global", this, JS::Attribute::Enumerable);
|
||||
for (auto& entry : s_exposed_global_functions) {
|
||||
define_native_function(
|
||||
|
||||
Reference in New Issue
Block a user