js/playscreen.js
changeset 23 933b388521f6
parent 22 4e1e66b2fdf1
child 24 b557f4bae85f
equal deleted inserted replaced
22:4e1e66b2fdf1 23:933b388521f6
   424         
   424         
   425 		ctx.strokeStyle = "#ccc";
   425 		ctx.strokeStyle = "#ccc";
   426 		
   426 		
   427         $(".play-localtweets .tweet").each(function() {
   427         $(".play-localtweets .tweet").each(function() {
   428         	var el = $(this),
   428         	var el = $(this),
   429         		liY = + el.offset().top + el.outerHeight() / 2 - deltaY,
   429         		liY = + el.offset().top + el.outerHeight() / 2 - deltaY;
   430         		t = +el.attr("data-timestamp"),
   430     		if (liY < 0 || liY > ph) {
       
   431     		    return;
       
   432     		}
       
   433         	var t = +el.attr("data-timestamp"),
   431         		tY = localyscale * (t - localpos + localduration / 2),
   434         		tY = localyscale * (t - localpos + localduration / 2),
   432                 tX = localL + lxscale * (data.fiveseconds[Math.floor(t / 5)].count - lmi);
   435                 tX = localL + lxscale * (data.fiveseconds[Math.floor(t / 5)].count - lmi);
   433     		ctx.beginPath();
   436     		ctx.beginPath();
   434     		ctx.moveTo(tX, tY);
   437     		ctx.moveTo(tX, tY);
   435     		ctx.lineTo(localR, tY);
   438     		ctx.lineTo(localR, tY);