mirror of
https://github.com/servo/servo.git
synced 2025-08-05 21:50:18 +01:00
Auto merge of #7452 - nox:cleanup-attributes, r=nox
Introduce VirtualMethods::attribute_mutated() <!-- Reviewable:start --> [<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/7452) <!-- Reviewable:end -->
This commit is contained in:
commit
eaf90c0b1c
33 changed files with 634 additions and 943 deletions
|
@ -68,7 +68,7 @@ impl HTMLCollection {
|
|||
HTMLCollection::create(window, root, box filter)
|
||||
}
|
||||
|
||||
pub fn by_tag_name(window: &Window, root: &Node, tag: DOMString)
|
||||
pub fn by_tag_name(window: &Window, root: &Node, mut tag: DOMString)
|
||||
-> Root<HTMLCollection> {
|
||||
if tag == "*" {
|
||||
return HTMLCollection::all_elements(window, root, None);
|
||||
|
@ -88,9 +88,12 @@ impl HTMLCollection {
|
|||
}
|
||||
}
|
||||
}
|
||||
let tag_atom = Atom::from_slice(&tag);
|
||||
tag.make_ascii_lowercase();
|
||||
let ascii_lower_tag = Atom::from_slice(&tag);
|
||||
let filter = TagNameFilter {
|
||||
tag: Atom::from_slice(&tag),
|
||||
ascii_lower_tag: Atom::from_slice(&tag.to_ascii_lowercase()),
|
||||
tag: tag_atom,
|
||||
ascii_lower_tag: ascii_lower_tag,
|
||||
};
|
||||
HTMLCollection::create(window, root, box filter)
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue