Fix shadowed variable

Layout passed into the overlay was accidentally shadowed by the
content's layout. So instead of offsetting by the proper layout, the
content layout was used instead.
This commit is contained in:
Cory Forsstrom 2023-01-05 08:57:38 -08:00
parent 43374f1f4e
commit c885f56748
No known key found for this signature in database
GPG key ID: 1DFE170A4415C9F5

View file

@ -280,12 +280,14 @@ where
);
let Content {
element, layout, ..
element,
layout: content_layout,
..
} = content.deref_mut();
let content_layout = Layout::with_offset(
layout.bounds().position() - Point::ORIGIN,
layout,
content_layout,
);
element