summaryrefslogtreecommitdiff
path: root/dom
diff options
context:
space:
mode:
authorGaming4JC <g4jc@hyperbola.info>2020-01-05 12:28:48 -0500
committerGaming4JC <g4jc@hyperbola.info>2020-01-26 15:50:27 -0500
commit5840b63cca00a45c8c40bf5e04195aabd4dabb73 (patch)
treed431d2a749758b6cfeecf4b966353ba610c4b527 /dom
parent45a4aaf7e0e6586e45d8da0bcc88b9ec8f539967 (diff)
downloaduxp-5840b63cca00a45c8c40bf5e04195aabd4dabb73.tar.gz
Bug 1301024 - Part 1: Set CreateElement/CreateElementNS is attribute.
Tag UXP Issue #1344
Diffstat (limited to 'dom')
-rw-r--r--dom/base/nsDocument.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/dom/base/nsDocument.cpp b/dom/base/nsDocument.cpp
index 602da421a4..99f922c98b 100644
--- a/dom/base/nsDocument.cpp
+++ b/dom/base/nsDocument.cpp
@@ -5399,6 +5399,10 @@ nsDocument::CreateElement(const nsAString& aTagName,
RefPtr<Element> elem = CreateElem(
needsLowercase ? lcTagName : aTagName, nullptr, mDefaultElementType, is);
+ if (is) {
+ elem->SetAttr(kNameSpaceID_None, nsGkAtoms::is, *is, true);
+ }
+
return elem.forget();
}
@@ -5443,6 +5447,10 @@ nsDocument::CreateElementNS(const nsAString& aNamespaceURI,
return nullptr;
}
+ if (is) {
+ element->SetAttr(kNameSpaceID_None, nsGkAtoms::is, *is, true);
+ }
+
return element.forget();
}