Revert "feat(script): add {DissimilarOriginWindow, PaintWorkletGlobalScope, TestWorkletGlobalScope}::origin"

This reverts commit 5959c2ef9b.
This commit is contained in:
yvt 2021-07-13 21:12:44 +09:00
parent c3de9b72a6
commit 90b78a193c
4 changed files with 2 additions and 19 deletions

View file

@ -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::{MutableOrigin, ServoUrl};
use servo_url::ServoUrl;
/// Represents a dissimilar-origin `Window` that exists in another script thread.
///
@ -194,10 +194,6 @@ 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,

View file

@ -52,7 +52,6 @@ use script_traits::Painter;
use script_traits::{DrawAPaintImageResult, PaintWorkletError};
use servo_atoms::Atom;
use servo_config::pref;
use servo_url::MutableOrigin;
use servo_url::ServoUrl;
use std::cell::Cell;
use std::collections::hash_map::Entry;
@ -137,10 +136,6 @@ impl PaintWorkletGlobalScope {
self.image_cache.clone()
}
pub fn origin(&self) -> &MutableOrigin {
self.worklet_global.origin()
}
pub fn perform_a_worklet_task(&self, task: PaintWorkletTask) {
match task {
PaintWorkletTask::DrawAPaintImage(

View file

@ -15,7 +15,7 @@ use crossbeam_channel::Sender;
use dom_struct::dom_struct;
use js::rust::Runtime;
use msg::constellation_msg::PipelineId;
use servo_url::{MutableOrigin, ServoUrl};
use servo_url::ServoUrl;
use std::collections::HashMap;
// check-tidy: no specs after this line
@ -53,10 +53,6 @@ impl TestWorkletGlobalScope {
unsafe { TestWorkletGlobalScopeBinding::Wrap(JSContext::from_ptr(runtime.cx()), global) }
}
pub fn origin(&self) -> &MutableOrigin {
self.worklet_global.origin()
}
pub fn perform_a_worklet_task(&self, task: TestWorkletTask) {
match task {
TestWorkletTask::Lookup(key, sender) => {

View file

@ -84,10 +84,6 @@ impl WorkletGlobalScope {
}
}
pub fn origin(&self) -> &MutableOrigin {
self.globalscope.origin()
}
/// Get the JS context.
pub fn get_cx(&self) -> JSContext {
self.globalscope.get_cx()