mirror of
https://github.com/servo/servo.git
synced 2025-08-24 14:48:21 +01:00
style: Add a StyleBuilder struct to avoid refcount and atomic CAS during the cascade.
This should fix most of the complaints that caused https://bugzilla.mozilla.org/show_bug.cgi?id=1360889 to be open, and also fix a bunch of other FIXMEs across the style system.
This commit is contained in:
parent
caa66a880a
commit
3b857f1c4e
11 changed files with 279 additions and 120 deletions
|
@ -8,7 +8,7 @@ use std::f32::consts::PI;
|
|||
use style::context::QuirksMode;
|
||||
use style::font_metrics::ServoMetricsProvider;
|
||||
use style::media_queries::{Device, MediaType};
|
||||
use style::properties::ComputedValues;
|
||||
use style::properties::{ComputedValues, StyleBuilder};
|
||||
use style::values::computed;
|
||||
use style::values::computed::{Angle, Context, ToComputedValue};
|
||||
use style::values::specified;
|
||||
|
@ -49,7 +49,8 @@ fn test_linear_gradient() {
|
|||
device: &device,
|
||||
inherited_style: initial_style,
|
||||
layout_parent_style: initial_style,
|
||||
style: initial_style.clone(),
|
||||
style: StyleBuilder::for_derived_style(&initial_style),
|
||||
cached_system_font: None,
|
||||
font_metrics_provider: &ServoMetricsProvider,
|
||||
in_media_query: false,
|
||||
quirks_mode: QuirksMode::NoQuirks,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue