Navigation Menu

Skip to content

Commit

Permalink
Simply element bounds in stylist
Browse files Browse the repository at this point in the history
TElement already inherits from Debug and PresentationalHintsSynthesizer.
  • Loading branch information
aethanyc committed May 10, 2017
1 parent dd5f737 commit 4c9d8d3
Showing 1 changed file with 4 additions and 9 deletions.
13 changes: 4 additions & 9 deletions components/style/stylist.rs
Expand Up @@ -10,7 +10,7 @@ use {Atom, LocalName};
use bit_vec::BitVec;
use context::QuirksMode;
use data::ComputedStyle;
use dom::{AnimationRules, PresentationalHintsSynthesizer, TElement};
use dom::{AnimationRules, TElement};
use error_reporting::RustLogReporter;
use font_metrics::FontMetricsProvider;
use keyframes::KeyframesAnimation;
Expand All @@ -35,7 +35,6 @@ use sink::Push;
use smallvec::VecLike;
use std::borrow::Borrow;
use std::collections::HashMap;
use std::fmt;
use std::hash::Hash;
#[cfg(feature = "servo")]
use std::marker::PhantomData;
Expand Down Expand Up @@ -488,9 +487,7 @@ impl Stylist {
parent: &Arc<ComputedValues>,
font_metrics: &FontMetricsProvider)
-> Option<ComputedStyle>
where E: TElement +
fmt::Debug +
PresentationalHintsSynthesizer
where E: TElement,
{
let rule_node = match self.lazy_pseudo_rules(guards, element, pseudo) {
Some(rule_node) => rule_node,
Expand Down Expand Up @@ -525,7 +522,7 @@ impl Stylist {
element: &E,
pseudo: &PseudoElement)
-> Option<StrongRuleNode>
where E: TElement + fmt::Debug + PresentationalHintsSynthesizer
where E: TElement
{
debug_assert!(pseudo.is_lazy());
if self.pseudos_map.get(pseudo).is_none() {
Expand Down Expand Up @@ -686,9 +683,7 @@ impl Stylist {
applicable_declarations: &mut V,
flags_setter: &mut F)
-> StyleRelations
where E: TElement +
fmt::Debug +
PresentationalHintsSynthesizer,
where E: TElement,
V: Push<ApplicableDeclarationBlock> + VecLike<ApplicableDeclarationBlock>,
F: FnMut(&E, ElementSelectorFlags),
{
Expand Down

0 comments on commit 4c9d8d3

Please sign in to comment.