mirror of https://github.com/rivo/tview.git
This commit is contained in:
parent
f8bc69b903
commit
de7ae86b5b
4
flex.go
4
flex.go
|
@ -149,9 +149,13 @@ func (f *Flex) Draw(screen tcell.Screen) {
|
|||
for _, item := range f.items {
|
||||
size := item.FixedSize
|
||||
if size <= 0 {
|
||||
if proportionSum > 0 {
|
||||
size = distSize * item.Proportion / proportionSum
|
||||
distSize -= size
|
||||
proportionSum -= item.Proportion
|
||||
} else {
|
||||
size = 0
|
||||
}
|
||||
}
|
||||
if item.Item != nil {
|
||||
if f.direction == FlexColumn {
|
||||
|
|
Loading…
Reference in New Issue