mirror of
https://github.com/hexedtech/codemp.git
synced 2024-11-22 15:24:48 +01:00
chore: moved tools into ext
This commit is contained in:
parent
9c6036da56
commit
781a130c62
4 changed files with 12 additions and 4 deletions
|
@ -12,7 +12,7 @@ use crate::api::Controller;
|
|||
|
||||
use crate::api::TextChange;
|
||||
|
||||
use super::tools::InternallyMutable;
|
||||
use crate::ext::InternallyMutable;
|
||||
|
||||
/// the buffer controller implementation
|
||||
///
|
||||
|
|
|
@ -9,9 +9,6 @@
|
|||
/// buffer controller implementation
|
||||
pub mod controller;
|
||||
|
||||
/// assorted helpers to handle buffer controllers
|
||||
pub mod tools;
|
||||
|
||||
pub(crate) mod worker;
|
||||
|
||||
pub use controller::BufferController as Controller;
|
||||
|
|
|
@ -81,3 +81,11 @@ impl<T: Clone> InternallyMutable<T> {
|
|||
self.getter.borrow().clone()
|
||||
}
|
||||
}
|
||||
|
||||
pub(crate) struct CallbackHandleWatch<T>(pub(crate) tokio::sync::watch::Sender<Option<T>>);
|
||||
|
||||
impl<T> crate::api::controller::CallbackHandle for CallbackHandleWatch<T> {
|
||||
fn unregister(self) {
|
||||
self.0.send_replace(None);
|
||||
}
|
||||
}
|
|
@ -140,6 +140,9 @@ pub mod prelude;
|
|||
/// language-specific ffi "glue"
|
||||
pub mod ffi;
|
||||
|
||||
/// common utils used in this library and re-exposed
|
||||
pub mod ext;
|
||||
|
||||
/// underlying OperationalTransform library used, re-exported
|
||||
pub use woot;
|
||||
|
||||
|
|
Loading…
Reference in a new issue