From 30608ffdf72d286e51c15b426f8f67317e926267 Mon Sep 17 00:00:00 2001 From: SHIMODA Hiroshi Date: Tue, 7 Dec 2010 19:22:41 +0900 Subject: [PATCH] don't call positionPinnedTabs() too many times --- content/treestyletab/treestyletabbrowser.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/content/treestyletab/treestyletabbrowser.js b/content/treestyletab/treestyletabbrowser.js index 11f17e3c..97c1f481 100644 --- a/content/treestyletab/treestyletabbrowser.js +++ b/content/treestyletab/treestyletabbrowser.js @@ -237,8 +237,12 @@ TreeStyleTabBrowser.prototype = { }, positionPinnedTabsWithDelay : function TSTBrowser_positionPinnedTabsWithDelay() { - window.setTimeout(function(aSelf) { + if (this.positionPinnedTabsWithDelayTimer) + return; + + this.positionPinnedTabsWithDelay = window.setTimeout(function(aSelf) { aSelf.positionPinnedTabs(); + aSelf.positionPinnedTabsWithDelay = null; }, 0, this); }, PINNED_TAB_DEFAULT_WIDTH : 24,