1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 19:37:35 +00:00

LibWeb: Add the Web::URL namespace and move URLEncoder to it

This namespace will be used for all interfaces defined in the URL
specification, like URL and URLSearchParams.

This has the unfortunate side-effect of requiring us to use the fully
qualified AK::URL name whenever we want to refer to the AK class, so
this commit also fixes all such references.
This commit is contained in:
Idan Horowitz 2021-09-13 00:33:23 +03:00 committed by Andreas Kling
parent 2b78e227f2
commit 4629f2e4ad
54 changed files with 236 additions and 225 deletions

View file

@ -651,7 +651,7 @@ class ImageStyleValue final
: public StyleValue
, public ImageResourceClient {
public:
static NonnullRefPtr<ImageStyleValue> create(const URL& url, DOM::Document& document) { return adopt_ref(*new ImageStyleValue(url, document)); }
static NonnullRefPtr<ImageStyleValue> create(const AK::URL& url, DOM::Document& document) { return adopt_ref(*new ImageStyleValue(url, document)); }
virtual ~ImageStyleValue() override { }
String to_string() const override { return String::formatted("Image({})", m_url.to_string()); }
@ -659,12 +659,12 @@ public:
const Gfx::Bitmap* bitmap() const { return m_bitmap; }
private:
ImageStyleValue(const URL&, DOM::Document&);
ImageStyleValue(const AK::URL&, DOM::Document&);
// ^ResourceClient
virtual void resource_did_load() override;
URL m_url;
AK::URL m_url;
WeakPtr<DOM::Document> m_document;
RefPtr<Gfx::Bitmap> m_bitmap;
};