mirror of
https://github.com/servo/servo.git
synced 2025-08-07 06:25:32 +01:00
Propagate CanGc
arguments through callers in constructors (#35541)
Signed-off-by: Auguste Baum <auguste.apple@gmail.com>
This commit is contained in:
parent
5465bfc2af
commit
863d2ce871
260 changed files with 986 additions and 603 deletions
|
@ -34,6 +34,7 @@ impl MutationRecord {
|
|||
attribute_name: &LocalName,
|
||||
attribute_namespace: Option<&Namespace>,
|
||||
old_value: Option<DOMString>,
|
||||
can_gc: CanGc,
|
||||
) -> DomRoot<MutationRecord> {
|
||||
let record = Box::new(MutationRecord::new_inherited(
|
||||
"attributes",
|
||||
|
@ -46,12 +47,13 @@ impl MutationRecord {
|
|||
None,
|
||||
None,
|
||||
));
|
||||
reflect_dom_object(record, &*target.owner_window(), CanGc::note())
|
||||
reflect_dom_object(record, &*target.owner_window(), can_gc)
|
||||
}
|
||||
|
||||
pub(crate) fn character_data_mutated(
|
||||
target: &Node,
|
||||
old_value: Option<DOMString>,
|
||||
can_gc: CanGc,
|
||||
) -> DomRoot<MutationRecord> {
|
||||
reflect_dom_object(
|
||||
Box::new(MutationRecord::new_inherited(
|
||||
|
@ -66,7 +68,7 @@ impl MutationRecord {
|
|||
None,
|
||||
)),
|
||||
&*target.owner_window(),
|
||||
CanGc::note(),
|
||||
can_gc,
|
||||
)
|
||||
}
|
||||
|
||||
|
@ -76,6 +78,7 @@ impl MutationRecord {
|
|||
removed_nodes: Option<&[&Node]>,
|
||||
next_sibling: Option<&Node>,
|
||||
prev_sibling: Option<&Node>,
|
||||
can_gc: CanGc,
|
||||
) -> DomRoot<MutationRecord> {
|
||||
let window = target.owner_window();
|
||||
let added_nodes = added_nodes.map(|list| NodeList::new_simple_list_slice(&window, list));
|
||||
|
@ -95,7 +98,7 @@ impl MutationRecord {
|
|||
prev_sibling,
|
||||
)),
|
||||
&*window,
|
||||
CanGc::note(),
|
||||
can_gc,
|
||||
)
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue