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

Renamed keyevent to press_keycode and added long_press_keycode. #2673

Merged
merged 1 commit into from May 28, 2014

Conversation

paymand
Copy link
Member

@paymand paymand commented May 26, 2014

Finishing off what was started in #1155.
Changes to Python bindings: appium/python-client#21

@bootstraponline
Copy link
Member

Looks good to me. I think we'll want appium 1.1 to ship before merging breaking changes.

@paymand
Copy link
Member Author

paymand commented May 27, 2014

Sure. This can wait of course.

@@ -94,7 +94,8 @@ module.exports = function (appium) {
// appium-specific extensions to JSONWP
rest.post('/wd/hub/session/:sessionId?/appium/device/shake', controller.mobileShake);
rest.post('/wd/hub/session/:sessionId?/appium/device/lock', controller.lock);
rest.post('/wd/hub/session/:sessionId?/appium/device/keyevent', controller.keyevent);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is there a reason we can't keep this around and just alias it to pressKeyCode for now? that way existing code doesn't break.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Originally this was implemented via adb shell input keyevent and that's why it was named keyevent. @paymand had pointed out on Slack that this name isn't great and press_keycode / long_press_keycode are more accurate now that uiautomator is used.

I think it's fine to keep an alias for now, it'd be nice to remove it after a depreciation period though.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

agreed. keeping the alias just means we don't have to change all the clients immediately, so I can merge this asap.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Makes sense to me. 👍

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agreed. Pushed a fixup.

@bootstraponline
Copy link
Member

Squash to one commit please.

@paymand
Copy link
Member Author

paymand commented May 28, 2014

Done.

jlipps added a commit that referenced this pull request May 28, 2014
Renamed keyevent to press_keycode and added long_press_keycode.
@jlipps jlipps merged commit 399adf2 into appium:master May 28, 2014
@jlipps
Copy link
Member

jlipps commented May 28, 2014

thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants