       for new_tool in new_tools
         # Set settings
         toolWindow = new_tool.el.closest('.window-container')
+        unless new_tool.settings_toggle
+          toolWindow.find(".settings").removeClass('active')
         toolWindow.find(".data-sources [data-source=#{new_tool.bindOptions.type}]").click()
         toolWindow.find(".source-choices").val(new_tool.bindOptions.source)
         toolWindow.find(".data-points input[name=params]").val(new_tool.bindOptions.params)
 
   # Helpers
+  getOffset: (tool) ->
+    toolWindow = tool.el.closest('.window-container')
+    toolWindow.offset()
+
   getZIndex: (tool) ->
-    z_index = if _.isNaN(parseInt(tool.el.css('z-index'))) then 0 else tool.el.css('z-index')
+    toolWindow = tool.el.closest('.window-container')
+    z_index = if toolWindow.css('z-index') is 'auto' then 0 else parseInt(toolWindow.css('z-index'))
+
+  getSettingsToggle: (tool) ->
+    toolWindow = tool.el.closest('.window-container')
+    if toolWindow.find('.settings').hasClass('active') then true else false
     
 
 module.exports = State
          binding: tool.bindOptions
          index: tool.count
          pos: pos
          z_index: parseInt(z_index)
        }

      tools.push obj

    state = {
        'tools': tools
      }

    $.post 'http://localhost:3001/state', {state: JSON.stringify(state)}, (data) ->
      console.log 'state saved', data

  load: (params) =>
    @trigger 'remove-all-tools'

      new_tools = []

      # Normalize z-index
      lowest_z_index = (_.min data.tools, (tool) -> tool.z_index).z_index
      _.each data.tools, (tool) -> tool.z_index -= lowest_z_index

      # Build initial state
      for tool in data.tools
