Expose WebGL-related interfaces only in Window

This commit is contained in:
Anthony Ramine 2016-11-27 13:29:22 +01:00
parent 6210bede8b
commit 8af2327e95
26 changed files with 82 additions and 67 deletions

View file

@ -2426,7 +2426,7 @@ impl DocumentMethods for Document {
)
)),
"webglcontextevent" =>
Ok(Root::upcast(WebGLContextEvent::new_uninitialized(self.window.upcast()))),
Ok(Root::upcast(WebGLContextEvent::new_uninitialized(&self.window))),
"storageevent" => {
let USVString(url) = self.URL();
Ok(Root::upcast(StorageEvent::new_uninitialized(&self.window, DOMString::from(url))))