diff options
author | Christian Duerr <chrisduerr@users.noreply.github.com> | 2019-04-14 15:37:58 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-04-14 15:37:58 +0000 |
commit | 5174f9b27488902e7862aeb470aa0f0375c95e46 (patch) | |
tree | bc22c88820e15a0bf1379bbfa371404c9706802b /src/tty | |
parent | aac62ce5acd2ef4d05a54bc13b7cf30c30f129b2 (diff) | |
download | alacritty-5174f9b27488902e7862aeb470aa0f0375c95e46.tar.gz alacritty-5174f9b27488902e7862aeb470aa0f0375c95e46.zip |
Fix duplicate resize events
If a resize event is identical to the current size, it is no longer
propagated but the resize is discarded immediately.
To further prevent resizes when not necessary, the list of monitors is
enumerated and the DPR of the first display is assumed to be the target
DPR.
This allows spawning a window with dimensions when the config has
columns and lines specified and the window only needs to be resized if
the estimated DPR is not correct.
Fixes #1825.
Fixes #204.
Diffstat (limited to 'src/tty')
-rw-r--r-- | src/tty/windows/conpty.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/tty/windows/conpty.rs b/src/tty/windows/conpty.rs index 70ca55fe..45718ed2 100644 --- a/src/tty/windows/conpty.rs +++ b/src/tty/windows/conpty.rs @@ -143,7 +143,7 @@ pub fn new<'a>( let mut startup_info_ex: STARTUPINFOEXW = Default::default(); - let title = options.title.as_ref().map(|w| w.as_str()).unwrap_or("Alacritty"); + let title = options.title.as_ref().map(String::as_str).unwrap_or("Alacritty"); let title = U16CString::from_str(title).unwrap(); startup_info_ex.StartupInfo.lpTitle = title.as_ptr() as LPWSTR; |