diff --git a/_examples/mouse.go b/_examples/mouse.go index 7c96eed..36048a1 100644 --- a/_examples/mouse.go +++ b/_examples/mouse.go @@ -24,7 +24,7 @@ func main() { if err := keybindings(g); err != nil { log.Panicln(err) } - g.EnableMouse = true + g.Mouse = true err = g.MainLoop() if err != nil && err != gocui.ErrQuit { diff --git a/gui.go b/gui.go index db37e18..a6cae96 100644 --- a/gui.go +++ b/gui.go @@ -43,8 +43,8 @@ type Gui struct { // If ShowCursor is true then the cursor is enabled. ShowCursor bool - // If EnableMouse is true then mouse events will be enabled. - EnableMouse bool + // If Mouse is true then mouse events will be enabled. + Mouse bool } // NewGui returns a new Gui object. @@ -225,7 +225,7 @@ func (g *Gui) MainLoop() error { }() inputMode := termbox.InputAlt - if g.EnableMouse == true { + if g.Mouse { inputMode |= termbox.InputMouse } termbox.SetInputMode(inputMode)