mirror of
https://github.com/servo/servo.git
synced 2025-08-06 14:10:11 +01:00
Support window.parent in the one-window case.
This commit is contained in:
parent
1f04ce807d
commit
881e4fcd6e
2 changed files with 6 additions and 0 deletions
|
@ -34,6 +34,7 @@
|
|||
//[Unforgeable] readonly attribute WindowProxy top;
|
||||
// attribute any opener;
|
||||
//readonly attribute WindowProxy parent;
|
||||
readonly attribute Window parent;
|
||||
//readonly attribute Element? frameElement;
|
||||
//WindowProxy open(optional DOMString url = "about:blank", optional DOMString target = "_blank", optional DOMString features = "", optional boolean replace = false);
|
||||
//getter WindowProxy (unsigned long index);
|
||||
|
|
|
@ -191,6 +191,11 @@ impl<'a> WindowMethods for JSRef<'a, Window> {
|
|||
self.Window()
|
||||
}
|
||||
|
||||
fn Parent(&self) -> Temporary<Window> {
|
||||
//TODO - Once we support iframes correctly this needs to return the parent frame
|
||||
self.Window()
|
||||
}
|
||||
|
||||
fn Performance(&self) -> Temporary<Performance> {
|
||||
if self.performance.get().is_none() {
|
||||
let performance = Performance::new(self);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue