diff options
author | sbansal3096 <sbansal3096@gmail.com> | 2019-03-21 22:11:20 +0530 |
---|---|---|
committer | sbansal3096 <sbansal3096@gmail.com> | 2019-03-22 15:45:18 +0530 |
commit | 13eebbfe565d0c96125c1a947249bac499ff5362 (patch) | |
tree | 4e9f272ae3d5748c1e31ab332a360e62e920292d /components/script/dom/cssstylesheet.rs | |
parent | e58226814f612edce3be999c0ced4a1edf0db96a (diff) | |
download | servo-13eebbfe565d0c96125c1a947249bac499ff5362.tar.gz servo-13eebbfe565d0c96125c1a947249bac499ff5362.zip |
Fix insertRule crash by exposing getter on stylesheet's owner
Diffstat (limited to 'components/script/dom/cssstylesheet.rs')
-rw-r--r-- | components/script/dom/cssstylesheet.rs | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/components/script/dom/cssstylesheet.rs b/components/script/dom/cssstylesheet.rs index 9ebc5d4bf6a..2def47d7aaa 100644 --- a/components/script/dom/cssstylesheet.rs +++ b/components/script/dom/cssstylesheet.rs @@ -75,6 +75,10 @@ impl CSSStyleSheet { self.style_stylesheet.disabled() } + pub fn get_owner(&self) -> &Element { + &*self.owner + } + pub fn set_disabled(&self, disabled: bool) { if self.style_stylesheet.set_disabled(disabled) { self.global() |