Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update handling of submit buttons on iOS keyboards #24

Open
ctrevarthen opened this issue Sep 11, 2019 · 0 comments
Open

Update handling of submit buttons on iOS keyboards #24

ctrevarthen opened this issue Sep 11, 2019 · 0 comments
Labels
enhancement New feature or request in progress This issue is being worked on currently

Comments

@ctrevarthen
Copy link
Contributor

In order to close an iOS keyboard/submit a form field, we rely on the keyboard toolbar to exist and have a button labeled "Done" (or some variant). This won't always be the case, so we need a more robust way of closing the iOS keyboard.

We can use the following:

import com.kms.katalon.core.mobile.keyword.internal.MobileDriverFactory
import io.appium.java_client.ios.IOSDriver
import io.appium.java_client.remote.HideKeyboardStrategy

IOSDriver<?> driver = MobileDriverFactory.getDriver()
driver.hideKeyboard(HideKeyboardStrategy.PRESS_KEY, "Search")

Where we replace the text of the "Search" key with whatever the keyboard's "Enter" button is. NOTE: This could probably be an enum since iOS has a limited number of words you can use for the standard keyboard enter key.

@ctrevarthen ctrevarthen added the enhancement New feature or request label Sep 11, 2019
@ctrevarthen ctrevarthen added the in progress This issue is being worked on currently label Sep 29, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request in progress This issue is being worked on currently
Projects
None yet
Development

No branches or pull requests

1 participant