                     .style("top", (d3.event.pageY - 28) + "px")
         )
         .on("mouseout", (record) =>
+            @element.dispatchEvent(
+                new CustomEvent('recordMouseout', {
+                    detail: {
+                        dataset: dataset.id,
+                        start: record[0],
+                        end: record[1],
+                        params: record[2]
+                    }
+                    bubbles: true,
+                    cancelable: true
+                })
+            )
             @tooltip.transition()
                 .duration(500)
                 .style("opacity", 0)


        datasetElement.append("g")
            .attr("class", "y axis")
            .attr('fill', color)
            .call(@axis.y)
            .attr("transform", "translate("+((index+1)*30)+","+ (-@options.height+29)+")")

        datasetElement.selectAll('.axis .domain')
            .attr("stroke-width", "1")
            .attr("stroke", color)
            .attr("shape-rendering", "crispEdges")
            .attr("fill", "none")

        datasetElement.selectAll('.axis line')
            .attr("stroke-width", "1")
            .attr("shape-rendering", "crispEdges")
            .attr("stroke", color)

        datasetElement.selectAll('.axis path')
            .attr("stroke-width", "1")
            .attr("shape-rendering", "crispEdges")
            .attr("stroke", color)

    # this function acually draws a dataset


        @redraw()
        true

    hasDataset: (id) ->
        return false unless @datasets[id]?

    # TODO redraws.
    center: (params...) ->
        start = new Date(params[0])
