diff options
author | Christian Duerr <chrisduerr@users.noreply.github.com> | 2019-07-10 21:17:20 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-07-10 21:17:20 +0000 |
commit | c4d2725e14ca9488b1b086024bf827c66945ae7b (patch) | |
tree | d8fd69f06671b30aa2df5c9bd5a0d161fabcfbc9 /alacritty_terminal/src/grid/mod.rs | |
parent | a99547cc6dc1d752b29de785f969591c1ed74782 (diff) | |
download | alacritty-c4d2725e14ca9488b1b086024bf827c66945ae7b.tar.gz alacritty-c4d2725e14ca9488b1b086024bf827c66945ae7b.zip |
Fix row occ not set during new and reset
Since ref tests were only stored whenever winit requested the window
close, they would not get stored properly when the terminal was closed
through Alacritty using `exit`, Ctrl+D or similar.
This moves the ref test code to the and of the main entry point, which
will always be executed regardless of how the terminal was shutdown.
Fixes #2613.
Diffstat (limited to 'alacritty_terminal/src/grid/mod.rs')
-rw-r--r-- | alacritty_terminal/src/grid/mod.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/alacritty_terminal/src/grid/mod.rs b/alacritty_terminal/src/grid/mod.rs index 792dd844..1925a6f4 100644 --- a/alacritty_terminal/src/grid/mod.rs +++ b/alacritty_terminal/src/grid/mod.rs @@ -565,7 +565,7 @@ impl<T> Grid<T> { /// This is used only for initializing after loading ref-tests pub fn initialize_all(&mut self, template: &T) where - T: Copy, + T: Copy + GridCell, { let history_size = self.raw.len().saturating_sub(*self.lines); self.raw.initialize(self.max_scroll_limit - history_size, Row::new(self.cols, template)); |