Bug 1264323 - Set namespace when DOMParser.parseFromString(application/xhtml+xml). r=smaug

This commit is contained in:
John Dai 2016-06-30 03:58:00 +02:00
Родитель 25b47e2c0a
Коммит 529d13327c
2 изменённых файлов: 5 добавлений и 3 удалений

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

@ -13375,6 +13375,11 @@ nsIDocument::SetCachedEncoder(already_AddRefed<nsIDocumentEncoder> aEncoder)
void
nsIDocument::SetContentTypeInternal(const nsACString& aType)
{
if (!IsHTMLOrXHTML() && mDefaultElementType == kNameSpaceID_None &&
aType.EqualsLiteral("application/xhtml+xml")) {
mDefaultElementType = kNameSpaceID_XHTML;
}
mCachedEncoder = nullptr;
mContentType = aType;
}

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

@ -6,6 +6,3 @@
[Created element's namespace in created SVG document]
expected: FAIL
[Created element's namespace in created XHTML document by DOMParser ('application/xhtml+xml')]
expected: FAIL