mirror of
https://github.com/go-vgo/robotgo.git
synced 2025-06-02 23:23:55 +00:00
Update README.md and CHANGELOG.md
This commit is contained in:
parent
d76ab89c9f
commit
5dd3b6cd66
14
README.md
14
README.md
@ -229,6 +229,20 @@ import (
|
|||||||
)
|
)
|
||||||
|
|
||||||
func main() {
|
func main() {
|
||||||
|
fmt.Println("--- Please press ctrl + shift + q to stop hook ---")
|
||||||
|
robotgo.EventHook(hook.KeyDown, []string{"q", "ctrl", "shift"}, func(e hook.Event) {
|
||||||
|
fmt.Println("ctrl-shift-q")
|
||||||
|
robotgo.EventEnd()
|
||||||
|
})
|
||||||
|
|
||||||
|
fmt.Println("--- Please press w---")
|
||||||
|
robotgo.EventHook(hook.KeyDown, []string{"w"}, func(e hook.Event) {
|
||||||
|
fmt.Println("w")
|
||||||
|
})
|
||||||
|
|
||||||
|
s := robotgo.EventStart()
|
||||||
|
<-robotgo.EventProcess(s)
|
||||||
|
|
||||||
ok := robotgo.AddEvents("q", "ctrl", "shift")
|
ok := robotgo.AddEvents("q", "ctrl", "shift")
|
||||||
if ok {
|
if ok {
|
||||||
fmt.Println("add events...")
|
fmt.Println("add events...")
|
||||||
|
14
README_zh.md
14
README_zh.md
@ -226,6 +226,20 @@ import (
|
|||||||
)
|
)
|
||||||
|
|
||||||
func main() {
|
func main() {
|
||||||
|
fmt.Println("--- Please press ctrl + shift + q to stop hook ---")
|
||||||
|
robotgo.EventHook(hook.KeyDown, []string{"q", "ctrl", "shift"}, func(e hook.Event) {
|
||||||
|
fmt.Println("ctrl-shift-q")
|
||||||
|
robotgo.EventEnd()
|
||||||
|
})
|
||||||
|
|
||||||
|
fmt.Println("--- Please press w---")
|
||||||
|
robotgo.EventHook(hook.KeyDown, []string{"w"}, func(e hook.Event) {
|
||||||
|
fmt.Println("w")
|
||||||
|
})
|
||||||
|
|
||||||
|
s := robotgo.EventStart()
|
||||||
|
<-robotgo.EventProcess(s)
|
||||||
|
|
||||||
ok := robotgo.AddEvents("q", "ctrl", "shift")
|
ok := robotgo.AddEvents("q", "ctrl", "shift")
|
||||||
if ok {
|
if ok {
|
||||||
fmt.Println("add events...")
|
fmt.Println("add events...")
|
||||||
|
@ -22,6 +22,8 @@ add int32_t types support
|
|||||||
update keycode type use uint16 with gohook, not type convert
|
update keycode type use uint16 with gohook, not type convert
|
||||||
add ToBitmapBytes func (#204)
|
add ToBitmapBytes func (#204)
|
||||||
|
|
||||||
|
gohook: sched_yield support for non-POSIX windows gcc
|
||||||
|
|
||||||
add gops test code support
|
add gops test code support
|
||||||
add Process() function test code
|
add Process() function test code
|
||||||
add more gops test code
|
add more gops test code
|
||||||
|
Loading…
Reference in New Issue
Block a user