2025-02-24 23:18:38 -06:00
|
|
|
use crate::cxx::ffi;
|
|
|
|
|
use cxx::UniquePtr;
|
|
|
|
|
|
|
|
|
|
pub struct Module {
|
|
|
|
|
module: UniquePtr<ffi::Module>,
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
impl Module {
|
|
|
|
|
pub fn new(module: UniquePtr<ffi::Module>) -> Self {
|
|
|
|
|
Self { module: module }
|
|
|
|
|
}
|
|
|
|
|
|
2025-02-25 15:36:58 -06:00
|
|
|
pub fn decrement(&mut self) {
|
|
|
|
|
self.module.pin_mut().decrement();
|
|
|
|
|
}
|
|
|
|
|
|
2025-02-24 23:18:38 -06:00
|
|
|
pub fn get_name(&self) -> String {
|
|
|
|
|
self.module.get_name()
|
|
|
|
|
}
|
|
|
|
|
|
2025-02-25 15:36:58 -06:00
|
|
|
pub fn increment(&mut self) {
|
|
|
|
|
self.module.pin_mut().increment();
|
|
|
|
|
}
|
|
|
|
|
|
2025-02-25 15:45:58 -06:00
|
|
|
pub fn is_skip_consecutive_links(&self) -> bool {
|
|
|
|
|
self.module.is_skip_consecutive_links()
|
|
|
|
|
}
|
|
|
|
|
|
2025-02-25 14:55:39 -06:00
|
|
|
pub fn render_text(&mut self) -> String {
|
|
|
|
|
self.module.pin_mut().render_text()
|
2025-02-24 23:18:38 -06:00
|
|
|
}
|
2025-02-25 00:06:12 -06:00
|
|
|
|
|
|
|
|
pub fn set_key_text(&mut self, key_text: &String) {
|
|
|
|
|
self.module.pin_mut().set_key_text(key_text);
|
|
|
|
|
}
|
2025-02-25 14:55:39 -06:00
|
|
|
|
2025-02-25 15:45:58 -06:00
|
|
|
pub fn set_skip_consecutive_links(&mut self, skip: bool) {
|
|
|
|
|
self.module.pin_mut().set_skip_consecutive_links(skip);
|
|
|
|
|
}
|
|
|
|
|
|
2025-02-25 14:55:39 -06:00
|
|
|
pub fn strip_text(&mut self) -> String {
|
|
|
|
|
self.module.pin_mut().strip_text()
|
|
|
|
|
}
|
2025-02-24 23:18:38 -06:00
|
|
|
}
|