mirror of
https://github.com/servo/servo.git
synced 2025-08-05 13:40:08 +01:00
changed to use globalscope origin
This commit is contained in:
parent
3577d1ff94
commit
aa7b4f6162
5 changed files with 19 additions and 21 deletions
|
@ -273,9 +273,6 @@ pub struct Window {
|
|||
/// Directory to store unminified scripts for this window if unminify-js
|
||||
/// opt is enabled.
|
||||
unminified_js_dir: DOMRefCell<Option<String>>,
|
||||
|
||||
/// origin for cross origin wrappers
|
||||
origin: Box<MutableOrigin>
|
||||
}
|
||||
|
||||
impl Window {
|
||||
|
@ -297,10 +294,6 @@ impl Window {
|
|||
self.js_runtime.borrow().as_ref().unwrap().cx()
|
||||
}
|
||||
|
||||
pub fn get_origin(&self) -> Box<MutableOrigin> {
|
||||
self.origin.clone()
|
||||
}
|
||||
|
||||
pub fn dom_manipulation_task_source(&self) -> DOMManipulationTaskSource {
|
||||
self.dom_manipulation_task_source.clone()
|
||||
}
|
||||
|
@ -1818,7 +1811,6 @@ impl Window {
|
|||
suppress_reflow: Cell::new(true),
|
||||
pending_reflow_count: Cell::new(0),
|
||||
current_state: Cell::new(WindowState::Alive),
|
||||
|
||||
devtools_marker_sender: DOMRefCell::new(None),
|
||||
devtools_markers: DOMRefCell::new(HashSet::new()),
|
||||
webdriver_script_chan: DOMRefCell::new(None),
|
||||
|
@ -1831,17 +1823,12 @@ impl Window {
|
|||
permission_state_invocation_results: DOMRefCell::new(HashMap::new()),
|
||||
pending_layout_images: DOMRefCell::new(HashMap::new()),
|
||||
unminified_js_dir: DOMRefCell::new(None),
|
||||
origin: Box::new(origin),
|
||||
};
|
||||
|
||||
unsafe {
|
||||
WindowBinding::Wrap(runtime.cx(), win)
|
||||
}
|
||||
}
|
||||
|
||||
pub fn origin(&self) -> Box<MutableOrigin> {
|
||||
self.origin.clone()
|
||||
}
|
||||
}
|
||||
|
||||
fn should_move_clip_rect(clip_rect: Rect<Au>, new_viewport: Rect<f32>) -> bool {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue