mirror of
https://github.com/go-vgo/robotgo.git
synced 2025-06-02 23:23:55 +00:00
Add TypeStrDelay and Warning
This commit is contained in:
parent
7e40b96d51
commit
98898850f1
9
doc.md
9
doc.md
@ -3,12 +3,13 @@
|
|||||||
##[Keyboard](#Keyboard)
|
##[Keyboard](#Keyboard)
|
||||||
|
|
||||||
#####[Keys](#keys)
|
#####[Keys](#keys)
|
||||||
#####[SetKeyboardDelay](#SetKeyDelay)(Equivalent to SetKeyDelay)
|
#####[SetKeyboardDelay](#SetKeyDelay)(Equivalent to SetKeyDelay,Wno-deprecated)
|
||||||
#####[SetKeyDelay](#SetKeyDelay)
|
#####[SetKeyDelay](#SetKeyDelay)
|
||||||
#####[KeyTap](#KeyTap)
|
#####[KeyTap](#KeyTap)
|
||||||
#####[KeyToggle](#KeyToggle)
|
#####[KeyToggle](#KeyToggle)
|
||||||
#####[TypeString](#TypeString)
|
#####[TypeString](#TypeString)
|
||||||
#####[TypeStringDelayed](#TypeStringDelayed)
|
#####[TypeStringDelayed](#TypeStrDelay)(Equivalent to TypeStrDelay,Wno-deprecated)
|
||||||
|
#####[TypeStrDelay](#TypeStrDelay)
|
||||||
|
|
||||||
##[Mouse](#Mouse)
|
##[Mouse](#Mouse)
|
||||||
|
|
||||||
@ -41,7 +42,7 @@
|
|||||||
|
|
||||||
##[Event](#Event)
|
##[Event](#Event)
|
||||||
|
|
||||||
#####[LEvent](#LEvent)(Equivalent to AddEvent)
|
#####[LEvent](#LEvent)(Equivalent to AddEvent,Wno-deprecated)
|
||||||
#####[AddEvent](#AddEvent)
|
#####[AddEvent](#AddEvent)
|
||||||
|
|
||||||
##[Window](#Window)
|
##[Window](#Window)
|
||||||
@ -101,7 +102,7 @@
|
|||||||
|
|
||||||
string - The string to send.
|
string - The string to send.
|
||||||
|
|
||||||
###<h3 id="TypeStringDelayed">.TypeStringDelayed(string, cpm)</h3>
|
###<h3 id="TypeStrDelay">.TypeStrDelay(string, cpm)</h3>
|
||||||
|
|
||||||
####Arguments:
|
####Arguments:
|
||||||
|
|
||||||
|
14
robotgo.go
14
robotgo.go
@ -1,6 +1,5 @@
|
|||||||
// Copyright 2016 The go-vgo Project Developers.
|
// Copyright 2016 The go-vgo Project Developers. See the COPYRIGHT
|
||||||
// All Rights Reserved. See the COPYRIGHT file at
|
// file at the top-level directory of this distribution and at
|
||||||
// the top-level directory of this distribution and at
|
|
||||||
// https://github.com/go-vgo/robotgo/blob/master/LICENSE
|
// https://github.com/go-vgo/robotgo/blob/master/LICENSE
|
||||||
//
|
//
|
||||||
// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
|
// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
|
||||||
@ -404,6 +403,14 @@ func TypeString(x string) {
|
|||||||
defer C.free(unsafe.Pointer(cx))
|
defer C.free(unsafe.Pointer(cx))
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//TypeStrDelay Type String Delayed
|
||||||
|
func TypeStrDelay(x string, y int) {
|
||||||
|
cx := C.CString(x)
|
||||||
|
cy := C.size_t(y)
|
||||||
|
C.aTypeStringDelayed(cx, cy)
|
||||||
|
defer C.free(unsafe.Pointer(cx))
|
||||||
|
}
|
||||||
|
|
||||||
//TypeStringDelayed Type String Delayed
|
//TypeStringDelayed Type String Delayed
|
||||||
func TypeStringDelayed(x string, y int) {
|
func TypeStringDelayed(x string, y int) {
|
||||||
cx := C.CString(x)
|
cx := C.CString(x)
|
||||||
@ -412,7 +419,6 @@ func TypeStringDelayed(x string, y int) {
|
|||||||
defer C.free(unsafe.Pointer(cx))
|
defer C.free(unsafe.Pointer(cx))
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//SetKeyDelay Set Keyboard Delay
|
//SetKeyDelay Set Keyboard Delay
|
||||||
func SetKeyDelay(x int) {
|
func SetKeyDelay(x int) {
|
||||||
C.aSetKeyboardDelay(C.size_t(x))
|
C.aSetKeyboardDelay(C.size_t(x))
|
||||||
|
@ -3,12 +3,13 @@
|
|||||||
##[键盘](#Keyboard)
|
##[键盘](#Keyboard)
|
||||||
|
|
||||||
#####[Keys](#keys)
|
#####[Keys](#keys)
|
||||||
#####[SetKeyboardDelay](#SetKeyDelay)(相当于SetKeyDelay)
|
#####[SetKeyboardDelay](#SetKeyDelay)(相当于SetKeyDelay,Wno-deprecated)
|
||||||
#####[SetKeyDelay](#SetKeyDelay)
|
#####[SetKeyDelay](#SetKeyDelay)
|
||||||
#####[KeyTap](#KeyTap)
|
#####[KeyTap](#KeyTap)
|
||||||
#####[KeyToggle](#KeyToggle)
|
#####[KeyToggle](#KeyToggle)
|
||||||
#####[TypeString](#TypeString)
|
#####[TypeString](#TypeString)
|
||||||
#####[TypeStringDelayed](#TypeStringDelayed)
|
#####[TypeStringDelayed](#TypeStrDelay)(相当于TypeStrDelay,Wno-deprecated)
|
||||||
|
#####[TypeStrDelay](#TypeStrDelay)
|
||||||
|
|
||||||
##[鼠标](#Mouse)
|
##[鼠标](#Mouse)
|
||||||
|
|
||||||
@ -41,7 +42,7 @@
|
|||||||
|
|
||||||
##[事件](#Event)
|
##[事件](#Event)
|
||||||
|
|
||||||
#####[LEvent](#AddEvent)(相当于AddEvent)
|
#####[LEvent](#AddEvent)(相当于AddEvent,Wno-deprecated)
|
||||||
#####[AddEvent](#AddEvent)
|
#####[AddEvent](#AddEvent)
|
||||||
|
|
||||||
##[窗口](#Window)
|
##[窗口](#Window)
|
||||||
@ -105,7 +106,7 @@
|
|||||||
|
|
||||||
string - The string to send.
|
string - The string to send.
|
||||||
|
|
||||||
###<h3 id="TypeStringDelayed">.TypeStringDelayed(string, cpm)</h3>
|
###<h3 id="TypeStrDelay">.TypeStrDelay(string, cpm)</h3>
|
||||||
|
|
||||||
####参数:
|
####参数:
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user