           index: tool.index
           channel: tool.channel
           filters: tool.filters
-
+          
         # I don't like this
         switch tool.name
           when "Map" then new_tool = params.dashboard.createTool Map, options

Histogram = require('controllers/Histogram')
Statistics = require('ubret/lib/controllers/Statistics')
WWT = require('ubret/lib/controllers/WWT')

class State extends Spine.Controller


          when "Histogram" then new_tool = params.dashboard.createTool Histogram, options
          when "Statistics" then new_tool = params.dashboard.createTool Statistics, options
          when "WWT" then new_tool = params.dashboard.createTool WWT, options
          when "Spectra" then new_tool = params.dashboard.createTool Spectra, options

        new_tool.data = tool.data
        new_tool.setBindOptions tool.bind_options.source, tool.bind_options.params

        toolWindow = new_tool.el.closest('.window-container')
        toolWindow.offset tool.pos
        toolWindow.css 'z-index', tool.z_index
        unless new_tool.settings_toggle
          toolWindow.find(".settings").removeClass('active')

        new_tools.push new_tool

      # Because some things may depend on all tools being available, run through the tools again to set setttings and the like.
      # Likely better ways to do this.
