nativeMouseClick
nativeMouseClick(x, y, button)
This function simulates a native mouse click on the currently active window. The x
and y
parameters are the coordinates where the mouse click must take place in screen coordinates. The button
parameter is the mouse button that should be used, and must be one of MouseButton.LeftButton
, MouseButton.MiddleButton
or MouseButton.RightButton
.
Note: In theory it is possible for a call to the nativeMouseClick
function to go astray. For example, if a window or control unexpectedly pops up over the window at which the mouse click was intended, the mouse click will go to the newly active window or control rather than to the intended one. In practice this is a very rare occurrence.
© 2024 The Qt Company Ltd.
Documentation contributions included herein are the copyrights of
their respective owners.
The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation.
Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property
of their respective owners.