Permalink
Browse files

Removed animation interval parameter

  • Loading branch information...
1 parent b373d7e commit ed57f500798270f6149f271191298814c8844aa0 @dhotson committed Nov 5, 2012
Showing with 4 additions and 5 deletions.
  1. +3 −4 springy.js
  2. +1 −1 springyui.js
View
@@ -411,7 +411,7 @@ Layout.requestAnimationFrame = __bind(window.requestAnimationFrame ||
// start simulation
-Layout.ForceDirected.prototype.start = function(interval, render, done) {
+Layout.ForceDirected.prototype.start = function(render, done) {
var t = this;
if (this._started) return;
@@ -547,8 +547,7 @@ Layout.ForceDirected.Spring = function(point1, point2, length, k) {
// };
// Renderer handles the layout rendering loop
-function Renderer(interval, layout, clear, drawEdge, drawNode) {
- this.interval = interval;
+function Renderer(layout, clear, drawEdge, drawNode) {
this.layout = layout;
this.clear = clear;
this.drawEdge = drawEdge;
@@ -563,7 +562,7 @@ Renderer.prototype.graphChanged = function(e) {
Renderer.prototype.start = function() {
var t = this;
- this.layout.start(50, function render() {
+ this.layout.start(function render() {
t.clear();
t.layout.eachEdge(function(edge, spring) {
View
@@ -131,7 +131,7 @@ jQuery.fn.springy = function(params) {
return 20;
};
- var renderer = new Renderer(1, layout,
+ var renderer = new Renderer(layout,
function clear() {
ctx.clearRect(0,0,canvas.width,canvas.height);
},

0 comments on commit ed57f50

Please sign in to comment.