How do a dragDrop() with the right mouse button?

979 views Asked by At

Does anyone know how to do a dragDrop() with the right mouse button?
I got this example code:

image = ("image.png")
App.focus('<nameProgramHere>')
imageE = find(image)
rightClick(dragDrop(imageE, imageE.offset(Location(0, -250))))

It does make a rightclick, but the dragDrop() is preformed with the left mouse click.
(I can see this becasue the colour is then different in my program.)

I do see the rightClick() in my log.
[log] RIGHT CLICK on L(1039,556)@S(0)[0,0 1920x1080]

1

There are 1 answers

0
Tenzin On

Found the answer myself on how to drag and drop with the right mouse button.

image = ("image.png")

imageE = find(image)
imageE.hover()
wait(2)
mouseDown(Button.RIGHT)
mouseMove(imageE.offset(Location(0,-250)))
wait(2)
mouseUp()