mirror of
https://github.com/servo/servo.git
synced 2025-08-06 14:10:11 +01:00
feat(script): add {DissimilarOriginWindow, PaintWorkletGlobalScope, TestWorkletGlobalScope}::origin
This commit is contained in:
parent
bfa2026220
commit
5959c2ef9b
4 changed files with 19 additions and 2 deletions
|
@ -20,7 +20,7 @@ use js::jsval::{JSVal, UndefinedValue};
|
|||
use js::rust::{CustomAutoRooter, CustomAutoRooterGuard, HandleValue};
|
||||
use msg::constellation_msg::PipelineId;
|
||||
use script_traits::{ScriptMsg, StructuredSerializedData};
|
||||
use servo_url::ServoUrl;
|
||||
use servo_url::{MutableOrigin, ServoUrl};
|
||||
|
||||
/// Represents a dissimilar-origin `Window` that exists in another script thread.
|
||||
///
|
||||
|
@ -195,6 +195,10 @@ impl DissimilarOriginWindowMethods for DissimilarOriginWindow {
|
|||
}
|
||||
|
||||
impl DissimilarOriginWindow {
|
||||
pub fn origin(&self) -> &MutableOrigin {
|
||||
self.globalscope.origin()
|
||||
}
|
||||
|
||||
/// https://html.spec.whatwg.org/multipage/#window-post-message-steps
|
||||
fn post_message_impl(
|
||||
&self,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue