Skip rendering when backend is inactive

This commit is contained in:
Ivan Molodetskikh
2023-09-26 10:42:56 +04:00
parent ac16717f4e
commit 906ee36a93
3 changed files with 19 additions and 0 deletions
+4
View File
@@ -945,6 +945,10 @@ impl Niri {
fn redraw(&mut self, backend: &mut Backend, output: &Output) {
let _span = tracy_client::span!("Niri::redraw");
if !backend.is_active() {
return;
}
let Some(renderer) = backend.renderer() else {
return;
};