aboutsummaryrefslogtreecommitdiff
path: root/helix-term/src
diff options
context:
space:
mode:
Diffstat (limited to 'helix-term/src')
-rw-r--r--helix-term/src/application.rs4
1 files changed, 3 insertions, 1 deletions
diff --git a/helix-term/src/application.rs b/helix-term/src/application.rs
index a7281ecf..82ad04d7 100644
--- a/helix-term/src/application.rs
+++ b/helix-term/src/application.rs
@@ -563,7 +563,9 @@ impl Application {
let mut stdout = stdout();
// reset cursor shape
write!(stdout, "\x1B[2 q")?;
- execute!(stdout, DisableMouseCapture)?;
+ // Ignore errors on disabling, this might trigger on windows if we call
+ // disable without calling enable previously
+ let _ = execute!(stdout, DisableMouseCapture);
execute!(stdout, terminal::LeaveAlternateScreen)?;
terminal::disable_raw_mode()?;
Ok(())