From fa216cb9f3a4ce5ce616e019c767cbc38136f182 Mon Sep 17 00:00:00 2001 From: "dbaron%dbaron.org" Date: Wed, 19 Apr 2006 19:07:41 +0000 Subject: [PATCH] Work around possible deficiency in HTML parser by replacing runs of whitespace with a single space in the title attribute. b=67127 Patch by Steuard Jensen . r=bryner sr=dbaron git-svn-id: svn://10.0.0.236/trunk@194688 18797224-902f-48f8-a5cc-f745e15eee43 --- mozilla/browser/base/content/browser.js | 3 ++- mozilla/xpfe/browser/resources/content/browser.js | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/mozilla/browser/base/content/browser.js b/mozilla/browser/base/content/browser.js index 5324b5a789d..578e32249da 100644 --- a/mozilla/browser/base/content/browser.js +++ b/mozilla/browser/base/content/browser.js @@ -2529,7 +2529,8 @@ function FillInHTMLTooltip(tipElement) for (var i = 0; i < texts.length; ++i) { var t = texts[i]; if (t && t.search(/\S/) >= 0) { - tipNode.setAttribute("label", t); + // XXX - Short-term fix to bug 67127: collapse whitespace here + tipNode.setAttribute("label", t.replace(/\s+/g, " ") ); retVal = true; } } diff --git a/mozilla/xpfe/browser/resources/content/browser.js b/mozilla/xpfe/browser/resources/content/browser.js index a113eeb1d4a..99e8a93b5a8 100644 --- a/mozilla/xpfe/browser/resources/content/browser.js +++ b/mozilla/xpfe/browser/resources/content/browser.js @@ -266,7 +266,8 @@ function FillInHTMLTooltip(tipElement) for (var i = 0; i < texts.length; ++i) { var t = texts[i]; if (t && t.search(/\S/) >= 0) { - tipNode.setAttribute("label", t); + // XXX - Short-term fix to bug 67127: collapse whitespace here + tipNode.setAttribute("label", t.replace(/\s+/g, " ") ); retVal = true; } }