Kenneth Myhra
e905f25911
LibWeb: Port Worker to new String
2023-02-23 15:48:38 +00:00
Kenneth Myhra
be727ea871
LibWeb: Port WorkerGlobalScope to new String
2023-02-23 15:48:38 +00:00
Kenneth Myhra
9c5bdb0b86
LibWeb: Port WorkerLocation to new String
2023-02-23 15:48:38 +00:00
Kenneth Myhra
f0fd1cae3d
LibWeb: Make factory method of IdleDeadline fallible
2023-02-22 09:55:33 +01:00
Kenneth Myhra
459959b297
LibWeb: Make factory method of HTML::BrowsingContext fallible
2023-02-22 09:55:33 +01:00
Kenneth Myhra
ff92324fa5
LibWeb: Make factory method of DOM::ElementFactory fallible
2023-02-22 09:55:33 +01:00
Kenneth Myhra
587cf355ed
LibWeb: Make factory methods of UIEvents::UIEvent fallible
...
This affects calls to FocusEvent::create() since FocusEvent does not
implement its own create() method.
2023-02-22 09:55:33 +01:00
Luke Wilde
2ca8cf49ca
LibWeb: Use browsing context creator URL for about:blank documents
...
In about:blank documents, we should use the browsing context's creator
URL as the base URL, if it exists and there is no <base> element.
This means that any about:blank frames will have URLs parse relative to
their parent frame's URL.
Fixes #17394 .
2023-02-21 18:52:46 +01:00
Andrew Kaster
f40094d014
LibWeb+LibJS: Format Console arguments with JS::Print
...
Instead of just calling JS::Value::to_string_without_side_effects() when
printing values to the console, have all the console clients use
the same JS::Print that the REPL does to print values.
This method leaves some things to be desired as far as OOM hardening
goes, however. We should be able to create a String in a way that
doesn't OOM on failure so hard.
2023-02-21 10:57:44 +01:00
Sam Atkins
2db168acc1
LibTextCodec+Everywhere: Port Decoders to new Strings
2023-02-19 17:15:47 +01:00
Sam Atkins
f2a9426885
LibTextCodec+Everywhere: Return Optional<Decoder&> from decoder_for()
2023-02-19 17:15:47 +01:00
Sam Atkins
2026ea557e
LibWeb: Use is_ascii_case_insensitive_match() where the spec says to
2023-02-19 00:46:47 +01:00
Luke Wilde
3275d659bf
LibWeb: Convert FormData to String and Vector storage
...
This makes use of the new [UseNewAKString] extended attribute. Using
Vector storage will make it easier to make this interface into an IDL
iterable. It seems the reason it didn't use Vector originally was due
to awkward DeprecatedString -> String conversions.
2023-02-18 01:23:36 +01:00
Kenneth Myhra
bfc8cbcf3b
LibWeb: Make factory method of HTML::ModuleScript fallible
2023-02-18 00:52:47 +01:00
Kenneth Myhra
3e834636a6
LibWeb: Make factory method of HTML::Window fallible
2023-02-18 00:52:47 +01:00
Kenneth Myhra
b41401bab2
LibWeb: Make factory method of HTML::Storage fallible
2023-02-18 00:52:47 +01:00
Kenneth Myhra
d7ee378018
LibWeb: Make factory method of HTML::Navigator fallible
2023-02-18 00:52:47 +01:00
Kenneth Myhra
2f4db60c08
LibWeb: Make factory method of HTML::History fallible
2023-02-18 00:52:47 +01:00
Kenneth Myhra
3941e64fde
LibWeb: Make factory method of HTML::PromiseRejectionEvent fallible
2023-02-18 00:52:47 +01:00
Kenneth Myhra
193de231e0
LibWeb: Make factory method of HTML::WorkerNavigator fallible
2023-02-18 00:52:47 +01:00
Kenneth Myhra
86b7f148b9
LibWeb: Make factory method of HTML::Path2D fallible
2023-02-18 00:52:47 +01:00
Kenneth Myhra
2b391ea622
LibWeb: Make factory method of HTML::HTMLOptionsCollection fallible
2023-02-18 00:52:47 +01:00
Kenneth Myhra
b604bbaf29
LibWeb: Make factory method of HTML::DOMStringMap fallible
2023-02-18 00:52:47 +01:00
Kenneth Myhra
809206f50e
LibWeb: Make factory method of HTML::SubmitEvent fallible
2023-02-18 00:52:47 +01:00
Kenneth Myhra
c5de2c3348
LibWeb: Make factory method of HTML::TextMetrics fallible
2023-02-18 00:52:47 +01:00
Kenneth Myhra
d9845bb24b
LibWeb: Make factory method of HTML::PageTransitionEvent fallible
2023-02-18 00:52:47 +01:00
Kenneth Myhra
97b5aa56da
LibWeb: Make factory method of HTML::ErrorEvent fallible
2023-02-18 00:52:47 +01:00
Kenneth Myhra
2ed7f64c73
LibWeb: Make factory method of HTML::CloseEvent fallible
2023-02-18 00:52:47 +01:00
Kenneth Myhra
b7c488e51e
LibWeb: Make factory method of HTML::CanvasRenderingContext2D fallible
2023-02-18 00:52:47 +01:00
Kenneth Myhra
2506666991
LibWeb: Make factory methods of HTML::CanvasGradient fallible
2023-02-18 00:52:47 +01:00
Kenneth Myhra
ff875d353b
LibWeb: Make factory method of DOM::HTMLCollection fallible
2023-02-18 00:52:47 +01:00
Kenneth Myhra
c120c46acc
LibWeb: Make factory methods of DOM::Event fallible
...
Because of interdependencies between DOM::Event and UIEvents::MouseEvent
to template function fire_an_event() in WebDriverConnection.cpp, the
commit: 'LibWeb: Make factory methods of UIEvents::MouseEvent fallible'
have been squashed into this commit.
2023-02-18 00:52:47 +01:00
Kenneth Myhra
0d9076c9f5
LibWeb: Make factory methods of DOM::Document fallible
2023-02-18 00:52:47 +01:00
Kenneth Myhra
50c5f0d7da
LibWeb: Make factory method of DOM::Attr fallible
2023-02-18 00:52:47 +01:00
Kenneth Myhra
8fbd43cb27
LibWeb: Make factory method of CSS::ResolvedCSSStyleDeclaration fallible
2023-02-18 00:52:47 +01:00
Kenneth Myhra
6688f89ad3
LibWeb: Make factory method of FileAPI::FileList fallible
2023-02-18 00:52:47 +01:00
Kenneth Myhra
bc02686ae9
LibWeb: Make factory method of CSS::MediaQueryList fallible
2023-02-18 00:52:47 +01:00
Kenneth Myhra
471ad7ba01
LibWeb: Make factory method of HTML::MessagePort fallible
2023-02-18 00:52:47 +01:00
Kenneth Myhra
7ec444047c
LibWeb: Make factory methods of HTML::MessageEvent fallible
2023-02-18 00:52:47 +01:00
Kenneth Myhra
3d79cdf095
LibWeb: Make factory method of HTML::MessageChannel fallible
2023-02-18 00:52:47 +01:00
Kenneth Myhra
58af8e2021
LibWeb: Make factory method of Crypto::Crypto fallible
2023-02-18 00:52:47 +01:00
Timothy Flynn
88814acbd3
LibJS+Everywhere: Convert JS::Error to String
...
This includes an Error::create overload to create an Error from a UTF-8
StringView. If creating a String from that view fails, the factory will
return an OOM InternalError instead. VM::throw_completion can also make
use of this overload via its perfect forwarding.
2023-02-17 09:14:23 -05:00
Timothy Flynn
527edb55ad
LibWeb: Convert usages of Value::TDSWOSE to Value::TSWOSE
2023-02-16 14:32:22 +01:00
Timothy Flynn
b245300ba1
LibJS+Everywhere: Deprecate Value::to_string_without_side_effects
2023-02-16 14:32:22 +01:00
Sam Atkins
d6075ef5b5
LibTextCodec+Everywhere: Make TextCodec::decoder_for() take a StringView
...
We don't need a full String/DeprecatedString inside this function, so we
might as well not force users to create one.
2023-02-15 12:48:26 -05:00
Kenneth Myhra
562594c416
LibWeb: Do not assume field element is always a HTMLInputElement
...
Cast to a HTMLElement instead and retrieve the value attribute from
there instead.
2023-02-13 14:34:37 +00:00
Kenneth Myhra
7d23af49c2
LibWeb: Avoid dereferencing null pointer
...
Null check was missing and we would crash when dereferencing the
pointer to access the type() member.
2023-02-13 14:34:37 +00:00
Andreas Kling
dadabb58eb
LibWeb: Implement location.hash setter
...
This stops a lot of the whining about uncaught exceptions on the
Speedometer benchmark.
2023-02-12 13:00:33 +01:00
Kenneth Myhra
4d27b9e553
LibWeb: Use 'auto& vm =' once at beginning to reduce noise
2023-02-12 11:53:52 +00:00
Kenneth Myhra
fc886b4556
LibWeb: Implement algorithm 'construct the entry list given a form'
2023-02-12 00:18:09 +00:00