aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKirill Chibisov <contact@kchibisov.com>2022-02-11 02:04:50 +0300
committerGitHub <noreply@github.com>2022-02-11 02:04:50 +0300
commit774eb03f4ff01f692f645d930da54990bf92d19c (patch)
tree8d99601fff7e45975f8b288ff236614e54f83fbd
parent933030efd45016e5a357ff6a271d38ee423e9395 (diff)
downloadalacritty-774eb03f4ff01f692f645d930da54990bf92d19c.tar.gz
alacritty-774eb03f4ff01f692f645d930da54990bf92d19c.zip
Clear damage rects right after drawing
Since we could queue damage before we get into the actual rendering we should clear it after drawing not before.
-rw-r--r--alacritty/src/display/mod.rs3
1 files changed, 2 insertions, 1 deletions
diff --git a/alacritty/src/display/mod.rs b/alacritty/src/display/mod.rs
index 7a694278..ef4cfc10 100644
--- a/alacritty/src/display/mod.rs
+++ b/alacritty/src/display/mod.rs
@@ -573,7 +573,6 @@ impl Display {
let vi_mode_cursor = if vi_mode { Some(terminal.vi_mode_cursor) } else { None };
if self.collect_damage() {
- self.damage_rects.clear();
self.update_damage(&mut terminal, selection_range, search_state);
}
@@ -740,6 +739,8 @@ impl Display {
api.finish();
});
}
+
+ self.damage_rects.clear();
}
/// Update to a new configuration.