aboutsummaryrefslogtreecommitdiffstats
path: root/components/style/context.rs
diff options
context:
space:
mode:
authorEmilio Cobos Álvarez <ecoal95@gmail.com>2016-09-06 11:13:50 +0800
committerSimon Sapin <simon.sapin@exyr.org>2016-11-05 17:29:52 +0100
commitde4fe6e2b69acebf015e0b154f3ebd0371f530f9 (patch)
tree788591e218c70117b4764ead369db5385262dece /components/style/context.rs
parentf7875dad1a43792ff3869f292990d03d30ebd9eb (diff)
downloadservo-de4fe6e2b69acebf015e0b154f3ebd0371f530f9.tar.gz
servo-de4fe6e2b69acebf015e0b154f3ebd0371f530f9.zip
Concurrent rule tree, v1
This patch introduces infrastructure for the rule tree, and constructs it. We don't use it yet, nor have good heuristics for GC'ing it, but this should not happen anymore once we store the rule node reference in the node. I haven't messed up with memory orders because I want to do a try run with it, then mess with them. Take down the ApplicableDeclarationsCache, use the rule tree for doing the cascade.
Diffstat (limited to 'components/style/context.rs')
-rw-r--r--components/style/context.rs4
1 files changed, 1 insertions, 3 deletions
diff --git a/components/style/context.rs b/components/style/context.rs
index fc3724452a7..2707a799713 100644
--- a/components/style/context.rs
+++ b/components/style/context.rs
@@ -9,7 +9,7 @@ use app_units::Au;
use dom::OpaqueNode;
use error_reporting::ParseErrorReporter;
use euclid::Size2D;
-use matching::{ApplicableDeclarationsCache, StyleSharingCandidateCache};
+use matching::StyleSharingCandidateCache;
use parking_lot::RwLock;
use selector_matching::Stylist;
use std::cell::RefCell;
@@ -66,7 +66,6 @@ pub struct SharedStyleContext {
}
pub struct LocalStyleContext {
- pub applicable_declarations_cache: RefCell<ApplicableDeclarationsCache>,
pub style_sharing_candidate_cache: RefCell<StyleSharingCandidateCache>,
/// A channel on which new animations that have been triggered by style
/// recalculation can be sent.
@@ -76,7 +75,6 @@ pub struct LocalStyleContext {
impl LocalStyleContext {
pub fn new(local_context_creation_data: &LocalStyleContextCreationInfo) -> Self {
LocalStyleContext {
- applicable_declarations_cache: RefCell::new(ApplicableDeclarationsCache::new()),
style_sharing_candidate_cache: RefCell::new(StyleSharingCandidateCache::new()),
new_animations_sender: local_context_creation_data.new_animations_sender.clone(),
}