     @editor.decorateMarker @marker, mark
     @disposables.add @marker.onDidChange (e) => @checkMarker e
 
+  toggleTree: ->
+    trees.toggle $(@view).find('> .tree')
+
   remove: ->
     @view.classList.add 'ink-hide'
     @timeout 200, => @destroy()

# TODO: better scrolling behaviour
{CompositeDisposable} = require 'atom'

# ## Result API
# `Result`s are DOM elements which represent the result of some operation. They

          done = true
    e.abortKeyBinding() unless done

  @toggleCurrent: ->
    ed = atom.workspace.getActiveTextEditor()
    for sel in ed.getSelections()
      rs = @forLines ed, sel.getHeadBufferPosition().row, sel.getTailBufferPosition().row
      rs.map (r) -> r.toggleTree()

  # Commands

  @activate: ->
