more explicit names for draw<Shape>

This commit is contained in:
Gavin McDonald
2016-02-19 13:06:50 -05:00
parent 63af7b6db8
commit 42ca0b6e4b
4 changed files with 3 additions and 20 deletions

21
src/drawCircle.js Normal file
View File

@@ -0,0 +1,21 @@
export default class DrawCircle {
constructor(settings) {
}
filled(context, cell) {
context.beginPath();
context.arc(cell.x, cell.y, cell.scale, 0, 2*Math.PI, false);
context.fillStyle = cell.getColor();
context.fill();
}
outline(context, cell) {
context.beginPath();
context.arc(cell.x, cell.y, cell.scale, 0, 2*Math.PI, false);
context.lineWidth = cell.width;
context.strokeStyle = cell.getColor();
context.stroke();
}
}