From 50b48b744fbe51accf19526a23b071ff43c9a24b Mon Sep 17 00:00:00 2001 From: Jesse Luehrs Date: Sun, 7 Mar 2021 18:07:13 -0500 Subject: a few renames --- examples/tmux.rs | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'examples/tmux.rs') diff --git a/examples/tmux.rs b/examples/tmux.rs index 7f5c748..e5e4fcd 100644 --- a/examples/tmux.rs +++ b/examples/tmux.rs @@ -1,6 +1,6 @@ use pty_process::Command as _; use smol::io::{AsyncReadExt as _, AsyncWriteExt as _}; -use textmode::TextmodeExt as _; +use textmode::Textmode as _; enum Command { NewWindow, @@ -213,7 +213,7 @@ impl State { .detach(); } - async fn redraw_current_window(&mut self, tm: &mut textmode::Textmode) { + async fn redraw_current_window(&mut self, tm: &mut textmode::Output) { let window = self.current_window(); tm.clear(); let new_screen = window.vt.lock_arc().await.screen().clone(); @@ -224,7 +224,7 @@ impl State { tm.refresh().await.unwrap(); } - async fn update_current_window(&mut self, tm: &mut textmode::Textmode) { + async fn update_current_window(&mut self, tm: &mut textmode::Output) { let window = self.current_window(); let old_screen = window.screen.clone(); let new_screen = window.vt.lock_arc().await.screen().clone(); @@ -244,7 +244,7 @@ impl State { fn clear_notifications( &mut self, - tm: &mut textmode::Textmode, + tm: &mut textmode::Output, screen: &vt100::Screen, ) { if self.notifications.is_empty() { @@ -269,7 +269,7 @@ impl State { fn draw_notifications( &mut self, - tm: &mut textmode::Textmode, + tm: &mut textmode::Output, screen: &vt100::Screen, ) { if self.notifications.is_empty() { @@ -310,14 +310,14 @@ impl State { #[must_use] struct Tmux { input: textmode::Input, - tm: textmode::Textmode, + tm: textmode::Output, state: State, } impl Tmux { async fn new() -> Self { let input = textmode::Input::new(); - let tm = textmode::Textmode::new().await.unwrap(); + let tm = textmode::Output::new().await.unwrap(); let state = State::new(); Self { input, tm, state } } -- cgit v1.2.3-54-g00ecf