     scope.providers = []
     scope.collapsed = true # Hide details in reduced real-estate view.
     scope.items = {}
+    scope.messages = {}
     scope.state = {}
 
     toolNotFound = (e) -> to -> scope.error = e


    scope.nextSteps = []

    scope.$watchCollection 'items', ->
      console.log "Items changed"
      exporters = []
      for tool in scope.nextTools when tool.handles is 'items'
        for key, data of scope.items when data.ids.length
          exporters.push {key, data, tool}
      otherSteps = (s for s in scope.nextSteps when s.tool.handles isnt 'items')
      scope.nextSteps = otherSteps.concat(exporters)

    scope.$watch 'list', ->
      listHandlers = []


    scope.setItems = (key, type, ids) -> to -> scope.items[key] = {type, ids}

    scope.hasSomething = (what, data, key) ->
      if what is 'list'
        to -> scope.list = data
      else
        for tool in scope.nextTools when tool.handles is what then do (tool, what, data, key) ->
          idx = tool.ident + what + key
          if scope.messages[idx]?
            scope.messages[idx].data = data
          else
            to -> scope.messages[idx] = {tool, data, kind: 'msg'}

    letUserChoose = (tools) ->
      dialogue = $modal.open
