Commit 1b097a63 authored by Joel Martin's avatar Joel Martin

Fix strict mode complaints in firefox 4.

parent 72f1348b
...@@ -10,7 +10,7 @@ ...@@ -10,7 +10,7 @@
/*jslint browser: true, white: false, bitwise: false */ /*jslint browser: true, white: false, bitwise: false */
/*global window, Util, Base64 */ /*global window, Util, Base64 */
Canvas = function(conf) { function Canvas(conf) {
conf = conf || {}; // Configuration conf = conf || {}; // Configuration
var that = {}, // Public API interface var that = {}, // Public API interface
...@@ -391,6 +391,9 @@ that.resize = function(width, height, true_color) { ...@@ -391,6 +391,9 @@ that.resize = function(width, height, true_color) {
that.clear = function() { that.clear = function() {
that.resize(640, 20); that.resize(640, 20);
conf.ctx.clearRect(0, 0, c_width, c_height); conf.ctx.clearRect(0, 0, c_width, c_height);
// No benefit over default ("source-over") in Chrome and firefox
//conf.ctx.globalCompositeOperation = "copy";
}; };
that.stop = function() { that.stop = function() {
......
...@@ -11,7 +11,7 @@ ...@@ -11,7 +11,7 @@
/*global window, document */ /*global window, document */
// Globals defined here // Globals defined here
var WebUtil = {}, $; var WebUtil = {}, $D;
/* /*
* Simple DOM selector by ID * Simple DOM selector by ID
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment