@@ -350,23 +350,6 @@ def hide_keyboard(self, key_name=None, key=None, strategy=None):
350350 self .execute (Command .HIDE_KEYBOARD , data )
351351 return self
352352
353- # TODO: remove when new Appium is out
354- def keyevent (self , keycode , metastate = None ):
355- """Sends a keycode to the device. Android only. Possible keycodes can be
356- found in http://developer.android.com/reference/android/view/KeyEvent.html.
357-
358- :Args:
359- - keycode - the keycode to be sent to the device
360- - metastate - meta information about the keycode being sent
361- """
362- data = {
363- 'keycode' : keycode ,
364- }
365- if metastate is not None :
366- data ['metastate' ] = metastate
367- self .execute (Command .KEY_EVENT , data )
368- return self
369-
370353 def press_keycode (self , keycode , metastate = None ):
371354 """Sends a keycode to the device. Android only. Possible keycodes can be
372355 found in http://developer.android.com/reference/android/view/KeyEvent.html.
@@ -657,9 +640,6 @@ def _addCommands(self):
657640 ('POST' , '/session/$sessionId/touch/multi/perform' )
658641 self .command_executor ._commands [Command .GET_APP_STRINGS ] = \
659642 ('POST' , '/session/$sessionId/appium/app/strings' )
660- # TODO: remove when new Appium is out
661- self .command_executor ._commands [Command .KEY_EVENT ] = \
662- ('POST' , '/session/$sessionId/appium/device/keyevent' )
663643 self .command_executor ._commands [Command .PRESS_KEYCODE ] = \
664644 ('POST' , '/session/$sessionId/appium/device/press_keycode' )
665645 self .command_executor ._commands [Command .LONG_PRESS_KEYCODE ] = \
0 commit comments