Bug 1328498 - Sourceeditor appendTo HTML element supports r=Honza

MozReview-Commit-ID: 1gdhH8PdIuc

--HG--
extra : rebase_source : f6722997d50d47d7a43e01921af2135b165295d9
This commit is contained in:
Ricky Chien 2017-01-04 11:52:26 +08:00
parent 56b56f5c9f
commit a8a552beb9

View File

@ -257,10 +257,12 @@ Editor.prototype = {
let cm = editors.get(this);
if (!env) {
env = el.ownerDocument.createElementNS(XUL_NS, "iframe");
}
env = el.ownerDocument.createElementNS(el.namespaceURI, "iframe");
env.flex = 1;
if (el.namespaceURI === XUL_NS) {
env.flex = 1;
}
}
if (cm) {
throw new Error("You can append an editor only once.");