Trait style::matching::PrivateMatchMethods

source ·
trait PrivateMatchMethods: TElement {
    // Provided methods
    fn replace_single_rule_node(
        context: &SharedStyleContext<'_>,
        level: CascadeLevel,
        layer_order: LayerOrder,
        pdb: Option<ArcBorrow<'_, Locked<PropertyDeclarationBlock>>>,
        path: &mut StrongRuleNode,
    ) -> bool { ... }
    fn replace_rules_internal(
        &self,
        replacements: RestyleHint,
        context: &mut StyleContext<'_, Self>,
        cascade_visited: CascadeVisitedMode,
        cascade_inputs: &mut ElementCascadeInputs,
    ) -> bool { ... }
    fn after_change_style(
        &self,
        context: &mut StyleContext<'_, Self>,
        primary_style: &Arc<ComputedValues>,
    ) -> Option<Arc<ComputedValues>> { ... }
    fn needs_animations_update(
        &self,
        context: &mut StyleContext<'_, Self>,
        old_style: Option<&ComputedValues>,
        new_style: &ComputedValues,
        pseudo_element: Option<PseudoElement>,
    ) -> bool { ... }
    fn might_need_transitions_update(
        &self,
        context: &StyleContext<'_, Self>,
        old_style: Option<&ComputedValues>,
        new_style: &ComputedValues,
        pseudo_element: Option<PseudoElement>,
    ) -> bool { ... }
    fn process_animations(
        &self,
        context: &mut StyleContext<'_, Self>,
        old_styles: &mut ElementStyles,
        new_resolved_styles: &mut ResolvedElementStyles,
        _restyle_hint: RestyleHint,
        _important_rules_changed: bool,
    ) { ... }
    fn process_animations_for_pseudo(
        &self,
        context: &mut StyleContext<'_, Self>,
        old_styles: &mut ElementStyles,
        new_resolved_styles: &mut ResolvedElementStyles,
        pseudo_element: PseudoElement,
    ) { ... }
    fn process_animations_for_style(
        &self,
        context: &mut StyleContext<'_, Self>,
        old_values: &mut Option<Arc<ComputedValues>>,
        new_values: &mut Arc<ComputedValues>,
        pseudo_element: Option<PseudoElement>,
    ) -> bool { ... }
    fn accumulate_damage_for(
        &self,
        shared_context: &SharedStyleContext<'_>,
        damage: &mut RestyleDamage,
        old_values: &ComputedValues,
        new_values: &ComputedValues,
        pseudo: Option<&PseudoElement>,
    ) -> ChildRestyleRequirement { ... }
}

Provided Methods§

source

fn replace_single_rule_node( context: &SharedStyleContext<'_>, level: CascadeLevel, layer_order: LayerOrder, pdb: Option<ArcBorrow<'_, Locked<PropertyDeclarationBlock>>>, path: &mut StrongRuleNode, ) -> bool

source

fn replace_rules_internal( &self, replacements: RestyleHint, context: &mut StyleContext<'_, Self>, cascade_visited: CascadeVisitedMode, cascade_inputs: &mut ElementCascadeInputs, ) -> bool

Updates the rule nodes without re-running selector matching, using just the rule tree, for a specific visited mode.

Returns true if an !important rule was replaced.

source

fn after_change_style( &self, context: &mut StyleContext<'_, Self>, primary_style: &Arc<ComputedValues>, ) -> Option<Arc<ComputedValues>>

If there is no transition rule in the ComputedValues, it returns None.

source

fn needs_animations_update( &self, context: &mut StyleContext<'_, Self>, old_style: Option<&ComputedValues>, new_style: &ComputedValues, pseudo_element: Option<PseudoElement>, ) -> bool

source

fn might_need_transitions_update( &self, context: &StyleContext<'_, Self>, old_style: Option<&ComputedValues>, new_style: &ComputedValues, pseudo_element: Option<PseudoElement>, ) -> bool

source

fn process_animations( &self, context: &mut StyleContext<'_, Self>, old_styles: &mut ElementStyles, new_resolved_styles: &mut ResolvedElementStyles, _restyle_hint: RestyleHint, _important_rules_changed: bool, )

source

fn process_animations_for_pseudo( &self, context: &mut StyleContext<'_, Self>, old_styles: &mut ElementStyles, new_resolved_styles: &mut ResolvedElementStyles, pseudo_element: PseudoElement, )

source

fn process_animations_for_style( &self, context: &mut StyleContext<'_, Self>, old_values: &mut Option<Arc<ComputedValues>>, new_values: &mut Arc<ComputedValues>, pseudo_element: Option<PseudoElement>, ) -> bool

source

fn accumulate_damage_for( &self, shared_context: &SharedStyleContext<'_>, damage: &mut RestyleDamage, old_values: &ComputedValues, new_values: &ComputedValues, pseudo: Option<&PseudoElement>, ) -> ChildRestyleRequirement

Computes and applies non-redundant damage.

Object Safety§

This trait is not object safe.

Implementors§