Skip to content

Commit

Permalink
Merge pull request #147 from kenan-rhoton/CloseInit
Browse files Browse the repository at this point in the history
Init() cleanly after Close()
  • Loading branch information
cjbassi committed Aug 17, 2018
2 parents e736b1b + 6e522b9 commit 5d65a22
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
2 changes: 1 addition & 1 deletion events.go
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,7 @@ func NewSysEvtCh() chan Event {
return ec
}

var DefaultEvtStream = NewEvtStream()
var DefaultEvtStream *EvtStream

type EvtStream struct {
sync.RWMutex
Expand Down
1 change: 1 addition & 0 deletions render.go
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ func Init() error {
return err
}
tm.SetInputMode(tm.InputEsc | tm.InputMouse)
DefaultEvtStream = NewEvtStream()

sysEvtChs = make([]chan Event, 0)
go hookTermboxEvt()
Expand Down

0 comments on commit 5d65a22

Please sign in to comment.