aboutsummaryrefslogtreecommitdiffstats
path: root/components/script/dom/element.rs
diff options
context:
space:
mode:
authorConnor Brewster <connor.brewster@eagles.oc.edu>2017-07-19 13:10:54 -0600
committerConnor Brewster <connor.brewster@eagles.oc.edu>2017-08-09 11:06:44 -0600
commite83a0045f9016b7d03631389107c1748a27fdb0c (patch)
tree5fd243b5602be68056c04bc1d0260aa40e03ef45 /components/script/dom/element.rs
parentec528e944a922ec4786b935be5a25e365174d1a1 (diff)
downloadservo-e83a0045f9016b7d03631389107c1748a27fdb0c.tar.gz
servo-e83a0045f9016b7d03631389107c1748a27fdb0c.zip
Add upgrade reaction
Diffstat (limited to 'components/script/dom/element.rs')
-rw-r--r--components/script/dom/element.rs4
1 files changed, 4 insertions, 0 deletions
diff --git a/components/script/dom/element.rs b/components/script/dom/element.rs
index 328dd76e822..b44757d3aa1 100644
--- a/components/script/dom/element.rs
+++ b/components/script/dom/element.rs
@@ -300,6 +300,10 @@ impl Element {
self.custom_element_reaction_queue.borrow_mut().push(CustomElementReaction::Callback(function, args));
}
+ pub fn push_upgrade_reaction(&self, definition: Rc<CustomElementDefinition>) {
+ self.custom_element_reaction_queue.borrow_mut().push(CustomElementReaction::Upgrade(definition));
+ }
+
pub fn invoke_reactions(&self) {
let mut reaction_queue = self.custom_element_reaction_queue.borrow_mut();
for reaction in reaction_queue.iter() {