Pass the event loop waker into WebXR

This commit is contained in:
Alan Jeffrey 2019-07-24 13:48:25 -05:00
parent c9dde3a4bb
commit 701256d837
9 changed files with 17 additions and 19 deletions

View file

@ -21,6 +21,8 @@ use servo_url::ServoUrl;
use std::fmt::{Debug, Error, Formatter};
use webrender_api::units::{DeviceIntPoint, DeviceIntSize};
pub use webxr_api::MainThreadWaker as EventLoopWaker;
/// A cursor for the window. This is different from a CSS cursor (see
/// `CursorKind`) in that it has no `Auto` value.
#[repr(u8)]
@ -63,12 +65,6 @@ pub enum Cursor {
ZoomOut,
}
/// Used to wake up the event loop, provided by the servo port/embedder.
pub trait EventLoopWaker: 'static + Send {
fn clone(&self) -> Box<dyn EventLoopWaker + Send>;
fn wake(&self);
}
/// Sends messages to the embedder.
pub struct EmbedderProxy {
pub sender: Sender<(Option<TopLevelBrowsingContextId>, EmbedderMsg)>,