diff options
Diffstat (limited to 'components/script/dom/document.rs')
-rw-r--r-- | components/script/dom/document.rs | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/components/script/dom/document.rs b/components/script/dom/document.rs index cb8a2d37cf9..5b1f4cfe404 100644 --- a/components/script/dom/document.rs +++ b/components/script/dom/document.rs @@ -125,7 +125,7 @@ use std::sync::Arc; use std::time::{Duration, Instant}; use style::attr::AttrValue; use style::context::ReflowGoal; -use style::selector_impl::ElementSnapshot; +use style::selector_impl::Snapshot; use style::str::{split_html_space_chars, str_join}; use style::stylesheets::Stylesheet; use time; @@ -236,7 +236,7 @@ pub struct Document { appropriate_template_contents_owner_document: MutNullableHeap<JS<Document>>, /// For each element that has had a state or attribute change since the last restyle, /// track the original condition of the element. - modified_elements: DOMRefCell<HashMap<JS<Element>, ElementSnapshot>>, + modified_elements: DOMRefCell<HashMap<JS<Element>, Snapshot>>, /// This flag will be true if layout suppressed a reflow attempt that was /// needed in order for the page to be painted. needs_paint: Cell<bool>, @@ -1708,7 +1708,7 @@ pub enum DocumentSource { #[allow(unsafe_code)] pub trait LayoutDocumentHelpers { unsafe fn is_html_document_for_layout(&self) -> bool; - unsafe fn drain_modified_elements(&self) -> Vec<(LayoutJS<Element>, ElementSnapshot)>; + unsafe fn drain_modified_elements(&self) -> Vec<(LayoutJS<Element>, Snapshot)>; unsafe fn needs_paint_from_layout(&self); unsafe fn will_paint(&self); } @@ -1722,7 +1722,7 @@ impl LayoutDocumentHelpers for LayoutJS<Document> { #[inline] #[allow(unrooted_must_root)] - unsafe fn drain_modified_elements(&self) -> Vec<(LayoutJS<Element>, ElementSnapshot)> { + unsafe fn drain_modified_elements(&self) -> Vec<(LayoutJS<Element>, Snapshot)> { let mut elements = (*self.unsafe_get()).modified_elements.borrow_mut_for_layout(); let result = elements.drain().map(|(k, v)| (k.to_layout(), v)).collect(); result @@ -1970,7 +1970,7 @@ impl Document { let mut map = self.modified_elements.borrow_mut(); let snapshot = map.entry(JS::from_ref(el)) .or_insert_with(|| { - ElementSnapshot::new(el.html_element_in_html_document()) + Snapshot::new(el.html_element_in_html_document()) }); if snapshot.state.is_none() { snapshot.state = Some(el.state()); @@ -1981,7 +1981,7 @@ impl Document { let mut map = self.modified_elements.borrow_mut(); let mut snapshot = map.entry(JS::from_ref(el)) .or_insert_with(|| { - ElementSnapshot::new(el.html_element_in_html_document()) + Snapshot::new(el.html_element_in_html_document()) }); if snapshot.attrs.is_none() { let attrs = el.attrs() |