Cleaned FrameRenderer.js FrameRenderer should also keep a reference on the frame it is updating - initially I wanted the renderer to be frame independant, but it doesnt bring much

This commit is contained in:
juliandescottes
2012-09-09 02:34:54 +02:00
parent 873a10caa2
commit 68c2cae658
3 changed files with 30 additions and 48 deletions

View File

@@ -35,7 +35,6 @@
// The fake canvas where we will draw the preview of the stroke:
// Drawing the first point of the stroke in the fake overlay canvas:
drawer.overlayFrame.setPixel(col, row, color);
drawer.renderOverlay();
};
ns.Stroke.prototype.moveToolAt = function(col, row, color, drawer) {
@@ -59,7 +58,6 @@
}
drawer.overlayFrame.setPixel(strokePoints[i].col, strokePoints[i].row, color);
}
drawer.renderOverlay();
};
/**
@@ -78,7 +76,6 @@
}
// Draw in canvas:
// TODO: Remove that when we have the centralized redraw loop
drawer.renderFrame();
}
// For now, we are done with the stroke tool and don't need an overlay anymore:
drawer.clearOverlay();