# HG changeset patch # User hamidouk # Date 1326903712 -3600 # Node ID 18318dd611c2cadc6abcf8d6ab4cf41e48ac87f5 # Parent 9013f6382f8cf44c374d315f9c1078e876c71599 made the stackGraphWidget send a message when hovered. diff -r 9013f6382f8c -r 18318dd611c2 src/js/widgets/stackGraphWidget.js --- a/src/js/widgets/stackGraphWidget.js Wed Jan 18 17:21:00 2012 +0100 +++ b/src/js/widgets/stackGraphWidget.js Wed Jan 18 17:21:52 2012 +0100 @@ -159,6 +159,12 @@ }) .mousemove(function(_e) { _this.updateTooltip(_e); + + // Also tell the world where the mouse is hovering. + var relX = event.pageX - this.selector.offset().left; + var duration = this._serializer.currentMedia().meta["dc:duration"]; + var Time = ((relX / _this.width) * duration).toFixed(2); + _this._Popcorn.trigger("IriSP.StackGraphWidget.mouseOver", Time); }) .mouseout(function() { _this.TooltipWidget.hide();