예제 #1
0
def quit_player():
    '''
        Signals the player to shut down gracefully, by sending the ESC keystroke.
        There is a possiblity it may not succeed if the keystroke is lost.
    '''
    import scalatools
    _log.info('called.')
    scalatools.send_key('escape')
예제 #2
0
def quit_player():
    '''
        Signals the player to shut down gracefully, by sending the ESC keystroke.
        There is a possiblity it may not succeed if the keystroke is lost.
    '''
    import scalatools
    _log.info('called.')
    scalatools.send_key('escape')
예제 #3
0
def scmd_send_key(*args):
    '''
        Send a virtual key press event to this listener\'s machine.
        Example:
            send_key f5
    '''
    import scalatools as st
    if not args:  raise TypeError, 'no arguments given.'
    for key in args:
        if not st.send_key(key):
            return 'ERROR key not found.'
예제 #4
0
def scmd_send_key(*args):
    '''
        Send a virtual key press event to this listener\'s machine.
        Example:
            send_key f5
    '''
    import scalatools as st
    if not args: raise TypeError, 'no arguments given.'
    for key in args:
        if not st.send_key(key):
            return 'ERROR key not found.'