Do not share entire FrameRenderer with layout, only current frame

This commit is contained in:
Fernando Jiménez Moreno 2018-08-31 17:41:23 +02:00
parent 1f406ef0a0
commit 8c40ef459b
8 changed files with 102 additions and 149 deletions

View file

@ -172,12 +172,6 @@ pub struct PendingImage {
pub id: PendingImageId,
}
/// FIXME(victor): probably this doesn't belong here
pub trait HTMLMediaFrameSource: Send + Sync + 'static {
fn get_current_frame(&self) -> Option<(webrender_api::ImageKey, i32, i32)>;
fn clone_boxed(&self) -> Box<HTMLMediaFrameSource>;
}
pub struct HTMLMediaData {
pub frame_source: Box<HTMLMediaFrameSource>,
pub current_frame: Option<(webrender_api::ImageKey, i32, i32)>,
}