From cd76ffa4f03c719bda3573dd7e125028fc048192 Mon Sep 17 00:00:00 2001 From: Sven Niederberger Date: Fri, 11 Jun 2021 23:26:18 +0200 Subject: [PATCH] apply suggested fix --- egui/src/containers/frame.rs | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/egui/src/containers/frame.rs b/egui/src/containers/frame.rs index 36b272c6071..cdb25d08535 100644 --- a/egui/src/containers/frame.rs +++ b/egui/src/containers/frame.rs @@ -113,7 +113,6 @@ impl Frame { pub struct Prepared { pub frame: Frame, - outer_rect_bounds: Rect, where_to_put_background: ShapeIdx, pub content_ui: Ui, } @@ -134,7 +133,6 @@ impl Frame { Prepared { frame: self, - outer_rect_bounds, where_to_put_background, content_ui, } @@ -175,10 +173,7 @@ impl Frame { impl Prepared { pub fn outer_rect(&self) -> Rect { - Rect::from_min_max( - self.outer_rect_bounds.min, - self.content_ui.min_rect().max + self.frame.margin, - ) + self.content_ui.min_rect().expand2(self.frame.margin) } pub fn end(self, ui: &mut Ui) -> Response {