diff --git a/src/raw.rs b/src/raw.rs index 6cd673d..2bf96e7 100644 --- a/src/raw.rs +++ b/src/raw.rs @@ -13,8 +13,7 @@ pub struct RawTerminal { #[cfg(target_os = "redox")] impl Drop for RawTerminal { fn drop(&mut self) { - use control::TermWrite; - self.csi(b"R").unwrap(); + write!(self, csi!("?82h")).unwrap(); } } @@ -98,11 +97,8 @@ impl IntoRawMode for W { #[cfg(target_os = "redox")] fn into_raw_mode(mut self) -> io::Result> { - use control::TermWrite; - - self.csi(b"r").map(|_| { - let mut res = RawTerminal { output: self }; - res + write!(self, csi!("?82h")).map(|_| { + RawTerminal { output: self } }) } }