From 38157b0e0cbab22dc3f5fa5cc66d9b673a18a55b Mon Sep 17 00:00:00 2001 From: Laurenz Date: Mon, 12 Oct 2020 17:10:01 +0200 Subject: =?UTF-8?q?Synchronous=20layout=20=F0=9F=AA=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/layout/fixed.rs | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'src/layout/fixed.rs') diff --git a/src/layout/fixed.rs b/src/layout/fixed.rs index 78a512e6..df099731 100644 --- a/src/layout/fixed.rs +++ b/src/layout/fixed.rs @@ -12,9 +12,8 @@ pub struct Fixed { pub child: LayoutNode, } -#[async_trait(?Send)] impl Layout for Fixed { - async fn layout(&self, ctx: &mut LayoutContext, areas: &Areas) -> Vec { + fn layout(&self, ctx: &mut LayoutContext, areas: &Areas) -> Vec { let Area { rem, full } = areas.current; let size = Size::new( self.width.map(|w| w.eval(full.width)).unwrap_or(rem.width), @@ -22,7 +21,7 @@ impl Layout for Fixed { ); let areas = Areas::once(size); - self.child.layout(ctx, &areas).await + self.child.layout(ctx, &areas) } } -- cgit v1.2.3