Timothy Flynn
b75b7f0c0d
LibJS+Everywhere: Propagate Cell::initialize errors from Heap::allocate
...
Callers that are already in a fallible context will now TRY to allocate
cells. Callers in infallible contexts get a FIXME.
2023-01-29 00:02:45 +00:00
Timothy Flynn
2692db8699
LibJS+Everywhere: Allow Cell::initialize overrides to throw OOM errors
...
Note that as of this commit, there aren't any such throwers, and the
call site in Heap::allocate will drop exceptions on the floor. This
commit only serves to change the declaration of the overrides, make sure
they return an empty value, and to propagate OOM errors frm their base
initialize invocations.
2023-01-29 00:02:45 +00:00
Timothy Flynn
af75493883
LibWeb: Move passing of Web object prototypes out of constructors
2023-01-10 16:08:14 +01:00
Timothy Flynn
834202aeb9
LibWeb: Move setting of Web object prototypes to initialize()
...
This needs to happen before prototype/constructor intitialization can be
made lazy. Otherwise, GC could run during the C++ constructor and try to
collect the object currently being created.
2023-01-10 16:08:14 +01:00
Linus Groh
22089436ed
LibJS: Convert Heap::allocate{,_without_realm}() to NonnullGCPtr
2022-12-15 06:56:37 -05:00
Andrew Kaster
67ceba2e6a
LibWeb: Add Exposed attribute and IDL spec links where missing
...
The intent is to use these to autogenerate prototype declarations for
Window and WorkerGlobalScope classes.
And the spec links are just nice to have :^)
2022-10-09 10:14:57 +02:00
Sam Atkins
ab19c5fab8
LibWeb: Implement DOMPoint/DOMPointReadOnly.fromPoint()
2022-10-06 21:45:07 +01:00
Sam Atkins
8a78679152
LibWeb: Correct types in DOMPoint IDL files, and add FIXMEs
...
Also, the `w` parameters for the constructor default to 1, not 0.
2022-10-06 21:45:07 +01:00
Andrew Kaster
56b381aac0
LibWeb: Cleanup unecessary uses and includes of HTML::Window
...
The big global refactor left some stragglers behind for atomicity.
Clean up the rest, and remove a ton of includes of LibWeb/HTML/Window.h
2022-10-01 21:05:32 +01:00
Andrew Kaster
320dddde6a
LibWeb: Remove unecessary dependence on Window from SVG classes
...
These classes only needed Window to get at its realm. Pass a realm
directly to construct SCG classes.
2022-10-01 21:05:32 +01:00
Andrew Kaster
62a8c26b73
LibWeb: Remove unecessary dependence on Window from Geometry classes
...
These classes only needed Window to get at its realm. Pass a realm
directly to construct Geometry classes.
2022-10-01 21:05:32 +01:00
Linus Groh
4270ede7c4
LibWeb: Remove WRAPPER_HACK() macro
...
We no longer access Bindings::FooWrapper anywhere for a Foo platform
object, so these can be removed :^)
2022-09-21 21:12:24 +01:00
Andreas Kling
57db2529cf
LibWeb: Make DOMRect, DOMRectReadOnly and DOMRectList GC-allocated
2022-09-06 00:27:09 +02:00
Andreas Kling
44415af428
LibWeb: Make DOMPoint and DOMPointReadOnly GC-allocated
2022-09-06 00:27:09 +02:00
Andreas Kling
6f433c8656
LibWeb+LibJS: Make the EventTarget hierarchy (incl. DOM) GC-allocated
...
This is a monster patch that turns all EventTargets into GC-allocated
PlatformObjects. Their C++ wrapper classes are removed, and the LibJS
garbage collector is now responsible for their lifetimes.
There's a fair amount of hacks and band-aids in this patch, and we'll
have a lot of cleanup to do after this.
2022-09-06 00:27:09 +02:00
Andreas Kling
e883777a18
LibWeb: Add barebones implementation of DOMPoint and DOMPointReadOnly
2022-07-12 23:12:11 +02:00
Ali Mohammad Pur
a59800b4a0
LibWeb: Add imports to all IDL files that depend on others
2022-02-16 22:48:32 +03:30
DerpyCrabs
2f828231c4
LibWeb: Implement Geometry::DOMRectList
...
Implement DOMRectList that is used as a return type of
getClientRects functions on Element and Range.
2022-02-12 22:43:10 +01:00
Andreas Kling
3c0b55c284
LibWeb: Add DOMRectReadOnly and make DOMRect inherit from it
...
This matches the class hierarchy of the CSS Geometry Interfaces Module.
2021-10-08 23:00:49 +02:00
Andreas Kling
43d378940f
LibWeb: Add DOMRect and Element.getBoundingClientRect()
...
This marks our entry into the Web::Geometry namespace, based on the
"Geometry" spec at https://drafts.fxtf.org/geometry/
2021-09-27 01:01:29 +02:00