     "dblclick": "edit"
     "blur input": "finishEdit"
     "keyup input": "finishEditOnEnter"
+
+    # Editing the actual task
+    'click .name': 'startEdit'
+    'blur .name': 'endEdit'
 
   constructor: ->
     super

    if List.current.id isnt "all" and task.list isnt List.current.id
      @release()

  remove: ->
    @task.destroy()


    @task.completed = !@task.completed
    @task.save()

  startEdit: (e) ->
    $(e.currentTarget).parent().draggable({ disabled: true }).find(".name").attr("contenteditable", "true")
    @log("clicked")

  endEdit: (e) ->
    $(e.currentTarget).removeAttr("contenteditable").parent().draggable({ disabled: false })
    @log("blur")

module.exports = TaskItem
