On Fri, May 12, 2017 at 7:54 AM, Nigel Tao <nigel...@golang.org> wrote: > On Fri, May 12, 2017 at 3:11 AM, anatoly techtonik <techto...@gmail.com> > wrote: >> I am new to Go and I need a cross-platform value for keyboard key codes to >> make sure I can react to user key presses regardless of operating system >> layer. > > FYI, there's already the key.Code type defined in > https://github.com/golang/mobile/blob/master/event/key/key.go
1. So does that mean it will conflict if both are imported? Right now https://github.com/yakshaveinc/go-keycodes/blob/master/keycodes.go uses KeyF11 while mobile lib uses CodeF11. For me Code is less clear than Key, because from user point of view they press keys, not symbols/characters of codes. 2. Does it provide reverse mapping, so that if user press F11, go program could write "KeyF11" to console? 3. How should keycodes package be renames and placed so that I could be reused in mobile? -- anatoly t. -- You received this message because you are subscribed to the Google Groups "golang-nuts" group. To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.