mirror of
https://github.com/servo/servo.git
synced 2025-08-06 14:10:11 +01:00
Stop using Ref::map for style().
It's not possible to implement a Ref::map equivalent method on AtomicRefCell while having AtomicRefCell implemented on top of RwArc. We could potentially reimplement AtomicRefCell to be more like RefCell and add a Ref::map equivalent method, but I (and pcwalton) think we should try just cloning a few extra Arcs at these callsites instead. MozReview-Commit-ID: 6H8vAWguO3z
This commit is contained in:
parent
518324cff6
commit
18d552a1e9
5 changed files with 20 additions and 28 deletions
|
@ -1272,7 +1272,7 @@ impl<'a> ImmutableFlowUtils for &'a Flow {
|
|||
/// as it's harder to understand.
|
||||
fn generate_missing_child_flow<N: ThreadSafeLayoutNode>(self, node: &N, ctx: &LayoutContext) -> FlowRef {
|
||||
let style_context = ctx.style_context();
|
||||
let mut style = node.style(style_context).clone();
|
||||
let mut style = node.style(style_context);
|
||||
match self.class() {
|
||||
FlowClass::Table | FlowClass::TableRowGroup => {
|
||||
properties::modify_style_for_anonymous_table_object(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue