Struct webrender_traits::CrossProcessCompositorApi

source ·
pub struct CrossProcessCompositorApi(pub IpcSender<CrossProcessCompositorMessage>);
Expand description

A mechanism to send messages from ScriptThread to the parent process’ WebRender instance.

Tuple Fields§

§0: IpcSender<CrossProcessCompositorMessage>

Implementations§

source§

impl CrossProcessCompositorApi

source

pub fn dummy() -> Self

Create a new CrossProcessCompositorApi struct that does not have a listener on the other end to use for unit testing.

source

pub fn sender(&self) -> &IpcSender<CrossProcessCompositorMessage>

Get the sender for this proxy.

source

pub fn send_initial_transaction(&self, pipeline: WebRenderPipelineId)

Inform WebRender of the existence of this pipeline.

source

pub fn send_scroll_node( &self, pipeline_id: WebRenderPipelineId, point: LayoutPoint, scroll_id: ExternalScrollId, )

Perform a scroll operation.

source

pub fn send_display_list( &self, display_list_info: CompositorDisplayListInfo, list: BuiltDisplayList, )

Inform WebRender of a new display list for the given pipeline.

source

pub fn hit_test( &self, pipeline: Option<WebRenderPipelineId>, point: DevicePoint, flags: HitTestFlags, ) -> Vec<CompositorHitTestResult>

Perform a hit test operation. Blocks until the operation is complete and and a result is available.

source

pub fn generate_image_key(&self) -> Option<ImageKey>

Create a new image key. Blocks until the key is available.

source

pub fn add_image( &self, key: ImageKey, descriptor: ImageDescriptor, data: SerializableImageData, )

source

pub fn update_images(&self, updates: Vec<ImageUpdate>)

Perform an image resource update operation.

source

pub fn remove_unused_font_resources( &self, keys: Vec<FontKey>, instance_keys: Vec<FontInstanceKey>, )

source

pub fn add_font_instance( &self, font_instance_key: FontInstanceKey, font_key: FontKey, size: f32, flags: FontInstanceFlags, )

source

pub fn add_font( &self, font_key: FontKey, data: Arc<IpcSharedMemory>, index: u32, )

source

pub fn add_system_font(&self, font_key: FontKey, handle: NativeFontHandle)

source

pub fn fetch_font_keys( &self, number_of_font_keys: usize, number_of_font_instance_keys: usize, ) -> (Vec<FontKey>, Vec<FontInstanceKey>)

Trait Implementations§

source§

impl Clone for CrossProcessCompositorApi

source§

fn clone(&self) -> CrossProcessCompositorApi

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl<'de> Deserialize<'de> for CrossProcessCompositorApi

source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
source§

impl Serialize for CrossProcessCompositorApi

source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T> Same for T

§

type Output = T

Should always be Self
source§

impl<T> ToOwned for T
where T: Clone,

§

type Owned = T

The resulting type after obtaining ownership.
source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
source§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

source§

fn vzip(self) -> V

source§

impl<T> DeserializeOwned for T
where T: for<'de> Deserialize<'de>,

source§

impl<T> ErasedDestructor for T
where T: 'static,

source§

impl<T> MaybeSendSync for T