mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 13:07:46 +00:00
LibWeb: Remove unecessary dependence on Window from Fetch, XHR, FileAPI
These classes only needed Window to get at its realm. Pass a realm directly to construct Fetch, XMLHttpRequest and FileAPI classes.
This commit is contained in:
parent
6a10352712
commit
4878a18ee7
17 changed files with 144 additions and 169 deletions
|
@ -31,7 +31,7 @@ public:
|
|||
None,
|
||||
};
|
||||
|
||||
static WebIDL::ExceptionOr<JS::NonnullGCPtr<Headers>> create_with_global_object(HTML::Window& window, Optional<HeadersInit> const& init);
|
||||
static WebIDL::ExceptionOr<JS::NonnullGCPtr<Headers>> construct_impl(JS::Realm& realm, Optional<HeadersInit> const& init);
|
||||
|
||||
virtual ~Headers() override;
|
||||
|
||||
|
@ -58,7 +58,7 @@ public:
|
|||
private:
|
||||
friend class HeadersIterator;
|
||||
|
||||
explicit Headers(HTML::Window&);
|
||||
explicit Headers(JS::Realm&);
|
||||
|
||||
void remove_privileged_no_cors_headers();
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue