Bug 637159 - Clean up the fix / workaround for bug 635252. r=neil

This commit is contained in:
Dão Gottwald 2011-03-23 12:36:25 +01:00
Родитель 6f94cbba35
Коммит ee40eb8a6e
1 изменённых файлов: 10 добавлений и 10 удалений

Просмотреть файл

@ -110,24 +110,24 @@
<!-- =================== nsIAutoCompleteInput =================== -->
<field name="popup"><![CDATA[
// Wrap in an anonymous function so that the var statements don't
// create properties on 'this'.
(function (that) {
var popup = null;
var popupId = that.getAttribute("autocompletepopup");
// Wrap in a block so that the let statements don't
// create properties on 'this' (bug 635252).
{
let popup = null;
let popupId = this.getAttribute("autocompletepopup");
if (popupId)
popup = document.getElementById(popupId);
if (!popup) {
popup = document.createElement("panel");
popup.setAttribute("type", "autocomplete");
popup.setAttribute("noautofocus", "true");
var popupset = document.getAnonymousElementByAttribute(that, "anonid", "popupset");
let popupset = document.getAnonymousElementByAttribute(this, "anonid", "popupset");
popupset.appendChild(popup);
}
popup.mInput = that;
return popup;
})(this);
popup.mInput = this;
popup;
}
]]></field>
<property name="controller" onget="return this.mController;" readonly="true"/>