aboutsummaryrefslogtreecommitdiffstats
path: root/components/layout/layout_thread.rs
diff options
context:
space:
mode:
authorMs2ger <Ms2ger@gmail.com>2016-06-15 00:16:49 +0100
committerMs2ger <Ms2ger@gmail.com>2016-06-20 19:02:39 +0200
commitbea96f60e322dae5262c4024a0b3d65f469b2979 (patch)
treeac3e4d834647e6278c3b04d621b162f13cdb86ab /components/layout/layout_thread.rs
parent6aaf3e6a0153725c2c458b791cc18c72c1e46115 (diff)
downloadservo-bea96f60e322dae5262c4024a0b3d65f469b2979.tar.gz
servo-bea96f60e322dae5262c4024a0b3d65f469b2979.zip
Introduce PartialStyleAndLayoutData.
Diffstat (limited to 'components/layout/layout_thread.rs')
-rw-r--r--components/layout/layout_thread.rs5
1 files changed, 3 insertions, 2 deletions
diff --git a/components/layout/layout_thread.rs b/components/layout/layout_thread.rs
index d0c27743667..64d37f889d4 100644
--- a/components/layout/layout_thread.rs
+++ b/components/layout/layout_thread.rs
@@ -49,13 +49,14 @@ use query::{process_node_overflow_request, process_resolved_style_request, proce
use script::layout_interface::{LayoutRPC, OffsetParentResponse, NodeOverflowResponse, MarginStyleResponse};
use script::layout_interface::{Msg, NewLayoutThreadInfo, Reflow, ReflowQueryType, ScriptReflow};
use script::reporter::CSSErrorReporter;
-use script_layout_interface::OpaqueStyleAndLayoutData;
use script_layout_interface::restyle_damage::{REPAINT, STORE_OVERFLOW, REFLOW_OUT_OF_FLOW, REFLOW};
+use script_layout_interface::{OpaqueStyleAndLayoutData, PartialStyleAndLayoutData};
use script_traits::{ConstellationControlMsg, LayoutControlMsg, LayoutMsg as ConstellationMsg};
use script_traits::{StackingContextScrollState, UntrustedNodeAddress};
use sequential;
use serde_json;
use std::borrow::ToOwned;
+use std::cell::RefCell;
use std::collections::HashMap;
use std::hash::BuildHasherDefault;
use std::ops::{Deref, DerefMut};
@@ -1480,7 +1481,7 @@ impl LayoutThread {
/// Handles a message to destroy layout data. Layout data must be destroyed on *this* thread
/// because the struct type is transmuted to a different type on the script side.
unsafe fn handle_reap_style_and_layout_data(&self, data: OpaqueStyleAndLayoutData) {
- let ptr: *mut () = *data.ptr;
+ let ptr: *mut RefCell<PartialStyleAndLayoutData> = *data.ptr;
let non_opaque: NonOpaqueStyleAndLayoutData = ptr as *mut _;
let _ = Box::from_raw(non_opaque);
}