diff --git a/go.mod b/go.mod index aa65700..2a182bc 100644 --- a/go.mod +++ b/go.mod @@ -1 +1 @@ -module github.com/cauefcr/gohook +module github.com/cauefcr/ghook diff --git a/test/main.go b/test/main.go index 6dec4ca..7698d41 100644 --- a/test/main.go +++ b/test/main.go @@ -4,13 +4,13 @@ import ( "fmt" "time" - "github.com/cauefcr/gohook" + "github.com/cauefcr/ghook" ) func main() { s := hook.Start() defer hook.End() - tout := time.After(time.Hour*2) + tout := time.After(time.Hour * 2) done := false for !done { select { @@ -19,13 +19,13 @@ func main() { if i.Keychar == 'q' { tout = time.After(0) } - fmt.Printf("%v key: %c:%v\n",i.Kind, i.Keychar,i.Rawcode) + fmt.Printf("%v key: %c:%v\n", i.Kind, i.Keychar, i.Rawcode) } else if i.Kind >= hook.MouseDown && i.Kind < hook.MouseWheel { //fmt.Printf("x: %v, y: %v, button: %v\n", i.X, i.Y, i.Button) - }else if i.Kind == hook.MouseWheel { + } else if i.Kind == hook.MouseWheel { //fmt.Printf("x: %v, y: %v, button: %v, wheel: %v, rotation: %v\n", i.X, i.Y, i.Button,i.Amount,i.Rotation) } else { - fmt.Printf("%+v\n",i) + fmt.Printf("%+v\n", i) } case <-tout: fmt.Print("Done.")