Increase dialogue modality, display keyboard dialogue
This commit is contained in:
25
internal/flow/keyboard.go
Normal file
25
internal/flow/keyboard.go
Normal file
@@ -0,0 +1,25 @@
|
||||
package flow
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"log"
|
||||
)
|
||||
|
||||
func (f *Flow) linkKeyboard() {
|
||||
// Keyboard settings
|
||||
// TODO: implement keybindings save/load behaviour
|
||||
f.onClick(kbd, "3.1", f.returnToLastDriver(kbd)) // Done button
|
||||
f.onClick(kbd, "3.2", f.returnToLastDriver(kbd)) // Cancel button
|
||||
f.onClick(kbd, "3.4", func() {}) // TODO: Reset to defaults button
|
||||
|
||||
for i := 1; i <= 13; i++ {
|
||||
f.onClick(kbd, fmt.Sprintf("2.%v", i), f.captureKeybinding(i))
|
||||
}
|
||||
}
|
||||
|
||||
func (f *Flow) captureKeybinding(forLine int) func() {
|
||||
return func() {
|
||||
log.Printf("HELLO %v", forLine)
|
||||
f.showDialogue(kbd, "4")()
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user