Skip to content

Commit 5e06ee8

Browse files
authored
Fix description of move_to_element_with_offset (#11402)
Fix the function comments according to the w3c spec: https://w3c.github.io/webdriver/#dfn-dispatch-a-pointermove-action Fixes #10261
1 parent f25c1d9 commit 5e06ee8

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

py/selenium/webdriver/common/action_chains.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -236,12 +236,12 @@ def move_to_element(self, to_element):
236236

237237
def move_to_element_with_offset(self, to_element, xoffset, yoffset):
238238
"""Move the mouse by an offset of the specified element. Offsets are
239-
relative to the top-left corner of the element.
239+
relative to the in-view center point of the element.
240240
241241
:Args:
242242
- to_element: The WebElement to move to.
243-
- xoffset: X offset to move to.
244-
- yoffset: Y offset to move to.
243+
- xoffset: X offset to move to, as a positive or negative integer.
244+
- yoffset: Y offset to move to, as a positive or negative integer.
245245
"""
246246

247247
self.w3c_actions.pointer_action.move_to(to_element, int(xoffset), int(yoffset))

0 commit comments

Comments
 (0)