aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorJesse Luehrs <doy@tozt.net>2021-03-06 18:56:18 -0500
committerJesse Luehrs <doy@tozt.net>2021-03-06 18:56:18 -0500
commitbd3c150d9276ffeee8cd9356ba91ad7f5b7fc180 (patch)
tree96bbb8070326d8fb6ee9ae9105c28960797b350b /src
parenta4bca446049fd488af29dd5ec26f953845e8e4fe (diff)
downloadtextmode-bd3c150d9276ffeee8cd9356ba91ad7f5b7fc180.tar.gz
textmode-bd3c150d9276ffeee8cd9356ba91ad7f5b7fc180.zip
rename a bit
Diffstat (limited to 'src')
-rw-r--r--src/async.rs2
-rw-r--r--src/blocking.rs (renamed from src/sync.rs)2
-rw-r--r--src/lib.rs7
3 files changed, 7 insertions, 4 deletions
diff --git a/src/async.rs b/src/async.rs
index a384da8..86f4bdb 100644
--- a/src/async.rs
+++ b/src/async.rs
@@ -25,7 +25,7 @@ impl super::private::TextmodeImpl for Textmode {
}
}
-impl super::Textmode for Textmode {}
+impl super::TextmodeExt for Textmode {}
impl Textmode {
pub async fn new() -> std::io::Result<Self> {
diff --git a/src/sync.rs b/src/blocking.rs
index 047036d..c06e0a3 100644
--- a/src/sync.rs
+++ b/src/blocking.rs
@@ -25,7 +25,7 @@ impl super::private::TextmodeImpl for Textmode {
}
}
-impl super::Textmode for Textmode {}
+impl super::TextmodeExt for Textmode {}
impl Textmode {
pub fn new() -> std::io::Result<Self> {
diff --git a/src/lib.rs b/src/lib.rs
index fcee1e9..4b09880 100644
--- a/src/lib.rs
+++ b/src/lib.rs
@@ -1,8 +1,11 @@
pub mod color;
+pub mod blocking;
+
#[cfg(feature = "async")]
pub mod r#async;
-pub mod sync;
+#[cfg(feature = "async")]
+pub use r#async::Textmode;
mod private {
pub trait TextmodeImpl {
@@ -23,7 +26,7 @@ mod private {
}
}
-pub trait Textmode: private::TextmodeImpl {
+pub trait TextmodeExt: private::TextmodeImpl {
fn cursor_position(&self) -> (u16, u16) {
self.next().screen().cursor_position()
}