Introduce Reflectable::global_scope

This commit is contained in:
Anthony Ramine 2016-10-01 18:15:15 +02:00
parent 27f100b1d4
commit ae6af5172b
30 changed files with 116 additions and 120 deletions

View file

@ -90,8 +90,7 @@ impl ServiceWorkerMethods for ServiceWorker {
let data = try!(StructuredCloneData::write(cx, message));
let msg_vec = DOMMessage(data.move_to_arraybuffer());
let _ =
self.global().r()
.as_global_scope()
self.global_scope()
.constellation_chan()
.send(ScriptMsg::ForwardDOMMessage(msg_vec, self.scope_url.clone()));
Ok(())