diff --git a/docs/en/writing-running-appium/ios-xctest-mobile-gestures.md b/docs/en/writing-running-appium/ios-xctest-mobile-gestures.md index f1255611d..571bab874 100644 --- a/docs/en/writing-running-appium/ios-xctest-mobile-gestures.md +++ b/docs/en/writing-running-appium/ios-xctest-mobile-gestures.md @@ -111,6 +111,28 @@ driver.execute('mobile: doubleTap', {element: element.value.ELEMENT}); ``` +### mobile: touchAndHold + +Performs long press gesture on the given element or on the screen. + +#### Supported arguments + + * _element_: The internal element identifier (as hexadecimal hash string) to long tap on + * _duration_: The float duration of press action in seconds. Mandatory patameter + * _x_: Screen x long tap coordinate of type float. Mandatory parameter only if _element_ is not set + * _y_: Screen y long tap coordinate of type float. Mandatory parameter only if _element_ is not set + +#### Usage examples + +```csharp +// c# +Dictionary tfLongTap = new Dictionary(); +tfLongTap.Add("element", element.Id); +tfLongTap.Add("duration", 2.0); +((IJavaScriptExecutor)driver).ExecuteScript("mobile: touchAndHold", tfLongTap); +``` + + ### mobile: twoFingerTap Performs two finger tap gesture on the given element or on the application element. @@ -127,7 +149,7 @@ Performs two finger tap gesture on the given element or on the application eleme // c# Dictionary tfTap = new Dictionary(); tfTap.Add("element", element.Id); -((IJavaScriptExecutor)driver).ExecuteScript("mobile: twoFingerTap", tfTap)); +((IJavaScriptExecutor)driver).ExecuteScript("mobile: twoFingerTap", tfTap); ```