From 665b4d2aca81af48b8e0eaca4e709ef2e7825844 Mon Sep 17 00:00:00 2001 From: Laurenz Date: Fri, 13 Dec 2019 23:59:01 +0100 Subject: =?UTF-8?q?More=20consistent=20library=20code=20and=20functions=20?= =?UTF-8?q?=F0=9F=8E=84?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/layout/flex.rs | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'src/layout/flex.rs') diff --git a/src/layout/flex.rs b/src/layout/flex.rs index 48853863..72878a29 100644 --- a/src/layout/flex.rs +++ b/src/layout/flex.rs @@ -66,6 +66,7 @@ pub struct FlexContext { pub axes: LayoutAxes, pub alignment: LayoutAlignment, pub flex_spacing: Size, + pub repeat: bool, pub debug: bool, } @@ -76,6 +77,7 @@ impl FlexLayouter { spaces: ctx.spaces, axes: ctx.axes, alignment: ctx.alignment, + repeat: ctx.repeat, debug: ctx.debug, }); @@ -144,7 +146,7 @@ impl FlexLayouter { pub fn finish(mut self) -> LayoutResult { self.finish_space(false)?; - Ok(self.stack.finish()) + self.stack.finish() } pub fn finish_space(&mut self, hard: bool) -> LayoutResult<()> { @@ -152,7 +154,7 @@ impl FlexLayouter { self.finish_run()?; } - self.stack.finish_space(hard); + self.stack.finish_space(hard)?; Ok(self.start_line()) } -- cgit v1.2.3