简体   繁体   中英

X11 - Mouse simulation drag action

I simulate click and move actions using XQueryPointer and XWarpPointer . I want to simulate drag action but I can't find a way to do it. How can I do on linux machine?

使用xtest扩展-使用XTestFakeButtonEvent / XTestFakeMotionEvent模拟初始的鼠标下移+鼠标移动事件+鼠标向上

if you are not restricted to c++ you can also use xdotool. It's command line tool. For dragging you can send buttondown, move, buttonup events.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM