mirror of
https://github.com/go-vgo/robotgo.git
synced 2025-06-01 06:33:56 +00:00
automatic free internal bitmap
This commit is contained in:
parent
496045e5d0
commit
44a2fc533b
@ -291,6 +291,7 @@ func GoCaptureScreen(args ...int) Bitmap {
|
||||
} else {
|
||||
bit = CaptureScreen()
|
||||
}
|
||||
defer FreeBitmap(bit)
|
||||
|
||||
return ToBitmap(bit)
|
||||
}
|
||||
@ -312,6 +313,7 @@ func SaveCapture(spath string, args ...int) {
|
||||
}
|
||||
|
||||
SaveBitmap(bit, spath)
|
||||
FreeBitmap(bit)
|
||||
}
|
||||
|
||||
/*
|
||||
|
Loading…
Reference in New Issue
Block a user