From 5bd080fd0508197e34e03e2d73447b7cfe9a3c26 Mon Sep 17 00:00:00 2001 From: Adil Allawi Date: Thu, 15 Dec 2011 11:32:58 +0000 Subject: [PATCH] oops, interval was not clearing because 'this' is not the same 'this' inside an interval. Should use local variable 'self' instead. Reviewers you should have spotted this! :) --- src/canvas.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/canvas.js b/src/canvas.js index 2d1130b4f..50c762bca 100644 --- a/src/canvas.js +++ b/src/canvas.js @@ -361,7 +361,7 @@ var CanvasGraphics = (function CanvasGraphicsClosure() { textLayerQueue.splice(i, 1); } if (textLayerQueue.length == 0) - clearInterval(this.textLayerTimer); + clearInterval(self.textLayerTimer); }, 1); },