Codebase list golang-github-vbauerster-mpb / 53473f7
sort back Vladimir Bauer 9 years ago
2 changed file(s) with 8 addition(s) and 0 deletion(s). Raw diff Collapse all Expand all
+0
-0
example/singleBar/e.txt less more
(Empty file)
44 "errors"
55 "io"
66 "os"
7 "sort"
78 "sync"
89 "time"
910
205206 case respCh := <-p.barCountReqCh:
206207 respCh <- len(bars)
207208 case <-t.C:
209 switch p.sort {
210 case SortTop:
211 sort.Sort(sort.Reverse(SortableBarSlice(bars)))
212 case SortBottom:
213 sort.Sort(SortableBarSlice(bars))
214 }
215
208216 width, _ := cwriter.TerminalWidth()
209217 ibars := iBarsGen(p.ctx.Done(), bars, width)
210218 c := make(chan *indexedBarBuffer)