mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-09-02 15:46:33 +00:00
LibWeb: Visit IntersectionObserverRegistration instead of using Handle
This fixes GC-leak caused by JS::Handle<IntersectionObserverver> preventing an element that owns the handle from being deallocated.
This commit is contained in:
parent
ac5c4705fd
commit
35623ad52e
Notes:
sideshowbarker
2024-07-17 05:06:13 +09:00
Author: https://github.com/kalenikaliaksandr
Commit: 35623ad52e
Pull-request: https://github.com/SerenityOS/serenity/pull/21235
3 changed files with 4 additions and 2 deletions
|
@ -23,7 +23,7 @@ struct IntersectionObserverInit {
|
|||
struct IntersectionObserverRegistration {
|
||||
// https://www.w3.org/TR/intersection-observer/#dom-intersectionobserverregistration-observer
|
||||
// [A]n observer property holding an IntersectionObserver.
|
||||
JS::Handle<IntersectionObserver> observer;
|
||||
JS::NonnullGCPtr<IntersectionObserver> observer;
|
||||
|
||||
// https://www.w3.org/TR/intersection-observer/#dom-intersectionobserverregistration-observer
|
||||
// NOTE: Optional is used in place of the spec using -1 to indicate no previous index.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue