mirror of
https://github.com/servo/servo.git
synced 2025-08-01 19:50:30 +01:00
Resolves long-running merge conflicts
This commit is contained in:
parent
419a26e619
commit
2ba1750c40
3 changed files with 11 additions and 14 deletions
|
@ -1095,7 +1095,7 @@ impl Element {
|
|||
assert!(local_name.chars().all(|ch| {
|
||||
!ch.is_ascii() || ch.to_ascii_lowercase() == ch
|
||||
}));
|
||||
let attribute = self.get_attribute(&ns!(""), local_name);
|
||||
let attribute = self.get_attribute(&ns!(), local_name);
|
||||
|
||||
match attribute {
|
||||
Some(ref attribute) => {
|
||||
|
|
|
@ -28,21 +28,18 @@ macro_rules! make_bool_getter(
|
|||
|
||||
#[macro_export]
|
||||
macro_rules! make_int_getter(
|
||||
($attr:ident, $htmlname:expr, $default:expr) => (
|
||||
($attr:ident, $htmlname:tt, $default:expr) => (
|
||||
fn $attr(&self) -> i32 {
|
||||
use dom::bindings::codegen::InheritTypes::ElementCast;
|
||||
use string_cache::Atom;
|
||||
let element = ElementCast::from_ref(self);
|
||||
// FIXME(pcwalton): Do this at compile time, not runtime.
|
||||
element.get_int_attribute(&Atom::from_slice($htmlname), $default)
|
||||
use dom::bindings::inheritance::Castable;
|
||||
use dom::element::Element;
|
||||
let element = self.upcast::<Element>();
|
||||
element.get_int_attribute(&atom!($htmlname), $default)
|
||||
}
|
||||
);
|
||||
($attr:ident, $htmlname:expr) => {
|
||||
|
||||
($attr:ident, $htmlname:tt) => {
|
||||
make_int_getter!($attr, $htmlname, 0);
|
||||
};
|
||||
($attr:ident) => {
|
||||
make_int_getter!($attr, to_lower!(stringify!($attr)));
|
||||
}
|
||||
);
|
||||
|
||||
#[macro_export]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue