From dd673a592b270159b4588da06c09672dc1d76df9 Mon Sep 17 00:00:00 2001 From: ian zhang Date: Mon, 9 Oct 2023 22:07:28 +0800 Subject: [PATCH] Update Actions.java as removed modifier keys #12902 as issue mentioned, the previous modifier keys won't be there any more, we should remove incorrect expectations. --- .../org/openqa/selenium/interactions/Actions.java | 14 ++++---------- 1 file changed, 4 insertions(+), 10 deletions(-) diff --git a/java/src/org/openqa/selenium/interactions/Actions.java b/java/src/org/openqa/selenium/interactions/Actions.java index 221d51afe1442..df89feee9d07e 100644 --- a/java/src/org/openqa/selenium/interactions/Actions.java +++ b/java/src/org/openqa/selenium/interactions/Actions.java @@ -65,9 +65,7 @@ public Actions(WebDriver driver) { * either keyUp(theKey) or sendKeys(Keys.NULL) must be called to release the * modifier. * - * @param key Either {@link Keys#META}, {@link Keys#COMMAND}, {@link Keys#SHIFT}, {@link Keys#ALT} - * or {@link Keys#CONTROL}. If the provided key is none of those, {@link - * IllegalArgumentException} is thrown. + * @param key * @return A self reference. */ public Actions keyDown(CharSequence key) { @@ -79,9 +77,7 @@ public Actions keyDown(CharSequence key) { * Actions.click(element).sendKeys(theKey); * * @see #keyDown(CharSequence) - * @param key Either {@link Keys#META}, {@link Keys#COMMAND}, {@link Keys#SHIFT}, {@link Keys#ALT} - * or {@link Keys#CONTROL}. If the provided key is none of those, {@link - * IllegalArgumentException} is thrown. + * @param key * @param target WebElement to perform the action * @return A self reference. */ @@ -94,8 +90,7 @@ public Actions keyDown(WebElement target, CharSequence key) { * Performs a modifier key release. Releasing a non-depressed modifier key will yield undefined * behaviour. * - * @param key Either {@link Keys#META}, {@link Keys#COMMAND}, {@link Keys#SHIFT}, {@link Keys#ALT} - * or {@link Keys#CONTROL}. + * @param key * @return A self reference. */ public Actions keyUp(CharSequence key) { @@ -107,8 +102,7 @@ public Actions keyUp(CharSequence key) { * Actions.click(element).sendKeys(theKey); * * @see #keyUp(CharSequence) on behaviour regarding non-depressed modifier keys. - * @param key Either {@link Keys#META}, {@link Keys#COMMAND}, {@link Keys#SHIFT}, {@link Keys#ALT} - * or {@link Keys#CONTROL}. + * @param key * @param target WebElement to perform the action on * @return A self reference. */