 
         input_line.on 'focus', =>
             @_input_line_is_focused = true
+            @terminal.blur()
         input_line.on 'blur', =>
             @_input_line_is_focused = false
 

        redux.getActions('file_use').mark_file(@project_id, @path, 'edit')

    client_keydown: (ev) =>
        #console.log("client_keydown", ev)
        if @_input_line_is_focused and ev.keyCode == 32
            # on mobile ipad we avoid sending space twice (see the hack in
            # term.js involving the smart keyboard)
            return false
        @mark_file_use()
        if ev.ctrlKey and ev.shiftKey
            switch ev.keyCode

focused_console = undefined
client_keydown = (ev) ->
    focused_console?.client_keydown(ev)

class Console extends EventEmitter
    constructor: (opts={}) ->
