From 5c79c117a2bdd9e279242fda9b0b85d6655f396d Mon Sep 17 00:00:00 2001 From: Joe Wilm Date: Mon, 4 Jul 2016 09:43:41 -0700 Subject: [PATCH] Fix resizing on macOS terminal.resize was not being called. Additionally, it was being called too much on other platforms (resize events were completely coalesced). --- src/main.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main.rs b/src/main.rs index 0cd1e674..5c52dcda 100644 --- a/src/main.rs +++ b/src/main.rs @@ -240,7 +240,6 @@ fn main() { } }, glutin::Event::Resized(w, h) => { - terminal.resize(w as f32, h as f32); new_size = Some((w, h)); }, glutin::Event::KeyboardInput(state, _code, key) => { @@ -267,6 +266,7 @@ fn main() { // Receive any resize events; only call gl::Viewport on last // available if let Some((w, h)) = new_size.take() { + terminal.resize(w as f32, h as f32); renderer.resize(w as i32, h as i32); }