mirror of
https://github.com/servo/servo.git
synced 2025-08-06 14:10:11 +01:00
Replace RwLock<CssRules> with Locked<CssRules>
This commit is contained in:
parent
b213daaa88
commit
f35b4e27b3
15 changed files with 85 additions and 52 deletions
|
@ -101,8 +101,9 @@ impl HTMLMetaElement {
|
|||
if let Some(translated_rule) = ViewportRule::from_meta(&**content) {
|
||||
let document = self.upcast::<Node>().owner_doc();
|
||||
let shared_lock = document.style_shared_lock();
|
||||
let rule = CssRule::Viewport(Arc::new(RwLock::new(translated_rule)));
|
||||
*self.stylesheet.borrow_mut() = Some(Arc::new(Stylesheet {
|
||||
rules: CssRules::new(vec![CssRule::Viewport(Arc::new(RwLock::new(translated_rule)))]),
|
||||
rules: CssRules::new(vec![rule], shared_lock),
|
||||
origin: Origin::Author,
|
||||
shared_lock: shared_lock.clone(),
|
||||
base_url: window_from_node(self).get_url(),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue