MCPcopy Create free account
hub / github.com/WallBreaker2/op / FindNearestPos

Method FindNearestPos

libop/com/OpAutomation.cpp:148–155  ·  view source on GitHub ↗

根据部分Ex接口的返回值,然后在所有坐标里找出距离指定坐标最近的那个坐标.

Source from the content-addressed store, hash-verified

146
147// 根据部分Ex接口的返回值,然后在所有坐标里找出距离指定坐标最近的那个坐标.
148STDMETHODIMP OpAutomation::FindNearestPos(BSTR all_pos, LONG type, LONG x, LONG y, BSTR *retstr) {
149 std::wstring s;
150 obj.FindNearestPos(all_pos, type, x, y, s);
151 CComBSTR newbstr;
152 auto hr = newbstr.Append(s.data());
153 hr = newbstr.CopyTo(retstr);
154 return S_OK;
155}
156
157STDMETHODIMP OpAutomation::EnumWindow(LONGLONG parent, BSTR title, BSTR class_name, LONG filter, BSTR *retstr) {
158 wstring s;

Callers 1

OpFindNearestPosFunction · 0.45

Calls 2

CopyToMethod · 0.80
dataMethod · 0.45

Tested by

no test coverage detected