Skip to content

Commit 706495a

Browse files
[py] Update docstring and comments in keys.py (#16187)
Co-authored-by: Corey Goldberg <[email protected]>
1 parent f9883e3 commit 706495a

File tree

1 file changed

+11
-3
lines changed
  • py/selenium/webdriver/common

1 file changed

+11
-3
lines changed

py/selenium/webdriver/common/keys.py

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,11 +14,16 @@
1414
# KIND, either express or implied. See the License for the
1515
# specific language governing permissions and limitations
1616
# under the License.
17+
1718
"""The Keys implementation."""
1819

1920

2021
class Keys:
21-
"""Set of special keys codes."""
22+
"""Set of special key codes for input actions.
23+
24+
Primarily intended for keyboard usage, but also applied in other contexts
25+
such as Action Chains and IME interactions.
26+
"""
2227

2328
NULL = "\ue000"
2429
CANCEL = "\ue001" # ^break
@@ -58,7 +63,8 @@ class Keys:
5863
SEMICOLON = "\ue018"
5964
EQUALS = "\ue019"
6065

61-
NUMPAD0 = "\ue01a" # number pad keys
66+
# Keys representing number pad digits
67+
NUMPAD0 = "\ue01a"
6268
NUMPAD1 = "\ue01b"
6369
NUMPAD2 = "\ue01c"
6470
NUMPAD3 = "\ue01d"
@@ -68,14 +74,16 @@ class Keys:
6874
NUMPAD7 = "\ue021"
6975
NUMPAD8 = "\ue022"
7076
NUMPAD9 = "\ue023"
77+
7178
MULTIPLY = "\ue024"
7279
ADD = "\ue025"
7380
SEPARATOR = "\ue026"
7481
SUBTRACT = "\ue027"
7582
DECIMAL = "\ue028"
7683
DIVIDE = "\ue029"
7784

78-
F1 = "\ue031" # function keys
85+
# Function keys
86+
F1 = "\ue031"
7987
F2 = "\ue032"
8088
F3 = "\ue033"
8189
F4 = "\ue034"

0 commit comments

Comments
 (0)