Skip to content
Browse files

Use confirm() on shake detect

  • Loading branch information...
1 parent 0ac6e12 commit d3f1045c2b1f36c389d877ddf22752900dc4dc9f @alexgibson committed Jun 19, 2012
Showing with 4 additions and 0 deletions.
  1. +4 −0 main.js
View
4 main.js
@@ -172,6 +172,10 @@ var sketch = (function () {
},
clearCanvas: function () {
+
+ if (!confirm("Clear the drawing?")) {
+ return;
+ }
canvas.setAttribute("height", window.innerHeight + "px");
canvas.setAttribute("width", window.innerWidth + "px");
}

0 comments on commit d3f1045

Please sign in to comment.
Something went wrong with that request. Please try again.