mirror of
https://codeberg.org/unspeaker/tek.git
synced 2025-12-09 05:06:43 +01:00
placebo
This commit is contained in:
parent
3ae2467acc
commit
94c1f83ef2
13 changed files with 277 additions and 124 deletions
|
|
@ -21,6 +21,16 @@ pub trait Render {
|
|||
fn max_height (&self) -> u16 {
|
||||
u16::MAX
|
||||
}
|
||||
|
||||
//fn boxed (self) -> Box<dyn Render> where Self: Sized + 'static {
|
||||
//Box::new(self)
|
||||
//}
|
||||
}
|
||||
|
||||
impl<T: Fn(&mut Buffer, Rect) -> Usually<Rect>> Render for T {
|
||||
fn render (&self, b: &mut Buffer, a: Rect) -> Usually<Rect> {
|
||||
(*self).render(b, a)
|
||||
}
|
||||
}
|
||||
|
||||
impl Render for Box<dyn Device> {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue