mirror of
https://github.com/servo/servo.git
synced 2025-06-10 17:43:16 +00:00
Use IpcBytesReceiver to send Display list data
This commit is contained in:
parent
34b3dafab8
commit
2cffbd7527
2 changed files with 28 additions and 20 deletions
|
@ -1123,7 +1123,7 @@ pub enum WebrenderMsg {
|
|||
LayoutSize,
|
||||
webrender_api::PipelineId,
|
||||
LayoutSize,
|
||||
Vec<u8>,
|
||||
ipc::IpcBytesReceiver,
|
||||
BuiltDisplayListDescriptor,
|
||||
),
|
||||
/// Perform a hit test operation. The result will be returned via
|
||||
|
@ -1181,16 +1181,21 @@ impl WebrenderIpcSender {
|
|||
(pipeline, size2, list): (webrender_api::PipelineId, LayoutSize, BuiltDisplayList),
|
||||
) {
|
||||
let (data, descriptor) = list.into_data();
|
||||
let (sender, receiver) = ipc::bytes_channel().unwrap();
|
||||
if let Err(e) = self.0.send(WebrenderMsg::SendDisplayList(
|
||||
webrender_api::Epoch(epoch.0),
|
||||
size,
|
||||
pipeline,
|
||||
size2,
|
||||
data,
|
||||
receiver,
|
||||
descriptor,
|
||||
)) {
|
||||
warn!("Error sending display list: {}", e);
|
||||
}
|
||||
|
||||
if let Err(e) = sender.send(&data) {
|
||||
warn!("Error sending display data: {}", e);
|
||||
}
|
||||
}
|
||||
|
||||
/// Perform a hit test operation. Blocks until the operation is complete and
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue