mirror of
https://github.com/go-vgo/robotgo
synced 2026-05-23 17:59:12 +00:00
add func microsleep and update
This commit is contained in:
parent
2423ad940d
commit
15afbb6132
1 changed files with 6 additions and 1 deletions
|
|
@ -65,7 +65,7 @@ import (
|
|||
)
|
||||
|
||||
const (
|
||||
version string = "v0.48.0.529, Ben Nevis!"
|
||||
version string = "v0.48.0.534, Ben Nevis!"
|
||||
)
|
||||
|
||||
type (
|
||||
|
|
@ -113,6 +113,11 @@ func Sleep(tm float64) {
|
|||
time.Sleep(time.Duration(tm) * time.Second)
|
||||
}
|
||||
|
||||
// MicroSleep time C.microsleep(tm)
|
||||
func MicroSleep(tm float64) {
|
||||
C.microsleep(C.double(tm))
|
||||
}
|
||||
|
||||
// GoString teans C.char to string
|
||||
func GoString(char *C.char) string {
|
||||
return C.GoString(char)
|
||||
|
|
|
|||
Loading…
Reference in a new issue