Update README.md

This commit is contained in:
vcaesar 2020-05-28 10:31:52 -04:00
parent 6ca4fbe91a
commit 0fa5a96dfe

View File

@ -17,6 +17,20 @@ import (
)
func main() {
fmt.Println("--- Please press ctrl + shift + q to stop hook ---")
hook.Register(hook.KeyDown, []string{"q", "ctrl", "shift"}, func(e hook.Event) {
fmt.Println("ctrl-shift-q")
hook.End()
})
fmt.Println("--- Please press w---")
hook.Register(hook.KeyDown, []string{"w"}, func(e hook.Event) {
fmt.Println("w")
})
s := hook.Start()
<-hook.Process(s)
EvChan := hook.Start()
defer hook.End()