With WebRender, only send resize events when window size is valid.

Fixes WR 116.
This commit is contained in:
Glenn Watson 2016-03-01 09:26:31 +10:00
parent 872ee19534
commit 78b284cefe

View file

@ -353,12 +353,13 @@ impl webrender_traits::RenderNotifier for RenderNotifier {
pipeline_id: webrender_traits::PipelineId, pipeline_id: webrender_traits::PipelineId,
size: Option<Size2D<f32>>) { size: Option<Size2D<f32>>) {
let pipeline_id = pipeline_id.from_webrender(); let pipeline_id = pipeline_id.from_webrender();
let size = size.unwrap_or(Size2D::zero());
if let Some(size) = size {
self.constellation_chan.send(ConstellationMsg::FrameSize(pipeline_id, self.constellation_chan.send(ConstellationMsg::FrameSize(pipeline_id,
size)).unwrap(); size)).unwrap();
} }
} }
}
impl<Window: WindowMethods> IOCompositor<Window> { impl<Window: WindowMethods> IOCompositor<Window> {
fn new(window: Rc<Window>, state: InitialCompositorState) fn new(window: Rc<Window>, state: InitialCompositorState)