← Back to team overview

sikuli-driver team mailing list archive

Re: [Question #154744]: holding shift key in java

 

Question #154744 on Sikuli changed:
https://answers.launchpad.net/sikuli/+question/154744

RaiMan proposed the following answer:
_screen.keyDown("\ue020");

should just do what it should: press and hold the shift key until a
keyUp() is given.

So if you want to fire a Shift+end with KeyDown()/keyUp():

_screen.keyDown("\ue020");
_screen.keyDown("\ue007");
_screen.keyUp(null) // releases all held keys

but I think, KeyUp/KeyDown only make sense instead of type() if you have
to press and hold keys during mouse actions or in very special
situations (e.g. games).

-- 
You received this question notification because you are a member of
Sikuli Drivers, which is an answer contact for Sikuli.