 
     destroy: () -> @remove()
 
-    focus: () -> @$el.focus()
+    focus: () -> @$input.focus()
 
     show: () ->
 


  class CellEditorView extends ContinuumView

    emptyValue: null
    defaultValue: null



    emptyValue: ""

    input: '<input type="text" class="bk-cell-editor bk-cell-editor-string" />'

    renderEditor: () ->
      completions = @model.get("completions")
      if not _.isEmpty(completions)
        @$input.autocomplete(source: completions)
        @$input.autocomplete("widget").addClass("bk-cell-editor-completion")
      @$input.focus().select()

    loadValue: (item) ->
      super(item)
      @$input[0].defaultValue = @defaultValue
      @$input.select()

  class StringEditor extends CellEditor
    type: 'StringEditor'
