mirror of
https://github.com/servo/servo.git
synced 2025-08-06 14:10:11 +01:00
auto merge of #3897 : Ms2ger/servo/enable-reflection, r=Manishearth
This commit is contained in:
commit
fba6cb9c42
5 changed files with 26915 additions and 13 deletions
|
@ -509,7 +509,7 @@ impl<'a> AttributeHandlers for JSRef<'a, Element> {
|
|||
value: DOMString) -> AttrValue {
|
||||
if *namespace == ns!("") {
|
||||
vtable_for(&NodeCast::from_ref(self))
|
||||
.parse_plain_attribute(local_name.as_slice(), value)
|
||||
.parse_plain_attribute(local_name, value)
|
||||
} else {
|
||||
StringAttrValue(value)
|
||||
}
|
||||
|
@ -1028,10 +1028,10 @@ impl<'a> VirtualMethods for JSRef<'a, Element> {
|
|||
self.notify_content_changed();
|
||||
}
|
||||
|
||||
fn parse_plain_attribute(&self, name: &str, value: DOMString) -> AttrValue {
|
||||
fn parse_plain_attribute(&self, name: &Atom, value: DOMString) -> AttrValue {
|
||||
match name {
|
||||
"id" => AttrValue::from_atomic(value),
|
||||
"class" => AttrValue::from_tokenlist(value),
|
||||
&atom!("id") => AttrValue::from_atomic(value),
|
||||
&atom!("class") => AttrValue::from_tokenlist(value),
|
||||
_ => self.super_type().unwrap().parse_plain_attribute(name, value),
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue