From 1ee0c559cc573be88a213268b060cbde3a93bf3e Mon Sep 17 00:00:00 2001 From: Oliver <480930+rivo@users.noreply.github.com> Date: Sat, 9 Jun 2018 22:16:38 +0200 Subject: [PATCH] Switched flexItem slice to pointers. --- flex.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/flex.go b/flex.go index e5bf5e0..7235614 100644 --- a/flex.go +++ b/flex.go @@ -28,7 +28,7 @@ type Flex struct { *Box // The items to be positioned. - items []flexItem + items []*flexItem // FlexRow or FlexColumn. direction int @@ -86,7 +86,7 @@ func (f *Flex) SetFullScreen(fullScreen bool) *Flex { // You can provide a nil value for the primitive. This will still consume screen // space but nothing will be drawn. func (f *Flex) AddItem(item Primitive, fixedSize, proportion int, focus bool) *Flex { - f.items = append(f.items, flexItem{Item: item, FixedSize: fixedSize, Proportion: proportion, Focus: focus}) + f.items = append(f.items, &flexItem{Item: item, FixedSize: fixedSize, Proportion: proportion, Focus: focus}) return f }