Skip to content

hook keycode event error #328

@bobwong89757

Description

@bobwong89757

when i touch the enter key on keyboard, the event is
2021-04-19 15:33:10.457 +0800 CST m=+65.499394961 - Event: {Kind: KeyDown, Rawcode: 36, Keychar: 13}

ctrl, shift and opt are not working fine.

My code is

evChan := robotgo.EventStart()
defer robotgo.EventEnd()

for ev := range evChan {

  if ev.Kind == hook.KeyDown {
	  fmt.Println("evt: ", ev)
	  //fmt.Println("pressed: ", hook.RawcodetoKeychar(ev.Rawcode))
  }

}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions