From f3a5747ac2330b0537542421234750c300b03ce9 Mon Sep 17 00:00:00 2001 From: vcaesar Date: Sun, 30 Sep 2018 09:41:35 -0400 Subject: [PATCH] add FindCBitmap func support --- robotgo.go | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/robotgo.go b/robotgo.go index 496fcd7..d2e2e3e 100644 --- a/robotgo.go +++ b/robotgo.go @@ -825,6 +825,11 @@ func internalFindBitmap(bit, sbit C.MMBitmapRef, tolerance float64) (int, int) { return int(pos.x), int(pos.y) } +// FindCBitmap find bitmap's pos by CBitmap +func FindCBitmap(bmp CBitmap, args ...interface{}) (int, int) { + return FindBitmap(ToMMBitmapRef(bmp), args...) +} + // FindBitmap find the bitmap's pos // // robotgo.FindBitmap(bitmap, subbitamp C.MMBitmapRef, tolerance float64)