diff options
| author | Pietro Gagliardi <[email protected]> | 2014-10-02 10:05:53 -0400 |
|---|---|---|
| committer | Pietro Gagliardi <[email protected]> | 2014-10-02 10:05:53 -0400 |
| commit | 982004d05052ef6aadd22dd5c4e7dbca85ab324a (patch) | |
| tree | 517a0f5a5397e6fb886b5e4741aff4fa18ba10d8 /stack.go | |
| parent | 09db0bffffded1a68c562b2d6451c2a2b29ac279 (diff) | |
go fmt. Precursor to bug report filing.
Diffstat (limited to 'stack.go')
| -rw-r--r-- | stack.go | 11 |
1 files changed, 5 insertions, 6 deletions
@@ -68,7 +68,7 @@ func (s *stack) setParent(parent *controlParent) { func (s *stack) allocate(x int, y int, width int, height int, d *sizing) (allocations []*allocation) { var stretchywid, stretchyht int - var current *allocation // for neighboring + var current *allocation // for neighboring if len(s.controls) == 0 { // do nothing if there's nothing to do return nil @@ -117,14 +117,14 @@ func (s *stack) allocate(x int, y int, width int, height int, d *sizing) (alloca // 3) now actually place controls for i, c := range s.controls { as := c.allocate(x, y, s.width[i], s.height[i], d) - if s.orientation == horizontal { // no vertical neighbors - if current != nil { // connect first left to first right + if s.orientation == horizontal { // no vertical neighbors + if current != nil { // connect first left to first right current.neighbor = c } if len(as) != 0 { - current = as[0] // next left is first subwidget + current = as[0] // next left is first subwidget } else { - current = nil // spaces don't have allocation data + current = nil // spaces don't have allocation data } } allocations = append(allocations, as...) @@ -192,7 +192,6 @@ func (s *stack) getAuxResizeInfo(d *sizing) { // this is to satisfy Control; nothing to do here } - // Space returns a null Control intended for padding layouts with blank space. // It appears to its owner as a Control of 0x0 size. // |
