mirror of
https://github.com/servo/servo.git
synced 2025-08-04 13:10:20 +01:00
Make RenderListener::paint take multiple replies
This commit is contained in:
parent
a832acc4c8
commit
340d9caba5
3 changed files with 8 additions and 10 deletions
|
@ -96,10 +96,11 @@ impl RenderListener for CompositorChan {
|
||||||
|
|
||||||
fn paint(&self,
|
fn paint(&self,
|
||||||
pipeline_id: PipelineId,
|
pipeline_id: PipelineId,
|
||||||
layer_id: LayerId,
|
epoch: Epoch,
|
||||||
layer_buffer_set: Box<LayerBufferSet>,
|
replies: Vec<(LayerId, Box<LayerBufferSet>)>) {
|
||||||
epoch: Epoch) {
|
for (layer_id, layer_buffer_set) in replies.move_iter() {
|
||||||
self.chan.send(Paint(pipeline_id, layer_id, layer_buffer_set, epoch))
|
self.chan.send(Paint(pipeline_id, layer_id, layer_buffer_set, epoch))
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
fn initialize_layers_for_pipeline(&self,
|
fn initialize_layers_for_pipeline(&self,
|
||||||
|
|
|
@ -256,9 +256,7 @@ impl<C:RenderListener + Send> RenderTask<C> {
|
||||||
}
|
}
|
||||||
|
|
||||||
debug!("render_task: returning surfaces");
|
debug!("render_task: returning surfaces");
|
||||||
for (layer_id, layer_buffer_set) in replies.move_iter() {
|
self.compositor.paint(self.id, self.epoch, replies);
|
||||||
self.compositor.paint(self.id, layer_id, layer_buffer_set, self.epoch);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
UnusedBufferMsg(unused_buffers) => {
|
UnusedBufferMsg(unused_buffers) => {
|
||||||
for buffer in unused_buffers.move_iter().rev() {
|
for buffer in unused_buffers.move_iter().rev() {
|
||||||
|
|
|
@ -102,9 +102,8 @@ pub trait RenderListener {
|
||||||
/// Sends new tiles for the given layer to the compositor.
|
/// Sends new tiles for the given layer to the compositor.
|
||||||
fn paint(&self,
|
fn paint(&self,
|
||||||
pipeline_id: PipelineId,
|
pipeline_id: PipelineId,
|
||||||
layer_id: LayerId,
|
epoch: Epoch,
|
||||||
layer_buffer_set: Box<LayerBufferSet>,
|
replies: Vec<(LayerId, Box<LayerBufferSet>)>);
|
||||||
epoch: Epoch);
|
|
||||||
|
|
||||||
fn set_render_state(&self, render_state: RenderState);
|
fn set_render_state(&self, render_state: RenderState);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue