X-Git-Url: http://git.iain.cx/?a=blobdiff_plain;f=app%2Fapp.go;h=358813301b539a8c6ac170366ff7d3031f622b57;hb=eb20c891f4e19c96d700989aa7c5006ba3e3b310;hp=c6c43bf100b301f98b32698ef9e1c9da6ce736b4;hpb=28f3ee44f6591ee899de237d7de027ae664d3eea;p=pstop.git diff --git a/app/app.go b/app/app.go index c6c43bf..3588133 100644 --- a/app/app.go +++ b/app/app.go @@ -496,18 +496,6 @@ func (app *App) Cleanup() { } } -// make chan for termbox events and run a poller to send events to the channel -// - return the channel -func new_tb_chan() chan termbox.Event { - termboxChan := make(chan termbox.Event) - go func() { - for { - termboxChan <- termbox.PollEvent() - } - }() - return termboxChan -} - // get into a run loop func (app *App) Run() { app.done = make(chan struct{}) @@ -518,7 +506,7 @@ func (app *App) Run() { app.wi.SetWaitInterval(time.Second) - termboxChan := new_tb_chan() + termboxChan := app.screen.TermBoxChan() for !app.Finished() { select {