mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 06:47:35 +00:00
LibWeb: Use the WRAPPER_HACK() macro instead of hand-coding wrap()
This macro will soon go away, but let's start by replacing all the hand-coded versions of wrap() with this macro that expands to the same exact thing.
This commit is contained in:
parent
bc74909308
commit
45425de849
17 changed files with 17 additions and 68 deletions
|
@ -40,7 +40,4 @@ private:
|
|||
|
||||
}
|
||||
|
||||
namespace Web::Bindings {
|
||||
inline JS::Object* wrap(JS::Realm&, Web::HTML::CloseEvent& object) { return &object; }
|
||||
using CloseEventWrapper = Web::HTML::CloseEvent;
|
||||
}
|
||||
WRAPPER_HACK(CloseEvent, Web::HTML)
|
||||
|
|
|
@ -58,7 +58,4 @@ private:
|
|||
|
||||
}
|
||||
|
||||
namespace Web::Bindings {
|
||||
inline JS::Object* wrap(JS::Realm&, Web::HTML::ErrorEvent& object) { return &object; }
|
||||
using ErrorEventWrapper = Web::HTML::ErrorEvent;
|
||||
}
|
||||
WRAPPER_HACK(ErrorEvent, Web::HTML)
|
||||
|
|
|
@ -41,7 +41,4 @@ private:
|
|||
|
||||
}
|
||||
|
||||
namespace Web::Bindings {
|
||||
inline JS::Object* wrap(JS::Realm&, Web::HTML::MessageEvent& object) { return &object; }
|
||||
using MessageEventWrapper = Web::HTML::MessageEvent;
|
||||
}
|
||||
WRAPPER_HACK(MessageEvent, Web::HTML)
|
||||
|
|
|
@ -33,7 +33,4 @@ private:
|
|||
|
||||
}
|
||||
|
||||
namespace Web::Bindings {
|
||||
inline JS::Object* wrap(JS::Realm&, Web::HTML::PageTransitionEvent& object) { return &object; }
|
||||
using PageTransitionEventWrapper = Web::HTML::PageTransitionEvent;
|
||||
}
|
||||
WRAPPER_HACK(PageTransitionEvent, Web::HTML)
|
||||
|
|
|
@ -42,7 +42,4 @@ private:
|
|||
|
||||
}
|
||||
|
||||
namespace Web::Bindings {
|
||||
inline JS::Object* wrap(JS::Realm&, Web::HTML::PromiseRejectionEvent& object) { return &object; }
|
||||
using PromiseRejectionEventWrapper = Web::HTML::PromiseRejectionEvent;
|
||||
}
|
||||
WRAPPER_HACK(PromiseRejectionEvent, Web::HTML)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue