mirror of
https://github.com/servo/servo.git
synced 2025-09-02 11:08:22 +01:00
Bug 1298588 part 9, servo piece. Pass through useful default styles to cascade(). r=bholley
This commit is contained in:
parent
09c74190b9
commit
61f6025dc3
6 changed files with 22 additions and 10 deletions
|
@ -1714,13 +1714,14 @@ bitflags! {
|
|||
pub fn cascade(viewport_size: Size2D<Au>,
|
||||
rule_node: &StrongRuleNode,
|
||||
parent_style: Option<<&ComputedValues>,
|
||||
default_style: &Arc<ComputedValues>,
|
||||
cascade_info: Option<<&mut CascadeInfo>,
|
||||
error_reporter: StdBox<ParseErrorReporter + Send>,
|
||||
flags: CascadeFlags)
|
||||
-> ComputedValues {
|
||||
let (is_root_element, inherited_style) = match parent_style {
|
||||
Some(parent_style) => (false, parent_style),
|
||||
None => (true, ComputedValues::initial_values()),
|
||||
None => (true, &**default_style),
|
||||
};
|
||||
// Hold locks until after the apply_declarations() call returns.
|
||||
// Use filter_map because the root node has no style source.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue