mirror of
https://github.com/servo/servo.git
synced 2025-08-04 13:10:20 +01:00
layout: add HTMLMediaFrameSource trait and HTMLMediaData struct
This commit is contained in:
parent
6e3c2fe41a
commit
623229dd8a
1 changed files with 11 additions and 0 deletions
|
@ -115,6 +115,7 @@ pub enum LayoutElementType {
|
||||||
HTMLIFrameElement,
|
HTMLIFrameElement,
|
||||||
HTMLImageElement,
|
HTMLImageElement,
|
||||||
HTMLInputElement,
|
HTMLInputElement,
|
||||||
|
HTMLMediaElement,
|
||||||
HTMLObjectElement,
|
HTMLObjectElement,
|
||||||
HTMLParagraphElement,
|
HTMLParagraphElement,
|
||||||
HTMLTableCellElement,
|
HTMLTableCellElement,
|
||||||
|
@ -170,3 +171,13 @@ pub struct PendingImage {
|
||||||
pub node: UntrustedNodeAddress,
|
pub node: UntrustedNodeAddress,
|
||||||
pub id: PendingImageId,
|
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>,
|
||||||
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue