diff options
author | Glenn Watson <github@intuitionlibrary.com> | 2018-01-19 15:55:52 +1000 |
---|---|---|
committer | Glenn Watson <github@intuitionlibrary.com> | 2018-01-19 15:55:52 +1000 |
commit | 800a66fc114c5724436a8c490bdaaf4d026f4794 (patch) | |
tree | e74c896d33afa6bea08293318f0755b0f80c745c /components/canvas/webgl_thread.rs | |
parent | 671b69c0b77f9a4bd0c098cb2a2f73c95dacb954 (diff) | |
download | servo-800a66fc114c5724436a8c490bdaaf4d026f4794.tar.gz servo-800a66fc114c5724436a8c490bdaaf4d026f4794.zip |
Update WR (minimal use of new transaction API).
Diffstat (limited to 'components/canvas/webgl_thread.rs')
-rw-r--r-- | components/canvas/webgl_thread.rs | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/components/canvas/webgl_thread.rs b/components/canvas/webgl_thread.rs index e03021761be..730071421d9 100644 --- a/components/canvas/webgl_thread.rs +++ b/components/canvas/webgl_thread.rs @@ -353,7 +353,9 @@ impl<VR: WebVRRenderHandler + 'static, OB: WebGLThreadObserver> WebGLThread<VR, self.dom_outputs.insert(pipeline_id, DOMToTextureData { context_id, texture_id, document_id, size }); - self.webrender_api.enable_frame_output(document_id, pipeline_id, true); + let mut txn = webrender_api::Transaction::new(); + txn.enable_frame_output(pipeline_id, true); + self.webrender_api.send_transaction(document_id, txn); }, DOMToTextureCommand::Lock(pipeline_id, gl_sync, sender) => { let contexts = &self.contexts; @@ -376,7 +378,9 @@ impl<VR: WebVRRenderHandler + 'static, OB: WebGLThreadObserver> WebGLThread<VR, if let Some((pipeline_id, document_id)) = self.dom_outputs.iter() .find(|&(_, v)| v.texture_id == texture_id) .map(|(k, v)| (*k, v.document_id)) { - self.webrender_api.enable_frame_output(document_id, pipeline_id, false); + let mut txn = webrender_api::Transaction::new(); + txn.enable_frame_output(pipeline_id, false); + self.webrender_api.send_transaction(document_id, txn); self.dom_outputs.remove(&pipeline_id); } }, |