diff options
author | Bobby Holley <bobbyholley@gmail.com> | 2016-11-14 14:46:59 -0800 |
---|---|---|
committer | Bobby Holley <bobbyholley@gmail.com> | 2016-11-16 12:09:47 -0800 |
commit | f1043f630563a7c4a4f3fcff11f6f63b3e9afaa2 (patch) | |
tree | c1795b05784a4122f00492edbb22b4dba15afe24 /components/script/dom/document.rs | |
parent | 0547a6b313072cde5870a61b97be10ee62ce65ad (diff) | |
download | servo-f1043f630563a7c4a4f3fcff11f6f63b3e9afaa2.tar.gz servo-f1043f630563a7c4a4f3fcff11f6f63b3e9afaa2.zip |
Track all node damage with PendingRestyles.
Diffstat (limited to 'components/script/dom/document.rs')
-rw-r--r-- | components/script/dom/document.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/components/script/dom/document.rs b/components/script/dom/document.rs index 829b1d98192..b3be9b8ec14 100644 --- a/components/script/dom/document.rs +++ b/components/script/dom/document.rs @@ -477,7 +477,7 @@ impl Document { } pub fn content_and_heritage_changed(&self, node: &Node, damage: NodeDamage) { - node.force_dirty_ancestors(damage); + node.dirty(damage); } /// Reflows and disarms the timer if the reflow timer has expired. @@ -1990,12 +1990,12 @@ impl Document { self.id_map.borrow().get(&id).map(|ref elements| Root::from_ref(&*(*elements)[0])) } - fn ensure_pending_restyle(&self, el: &Element) -> RefMut<PendingRestyle> { + pub fn ensure_pending_restyle(&self, el: &Element) -> RefMut<PendingRestyle> { let map = self.pending_restyles.borrow_mut(); RefMut::map(map, |m| m.entry(JS::from_ref(el)).or_insert_with(PendingRestyle::new)) } - fn ensure_snapshot(&self, el: &Element) -> RefMut<Snapshot> { + pub fn ensure_snapshot(&self, el: &Element) -> RefMut<Snapshot> { let mut entry = self.ensure_pending_restyle(el); if entry.snapshot.is_none() { entry.snapshot = Some(Snapshot::new(el.html_element_in_html_document())); |