moveTo method
Future
moveTo(
- covariant PageLoaderElement element,
- int? xOffset,
- int? yOffset, {
- List<
PageLoaderElement> ? dispatchTo, - int? stepPixels,
- Duration? duration,
override
Move the mouse from previous location to a location relative to element
,
offset by xOffset
and yOffset
.
If xOffset
and yOffset
are both null, automatically moves the mouse
to the center of element
.
The optional named parameters have no impact when used with Webdriver implementation.
Otherwise, mouse events are sent along the mouse path
every stepPixels
over duration
milliseconds. If any of the
dispatchTo
land on these intervals, mouse events are also sent
to that element. If stepPixels
is not provided, the mouse movement
instantaneously moves from its current position to the final position
with no intermediate steps. If provided, stepPixels
must be a value
greater than zero.
Implementation
@override
Future moveTo(PageLoaderElement element, int? xOffset, int? yOffset,
{List<PageLoaderElement>? dispatchTo,
int? stepPixels,
Duration? duration}) async =>
_driver.mouse.moveTo(
element: (element as WebDriverPageLoaderElement).contextSync
as wd.WebElement,
xOffset: xOffset,
yOffset: yOffset);