mirror of
https://github.com/go-vgo/robotgo.git
synced 2025-05-31 06:13:55 +00:00
update var code style
This commit is contained in:
parent
44a2fc533b
commit
69b4f4210f
@ -170,7 +170,7 @@ static uint32_t parseDimension(const uint8_t *buf,
|
||||
size_t i;
|
||||
// ssize_t len;
|
||||
// size_t len;
|
||||
// uint8_t * len;
|
||||
// uint8_t *len;
|
||||
|
||||
assert(buf != NULL);
|
||||
// assert(len != NULL);
|
||||
|
13
robotgo.go
13
robotgo.go
@ -254,12 +254,7 @@ func GetXDisplayName() string {
|
||||
|
||||
// CaptureScreen capture the screen return bitmap(c struct)
|
||||
func CaptureScreen(args ...int) C.MMBitmapRef {
|
||||
var (
|
||||
x C.size_t
|
||||
y C.size_t
|
||||
w C.size_t
|
||||
h C.size_t
|
||||
)
|
||||
var x, y, w, h C.size_t
|
||||
|
||||
if len(args) > 3 {
|
||||
x = C.size_t(args[0])
|
||||
@ -574,9 +569,7 @@ func KeyTap(tapKey string, args ...interface{}) {
|
||||
// https://github.com/go-vgo/robotgo/blob/master/docs/keys.md
|
||||
func KeyToggle(args ...string) string {
|
||||
var (
|
||||
adown string
|
||||
mKey string
|
||||
mKeyT string
|
||||
adown, mKey, mKeyT string
|
||||
// keyDelay = 10
|
||||
)
|
||||
|
||||
@ -906,7 +899,7 @@ func FindEveryBitmap(bit C.MMBitmapRef, args ...interface{}) (int, int) {
|
||||
}
|
||||
|
||||
// CountBitmap count of the bitmap
|
||||
func CountBitmap(bitmap C.MMBitmapRef, sbit C.MMBitmapRef, args ...float32) int {
|
||||
func CountBitmap(bitmap, sbit C.MMBitmapRef, args ...float32) int {
|
||||
var tolerance C.float
|
||||
if len(args) > 0 {
|
||||
tolerance = C.float(args[0])
|
||||
|
Loading…
Reference in New Issue
Block a user