mirror of
https://github.com/servo/servo.git
synced 2025-08-05 21:50:18 +01:00
Upgrade rust-selectors.
This commit is contained in:
parent
364c8e2976
commit
1d8d1cb9d9
19 changed files with 280 additions and 174 deletions
|
@ -38,9 +38,8 @@ fn create_common_style_affecting_attributes_from_element<E: TElement>(element: &
|
|||
flags.insert(flag)
|
||||
}
|
||||
}
|
||||
CommonStyleAffectingAttributeMode::IsEqual(target_value, flag) => {
|
||||
let atom = Atom::from(target_value); // FIXME(bholley): This goes away in the next patch.
|
||||
if element.attr_equals(&ns!(), &attribute_info.atom, &atom) {
|
||||
CommonStyleAffectingAttributeMode::IsEqual(ref target_value, flag) => {
|
||||
if element.attr_equals(&ns!(), &attribute_info.atom, target_value) {
|
||||
flags.insert(flag)
|
||||
}
|
||||
}
|
||||
|
@ -298,11 +297,10 @@ impl<C: ComputedValues> StyleSharingCandidate<C> {
|
|||
return false
|
||||
}
|
||||
}
|
||||
CommonStyleAffectingAttributeMode::IsEqual(target_value, flag) => {
|
||||
let atom = Atom::from(target_value); // FIXME(bholley): This goes away in the next patch.
|
||||
CommonStyleAffectingAttributeMode::IsEqual(ref target_value, flag) => {
|
||||
let contains = self.common_style_affecting_attributes.contains(flag);
|
||||
if element.has_attr(&ns!(), &attribute_info.atom) {
|
||||
if !contains || !element.attr_equals(&ns!(), &attribute_info.atom, &atom) {
|
||||
if !contains || !element.attr_equals(&ns!(), &attribute_info.atom, target_value) {
|
||||
return false
|
||||
}
|
||||
} else if contains {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue