Compiling checkpoint
This commit is contained in:
parent
e7489bd4c9
commit
65a5c54a2c
7 changed files with 224 additions and 82 deletions
|
@ -0,0 +1,48 @@
|
|||
// type Result = ();
|
||||
// type LayoutContext<> = ();
|
||||
|
||||
// trait Element<V: 'static>: 'static + Clone {
|
||||
// type Layout: 'static;
|
||||
|
||||
// fn style_mut(&mut self) -> &mut Style;
|
||||
// fn layout(&mut self, view: &mut V, cx: &mut LayoutContext<V>)
|
||||
// -> Result<(NodeId, Self::Layout)>;
|
||||
// fn paint<'a>(
|
||||
// &mut self,
|
||||
// layout: Layout<'a, Self::Layout>,
|
||||
// view: &mut V,
|
||||
// cx: &mut PaintContext<V>,
|
||||
// ) -> Result<()>;
|
||||
// }
|
||||
|
||||
// struct Button {
|
||||
// style: Style,
|
||||
// }
|
||||
|
||||
// type Style = ();
|
||||
|
||||
// impl Button {
|
||||
// fn render<V>() -> impl Element<V> {
|
||||
// todo!()
|
||||
// }
|
||||
// }
|
||||
|
||||
// impl<V: 'static> Element<V> for Foo {
|
||||
// type Layout = ();
|
||||
|
||||
// fn style_mut(&mut self) -> &mut Style {
|
||||
// unimplemented!()
|
||||
// }
|
||||
|
||||
// fn layout(
|
||||
// &mut self,
|
||||
// view: &mut V,
|
||||
// cx: &mut LayoutContext<V>,
|
||||
// ) -> Result<(NodeId, Self::Layout)> {
|
||||
// unimplemented!()
|
||||
// }
|
||||
|
||||
// fn paint(&mut self, layout: Layout<()>, view: &mut V, cx: &mut PaintContext<V>) -> Result<()> {
|
||||
// unimplemented!()
|
||||
// }
|
||||
// }
|
Loading…
Add table
Add a link
Reference in a new issue