Collapse All
Parallels Virtualization SDK
ContentsIndex
PreviousUpNext
PrlVm_UIEmuQueryNearestElementAtPos Function
PHT_VIRTUAL_MACHINE

Posts "get info on nearest element at specified position" query to guest User Input Emulation tool.

Syntax
PRL_RESULT PrlVm_UIEmuQueryNearestElementAtPos(
    PRL_HANDLE hVm, 
    PRL_INT32 queryId, 
    PRL_INT32 posX, 
    PRL_INT32 posY, 
    PRL_UINT32 searchDiameter, 
    PRL_UINT32 queryFlags
);
File

PrlApiVm.h

Parameters

hVm
[in] Handle of type PHT_VIRTUAL_MACHINE. Must be valid.
queryId
[in] user-defined value that will be in response.
posX
[in] x coordinate within guest screen.
posY
[in] y coordinate within guest screen.
searchDiameter
[in] diameter of search nearest element area.
queryFlags
[in] additional options. One of PRL_QUERY_ELEMENT_FLAGS.

Returns

PRL_RESULT. Possible values: PRL_ERR_UNINITIALIZED - SDK was not properly initialized. PRL_ERR_INVALID_ARG - specified arguments are invalid. PRL_ERR_OUT_OF_MEMORY - memory allocation error during send. PRL_ERR_SUCCESS - function completed successfully.

Remarks

Response will be received via PET_IO_UIEMU_ELEMENT_AT_POS event with PRL_UIEMU_ELEMENT_AT_POS structure on board. Guest tool will always reply. Since not all versions of User Input Emulation tool support this request and not all guest OS can supply required functionality, use TIS uuid TIS_UID_UIEMU_GUEST_CROSS_PLUGIN_NEAREST_ELEMENT ("parallels.UserInputEmulation.guest.cross.plugin.NearestElement") to get status of that feature. If this uuid is in active state in TIS database, this function can be used.

Links
© 2021 Parallels International GmbH. All rights reserved.