Expose Getter and Setter for Engine Running Variable

This commit is contained in:
Marty Oehme 2018-07-09 17:00:53 +02:00
parent e472766bcc
commit 7c49531d0e
1 changed files with 4 additions and 1 deletions

View File

@ -20,7 +20,7 @@ class Engine {
final html.CanvasElement canvas;
Grid grid = new Grid(100, 100);
bool running = false;
bool _running = false;
Engine(this.canvas) {
_elapsed.start();
@ -66,4 +66,7 @@ class Engine {
// print("rendering");
grid.render(canvas, interp);
}
void set running(bool on) => _running = on;
bool get running => _running;
}