From 4f8095816ee43e99fc131375817033bd75c7288e Mon Sep 17 00:00:00 2001 From: Adam Badawy Date: Tue, 27 Oct 2015 00:33:48 -0400 Subject: Allow any mode larger than requested dimensions We were previously allowing only fullscreen modes which were exactly as tall as the requested dimensions, perhaps erroneously. --- src/api/x11/window.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src') diff --git a/src/api/x11/window.rs b/src/api/x11/window.rs index 7ad2951..c8c0bf7 100644 --- a/src/api/x11/window.rs +++ b/src/api/x11/window.rs @@ -333,7 +333,7 @@ impl Window { } else { let m = (0 .. mode_num).map(|i| { let m: ffi::XF86VidModeModeInfo = ptr::read(*modes.offset(i as isize) as *const _); m - }).find(|m| m.hdisplay >= dimensions.0 as u16 && m.vdisplay == dimensions.1 as u16); + }).find(|m| m.hdisplay >= dimensions.0 as u16 && m.vdisplay >= dimensions.1 as u16); match m { Some(m) => Some(m), -- cgit v1.2.3