mirror of
https://github.com/servo/servo.git
synced 2025-08-05 05:30:08 +01:00
Upgrade to rustc 1.21.0-nightly (13d94d5fa 2017-08-10)
This commit is contained in:
parent
41fb10c589
commit
b5a4b8d6a0
40 changed files with 73 additions and 79 deletions
|
@ -633,7 +633,7 @@ impl Document {
|
|||
// reset_form_owner_for_listeners -> reset_form_owner -> GetElementById
|
||||
{
|
||||
let mut id_map = self.id_map.borrow_mut();
|
||||
let mut elements = id_map.entry(id.clone()).or_insert(Vec::new());
|
||||
let elements = id_map.entry(id.clone()).or_insert(Vec::new());
|
||||
elements.insert_pre_order(element, root.r().upcast::<Node>());
|
||||
}
|
||||
self.reset_form_owner_for_listeners(&id);
|
||||
|
@ -642,7 +642,7 @@ impl Document {
|
|||
pub fn register_form_id_listener<T: ?Sized + FormControl>(&self, id: DOMString, listener: &T) {
|
||||
let mut map = self.form_id_listener_map.borrow_mut();
|
||||
let listener = listener.to_element();
|
||||
let mut set = map.entry(Atom::from(id)).or_insert(HashSet::new());
|
||||
let set = map.entry(Atom::from(id)).or_insert(HashSet::new());
|
||||
set.insert(JS::from_ref(listener));
|
||||
}
|
||||
|
||||
|
@ -1559,7 +1559,7 @@ impl Document {
|
|||
/// https://html.spec.whatwg.org/multipage/#dom-window-cancelanimationframe
|
||||
pub fn cancel_animation_frame(&self, ident: u32) {
|
||||
let mut list = self.animation_frame_list.borrow_mut();
|
||||
if let Some(mut pair) = list.iter_mut().find(|pair| pair.0 == ident) {
|
||||
if let Some(pair) = list.iter_mut().find(|pair| pair.0 == ident) {
|
||||
pair.1 = None;
|
||||
}
|
||||
}
|
||||
|
@ -2391,7 +2391,7 @@ impl Document {
|
|||
if entry.snapshot.is_none() {
|
||||
entry.snapshot = Some(Snapshot::new(el.html_element_in_html_document()));
|
||||
}
|
||||
let mut snapshot = entry.snapshot.as_mut().unwrap();
|
||||
let snapshot = entry.snapshot.as_mut().unwrap();
|
||||
if snapshot.state.is_none() {
|
||||
snapshot.state = Some(el.state());
|
||||
}
|
||||
|
@ -2418,7 +2418,7 @@ impl Document {
|
|||
entry.hint.insert(RESTYLE_SELF);
|
||||
}
|
||||
|
||||
let mut snapshot = entry.snapshot.as_mut().unwrap();
|
||||
let snapshot = entry.snapshot.as_mut().unwrap();
|
||||
if attr.local_name() == &local_name!("id") {
|
||||
snapshot.id_changed = true;
|
||||
} else if attr.local_name() == &local_name!("class") {
|
||||
|
@ -4019,7 +4019,7 @@ impl PendingInOrderScriptVec {
|
|||
|
||||
fn loaded(&self, element: &HTMLScriptElement, result: ScriptResult) {
|
||||
let mut scripts = self.scripts.borrow_mut();
|
||||
let mut entry = scripts.iter_mut().find(|entry| &*entry.element == element).unwrap();
|
||||
let entry = scripts.iter_mut().find(|entry| &*entry.element == element).unwrap();
|
||||
entry.loaded(result);
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue