Revert "Send IPC receiver for canvas as part of CreateCanvasPaintThread message"

This reverts commit a504c9358b.
This commit is contained in:
Josh Matthews 2017-12-18 10:51:00 -05:00
parent 3a37d80931
commit 0e211d0d8f
4 changed files with 18 additions and 13 deletions

View file

@ -129,10 +129,11 @@ impl CanvasRenderingContext2D {
size: Size2D<i32>)
-> CanvasRenderingContext2D {
debug!("Creating new canvas rendering context.");
let (ipc_renderer, receiver) = ipc::channel::<CanvasMsg>().unwrap();
let (sender, receiver) = ipc::channel().unwrap();
let script_to_constellation_chan = global.script_to_constellation_chan();
debug!("Asking constellation to create new canvas thread.");
script_to_constellation_chan.send(ScriptMsg::CreateCanvasPaintThread(size, receiver)).unwrap();
script_to_constellation_chan.send(ScriptMsg::CreateCanvasPaintThread(size, sender)).unwrap();
let ipc_renderer = receiver.recv().unwrap();
debug!("Done.");
CanvasRenderingContext2D {
reflector_: Reflector::new(),