mirror of
https://github.com/servo/servo.git
synced 2025-10-01 00:59:15 +01:00
Auto merge of #7925 - Ms2ger:iframe-pipeline-layout, r=glennw
Implement HTMLIFrameElement::pipeline_id on LayoutJS<HTMLIFrameElement>. <!-- Reviewable:start --> [<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/7925) <!-- Reviewable:end -->
This commit is contained in:
commit
12139f73ef
2 changed files with 14 additions and 4 deletions
|
@ -1014,10 +1014,11 @@ impl<'ln> ThreadSafeLayoutNode<'ln> {
|
|||
/// If this node is an iframe element, returns its pipeline ID. If this node is
|
||||
/// not an iframe element, fails.
|
||||
pub fn iframe_pipeline_id(&self) -> PipelineId {
|
||||
use script::dom::htmliframeelement::HTMLIFrameElementLayoutMethods;
|
||||
unsafe {
|
||||
let iframe_element = HTMLIFrameElementCast::to_layout_js(self.get_jsmanaged())
|
||||
.expect("not an iframe element!");
|
||||
(*iframe_element.unsafe_get()).pipeline_id().unwrap()
|
||||
iframe_element.pipeline_id().unwrap()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue