Buffers ?!
This commit is contained in:
@@ -63,12 +63,14 @@ func (w *Checkbox) Init(id string, style tcell.Style) {
|
||||
w.visible = true
|
||||
w.stateRunes = []rune{'X', ' ', '-'}
|
||||
w.focusable = true
|
||||
w.keyMap = NewKeyMap(map[tcell.Key]func(ev *tcell.EventKey) bool{
|
||||
tcell.KeyEnter: w.ToggleState,
|
||||
})
|
||||
w.AddToKeyMap(NewRuneMap(map[rune]func(ev *tcell.EventKey) bool{
|
||||
' ': w.ToggleState,
|
||||
}))
|
||||
w.keyMap = KeyMap{
|
||||
Keys: map[tcell.Key]func(ev *tcell.EventKey) bool{
|
||||
tcell.KeyEnter: w.ToggleState,
|
||||
},
|
||||
Runes: map[rune]func(ev *tcell.EventKey) bool{
|
||||
' ': w.ToggleState,
|
||||
},
|
||||
}
|
||||
w.customKeyMap = BlankKeyMap()
|
||||
}
|
||||
func (w *Checkbox) Id() string { return w.id }
|
||||
|
||||
Reference in New Issue
Block a user