pub struct CompositorDisplayListInfo {
pub pipeline_id: PipelineId,
pub viewport_size: LayoutSize,
pub epoch: Epoch,
pub hit_test_info: Vec<HitTestInfo>,
pub scroll_tree: ScrollTree,
pub root_reference_frame_id: ScrollTreeNodeId,
pub root_scroll_node_id: ScrollTreeNodeId,
}
Expand description
A data structure which stores compositor-side information about display lists sent to the compositor.
Fields§
§pipeline_id: PipelineId
The WebRender PipelineId of this display list.
viewport_size: LayoutSize
The size of the viewport that this display list renders into.
epoch: Epoch
The epoch of the display list.
hit_test_info: Vec<HitTestInfo>
An array of HitTestInfo
which is used to store information
to assist the compositor to take various actions (set the cursor,
scroll without layout) using a WebRender hit test result.
scroll_tree: ScrollTree
A ScrollTree used by the compositor to scroll the contents of the display list.
root_reference_frame_id: ScrollTreeNodeId
The ScrollTreeNodeId
of the root reference frame of this info’s scroll
tree.
root_scroll_node_id: ScrollTreeNodeId
The ScrollTreeNodeId
of the topmost scrolling frame of this info’s scroll
tree.
Implementations§
source§impl CompositorDisplayListInfo
impl CompositorDisplayListInfo
sourcepub fn new(
viewport_size: LayoutSize,
content_size: LayoutSize,
pipeline_id: PipelineId,
epoch: Epoch
) -> Self
pub fn new(
viewport_size: LayoutSize,
content_size: LayoutSize,
pipeline_id: PipelineId,
epoch: Epoch
) -> Self
Create a new CompositorDisplayListInfo with the root reference frame and scroll frame already added to the scroll tree.
sourcepub fn add_hit_test_info(
&mut self,
node: u64,
cursor: Option<Cursor>,
scroll_tree_node: ScrollTreeNodeId
) -> usize
pub fn add_hit_test_info(
&mut self,
node: u64,
cursor: Option<Cursor>,
scroll_tree_node: ScrollTreeNodeId
) -> usize
Add or re-use a duplicate HitTestInfo entry in this CompositorHitTestInfo
and return the index.