summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMoonchild <moonchild@palemoon.org>2020-09-23 23:45:46 +0000
committerMoonchild <moonchild@palemoon.org>2020-09-23 23:45:46 +0000
commit9f5c27ba479c54d4ebb1bd59b61fbf793f6df93f (patch)
tree831e0ae1649d6135429def03688bc93ff7c86b03
parent42f895f27f239e973c9c06241f7a58da7381353c (diff)
parentf624bd1375655dea196cdcb70a9860bc5817df49 (diff)
downloadUXP-9f5c27ba479c54d4ebb1bd59b61fbf793f6df93f.tar
UXP-9f5c27ba479c54d4ebb1bd59b61fbf793f6df93f.tar.gz
UXP-9f5c27ba479c54d4ebb1bd59b61fbf793f6df93f.tar.lz
UXP-9f5c27ba479c54d4ebb1bd59b61fbf793f6df93f.tar.xz
UXP-9f5c27ba479c54d4ebb1bd59b61fbf793f6df93f.zip
Merge branch 'redwood' into releaseRELBASE_20200929RC_20200924
-rw-r--r--CLOBBER2
-rw-r--r--accessible/base/ARIAMap.cpp10
-rw-r--r--accessible/mac/mozAccessible.mm3
-rw-r--r--accessible/tests/mochitest/attributes/test_obj.html6
-rw-r--r--accessible/tests/mochitest/role/test_aria.html6
-rw-r--r--dom/animation/AnimationPerformanceWarning.h6
-rw-r--r--dom/base/ResizeObserver.cpp304
-rw-r--r--dom/base/ResizeObserver.h254
-rw-r--r--dom/base/ResizeObserverController.cpp234
-rw-r--r--dom/base/ResizeObserverController.h129
-rw-r--r--dom/base/WindowNamedPropertiesHandler.h2
-rw-r--r--dom/base/crashtests/1251361.html33
-rw-r--r--dom/base/crashtests/371466-1.xhtml24
-rw-r--r--dom/base/crashtests/535926-1.html28
-rwxr-xr-xdom/base/moz.build4
-rw-r--r--dom/base/nsAttrValue.h4
-rw-r--r--dom/base/nsContentUtils.cpp16
-rw-r--r--dom/base/nsContentUtils.h8
-rw-r--r--dom/base/nsDocument.cpp28
-rw-r--r--dom/base/nsDocument.h8
-rw-r--r--dom/base/nsGkAtomList.h1
-rw-r--r--dom/base/nsGlobalWindow.cpp4
-rw-r--r--dom/base/nsIDocument.h5
-rw-r--r--dom/base/nsJSEnvironment.cpp2
-rw-r--r--dom/base/test/test_bug840098.html2
-rw-r--r--dom/base/test/test_caretPositionFromPoint.html2
-rw-r--r--dom/base/test/test_mutationobservers.html913
-rw-r--r--dom/bindings/BindingUtils.h12
-rw-r--r--dom/bindings/Bindings.conf15
-rw-r--r--dom/bindings/DOMJSClass.h2
-rw-r--r--dom/bindings/GenerateCSS2PropertiesWebIDL.py1
-rw-r--r--dom/bindings/mozwebidlcodegen/__init__.py2
-rw-r--r--dom/cache/DBSchema.cpp2
-rw-r--r--dom/canvas/test/webgl-conf/checkout/deqp/temp_externs/webkit_css.js456
-rw-r--r--dom/events/EventStates.h8
-rw-r--r--dom/heapsnapshot/HeapSnapshot.cpp2
-rw-r--r--dom/html/HTMLDivElement.cpp34
-rw-r--r--dom/html/HTMLTrackElement.cpp4
-rw-r--r--dom/html/nsHTMLDocument.cpp3
-rw-r--r--dom/html/test/test_bug389797.html1
-rw-r--r--dom/html/test/test_documentAll.html2
-rw-r--r--dom/indexedDB/ActorsParent.cpp12
-rw-r--r--dom/media/MediaCache.cpp2
-rw-r--r--dom/media/MediaStreamGraphImpl.h2
-rw-r--r--dom/media/platforms/PDMFactory.h8
-rw-r--r--dom/media/webaudio/blink/HRTFDatabaseLoader.cpp3
-rw-r--r--dom/media/webaudio/blink/HRTFDatabaseLoader.h9
-rw-r--r--dom/plugins/ipc/PluginModuleChild.cpp6
-rw-r--r--dom/script/ModuleLoadRequest.h2
-rw-r--r--dom/script/ScriptLoader.cpp115
-rw-r--r--dom/script/ScriptLoader.h16
-rw-r--r--dom/security/test/csp/file_bug1312272.html13
-rw-r--r--dom/security/test/csp/file_strict_dynamic_script_events_xbl.html14
-rw-r--r--dom/security/test/csp/test_strict_dynamic.html7
-rw-r--r--dom/smil/SMILBoolType.h2
-rw-r--r--dom/smil/SMILEnumType.h2
-rw-r--r--dom/smil/SMILIntegerType.h3
-rw-r--r--dom/smil/SMILStringType.h2
-rw-r--r--dom/smil/nsSMILCSSValueType.h2
-rw-r--r--dom/smil/nsSMILFloatType.h2
-rw-r--r--dom/smil/nsSMILNullType.h2
-rw-r--r--dom/svg/SVGIntegerPairSMILType.h2
-rw-r--r--dom/svg/SVGLengthListSMILType.h2
-rw-r--r--dom/svg/SVGMotionSMILType.h2
-rw-r--r--dom/svg/SVGNumberListSMILType.h2
-rw-r--r--dom/svg/SVGNumberPairSMILType.h2
-rw-r--r--dom/svg/SVGOrientSMILType.h2
-rw-r--r--dom/svg/SVGPathSegListSMILType.h2
-rw-r--r--dom/svg/SVGPointListSMILType.h2
-rw-r--r--dom/svg/SVGTransformListSMILType.h2
-rw-r--r--dom/svg/SVGViewBoxSMILType.h2
-rw-r--r--dom/tests/browser/browser_bug396843.js1
-rw-r--r--dom/tests/mochitest/bugs/mochitest.ini1
-rw-r--r--dom/tests/mochitest/bugs/test_bug1160342_marquee.html337
-rw-r--r--dom/tests/mochitest/bugs/test_bug396843.html1
-rw-r--r--dom/webidl/MediaQueryList.webidl16
-rw-r--r--dom/webidl/MediaQueryListEvent.webidl18
-rw-r--r--dom/webidl/ResizeObserver.webidl39
-rw-r--r--dom/webidl/moz.build2
-rw-r--r--dom/xbl/crashtests/342954-1.xhtml46
-rw-r--r--dom/xbl/crashtests/342954-2-xbl.xml19
-rw-r--r--dom/xbl/crashtests/342954-2.xhtml29
-rw-r--r--dom/xbl/crashtests/477878-1.html4
-rw-r--r--dom/xbl/nsXBLMaybeCompiled.h2
-rw-r--r--editor/libeditor/HTMLEditUtils.cpp1
-rwxr-xr-xgfx/thebes/gfxWindowsPlatform.cpp18
-rw-r--r--js/src/builtin/Object.cpp1
-rw-r--r--js/src/builtin/Object.js18
-rw-r--r--js/src/jsapi.cpp6
-rw-r--r--js/xpconnect/tests/chrome/test_xrayToJS.xul4
-rw-r--r--layout/base/crashtests/265027-1.html19
-rw-r--r--layout/base/crashtests/265986-1.html10
-rw-r--r--layout/base/crashtests/265999-1.html8
-rw-r--r--layout/base/crashtests/367498-2.html14
-rw-r--r--layout/base/crashtests/404491-1.html5
-rw-r--r--layout/base/crashtests/580129-1.html19
-rw-r--r--layout/base/crashtests/580494-1.html1
-rw-r--r--layout/base/crashtests/597924-1.html16
-rw-r--r--layout/base/nsCSSFrameConstructor.cpp8
-rw-r--r--layout/base/nsLayoutUtils.cpp34
-rw-r--r--layout/base/nsPresContext.cpp26
-rw-r--r--layout/base/nsPresShell.cpp5
-rw-r--r--layout/forms/nsLegendFrame.cpp4
-rw-r--r--layout/generic/ReflowInput.cpp1
-rw-r--r--layout/generic/crashtests/265867-1.html11
-rw-r--r--layout/generic/crashtests/348510-1.html7
-rw-r--r--layout/generic/crashtests/348510-2.html7
-rw-r--r--layout/generic/crashtests/363722-1.html9
-rw-r--r--layout/generic/crashtests/363722-2.html10
-rw-r--r--layout/generic/crashtests/370866-1.xhtml14
-rw-r--r--layout/generic/crashtests/379917-1.xhtml35
-rw-r--r--layout/generic/crashtests/398332-3.html4
-rw-r--r--layout/generic/crashtests/421671.html202
-rw-r--r--layout/generic/crashtests/619021.html5
-rw-r--r--layout/generic/crashtests/724235.html28
-rw-r--r--layout/generic/nsBlockFrame.cpp7
-rw-r--r--layout/generic/nsFrameStateBits.h3
-rw-r--r--layout/generic/nsHTMLParts.h3
-rw-r--r--layout/inspector/inDOMUtils.cpp4
-rw-r--r--layout/reftests/bidi/logicalmarquee.html11
-rw-r--r--layout/reftests/bidi/marquee-ref.html11
-rw-r--r--layout/reftests/bidi/reftest-stylo.list3
-rw-r--r--layout/reftests/bidi/reftest.list3
-rw-r--r--layout/reftests/bidi/visualmarquee.html11
-rw-r--r--layout/reftests/marquee/1160342-1.html10
-rw-r--r--layout/reftests/marquee/1160342-2.html10
-rw-r--r--layout/reftests/marquee/1160342-ref.html10
-rw-r--r--layout/reftests/marquee/166591-dynamic-1-ref.html6
-rw-r--r--layout/reftests/marquee/166591-dynamic-1.html11
-rw-r--r--layout/reftests/marquee/336736-1-ref.html5
-rw-r--r--layout/reftests/marquee/336736-1a.html13
-rw-r--r--layout/reftests/marquee/336736-1b.html13
-rw-r--r--layout/reftests/marquee/406073-1-ref.html11
-rw-r--r--layout/reftests/marquee/406073-1.html23
-rw-r--r--layout/reftests/marquee/407016-2-ref.html5
-rw-r--r--layout/reftests/marquee/407016-2.html7
-rw-r--r--layout/reftests/marquee/413027-4-ref.html10
-rw-r--r--layout/reftests/marquee/413027-4.html15
-rw-r--r--layout/reftests/marquee/425247-1-ref.html9
-rw-r--r--layout/reftests/marquee/425247-1.html9
-rw-r--r--layout/reftests/marquee/425247-2-ref.html9
-rw-r--r--layout/reftests/marquee/425247-2.html9
-rw-r--r--layout/reftests/marquee/429849-1-ref.html10
-rw-r--r--layout/reftests/marquee/429849-1.html10
-rw-r--r--layout/reftests/marquee/reftest-stylo.list16
-rw-r--r--layout/reftests/marquee/reftest.list11
-rw-r--r--layout/reftests/moz.build2
-rw-r--r--layout/reftests/reftest-stylo.list3
-rw-r--r--layout/reftests/reftest.list3
-rw-r--r--layout/reftests/writing-mode/reftest-stylo.list2
-rw-r--r--layout/reftests/writing-mode/reftest.list2
-rw-r--r--layout/reftests/writing-mode/ua-style-sheet-size-1-ref.html22
-rw-r--r--layout/reftests/writing-mode/ua-style-sheet-size-1.html19
-rw-r--r--layout/reftests/writing-mode/ua-style-sheet-size-2-ref.html22
-rw-r--r--layout/reftests/writing-mode/ua-style-sheet-size-2.html19
-rw-r--r--layout/style/Loader.cpp12
-rw-r--r--layout/style/MediaQueryList.cpp215
-rw-r--r--layout/style/MediaQueryList.h48
-rw-r--r--layout/style/contenteditable.css9
-rw-r--r--layout/style/moz.build1
-rw-r--r--layout/style/nsCSSKeywordList.h1
-rw-r--r--layout/style/nsCSSParser.cpp54
-rw-r--r--layout/style/nsCSSPropList.h10
-rw-r--r--layout/style/nsCSSProps.cpp3
-rw-r--r--layout/style/nsCSSProps.h1
-rw-r--r--layout/style/nsRuleNode.cpp2
-rw-r--r--layout/style/nsStyleConsts.h1
-rw-r--r--layout/style/nsStyleStruct.h6
-rw-r--r--layout/style/res/html.css17
-rw-r--r--layout/style/test/property_database.js22
-rw-r--r--layout/style/xbl-marquee/jar.mn8
-rw-r--r--layout/style/xbl-marquee/moz.build7
-rw-r--r--layout/style/xbl-marquee/xbl-marquee.css12
-rw-r--r--layout/style/xbl-marquee/xbl-marquee.xml733
-rw-r--r--layout/svg/nsCSSClipPathInstance.cpp2
-rw-r--r--layout/xul/nsXULLabelFrame.cpp4
-rw-r--r--modules/libpref/init/all.js6
-rw-r--r--parser/html/java/htmlparser/src/nu/validator/htmlparser/impl/AttributeName.java3
-rw-r--r--parser/html/java/htmlparser/src/nu/validator/htmlparser/impl/ElementName.java3
-rw-r--r--parser/html/nsHtml5AtomList.h2
-rw-r--r--parser/html/nsHtml5AttributeName.cpp652
-rw-r--r--parser/html/nsHtml5AttributeName.h1
-rw-r--r--parser/html/nsHtml5ElementName.cpp248
-rw-r--r--parser/html/nsHtml5ElementName.h1
-rw-r--r--parser/html/nsHtml5SpeculativeLoad.cpp16
-rw-r--r--parser/html/nsHtml5SpeculativeLoad.h17
-rw-r--r--parser/html/nsHtml5TreeBuilderCppSupplement.h11
-rw-r--r--parser/html/nsHtml5TreeOpExecutor.cpp6
-rw-r--r--parser/html/nsHtml5TreeOpExecutor.h3
-rw-r--r--parser/htmlparser/nsElementTable.cpp4
-rw-r--r--parser/htmlparser/nsHTMLTagList.h1
-rw-r--r--security/certverifier/CertVerifier.cpp23
-rw-r--r--security/certverifier/NSSCertDBTrustDomain.cpp4
-rw-r--r--security/certverifier/NSSCertDBTrustDomain.h4
-rw-r--r--testing/mozbase/mozlog/mozlog/formatters/html/xmlgen.py2
-rw-r--r--testing/web-platform/tests/dom/nodes/Node-cloneNode.html1
-rw-r--r--testing/web-platform/tests/tools/html5lib/html5lib/constants.py2
-rw-r--r--testing/web-platform/tests/tools/html5lib/html5lib/html5parser.py19
-rw-r--r--testing/web-platform/tests/tools/html5lib/html5lib/tests/testdata/tree-construction/tests1.dat280
-rw-r--r--testing/web-platform/tests/tools/html5lib/html5lib/tests/testdata/tree-construction/tests19.dat12
-rw-r--r--testing/web-platform/tests/tools/html5lib/html5lib/treebuilders/_base.py4
-rw-r--r--testing/web-platform/tests/tools/py/py/_xmlgen.py2
-rw-r--r--toolkit/library/moz.build1
-rw-r--r--toolkit/locales/en-US/chrome/mozapps/extensions/extensions.dtd4
-rw-r--r--toolkit/mozapps/extensions/content/extensions.js14
-rw-r--r--toolkit/mozapps/extensions/content/extensions.xml4
-rw-r--r--toolkit/mozapps/extensions/content/extensions.xul10
-rw-r--r--widget/cocoa/nsDragService.mm4
-rw-r--r--widget/windows/AudioSession.cpp4
-rw-r--r--widget/windows/CompositorWidgetParent.cpp1
-rw-r--r--widget/windows/IMMHandler.cpp2
-rw-r--r--widget/windows/InkCollector.cpp2
-rw-r--r--widget/windows/KeyboardLayout.cpp5
-rw-r--r--widget/windows/TaskbarPreview.cpp14
-rw-r--r--widget/windows/WinIMEHandler.cpp4
-rw-r--r--widget/windows/WinUtils.cpp59
-rw-r--r--widget/windows/WinUtils.h39
-rw-r--r--widget/windows/nsAppShell.cpp64
-rw-r--r--widget/windows/nsFilePicker.cpp2
-rw-r--r--widget/windows/nsUXThemeData.cpp12
-rw-r--r--widget/windows/nsWindow.cpp10
-rw-r--r--xpcom/glue/nsBaseHashtable.h1
222 files changed, 2149 insertions, 4875 deletions
diff --git a/CLOBBER b/CLOBBER
index ba7942e61..0dc1fdb0d 100644
--- a/CLOBBER
+++ b/CLOBBER
@@ -22,4 +22,4 @@
# changes to stick? As of bug 928195, this shouldn't be necessary! Please
# don't change CLOBBER for WebIDL changes any more.
-Clobber for NSS update
+Clobber for CSS flow-root implementation
diff --git a/accessible/base/ARIAMap.cpp b/accessible/base/ARIAMap.cpp
index c29d37873..3a89cf9ed 100644
--- a/accessible/base/ARIAMap.cpp
+++ b/accessible/base/ARIAMap.cpp
@@ -347,16 +347,6 @@ static const nsRoleMapEntry sWAIRoleMaps[] =
eLandmark,
kNoReqStates
},
- { // marquee
- &nsGkAtoms::marquee,
- roles::ANIMATION,
- kUseMapRole,
- eNoValue,
- eNoAction,
- eOffLiveAttr,
- kGenericAccType,
- kNoReqStates
- },
{ // math
&nsGkAtoms::math,
roles::FLAT_EQUATION,
diff --git a/accessible/mac/mozAccessible.mm b/accessible/mac/mozAccessible.mm
index 07868fea6..a02779ef2 100644
--- a/accessible/mac/mozAccessible.mm
+++ b/accessible/mac/mozAccessible.mm
@@ -732,8 +732,6 @@ using namespace mozilla::a11y;
return @"AXDocument";
if (roleAtom == nsGkAtoms::log_)
return @"AXApplicationLog";
- if (roleAtom == nsGkAtoms::marquee)
- return @"AXApplicationMarquee";
if (roleAtom == nsGkAtoms::math)
return @"AXDocumentMath";
if (roleAtom == nsGkAtoms::note_)
@@ -869,7 +867,6 @@ static const RoleDescrMap sRoleDescrMap[] = {
{ @"AXApplicationAlert", NS_LITERAL_STRING("alert") },
{ @"AXApplicationAlertDialog", NS_LITERAL_STRING("alertDialog") },
{ @"AXApplicationLog", NS_LITERAL_STRING("log") },
- { @"AXApplicationMarquee", NS_LITERAL_STRING("marquee") },
{ @"AXApplicationStatus", NS_LITERAL_STRING("status") },
{ @"AXApplicationTimer", NS_LITERAL_STRING("timer") },
{ @"AXContentSeparator", NS_LITERAL_STRING("separator") },
diff --git a/accessible/tests/mochitest/attributes/test_obj.html b/accessible/tests/mochitest/attributes/test_obj.html
index 9e147e1d1..0706dd408 100644
--- a/accessible/tests/mochitest/attributes/test_obj.html
+++ b/accessible/tests/mochitest/attributes/test_obj.html
@@ -62,7 +62,6 @@ https://bugzilla.mozilla.org/show_bug.cgi?id=558036
testAbsentAttrs("live3", {"live" : ""});
testAttrs("log", {"live" : "polite"}, true);
testAttrs("logAssertive", {"live" : "assertive"}, true);
- testAttrs("marquee", {"live" : "off"}, true);
testAttrs("status", {"live" : "polite"}, true);
testAttrs("timer", {"live" : "off"}, true);
testAbsentAttrs("tablist", {"live" : "polite"});
@@ -72,7 +71,6 @@ https://bugzilla.mozilla.org/show_bug.cgi?id=558036
testAttrs("live2Child", {"container-live" : "polite"}, true);
testAttrs("logChild", {"container-live" : "polite"}, true);
testAttrs("logAssertiveChild", {"container-live" : "assertive"}, true);
- testAttrs("marqueeChild", {"container-live" : "off"}, true);
testAttrs("statusChild", {"container-live" : "polite"}, true);
testAttrs("timerChild", {"container-live" : "off"}, true);
testAbsentAttrs("tablistChild", {"container-live" : "polite"});
@@ -80,13 +78,11 @@ https://bugzilla.mozilla.org/show_bug.cgi?id=558036
// container-live-role object attribute
testAttrs("log", {"container-live-role" : "log"}, true);
testAttrs("logAssertive", {"container-live-role" : "log"}, true);
- testAttrs("marquee", {"container-live-role" : "marquee"}, true);
testAttrs("status", {"container-live-role" : "status"}, true);
testAttrs("timer", {"container-live-role" : "timer"}, true);
testAttrs("logChild", {"container-live-role" : "log"}, true);
testAttrs("logAssertive", {"container-live-role" : "log"}, true);
testAttrs("logAssertiveChild", {"container-live-role" : "log"}, true);
- testAttrs("marqueeChild", {"container-live-role" : "marquee"}, true);
testAttrs("statusChild", {"container-live-role" : "status"}, true);
testAttrs("timerChild", {"container-live-role" : "timer"}, true);
testAbsentAttrs("tablistChild", {"container-live-role" : "tablist"});
@@ -230,11 +226,9 @@ https://bugzilla.mozilla.org/show_bug.cgi?id=558036
<!-- back to aria -->
<div id="live" aria-live="polite">excuse <div id="liveChild">me</div></div>
- <div id="live2" role="marquee" aria-live="polite">excuse <div id="live2Child">me</div></div>
<div id="live3" role="region">excuse</div>
<div id="log" role="log">excuse <div id="logChild">me</div></div>
<div id="logAssertive" role="log" aria-live="assertive">excuse <div id="logAssertiveChild">me</div></div>
- <div id="marquee" role="marquee">excuse <div id="marqueeChild">me</div></div>
<div id="status" role="status">excuse <div id="statusChild">me</div></div>
<div id="tablist" role="tablist">tablist <div id="tablistChild">tab</div></div>
<div id="timer" role="timer">excuse <div id="timerChild">me</div></div>
diff --git a/accessible/tests/mochitest/role/test_aria.html b/accessible/tests/mochitest/role/test_aria.html
index 22021fa57..482ce4327 100644
--- a/accessible/tests/mochitest/role/test_aria.html
+++ b/accessible/tests/mochitest/role/test_aria.html
@@ -41,7 +41,6 @@
testRole("aria_listbox", ROLE_LISTBOX);
testRole("aria_listitem", ROLE_LISTITEM);
testRole("aria_log", ROLE_TEXT); // weak role
- testRole("aria_marquee", ROLE_ANIMATION);
testRole("aria_math", ROLE_FLAT_EQUATION);
testRole("aria_menu", ROLE_MENUPOPUP);
testRole("aria_menubar", ROLE_MENUBAR);
@@ -89,9 +88,6 @@
testRole("log_table", ROLE_TABLE);
testRole("timer_div", ROLE_SECTION);
- // other roles that are forms of "live regions"
- testRole("marquee_h1", ROLE_ANIMATION);
-
// strong landmark
testRole("application", ROLE_APPLICATION);
testRole("form", ROLE_FORM);
@@ -219,7 +215,6 @@
<span id="aria_listbox" role="listbox"/>
<span id="aria_listitem" role="listitem"/>
<span id="aria_log" role="log"/>
- <span id="aria_marquee" role="marquee"/>
<span id="aria_math" role="math"/>
<span id="aria_menu" role="menu"/>
<span id="aria_menubar" role="menubar"/>
@@ -263,7 +258,6 @@
<table role="log" id="log_table">
<tr><td>Table based log</td></tr>
</table>
- <h1 role="marquee" id="marquee_h1">marquee</h1>
<div role="timer" id="timer_div">timer</div>
<!-- landmarks -->
diff --git a/dom/animation/AnimationPerformanceWarning.h b/dom/animation/AnimationPerformanceWarning.h
index a1ac35cba..582c48cc3 100644
--- a/dom/animation/AnimationPerformanceWarning.h
+++ b/dom/animation/AnimationPerformanceWarning.h
@@ -38,8 +38,6 @@ struct AnimationPerformanceWarning
std::initializer_list<int32_t> aParams)
: mType(aType)
{
- // FIXME: Once std::initializer_list::size() become a constexpr function,
- // we should use static_assert here.
MOZ_ASSERT(aParams.size() <= kMaxParamsForLocalization,
"The length of parameters should be less than "
"kMaxParamsForLocalization");
@@ -49,11 +47,11 @@ struct AnimationPerformanceWarning
// Maximum number of parameters passed to
// nsContentUtils::FormatLocalizedString to localize warning messages.
//
- // NOTE: This constexpr can't be forward declared, so if you want to use
+ // NOTE: This can't be forward declared, so if you want to use
// this variable, please include this header file directly.
// This value is the same as the limit of nsStringBundle::FormatString.
// See the implementation of nsStringBundle::FormatString.
- static constexpr uint8_t kMaxParamsForLocalization = 10;
+ static const uint8_t kMaxParamsForLocalization = 10;
// Indicates why this property could not be animated on the compositor.
Type mType;
diff --git a/dom/base/ResizeObserver.cpp b/dom/base/ResizeObserver.cpp
new file mode 100644
index 000000000..37d940c2b
--- /dev/null
+++ b/dom/base/ResizeObserver.cpp
@@ -0,0 +1,304 @@
+/* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
+/* This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this file,
+ * You can obtain one at http://mozilla.org/MPL/2.0/. */
+
+#include "mozilla/dom/ResizeObserver.h"
+
+#include "mozilla/dom/DOMRect.h"
+#include "nsContentUtils.h"
+#include "nsIFrame.h"
+#include "nsSVGUtils.h"
+
+namespace mozilla {
+namespace dom {
+
+NS_INTERFACE_MAP_BEGIN_CYCLE_COLLECTION(ResizeObserver)
+ NS_WRAPPERCACHE_INTERFACE_MAP_ENTRY
+ NS_INTERFACE_MAP_ENTRY(nsISupports)
+NS_INTERFACE_MAP_END
+
+NS_IMPL_CYCLE_COLLECTING_ADDREF(ResizeObserver)
+NS_IMPL_CYCLE_COLLECTING_RELEASE(ResizeObserver)
+
+NS_IMPL_CYCLE_COLLECTION_CLASS(ResizeObserver)
+
+NS_IMPL_CYCLE_COLLECTION_TRACE_BEGIN(ResizeObserver)
+ NS_IMPL_CYCLE_COLLECTION_TRACE_PRESERVED_WRAPPER
+NS_IMPL_CYCLE_COLLECTION_TRACE_END
+
+NS_IMPL_CYCLE_COLLECTION_UNLINK_BEGIN(ResizeObserver)
+ NS_IMPL_CYCLE_COLLECTION_UNLINK_PRESERVED_WRAPPER
+ NS_IMPL_CYCLE_COLLECTION_UNLINK(mOwner)
+ NS_IMPL_CYCLE_COLLECTION_UNLINK(mCallback)
+ NS_IMPL_CYCLE_COLLECTION_UNLINK(mObservationMap)
+NS_IMPL_CYCLE_COLLECTION_UNLINK_END
+
+NS_IMPL_CYCLE_COLLECTION_TRAVERSE_BEGIN(ResizeObserver)
+ NS_IMPL_CYCLE_COLLECTION_TRAVERSE(mOwner)
+ NS_IMPL_CYCLE_COLLECTION_TRAVERSE(mCallback)
+ NS_IMPL_CYCLE_COLLECTION_TRAVERSE(mObservationMap)
+NS_IMPL_CYCLE_COLLECTION_TRAVERSE_END
+
+already_AddRefed<ResizeObserver>
+ResizeObserver::Constructor(const GlobalObject& aGlobal,
+ ResizeObserverCallback& aCb,
+ ErrorResult& aRv)
+{
+ nsCOMPtr<nsPIDOMWindowInner> window =
+ do_QueryInterface(aGlobal.GetAsSupports());
+
+ if (!window) {
+ aRv.Throw(NS_ERROR_FAILURE);
+ return nullptr;
+ }
+
+ nsCOMPtr<nsIDocument> document = window->GetExtantDoc();
+
+ if (!document) {
+ aRv.Throw(NS_ERROR_FAILURE);
+ return nullptr;
+ }
+
+ RefPtr<ResizeObserver> observer = new ResizeObserver(window.forget(), aCb);
+ document->AddResizeObserver(observer);
+
+ return observer.forget();
+}
+
+void
+ResizeObserver::Observe(Element* aTarget,
+ ErrorResult& aRv)
+{
+ if (!aTarget) {
+ aRv.Throw(NS_ERROR_DOM_NOT_FOUND_ERR);
+ return;
+ }
+
+ RefPtr<ResizeObservation> observation;
+
+ if (!mObservationMap.Get(aTarget, getter_AddRefs(observation))) {
+ observation = new ResizeObservation(this, aTarget);
+
+ mObservationMap.Put(aTarget, observation);
+ mObservationList.insertBack(observation);
+
+ // Per the spec, we need to trigger notification in event loop that
+ // contains ResizeObserver observe call even when resize/reflow does
+ // not happen.
+ aTarget->OwnerDoc()->ScheduleResizeObserversNotification();
+ }
+}
+
+void
+ResizeObserver::Unobserve(Element* aTarget,
+ ErrorResult& aRv)
+{
+ if (!aTarget) {
+ aRv.Throw(NS_ERROR_DOM_NOT_FOUND_ERR);
+ return;
+ }
+
+ RefPtr<ResizeObservation> observation;
+
+ if (mObservationMap.Get(aTarget, getter_AddRefs(observation))) {
+ mObservationMap.Remove(aTarget);
+
+ MOZ_ASSERT(!mObservationList.isEmpty(),
+ "If ResizeObservation found for an element, observation list "
+ "must be not empty.");
+
+ observation->remove();
+ }
+}
+
+void
+ResizeObserver::Disconnect()
+{
+ mObservationMap.Clear();
+ mObservationList.clear();
+ mActiveTargets.Clear();
+}
+
+void
+ResizeObserver::GatherActiveObservations(uint32_t aDepth)
+{
+ mActiveTargets.Clear();
+ mHasSkippedTargets = false;
+
+ for (auto observation : mObservationList) {
+ if (observation->IsActive()) {
+ uint32_t targetDepth =
+ nsContentUtils::GetNodeDepth(observation->Target());
+
+ if (targetDepth > aDepth) {
+ mActiveTargets.AppendElement(observation);
+ } else {
+ mHasSkippedTargets = true;
+ }
+ }
+ }
+}
+
+bool
+ResizeObserver::HasActiveObservations() const
+{
+ return !mActiveTargets.IsEmpty();
+}
+
+bool
+ResizeObserver::HasSkippedObservations() const
+{
+ return mHasSkippedTargets;
+}
+
+uint32_t
+ResizeObserver::BroadcastActiveObservations()
+{
+ uint32_t shallowestTargetDepth = UINT32_MAX;
+
+ if (HasActiveObservations()) {
+ Sequence<OwningNonNull<ResizeObserverEntry>> entries;
+
+ for (auto observation : mActiveTargets) {
+ RefPtr<ResizeObserverEntry> entry =
+ new ResizeObserverEntry(this, observation->Target());
+
+ nsRect rect = observation->GetTargetRect();
+ entry->SetContentRect(rect);
+
+ if (!entries.AppendElement(entry.forget(), fallible)) {
+ // Out of memory.
+ break;
+ }
+
+ // Sync the broadcast size of observation so the next size inspection
+ // will be based on the updated size from last delivered observations.
+ observation->UpdateBroadcastSize(rect);
+
+ uint32_t targetDepth =
+ nsContentUtils::GetNodeDepth(observation->Target());
+
+ if (targetDepth < shallowestTargetDepth) {
+ shallowestTargetDepth = targetDepth;
+ }
+ }
+
+ mCallback->Call(this, entries, *this);
+ mActiveTargets.Clear();
+ mHasSkippedTargets = false;
+ }
+
+ return shallowestTargetDepth;
+}
+
+NS_INTERFACE_MAP_BEGIN_CYCLE_COLLECTION(ResizeObserverEntry)
+ NS_WRAPPERCACHE_INTERFACE_MAP_ENTRY
+ NS_INTERFACE_MAP_ENTRY(nsISupports)
+NS_INTERFACE_MAP_END
+
+NS_IMPL_CYCLE_COLLECTING_ADDREF(ResizeObserverEntry)
+NS_IMPL_CYCLE_COLLECTING_RELEASE(ResizeObserverEntry)
+
+NS_IMPL_CYCLE_COLLECTION_WRAPPERCACHE(ResizeObserverEntry,
+ mTarget, mContentRect,
+ mOwner)
+
+already_AddRefed<ResizeObserverEntry>
+ResizeObserverEntry::Constructor(const GlobalObject& aGlobal,
+ Element* aTarget,
+ ErrorResult& aRv)
+{
+ RefPtr<ResizeObserverEntry> observerEntry =
+ new ResizeObserverEntry(aGlobal.GetAsSupports(), aTarget);
+ return observerEntry.forget();
+}
+
+void
+ResizeObserverEntry::SetContentRect(nsRect aRect)
+{
+ RefPtr<DOMRect> contentRect = new DOMRect(mTarget);
+ nsIFrame* frame = mTarget->GetPrimaryFrame();
+
+ if (frame) {
+ nsMargin padding = frame->GetUsedPadding();
+
+ // Per the spec, we need to include padding in contentRect of
+ // ResizeObserverEntry.
+ aRect.x = padding.left;
+ aRect.y = padding.top;
+ }
+
+ contentRect->SetLayoutRect(aRect);
+ mContentRect = contentRect.forget();
+}
+
+ResizeObserverEntry::~ResizeObserverEntry()
+{
+}
+
+NS_INTERFACE_MAP_BEGIN_CYCLE_COLLECTION(ResizeObservation)
+ NS_WRAPPERCACHE_INTERFACE_MAP_ENTRY
+ NS_INTERFACE_MAP_ENTRY(nsISupports)
+NS_INTERFACE_MAP_END
+
+NS_IMPL_CYCLE_COLLECTING_ADDREF(ResizeObservation)
+NS_IMPL_CYCLE_COLLECTING_RELEASE(ResizeObservation)
+
+NS_IMPL_CYCLE_COLLECTION_WRAPPERCACHE(ResizeObservation,
+ mTarget, mOwner)
+
+already_AddRefed<ResizeObservation>
+ResizeObservation::Constructor(const GlobalObject& aGlobal,
+ Element* aTarget,
+ ErrorResult& aRv)
+{
+ RefPtr<ResizeObservation> observation =
+ new ResizeObservation(aGlobal.GetAsSupports(), aTarget);
+ return observation.forget();
+}
+
+bool
+ResizeObservation::IsActive() const
+{
+ nsRect rect = GetTargetRect();
+ return (rect.width != mBroadcastWidth || rect.height != mBroadcastHeight);
+}
+
+void
+ResizeObservation::UpdateBroadcastSize(nsRect aRect)
+{
+ mBroadcastWidth = aRect.width;
+ mBroadcastHeight = aRect.height;
+}
+
+nsRect
+ResizeObservation::GetTargetRect() const
+{
+ nsRect rect;
+ nsIFrame* frame = mTarget->GetPrimaryFrame();
+
+ if (frame) {
+ if (mTarget->IsSVGElement()) {
+ gfxRect bbox = nsSVGUtils::GetBBox(frame);
+ rect.width = NSFloatPixelsToAppUnits(bbox.width, AppUnitsPerCSSPixel());
+ rect.height = NSFloatPixelsToAppUnits(bbox.height, AppUnitsPerCSSPixel());
+ } else {
+ // Per the spec, non-replaced inline Elements will always have an empty
+ // content rect.
+ if (frame->IsFrameOfType(nsIFrame::eReplaced) ||
+ !frame->IsFrameOfType(nsIFrame::eLineParticipant)) {
+ rect = frame->GetContentRectRelativeToSelf();
+ }
+ }
+ }
+
+ return rect;
+}
+
+ResizeObservation::~ResizeObservation()
+{
+}
+
+} // namespace dom
+} // namespace mozilla
diff --git a/dom/base/ResizeObserver.h b/dom/base/ResizeObserver.h
new file mode 100644
index 000000000..2f56c580f
--- /dev/null
+++ b/dom/base/ResizeObserver.h
@@ -0,0 +1,254 @@
+/* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
+/* This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this file,
+ * You can obtain one at http://mozilla.org/MPL/2.0/. */
+
+#ifndef mozilla_dom_ResizeObserver_h
+#define mozilla_dom_ResizeObserver_h
+
+#include "mozilla/dom/ResizeObserverBinding.h"
+
+namespace mozilla {
+namespace dom {
+
+/**
+ * ResizeObserver interfaces and algorithms are based on
+ * https://wicg.github.io/ResizeObserver/#api
+ */
+class ResizeObserver final
+ : public nsISupports
+ , public nsWrapperCache
+{
+public:
+ NS_DECL_CYCLE_COLLECTING_ISUPPORTS
+ NS_DECL_CYCLE_COLLECTION_SCRIPT_HOLDER_CLASS(ResizeObserver)
+
+ ResizeObserver(already_AddRefed<nsPIDOMWindowInner>&& aOwner,
+ ResizeObserverCallback& aCb)
+ : mOwner(aOwner)
+ , mCallback(&aCb)
+ {
+ MOZ_ASSERT(mOwner, "Need a non-null owner window");
+ }
+
+ static already_AddRefed<ResizeObserver>
+ Constructor(const GlobalObject& aGlobal,
+ ResizeObserverCallback& aCb,
+ ErrorResult& aRv);
+
+ JSObject* WrapObject(JSContext* aCx,
+ JS::Handle<JSObject*> aGivenProto) override
+ {
+ return ResizeObserverBinding::Wrap(aCx, this, aGivenProto);
+ }
+
+ nsISupports* GetParentObject() const
+ {
+ return mOwner;
+ }
+
+ void Observe(Element* aTarget, ErrorResult& aRv);
+
+ void Unobserve(Element* aTarget, ErrorResult& aRv);
+
+ void Disconnect();
+
+ /*
+ * Gather all observations which have an observed target with size changed
+ * since last BroadcastActiveObservations() in this ResizeObserver.
+ * An observation will be skipped if the depth of its observed target is less
+ * or equal than aDepth. All gathered observations will be added to
+ * mActiveTargets.
+ */
+ void GatherActiveObservations(uint32_t aDepth);
+
+ /*
+ * Returns whether this ResizeObserver has any active observations
+ * since last GatherActiveObservations().
+ */
+ bool HasActiveObservations() const;
+
+ /*
+ * Returns whether this ResizeObserver has any skipped observations
+ * since last GatherActiveObservations().
+ */
+ bool HasSkippedObservations() const;
+
+ /*
+ * Deliver the callback function in JavaScript for all active observations
+ * and pass the sequence of ResizeObserverEntry so JavaScript can access them.
+ * The broadcast size of observations will be updated and mActiveTargets will
+ * be cleared. It also returns the shallowest depth of elements from active
+ * observations or UINT32_MAX if there is no any active observations.
+ */
+ uint32_t BroadcastActiveObservations();
+
+protected:
+ ~ResizeObserver()
+ {
+ mObservationList.clear();
+ }
+
+ nsCOMPtr<nsPIDOMWindowInner> mOwner;
+ RefPtr<ResizeObserverCallback> mCallback;
+ nsTArray<RefPtr<ResizeObservation>> mActiveTargets;
+ bool mHasSkippedTargets;
+
+ // Combination of HashTable and LinkedList so we can iterate through
+ // the elements of HashTable in order of insertion time.
+ // Will be nice if we have our own data structure for this in the future.
+ nsRefPtrHashtable<nsPtrHashKey<Element>, ResizeObservation> mObservationMap;
+ LinkedList<ResizeObservation> mObservationList;
+};
+
+/**
+ * ResizeObserverEntry is the entry that contains the information for observed
+ * elements. This object is the one that visible to JavaScript in callback
+ * function that is fired by ResizeObserver.
+ */
+class ResizeObserverEntry final
+ : public nsISupports
+ , public nsWrapperCache
+{
+public:
+ NS_DECL_CYCLE_COLLECTING_ISUPPORTS
+ NS_DECL_CYCLE_COLLECTION_SCRIPT_HOLDER_CLASS(ResizeObserverEntry)
+
+ ResizeObserverEntry(nsISupports* aOwner, Element* aTarget)
+ : mOwner(aOwner)
+ , mTarget(aTarget)
+ {
+ MOZ_ASSERT(mOwner, "Need a non-null owner");
+ MOZ_ASSERT(mTarget, "Need a non-null target element");
+ }
+
+ static already_AddRefed<ResizeObserverEntry>
+ Constructor(const GlobalObject& aGlobal,
+ Element* aTarget,
+ ErrorResult& aRv);
+
+ JSObject* WrapObject(JSContext* aCx,
+ JS::Handle<JSObject*> aGivenProto) override
+ {
+ return ResizeObserverEntryBinding::Wrap(aCx, this,
+ aGivenProto);
+ }
+
+ nsISupports* GetParentObject() const
+ {
+ return mOwner;
+ }
+
+ Element* Target() const
+ {
+ return mTarget;
+ }
+
+ /*
+ * Returns the DOMRectReadOnly of target's content rect so it can be
+ * accessed from JavaScript in callback function of ResizeObserver.
+ */
+ DOMRectReadOnly* GetContentRect() const
+ {
+ return mContentRect;
+ }
+
+ void SetContentRect(nsRect aRect);
+
+protected:
+ ~ResizeObserverEntry();
+
+ nsCOMPtr<nsISupports> mOwner;
+ nsCOMPtr<Element> mTarget;
+ RefPtr<DOMRectReadOnly> mContentRect;
+};
+
+/**
+ * We use ResizeObservation to store and sync the size information of one
+ * observed element so we can decide whether an observation should be fired
+ * or not.
+ */
+class ResizeObservation final
+ : public nsISupports
+ , public nsWrapperCache
+ , public LinkedListElement<ResizeObservation>
+{
+public:
+ NS_DECL_CYCLE_COLLECTING_ISUPPORTS
+ NS_DECL_CYCLE_COLLECTION_SCRIPT_HOLDER_CLASS(ResizeObservation)
+
+ ResizeObservation(nsISupports* aOwner, Element* aTarget)
+ : mOwner(aOwner)
+ , mTarget(aTarget)
+ , mBroadcastWidth(0)
+ , mBroadcastHeight(0)
+ {
+ MOZ_ASSERT(mOwner, "Need a non-null owner");
+ MOZ_ASSERT(mTarget, "Need a non-null target element");
+ }
+
+ static already_AddRefed<ResizeObservation>
+ Constructor(const GlobalObject& aGlobal,
+ Element* aTarget,
+ ErrorResult& aRv);
+
+ JSObject* WrapObject(JSContext* aCx,
+ JS::Handle<JSObject*> aGivenProto) override
+ {
+ return ResizeObservationBinding::Wrap(aCx, this, aGivenProto);
+ }
+
+ nsISupports* GetParentObject() const
+ {
+ return mOwner;
+ }
+
+ Element* Target() const
+ {
+ return mTarget;
+ }
+
+ nscoord BroadcastWidth() const
+ {
+ return mBroadcastWidth;
+ }
+
+ nscoord BroadcastHeight() const
+ {
+ return mBroadcastHeight;
+ }
+
+ /*
+ * Returns whether the observed target element size differs from current
+ * BroadcastWidth and BroadcastHeight
+ */
+ bool IsActive() const;
+
+ /*
+ * Update current BroadcastWidth and BroadcastHeight with size from aRect.
+ */
+ void UpdateBroadcastSize(nsRect aRect);
+
+ /*
+ * Returns the target's rect in the form of nsRect.
+ * If the target is SVG, width and height are determined from bounding box.
+ */
+ nsRect GetTargetRect() const;
+
+protected:
+ ~ResizeObservation();
+
+ nsCOMPtr<nsISupports> mOwner;
+ nsCOMPtr<Element> mTarget;
+
+ // Broadcast width and broadcast height are the latest recorded size
+ // of observed target.
+ nscoord mBroadcastWidth;
+ nscoord mBroadcastHeight;
+};
+
+} // namespace dom
+} // namespace mozilla
+
+#endif // mozilla_dom_ResizeObserver_h
+
diff --git a/dom/base/ResizeObserverController.cpp b/dom/base/ResizeObserverController.cpp
new file mode 100644
index 000000000..924bba10d
--- /dev/null
+++ b/dom/base/ResizeObserverController.cpp
@@ -0,0 +1,234 @@
+/* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
+/* vim: set ts=8 sts=2 et sw=2 tw=80: */
+/* This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this file,
+ * You can obtain one at http://mozilla.org/MPL/2.0/. */
+
+#include "mozilla/dom/ResizeObserverController.h"
+#include "mozilla/dom/Element.h"
+#include "mozilla/dom/ErrorEvent.h"
+#include "nsIPresShell.h"
+#include "nsPresContext.h"
+
+namespace mozilla {
+namespace dom {
+
+void
+ResizeObserverNotificationHelper::WillRefresh(TimeStamp aTime)
+{
+ MOZ_ASSERT(mOwner, "Why is mOwner already dead when this RefreshObserver is still registered?");
+ if (mOwner) {
+ mOwner->Notify();
+ }
+}
+
+nsRefreshDriver*
+ResizeObserverNotificationHelper::GetRefreshDriver() const
+{
+ nsIPresShell* presShell = mOwner->GetShell();
+ if (MOZ_UNLIKELY(!presShell)) {
+ return nullptr;
+ }
+
+ nsPresContext* presContext = presShell->GetPresContext();
+ if (MOZ_UNLIKELY(!presContext)) {
+ return nullptr;
+ }
+
+ return presContext->RefreshDriver();
+}
+
+void
+ResizeObserverNotificationHelper::Register()
+{
+ if (mRegistered) {
+ return;
+ }
+
+ nsRefreshDriver* refreshDriver = GetRefreshDriver();
+ if (!refreshDriver) {
+ // We maybe navigating away from this page or currently in an iframe with
+ // display: none. Just abort the Register(), no need to do notification.
+ return;
+ }
+
+ refreshDriver->AddRefreshObserver(this, Flush_Display);
+ mRegistered = true;
+}
+
+void
+ResizeObserverNotificationHelper::Unregister()
+{
+ if (!mRegistered) {
+ return;
+ }
+
+ nsRefreshDriver* refreshDriver = GetRefreshDriver();
+ if (!refreshDriver) {
+ // We can't access RefreshDriver now. Just abort the Unregister().
+ return;
+ }
+
+ refreshDriver->RemoveRefreshObserver(this, Flush_Display);
+ mRegistered = false;
+}
+
+void
+ResizeObserverNotificationHelper::Disconnect()
+{
+ Unregister();
+ // Our owner is dying. Clear our pointer to it, in case we outlive it.
+ mOwner = nullptr;
+}
+
+ResizeObserverNotificationHelper::~ResizeObserverNotificationHelper()
+{
+ Unregister();
+}
+
+void
+ResizeObserverController::Traverse(nsCycleCollectionTraversalCallback& aCb)
+{
+ ImplCycleCollectionTraverse(aCb, mResizeObservers, "mResizeObservers");
+}
+
+void
+ResizeObserverController::Unlink()
+{
+ mResizeObservers.Clear();
+}
+
+void
+ResizeObserverController::AddResizeObserver(ResizeObserver* aObserver)
+{
+ MOZ_ASSERT(aObserver, "AddResizeObserver() should never be called with "
+ "a null parameter");
+ mResizeObservers.AppendElement(aObserver);
+}
+
+void
+ResizeObserverController::Notify()
+{
+ if (mResizeObservers.IsEmpty()) {
+ return;
+ }
+
+ uint32_t shallowestTargetDepth = 0;
+
+ GatherAllActiveObservations(shallowestTargetDepth);
+
+ while (HasAnyActiveObservations()) {
+ DebugOnly<uint32_t> oldShallowestTargetDepth = shallowestTargetDepth;
+ shallowestTargetDepth = BroadcastAllActiveObservations();
+ NS_ASSERTION(oldShallowestTargetDepth < shallowestTargetDepth,
+ "shallowestTargetDepth should be getting strictly deeper");
+
+ // Flush layout, so that any callback functions' style changes / resizes
+ // get a chance to take effect.
+ mDocument->FlushPendingNotifications(Flush_Layout);
+
+ // To avoid infinite resize loop, we only gather all active observations
+ // that have the depth of observed target element more than current
+ // shallowestTargetDepth.
+ GatherAllActiveObservations(shallowestTargetDepth);
+ }
+
+ mResizeObserverNotificationHelper->Unregister();
+
+ // Per spec, we deliver an error if the document has any skipped observations.
+ if (HasAnySkippedObservations()) {
+ RootedDictionary<ErrorEventInit> init(RootingCx());
+
+ init.mMessage.AssignLiteral("ResizeObserver loop completed with undelivered"
+ " notifications.");
+ init.mCancelable = true;
+ init.mBubbles = true;
+
+ nsEventStatus status = nsEventStatus_eIgnore;
+
+ nsCOMPtr<nsPIDOMWindowInner> window =
+ mDocument->GetWindow()->GetCurrentInnerWindow();
+
+ if (window) {
+ nsCOMPtr<nsIScriptGlobalObject> sgo = do_QueryInterface(window);
+ MOZ_ASSERT(sgo);
+
+ if (NS_WARN_IF(NS_FAILED(sgo->HandleScriptError(init, &status)))) {
+ status = nsEventStatus_eIgnore;
+ }
+ } else {
+ // We don't fire error events at any global for non-window JS on the main
+ // thread.
+ }
+
+ // We need to deliver pending notifications in next cycle.
+ ScheduleNotification();
+ }
+}
+
+void
+ResizeObserverController::GatherAllActiveObservations(uint32_t aDepth)
+{
+ for (auto observer : mResizeObservers) {
+ observer->GatherActiveObservations(aDepth);
+ }
+}
+
+uint32_t
+ResizeObserverController::BroadcastAllActiveObservations()
+{
+ uint32_t shallowestTargetDepth = UINT32_MAX;
+
+ for (auto observer : mResizeObservers) {
+
+ uint32_t targetDepth = observer->BroadcastActiveObservations();
+
+ if (targetDepth < shallowestTargetDepth) {
+ shallowestTargetDepth = targetDepth;
+ }
+ }
+
+ return shallowestTargetDepth;
+}
+
+bool
+ResizeObserverController::HasAnyActiveObservations() const
+{
+ for (auto observer : mResizeObservers) {
+ if (observer->HasActiveObservations()) {
+ return true;
+ }
+ }
+ return false;
+}
+
+bool
+ResizeObserverController::HasAnySkippedObservations() const
+{
+ for (auto observer : mResizeObservers) {
+ if (observer->HasSkippedObservations()) {
+ return true;
+ }
+ }
+ return false;
+}
+
+void
+ResizeObserverController::ScheduleNotification()
+{
+ mResizeObserverNotificationHelper->Register();
+}
+
+nsIPresShell*
+ResizeObserverController::GetShell() const
+{
+ return mDocument->GetShell();
+}
+
+ResizeObserverController::~ResizeObserverController()
+{
+ mResizeObserverNotificationHelper->Disconnect();
+}
+
+} // namespace dom
+} // namespace mozilla
diff --git a/dom/base/ResizeObserverController.h b/dom/base/ResizeObserverController.h
new file mode 100644
index 000000000..a77511587
--- /dev/null
+++ b/dom/base/ResizeObserverController.h
@@ -0,0 +1,129 @@
+/* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
+/* vim: set ts=8 sts=2 et sw=2 tw=80: */
+/* This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this file,
+ * You can obtain one at http://mozilla.org/MPL/2.0/. */
+
+#ifndef mozilla_dom_ResizeObserverController_h
+#define mozilla_dom_ResizeObserverController_h
+
+#include "mozilla/dom/ResizeObserver.h"
+#include "mozilla/TimeStamp.h"
+#include "nsRefreshDriver.h"
+
+namespace mozilla {
+namespace dom {
+
+class ResizeObserverController;
+
+/*
+ * ResizeObserverNotificationHelper will trigger ResizeObserver notifications
+ * by registering with the Refresh Driver.
+*/
+class ResizeObserverNotificationHelper final : public nsARefreshObserver
+{
+public:
+ NS_INLINE_DECL_REFCOUNTING(ResizeObserverNotificationHelper, override)
+
+ explicit ResizeObserverNotificationHelper(ResizeObserverController* aOwner)
+ : mOwner(aOwner)
+ , mRegistered(false)
+ {
+ MOZ_ASSERT(mOwner, "Need a non-null owner");
+ }
+
+ void WillRefresh(TimeStamp aTime) override;
+
+ nsRefreshDriver* GetRefreshDriver() const;
+
+ void Register();
+
+ void Unregister();
+
+ void Disconnect();
+
+protected:
+ virtual ~ResizeObserverNotificationHelper();
+
+ ResizeObserverController* mOwner;
+ bool mRegistered;
+};
+
+/*
+ * ResizeObserverController contains the list of ResizeObservers and controls
+ * the flow of notification.
+*/
+class ResizeObserverController final
+{
+public:
+ explicit ResizeObserverController(nsIDocument* aDocument)
+ : mDocument(aDocument)
+ , mIsNotificationActive(false)
+ {
+ MOZ_ASSERT(mDocument, "Need a non-null document");
+ mResizeObserverNotificationHelper =
+ new ResizeObserverNotificationHelper(this);
+ }
+
+ // Methods for supporting cycle-collection
+ void Traverse(nsCycleCollectionTraversalCallback& aCb);
+ void Unlink();
+
+ void AddResizeObserver(ResizeObserver* aObserver);
+
+ /*
+ * Schedule the notification via ResizeObserverNotificationHelper refresh
+ * observer.
+ */
+ void ScheduleNotification();
+
+ /*
+ * Notify all ResizeObservers by gathering and broadcasting all active
+ * observations.
+ */
+ void Notify();
+
+ nsIPresShell* GetShell() const;
+
+ ~ResizeObserverController();
+
+private:
+ /*
+ * Calls GatherActiveObservations(aDepth) for all ResizeObservers in this
+ * controller. All observations in each ResizeObserver with element's depth
+ * more than aDepth will be gathered.
+ */
+ void GatherAllActiveObservations(uint32_t aDepth);
+
+ /*
+ * Calls BroadcastActiveObservations() for all ResizeObservers in this
+ * controller. It also returns the shallowest depth of observed target
+ * elements from all ResizeObserver or UINT32_MAX if there is no any
+ * active obsevations at all.
+ */
+ uint32_t BroadcastAllActiveObservations();
+
+ /*
+ * Returns whether there is any ResizeObserver that has active observations.
+ */
+ bool HasAnyActiveObservations() const;
+
+ /*
+ * Returns whether there is any ResizeObserver that has skipped observations.
+ */
+ bool HasAnySkippedObservations() const;
+
+protected:
+ // Raw pointer is OK because mDocument strongly owns us & hence must outlive
+ // us.
+ nsIDocument* const mDocument;
+
+ RefPtr<ResizeObserverNotificationHelper> mResizeObserverNotificationHelper;
+ nsTArray<RefPtr<ResizeObserver>> mResizeObservers;
+ bool mIsNotificationActive;
+};
+
+} // namespace dom
+} // namespace mozilla
+
+#endif // mozilla_dom_ResizeObserverController_h
diff --git a/dom/base/WindowNamedPropertiesHandler.h b/dom/base/WindowNamedPropertiesHandler.h
index 227d8c946..cafeadb85 100644
--- a/dom/base/WindowNamedPropertiesHandler.h
+++ b/dom/base/WindowNamedPropertiesHandler.h
@@ -15,7 +15,7 @@ namespace dom {
class WindowNamedPropertiesHandler : public BaseDOMProxyHandler
{
public:
- constexpr WindowNamedPropertiesHandler()
+ WindowNamedPropertiesHandler()
: BaseDOMProxyHandler(nullptr, /* hasPrototype = */ true)
{
}
diff --git a/dom/base/crashtests/1251361.html b/dom/base/crashtests/1251361.html
deleted file mode 100644
index 57c76121f..000000000
--- a/dom/base/crashtests/1251361.html
+++ /dev/null
@@ -1,33 +0,0 @@
-<!DOCTYPE html>
-<html>
-<head>
-<meta charset="UTF-8">
-<script>
-
-var frameRoot;
-
-function boom()
-{
- var frameWin = f.contentWindow;
- frameRoot = frameWin.document.documentElement;
- frameWin.location.replace("data:text/html;charset=UTF-8,<body onload='parent.g();'>2");
-}
-
-function g()
-{
- setTimeout(h, 0);
-}
-
-function h()
-{
- var newDoc = document.implementation.createDocument('', '', null);
- newDoc.adoptNode(frameRoot);
-}
-
-</script>
-<body onload="boom();">
-
-<iframe id="f" src="data:text/html;charset=UTF-8,<marquee>1"></iframe>
-
-</body>
-</html>
diff --git a/dom/base/crashtests/371466-1.xhtml b/dom/base/crashtests/371466-1.xhtml
deleted file mode 100644
index 8da0b22b1..000000000
--- a/dom/base/crashtests/371466-1.xhtml
+++ /dev/null
@@ -1,24 +0,0 @@
-<html xmlns="http://www.w3.org/1999/xhtml" class="reftest-wait">
-<head>
-<script>
-
-function boom()
-{
- var marquee = document.getElementById("marquee");
- var span = document.getElementById("span");
- marquee.appendChild(span);
- marquee.removeChild(span);
- document.documentElement.removeAttribute("class");
-}
-
-</script>
-</head>
-
-<body onload="setTimeout(boom, 30);">
-
-<marquee id="marquee" />
-
-<span id="span"><div>Foo</div><textarea/></span>
-
-</body>
-</html>
diff --git a/dom/base/crashtests/535926-1.html b/dom/base/crashtests/535926-1.html
deleted file mode 100644
index bddd8dc28..000000000
--- a/dom/base/crashtests/535926-1.html
+++ /dev/null
@@ -1,28 +0,0 @@
-<html class="reftest-wait">
-<head>
-
-<script type="text/javascript">
-
-var i = 0;
-function mmf()
-{
- if (++i == 2) {
- document.body.innerHTML = "<marquee>";
- document.documentElement.removeAttribute("class");
- }
-}
-
-function init()
-{
- document.documentElement.offsetHeight;
- for (var j = 0; j < 2; ++j) {
- var iframe = document.createElementNS("http://www.w3.org/1999/xhtml", "iframe");
- iframe.addEventListener("load", mmf, false);
- document.body.appendChild(iframe);
- }
-}
-
-</script>
-</head>
-<body onload="setTimeout(init, 0);"></body>
-</html>
diff --git a/dom/base/moz.build b/dom/base/moz.build
index 1de49424b..65e3c3d76 100755
--- a/dom/base/moz.build
+++ b/dom/base/moz.build
@@ -202,6 +202,8 @@ EXPORTS.mozilla.dom += [
'PartialSHistory.h',
'Pose.h',
'ProcessGlobal.h',
+ 'ResizeObserver.h',
+ 'ResizeObserverController.h',
'ResponsiveImageSelector.h',
'SameProcessMessageQueue.h',
'ScreenOrientation.h',
@@ -347,6 +349,8 @@ SOURCES += [
'Pose.cpp',
'PostMessageEvent.cpp',
'ProcessGlobal.cpp',
+ 'ResizeObserver.cpp',
+ 'ResizeObserverController.cpp',
'ResponsiveImageSelector.cpp',
'SameProcessMessageQueue.cpp',
'ScreenOrientation.cpp',
diff --git a/dom/base/nsAttrValue.h b/dom/base/nsAttrValue.h
index 23f61a614..33ee91afd 100644
--- a/dom/base/nsAttrValue.h
+++ b/dom/base/nsAttrValue.h
@@ -268,7 +268,7 @@ public:
// EnumTable can be initialized either with an int16_t value
// or a value of an enumeration type that can fit within an int16_t.
- constexpr EnumTable(const char* aTag, int16_t aValue)
+ EnumTable(const char* aTag, int16_t aValue)
: tag(aTag)
, value(aValue)
{
@@ -276,7 +276,7 @@ public:
template<typename T,
typename = typename std::enable_if<std::is_enum<T>::value>::type>
- constexpr EnumTable(const char* aTag, T aValue)
+ EnumTable(const char* aTag, T aValue)
: tag(aTag)
, value(static_cast<int16_t>(aValue))
{
diff --git a/dom/base/nsContentUtils.cpp b/dom/base/nsContentUtils.cpp
index 1a3f5b5ca..ffe50a015 100644
--- a/dom/base/nsContentUtils.cpp
+++ b/dom/base/nsContentUtils.cpp
@@ -9843,4 +9843,18 @@ nsContentUtils::IsLocalRefURL(const nsString& aString)
}
return false;
-} \ No newline at end of file
+}
+
+/* static */ uint32_t
+nsContentUtils::GetNodeDepth(nsINode* aNode)
+{
+ uint32_t depth = 1;
+
+ MOZ_ASSERT(aNode, "Node shouldn't be null");
+
+ while ((aNode = aNode->GetParentNode())) {
+ ++depth;
+ }
+
+ return depth;
+}
diff --git a/dom/base/nsContentUtils.h b/dom/base/nsContentUtils.h
index ffbd15e78..08587b5e4 100644
--- a/dom/base/nsContentUtils.h
+++ b/dom/base/nsContentUtils.h
@@ -2745,6 +2745,14 @@ public:
static bool
IsLocalRefURL(const nsString& aString);
+ /**
+ * Returns the length of the parent-traversal path (in terms of the number of
+ * nodes) to an unparented/root node from aNode. An unparented/root node is
+ * considered to have a depth of 1, its children have a depth of 2, etc.
+ * aNode is expected to be non-null.
+ */
+ static uint32_t GetNodeDepth(nsINode* aNode);
+
private:
static bool InitializeEventTable();
diff --git a/dom/base/nsDocument.cpp b/dom/base/nsDocument.cpp
index de793bfab..0b07ef4ec 100644
--- a/dom/base/nsDocument.cpp
+++ b/dom/base/nsDocument.cpp
@@ -1727,6 +1727,10 @@ NS_IMPL_CYCLE_COLLECTION_TRAVERSE_BEGIN_INTERNAL(nsDocument)
cb.NoteXPCOMChild(mql);
}
}
+
+ if (tmp->mResizeObserverController) {
+ tmp->mResizeObserverController->Traverse(cb);
+ }
NS_IMPL_CYCLE_COLLECTION_TRAVERSE_END
NS_IMPL_CYCLE_COLLECTION_CLASS(nsDocument)
@@ -1827,11 +1831,15 @@ NS_IMPL_CYCLE_COLLECTION_UNLINK_BEGIN(nsDocument)
l != &tmp->mDOMMediaQueryLists; ) {
PRCList *next = PR_NEXT_LINK(l);
MediaQueryList *mql = static_cast<MediaQueryList*>(l);
- mql->RemoveAllListeners();
+ mql->Disconnect();
l = next;
}
tmp->mInUnlinkOrDeletion = false;
+
+ if (tmp->mResizeObserverController) {
+ tmp->mResizeObserverController->Unlink();
+ }
NS_IMPL_CYCLE_COLLECTION_UNLINK_END
nsresult
@@ -12105,6 +12113,24 @@ nsDocument::QuerySelectorAll(const nsAString& aSelector, nsIDOMNodeList **aRetur
return nsINode::QuerySelectorAll(aSelector, aReturn);
}
+void
+nsDocument::AddResizeObserver(ResizeObserver* aResizeObserver)
+{
+ if (!mResizeObserverController) {
+ mResizeObserverController = MakeUnique<ResizeObserverController>(this);
+ }
+
+ mResizeObserverController->AddResizeObserver(aResizeObserver);
+}
+
+void
+nsDocument::ScheduleResizeObserversNotification() const
+{
+ if (mResizeObserverController) {
+ mResizeObserverController->ScheduleNotification();
+ }
+}
+
already_AddRefed<nsIDocument>
nsIDocument::Constructor(const GlobalObject& aGlobal,
ErrorResult& rv)
diff --git a/dom/base/nsDocument.h b/dom/base/nsDocument.h
index a319ad13e..220f4152d 100644
--- a/dom/base/nsDocument.h
+++ b/dom/base/nsDocument.h
@@ -59,6 +59,7 @@
#include "mozilla/MemoryReporting.h"
#include "mozilla/PendingAnimationTracker.h"
#include "mozilla/dom/DOMImplementation.h"
+#include "mozilla/dom/ResizeObserverController.h"
#include "mozilla/dom/ScriptLoader.h"
#include "mozilla/dom/StyleSheetList.h"
#include "nsDataHashtable.h"
@@ -1206,6 +1207,10 @@ public:
virtual void UnblockDOMContentLoaded() override;
+ void AddResizeObserver(mozilla::dom::ResizeObserver* aResizeObserver) override;
+
+ void ScheduleResizeObserversNotification() const override;
+
protected:
friend class nsNodeUtils;
friend class nsDocumentOnStack;
@@ -1342,6 +1347,9 @@ protected:
nsTArray<nsIObserver*> mCharSetObservers;
+ mozilla::UniquePtr<mozilla::dom::ResizeObserverController>
+ mResizeObserverController;
+
PLDHashTable *mSubDocuments;
// Array of owning references to all children
diff --git a/dom/base/nsGkAtomList.h b/dom/base/nsGkAtomList.h
index 96f5acf3a..22869bd66 100644
--- a/dom/base/nsGkAtomList.h
+++ b/dom/base/nsGkAtomList.h
@@ -580,7 +580,6 @@ GK_ATOM(marginTop, "margin-top")
GK_ATOM(marginheight, "marginheight")
GK_ATOM(marginwidth, "marginwidth")
GK_ATOM(mark, "mark")
-GK_ATOM(marquee, "marquee")
GK_ATOM(match, "match")
GK_ATOM(max, "max")
GK_ATOM(maxheight, "maxheight")
diff --git a/dom/base/nsGlobalWindow.cpp b/dom/base/nsGlobalWindow.cpp
index d696d826b..1c098897b 100644
--- a/dom/base/nsGlobalWindow.cpp
+++ b/dom/base/nsGlobalWindow.cpp
@@ -956,7 +956,7 @@ NS_IMPL_CYCLE_COLLECTING_RELEASE(DialogValueHolder)
class nsOuterWindowProxy : public js::Wrapper
{
public:
- constexpr nsOuterWindowProxy() : js::Wrapper(0) { }
+ nsOuterWindowProxy() : js::Wrapper(0) { }
virtual bool finalizeInBackground(const JS::Value& priv) const override {
return false;
@@ -1407,7 +1407,7 @@ nsOuterWindowProxy::singleton;
class nsChromeOuterWindowProxy : public nsOuterWindowProxy
{
public:
- constexpr nsChromeOuterWindowProxy() : nsOuterWindowProxy() { }
+ nsChromeOuterWindowProxy() : nsOuterWindowProxy() { }
virtual const char *className(JSContext *cx, JS::Handle<JSObject*> wrapper) const override;
diff --git a/dom/base/nsIDocument.h b/dom/base/nsIDocument.h
index 29afa5439..760048501 100644
--- a/dom/base/nsIDocument.h
+++ b/dom/base/nsIDocument.h
@@ -152,6 +152,7 @@ class ProcessingInstruction;
class Promise;
class Selection;
class ScriptLoader;
+class ResizeObserver;
class StyleSheetList;
class SVGDocument;
class SVGSVGElement;
@@ -2874,6 +2875,10 @@ public:
bool ModuleScriptsEnabled();
+ virtual void AddResizeObserver(mozilla::dom::ResizeObserver* aResizeObserver) = 0;
+
+ virtual void ScheduleResizeObserversNotification() const = 0;
+
protected:
bool GetUseCounter(mozilla::UseCounter aUseCounter)
{
diff --git a/dom/base/nsJSEnvironment.cpp b/dom/base/nsJSEnvironment.cpp
index 605b1917f..0411bee80 100644
--- a/dom/base/nsJSEnvironment.cpp
+++ b/dom/base/nsJSEnvironment.cpp
@@ -1161,7 +1161,7 @@ TimeUntilNow(TimeStamp start)
struct CycleCollectorStats
{
- constexpr CycleCollectorStats() :
+ CycleCollectorStats() :
mMaxGCDuration(0), mRanSyncForgetSkippable(false), mSuspected(0),
mMaxSkippableDuration(0), mMaxSliceTime(0), mMaxSliceTimeSinceClear(0),
mTotalSliceTime(0), mAnyLockedOut(false), mExtraForgetSkippableCalls(0),
diff --git a/dom/base/test/test_bug840098.html b/dom/base/test/test_bug840098.html
index 8eaceb589..e9275d55b 100644
--- a/dom/base/test/test_bug840098.html
+++ b/dom/base/test/test_bug840098.html
@@ -15,7 +15,7 @@ https://bugzilla.mozilla.org/show_bug.cgi?id=840098
<div id="content" style="display: none">
<div id="foo"></div>
</div>
-<marquee id="m">Hello</marquee>
+<div id="m">Hello</div>
<pre id="test">
<script type="application/javascript">
diff --git a/dom/base/test/test_caretPositionFromPoint.html b/dom/base/test/test_caretPositionFromPoint.html
index 50f12b1ef..054f73227 100644
--- a/dom/base/test/test_caretPositionFromPoint.html
+++ b/dom/base/test/test_caretPositionFromPoint.html
@@ -115,7 +115,7 @@
<div id="a" contenteditable><span id="test1">abc, abc, abc</span><br>
<span id="test2" style="color: blue;">abc, abc, abc</span><br>
<textarea id="test3">abc</textarea><input id="test4" value="abcdef"><br><br>
-<marquee>marquee</marquee>
+<div>div</div>
</div>
<input id="test5" value="The rabbit-hole went straight on like a tunnel for some way, and then dipped suddenly down, so suddenly that Alice had not a moment to think about stopping herself before she found herself falling down a very deep well. Either the well was very deep, or she fell very slowly, for she had plenty of time as she went down to look about her and to wonder what was going to happen next. First, she tried to look down and make out what she was coming to, but it was too dark to see anything; then she looked at the sides of the well, and noticed that they were filled with cupboards and book-shelves; here and there she saw maps and pictures hung upon pegs. She took down a jar from one of the shelves as she passed; it was labelled `ORANGE MARMALADE', but to her great disappointment it was empty: she did not like to drop the jar for fear of killing somebody, so managed to put it into one of the cupboards as she fell past it." type="text">
<input id="test6" type="number" style="width:150px; height:57px;" value="31415"><br>
diff --git a/dom/base/test/test_mutationobservers.html b/dom/base/test/test_mutationobservers.html
deleted file mode 100644
index a6de89595..000000000
--- a/dom/base/test/test_mutationobservers.html
+++ /dev/null
@@ -1,913 +0,0 @@
-<!DOCTYPE HTML>
-<html>
-<!--
-https://bugzilla.mozilla.org/show_bug.cgi?id=641821
--->
-<head>
- <meta charset="utf-8">
- <title>Test for Bug 641821</title>
- <script type="application/javascript" src="/tests/SimpleTest/SimpleTest.js"></script>
- <link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css"/>
-</head>
-<body onload="runTest()">
-<a target="_blank" href="https://bugzilla.mozilla.org/show_bug.cgi?id=641821">Mozilla Bug 641821</a>
-<p id="display"></p>
-<div id="content" style="display: none">
-
-</div>
-<pre id="test">
-<script type="application/javascript">
-
-/** Test for Bug 641821 **/
-
-SimpleTest.requestFlakyTimeout("requestFlakyTimeout is silly. (But make sure marquee has time to initialize itself.)");
-
-var div = document.createElement("div");
-
-var M;
-if ("MozMutationObserver" in window) {
- M = window.MozMutationObserver;
-} else if ("WebKitMutationObserver" in window) {
- M = window.WebKitMutationObserver;
-} else {
- M = window.MutationObserver;
-}
-
-function log(str) {
- var d = document.createElement("div");
- d.textContent = str;
- if (str.indexOf("PASSED") >= 0) {
- d.setAttribute("style", "color: green;");
- } else {
- d.setAttribute("style", "color: red;");
- }
- document.getElementById("log").appendChild(d);
-}
-
-// Some helper functions so that this test runs also outside mochitest.
-if (!("ok" in window)) {
- window.ok = function(val, str) {
- log(str + (val ? " PASSED\n" : " FAILED\n"));
- }
-}
-
-if (!("is" in window)) {
- window.is = function(val, refVal, str) {
- log(str + (val == refVal? " PASSED " : " FAILED ") +
- (val != refVal ? "expected " + refVal + " got " + val + "\n" : "\n"));
- }
-}
-
-if (!("isnot" in window)) {
- window.isnot = function(val, refVal, str) {
- log(str + (val != refVal? " PASSED " : " FAILED ") +
- (val == refVal ? "Didn't expect " + refVal + "\n" : "\n"));
- }
-}
-
-if (!("SimpleTest" in window)) {
- window.SimpleTest =
- {
- finish: function() {
- document.getElementById("log").appendChild(document.createTextNode("DONE"));
- },
- waitForExplicitFinish: function() {}
- }
-}
-
-function then(thenFn) {
- setTimeout(function() {
- if (thenFn) {
- setTimeout(thenFn, 0);
- } else {
- SimpleTest.finish();
- }
- }, 0);
-}
-
-var m;
-var m2;
-var m3;
-var m4;
-
-// Checks basic parameter validation and normal 'this' handling.
-// Tests also basic attribute handling.
-function runTest() {
- m = new M(function(){});
- ok(m, "MutationObserver supported");
-
- var e = null;
- try {
- m.observe(document, {});
- } catch (ex) {
- e = ex;
- }
- ok(e, "Should have thrown an exception");
- is(e.name, "TypeError", "Should have thrown TypeError");
-
- e = null;
- try {
- m.observe(document, { childList: true, attributeOldValue: true });
- } catch (ex) {
- e = ex;
- }
- ok(!e, "Shouldn't have thrown an exception");
-
- e = null;
- try {
- m.observe(document, { childList: true, attributeFilter: ["foo"] });
- } catch (ex) {
- e = ex;
- }
- ok(!e, "Shouldn't have thrown an exception");
-
- e = null;
- try {
- m.observe(document, { childList: true, characterDataOldValue: true });
- } catch (ex) {
- e = ex;
- }
- ok(!e, "Shouldn't have thrown an exception");
-
- e = null;
- try {
- m.observe(document);
- } catch (ex) {
- e = ex;
- }
- ok(e, "Should have thrown an exception");
-
- m = new M(function(records, observer) {
- is(observer, m, "2nd parameter should be the mutation observer");
- is(observer, this, "2nd parameter should be 'this'");
- is(records.length, 1, "Should have one record.");
- is(records[0].type, "attributes", "Should have got attributes record");
- is(records[0].target, div, "Should have got div as target");
- is(records[0].attributeName, "foo", "Should have got record about foo attribute");
- observer.disconnect();
- then(testThisBind);
- m = null;
- });
- m.observe(div, { attributes: true, attributeFilter: ["foo"] });
- is(SpecialPowers.wrap(div).getBoundMutationObservers()[0].getObservingInfo()[0].attributes, true);
- is(SpecialPowers.wrap(div).getBoundMutationObservers()[0].getObservingInfo()[0].attributeFilter.length, 1)
- is(SpecialPowers.wrap(div).getBoundMutationObservers()[0].getObservingInfo()[0].attributeFilter[0], "foo")
- div.setAttribute("foo", "bar");
-}
-
-// 'this' handling when fn.bind() is used.
-function testThisBind() {
- var child = div.appendChild(document.createElement("div"));
- var gchild = child.appendChild(document.createElement("div"));
- m = new M((function(records, observer) {
- is(observer, m, "2nd parameter should be the mutation observer");
- isnot(observer, this, "2nd parameter should be 'this'");
- is(records.length, 3, "Should have one record.");
- is(records[0].type, "attributes", "Should have got attributes record");
- is(records[0].target, div, "Should have got div as target");
- is(records[0].attributeName, "foo", "Should have got record about foo attribute");
- is(records[0].oldValue, "bar", "oldValue should be bar");
- is(records[1].type, "attributes", "Should have got attributes record");
- is(records[1].target, div, "Should have got div as target");
- is(records[1].attributeName, "foo", "Should have got record about foo attribute");
- is(records[1].oldValue, "bar2", "oldValue should be bar2");
- is(records[2].type, "attributes", "Should have got attributes record");
- is(records[2].target, gchild, "Should have got div as target");
- is(records[2].attributeName, "foo", "Should have got record about foo attribute");
- is(records[2].oldValue, null, "oldValue should be bar2");
- observer.disconnect();
- then(testCharacterData);
- m = null;
- }).bind(window));
- m.observe(div, { attributes: true, attributeOldValue: true, subtree: true });
- is(SpecialPowers.wrap(div).getBoundMutationObservers()[0].getObservingInfo()[0].attributes, true)
- is(SpecialPowers.wrap(div).getBoundMutationObservers()[0].getObservingInfo()[0].attributeOldValue, true)
- is(SpecialPowers.wrap(div).getBoundMutationObservers()[0].getObservingInfo()[0].subtree, true)
- div.setAttribute("foo", "bar2");
- div.removeAttribute("foo");
- div.removeChild(child);
- child.removeChild(gchild);
- div.appendChild(gchild);
- div.removeChild(gchild);
- gchild.setAttribute("foo", "bar");
-}
-
-function testCharacterData() {
- m = new M(function(records, observer) {
- is(records[0].type, "characterData", "Should have got characterData");
- is(records[0].oldValue, null, "Shouldn't have got oldData");
- observer.disconnect();
- m = null;
- });
- m2 = new M(function(records, observer) {
- is(records[0].type, "characterData", "Should have got characterData");
- is(records[0].oldValue, "foo", "Should have got oldData");
- observer.disconnect();
- m2 = null;
- });
- m3 = new M(function(records, observer) {
- ok(false, "This should not be called!");
- observer.disconnect();
- m3 = null;
- });
- m4 = new M(function(records, observer) {
- is(records[0].oldValue, null, "Shouldn't have got oldData");
- observer.disconnect();
- m3.disconnect();
- m3 = null;
- then(testChildList);
- m4 = null;
- });
-
- div.appendChild(document.createTextNode("foo"));
- m.observe(div, { characterData: true, subtree: true });
- m2.observe(div, { characterData: true, characterDataOldValue: true, subtree: true});
- // If observing the same node twice, only the latter option should apply.
- m3.observe(div, { characterData: true, subtree: true });
- m3.observe(div, { characterData: true, subtree: false });
- m4.observe(div.firstChild, { characterData: true, subtree: false });
-
- is(SpecialPowers.wrap(div).getBoundMutationObservers().length, 3)
- is(SpecialPowers.wrap(div).getBoundMutationObservers()[2].getObservingInfo()[0].characterData, true)
- is(SpecialPowers.wrap(div).getBoundMutationObservers()[2].getObservingInfo()[0].subtree, false)
-
- div.firstChild.data = "bar";
-}
-
-function testChildList() {
- var fc = div.firstChild;
- m = new M(function(records, observer) {
- is(records[0].type, "childList", "Should have got childList");
- is(records[0].addedNodes.length, 0, "Shouldn't have got addedNodes");
- is(records[0].removedNodes.length, 1, "Should have got removedNodes");
- is(records[0].removedNodes[0], fc, "Should have removed a text node");
- observer.disconnect();
- then(testChildList2);
- m = null;
- });
- m.observe(div, { childList: true});
- div.removeChild(div.firstChild);
-}
-
-function testChildList2() {
- div.innerHTML = "<span>1</span><span>2</span>";
- m = new M(function(records, observer) {
- is(records[0].type, "childList", "Should have got childList");
- is(records[0].removedNodes.length, 2, "Should have got removedNodes");
- is(records[0].addedNodes.length, 1, "Should have got addedNodes");
- observer.disconnect();
- then(testChildList3);
- m = null;
- });
- m.observe(div, { childList: true });
- div.innerHTML = "<span><span>foo</span></span>";
-}
-
-function testChildList3() {
- m = new M(function(records, observer) {
- is(records[0].type, "childList", "Should have got childList");
- is(records[0].removedNodes.length, 1, "Should have got removedNodes");
- is(records[0].addedNodes.length, 1, "Should have got addedNodes");
- observer.disconnect();
- then(testChildList4);
- m = null;
- });
- m.observe(div, { childList: true });
- div.textContent = "hello";
-}
-
-function testChildList4() {
- div.textContent = null;
- var df = document.createDocumentFragment();
- var t1 = df.appendChild(document.createTextNode("Hello "));
- var t2 = df.appendChild(document.createTextNode("world!"));
- var s1 = div.appendChild(document.createElement("span"));
- s1.textContent = "foo";
- var s2 = div.appendChild(document.createElement("span"));
- function callback(records, observer) {
- is(records.length, 3, "Should have got one record for removing nodes from document fragment and one record for adding them to div");
- is(records[0].removedNodes.length, 2, "Should have got removedNodes");
- is(records[0].removedNodes[0], t1, "Should be the 1st textnode");
- is(records[0].removedNodes[1], t2, "Should be the 2nd textnode");
- is(records[1].addedNodes.length, 2, "Should have got addedNodes");
- is(records[1].addedNodes[0], t1, "Should be the 1st textnode");
- is(records[1].addedNodes[1], t2, "Should be the 2nd textnode");
- is(records[1].previousSibling, s1, "Should have previousSibling");
- is(records[1].nextSibling, s2, "Should have nextSibling");
- is(records[2].type, "characterData", "3rd record should be characterData");
- is(records[2].target, t1, "target should be the textnode");
- is(records[2].oldValue, "Hello ", "oldValue was 'Hello '");
- observer.disconnect();
- then(testChildList5);
- m = null;
- };
- m = new M(callback);
- m.observe(df, { childList: true, characterData: true, characterDataOldValue: true, subtree: true });
- is(SpecialPowers.wrap(df).getBoundMutationObservers()[0].getObservingInfo()[0].childList, true)
- is(SpecialPowers.wrap(df).getBoundMutationObservers()[0].getObservingInfo()[0].characterData, true)
- is(SpecialPowers.wrap(df).getBoundMutationObservers()[0].getObservingInfo()[0].characterDataOldValue, true)
- is(SpecialPowers.wrap(df).getBoundMutationObservers()[0].getObservingInfo()[0].subtree, true)
- ok(SpecialPowers.compare(SpecialPowers.wrap(df).getBoundMutationObservers()[0].mutationCallback, callback))
- m.observe(div, { childList: true });
- is(SpecialPowers.wrap(df).getBoundMutationObservers()[0].getObservingInfo().length, 2)
-
- // Make sure transient observers aren't leaked.
- var leakTest = new M(function(){});
- leakTest.observe(div, { characterData: true, subtree: true });
-
- div.insertBefore(df, s2);
- s1.firstChild.data = "bar"; // This should *not* create a record.
- t1.data = "Hello the whole "; // This should create a record.
-}
-
-function testChildList5() {
- div.textContent = null;
- var c1 = div.appendChild(document.createElement("div"));
- var c2 = document.createElement("div");
- var div2 = document.createElement("div");
- var c3 = div2.appendChild(document.createElement("div"));
- var c4 = document.createElement("div");
- var c5 = document.createElement("div");
- var df = document.createDocumentFragment();
- var emptyDF = document.createDocumentFragment();
- var dfc1 = df.appendChild(document.createElement("div"));
- var dfc2 = df.appendChild(document.createElement("div"));
- var dfc3 = df.appendChild(document.createElement("div"));
- m = new M(function(records, observer) {
- is(records.length, 6 , "");
- is(records[0].removedNodes.length, 1, "Should have got removedNodes");
- is(records[0].removedNodes[0], c1, "");
- is(records[0].addedNodes.length, 1, "Should have got addedNodes");
- is(records[0].addedNodes[0], c2, "");
- is(records[0].previousSibling, null, "");
- is(records[0].nextSibling, null, "");
- is(records[1].removedNodes.length, 1, "Should have got removedNodes");
- is(records[1].removedNodes[0], c3, "");
- is(records[1].addedNodes.length, 0, "Shouldn't have got addedNodes");
- is(records[1].previousSibling, null, "");
- is(records[1].nextSibling, null, "");
- is(records[2].removedNodes.length, 1, "Should have got removedNodes");
- is(records[2].removedNodes[0], c2, "");
- is(records[2].addedNodes.length, 1, "Should have got addedNodes");
- is(records[2].addedNodes[0], c3, "");
- is(records[2].previousSibling, null, "");
- is(records[2].nextSibling, null, "");
- // Check document fragment handling
- is(records[5].removedNodes.length, 1, "");
- is(records[5].removedNodes[0], c4, "");
- is(records[5].addedNodes.length, 3, "");
- is(records[5].addedNodes[0], dfc1, "");
- is(records[5].addedNodes[1], dfc2, "");
- is(records[5].addedNodes[2], dfc3, "");
- is(records[5].previousSibling, c3, "");
- is(records[5].nextSibling, c5, "");
- observer.disconnect();
- then(testAdoptNode);
- m = null;
- });
- m.observe(div, { childList: true, subtree: true });
- m.observe(div2, { childList: true, subtree: true });
- div.replaceChild(c2, c1);
- div.replaceChild(c3, c2);
- div.appendChild(c4);
- div.appendChild(c5);
- div.replaceChild(df, c4);
- div.appendChild(emptyDF); // empty document shouldn't cause mutation records
-}
-
-function testAdoptNode() {
- var d1 = document.implementation.createHTMLDocument(null);
- var d2 = document.implementation.createHTMLDocument(null);
- var addedNode;
- m = new M(function(records, observer) {
- is(records.length, 3, "Should have 2 records");
- is(records[0].target.ownerDocument, d1, "ownerDocument should be the initial document")
- is(records[1].target.ownerDocument, d2, "ownerDocument should be the new document");
- is(records[2].type, "attributes", "Should have got attribute mutation")
- is(records[2].attributeName, "foo", "Should have got foo attribute mutation")
- observer.disconnect();
- then(testOuterHTML);
- m = null;
- });
- m.observe(d1, { childList: true, subtree: true, attributes: true });
- d2.body.appendChild(d1.body);
- addedNode = d2.body.lastChild.appendChild(d2.createElement("div"));
- addedNode.setAttribute("foo", "bar");
-}
-
-function testOuterHTML() {
- var doc = document.implementation.createHTMLDocument(null);
- var d1 = doc.body.appendChild(document.createElement("div"));
- var d2 = doc.body.appendChild(document.createElement("div"));
- var d3 = doc.body.appendChild(document.createElement("div"));
- var d4 = doc.body.appendChild(document.createElement("div"));
- m = new M(function(records, observer) {
- is(records.length, 4, "Should have 1 record");
- is(records[0].removedNodes.length, 1, "Should have 1 removed nodes");
- is(records[0].addedNodes.length, 2, "Should have 2 added nodes");
- is(records[0].previousSibling, null, "");
- is(records[0].nextSibling, d2, "");
- is(records[1].removedNodes.length, 1, "Should have 1 removed nodes");
- is(records[1].addedNodes.length, 2, "Should have 2 added nodes");
- is(records[1].previousSibling, records[0].addedNodes[1], "");
- is(records[1].nextSibling, d3, "");
- is(records[2].removedNodes.length, 1, "Should have 1 removed nodes");
- is(records[2].addedNodes.length, 2, "Should have 2 added nodes");
- is(records[2].previousSibling, records[1].addedNodes[1], "");
- is(records[2].nextSibling, d4, "");
- is(records[3].removedNodes.length, 1, "Should have 1 removed nodes");
- is(records[3].addedNodes.length, 0);
- is(records[3].previousSibling, records[2].addedNodes[1], "");
- is(records[3].nextSibling, null, "");
- observer.disconnect();
- then(testInsertAdjacentHTML);
- m = null;
- });
- m.observe(doc, { childList: true, subtree: true });
- d1.outerHTML = "<div>1</div><div>1</div>";
- d2.outerHTML = "<div>2</div><div>2</div>";
- d3.outerHTML = "<div>3</div><div>3</div>";
- d4.outerHTML = "";
-}
-
-function testInsertAdjacentHTML() {
- var doc = document.implementation.createHTMLDocument(null);
- var d1 = doc.body.appendChild(document.createElement("div"));
- var d2 = doc.body.appendChild(document.createElement("div"));
- var d3 = doc.body.appendChild(document.createElement("div"));
- var d4 = doc.body.appendChild(document.createElement("div"));
- m = new M(function(records, observer) {
- is(records.length, 4, "");
- is(records[0].target, doc.body, "");
- is(records[0].previousSibling, null, "");
- is(records[0].nextSibling, d1, "");
- is(records[1].target, d2, "");
- is(records[1].previousSibling, null, "");
- is(records[1].nextSibling, null, "");
- is(records[2].target, d3, "");
- is(records[2].previousSibling, null, "");
- is(records[2].nextSibling, null, "");
- is(records[3].target, doc.body, "");
- is(records[3].previousSibling, d4, "");
- is(records[3].nextSibling, null, "");
- observer.disconnect();
- then(testSyncXHR);
- m = null;
- });
- m.observe(doc, { childList: true, subtree: true });
- d1.insertAdjacentHTML("beforebegin", "<div></div><div></div>");
- d2.insertAdjacentHTML("afterbegin", "<div></div><div></div>");
- d3.insertAdjacentHTML("beforeend", "<div></div><div></div>");
- d4.insertAdjacentHTML("afterend", "<div></div><div></div>");
-}
-
-
-var callbackHandled = false;
-
-function testSyncXHR() {
- div.textContent = null;
- m = new M(function(records, observer) {
- is(records.length, 1, "");
- is(records[0].addedNodes.length, 1, "");
- callbackHandled = true;
- observer.disconnect();
- m = null;
- });
- m.observe(div, { childList: true, subtree: true });
- div.innerHTML = "<div>hello</div>";
- var x = new XMLHttpRequest();
- x.open("GET", window.location, false);
- x.send();
- ok(!callbackHandled, "Shouldn't have called the mutation callback!");
- setTimeout(testSyncXHR2, 0);
-}
-
-function testSyncXHR2() {
- ok(callbackHandled, "Should have called the mutation callback!");
- then(testTakeRecords);
-}
-
-function testTakeRecords() {
- var s = "<span>1</span><span>2</span>";
- div.innerHTML = s;
- var takenRecords;
- m = new M(function(records, observer) {
- is(records.length, 3, "Should have got 3 records");
-
- is(records[0].type, "attributes", "Should have got attributes");
- is(records[0].attributeName, "foo", "");
- is(records[0].attributeNamespace, null, "");
- is(records[0].prevValue, null, "");
- is(records[1].type, "childList", "Should have got childList");
- is(records[1].removedNodes.length, 2, "Should have got removedNodes");
- is(records[1].addedNodes.length, 2, "Should have got addedNodes");
- is(records[2].type, "attributes", "Should have got attributes");
- is(records[2].attributeName, "foo", "");
-
- is(records.length, takenRecords.length, "Should have had similar mutations");
- is(records[0].type, takenRecords[0].type, "Should have had similar mutations");
- is(records[1].type, takenRecords[1].type, "Should have had similar mutations");
- is(records[2].type, takenRecords[2].type, "Should have had similar mutations");
-
- is(records[1].removedNodes.length, takenRecords[1].removedNodes.length, "Should have had similar mutations");
- is(records[1].addedNodes.length, takenRecords[1].addedNodes.length, "Should have had similar mutations");
-
- is(m.takeRecords().length, 0, "Shouldn't have any records");
- observer.disconnect();
- then(testMutationObserverAndEvents);
- m = null;
- });
- m.observe(div, { childList: true, attributes: true });
- div.setAttribute("foo", "bar");
- div.innerHTML = s;
- div.removeAttribute("foo");
- takenRecords = m.takeRecords();
- div.setAttribute("foo", "bar");
- div.innerHTML = s;
- div.removeAttribute("foo");
-}
-
-function testTakeRecords() {
- function mutationListener(e) {
- ++mutationEventCount;
- is(e.attrChange, MutationEvent.ADDITION, "unexpected change");
- }
-
- m = new M(function(records, observer) {
- is(records.length, 2, "Should have got 2 records");
- is(records[0].type, "attributes", "Should have got attributes");
- is(records[0].attributeName, "foo", "");
- is(records[0].oldValue, null, "");
- is(records[1].type, "attributes", "Should have got attributes");
- is(records[1].attributeName, "foo", "");
- is(records[1].oldValue, "bar", "");
- observer.disconnect();
- div.removeEventListener("DOMAttrModified", mutationListener);
- then(testExpandos);
- m = null;
- });
- m.observe(div, { attributes: true, attributeOldValue: true });
- // Note, [0] points to a mutation observer which is there for a leak test!
- ok(SpecialPowers.compare(SpecialPowers.wrap(div).getBoundMutationObservers()[1], m));
- var mutationEventCount = 0;
- div.addEventListener("DOMAttrModified", mutationListener);
- div.setAttribute("foo", "bar");
- div.setAttribute("foo", "bar");
- is(mutationEventCount, 1, "Should have got only one mutation event!");
-}
-
-function testExpandos() {
- var m2 = new M(function(records, observer) {
- is(observer.expandoProperty, true);
- observer.disconnect();
- then(testOutsideShadowDOM);
- });
- m2.expandoProperty = true;
- m2.observe(div, { attributes: true });
- m2 = null;
- if (SpecialPowers) {
- // Run GC several times to see if the expando property disappears.
-
- SpecialPowers.gc();
- SpecialPowers.gc();
- SpecialPowers.gc();
- SpecialPowers.gc();
- }
- div.setAttribute("foo", "bar2");
-}
-
-function testOutsideShadowDOM() {
- var m = new M(function(records, observer) {
- is(records.length, 1);
- is(records[0].type, "attributes", "Should have got attributes");
- observer.disconnect();
- then(testInsideShadowDOM);
- });
- m.observe(div, {
- attributes: true,
- childList: true,
- characterData: true,
- subtree: true
- })
- var sr = div.createShadowRoot();
- sr.innerHTML = "<div" + ">text</" + "div>";
- sr.firstChild.setAttribute("foo", "bar");
- sr.firstChild.firstChild.data = "text2";
- sr.firstChild.appendChild(document.createElement("div"));
- div.setAttribute("foo", "bar");
-}
-
-function testInsideShadowDOM() {
- var m = new M(function(records, observer) {
- is(records.length, 4);
- is(records[0].type, "childList");
- is(records[1].type, "attributes");
- is(records[2].type, "characterData");
- is(records[3].type, "childList");
- observer.disconnect();
- then(testMarquee);
- });
- var sr = div.createShadowRoot();
- m.observe(sr, {
- attributes: true,
- childList: true,
- characterData: true,
- subtree: true
- });
-
- sr.innerHTML = "<div" + ">text</" + "div>";
- sr.firstChild.setAttribute("foo", "bar");
- sr.firstChild.firstChild.data = "text2";
- sr.firstChild.appendChild(document.createElement("div"));
- div.setAttribute("foo", "bar2");
-
-}
-
-function testMarquee() {
- var m = new M(function(records, observer) {
- is(records.length, 1);
- is(records[0].type, "attributes");
- is(records[0].attributeName, "ok");
- is(records[0].oldValue, null);
- observer.disconnect();
- then(testStyleCreate);
- });
- var marquee = document.createElement("marquee");
- m.observe(marquee, {
- attributes: true,
- attributeOldValue: true,
- childList: true,
- characterData: true,
- subtree: true
- });
- document.body.appendChild(marquee);
- setTimeout(function() {marquee.setAttribute("ok", "ok")}, 500);
-}
-
-function testStyleCreate() {
- m = new M(function(records, observer) {
- is(records.length, 1, "number of records");
- is(records[0].type, "attributes", "record.type");
- is(records[0].attributeName, "style", "record.attributeName");
- is(records[0].oldValue, null, "record.oldValue");
- isnot(div.getAttribute("style"), null, "style attribute after creation");
- observer.disconnect();
- m = null;
- div.removeAttribute("style");
- then(testStyleModify);
- });
- m.observe(div, { attributes: true, attributeOldValue: true });
- is(div.getAttribute("style"), null, "style attribute before creation");
- div.style.color = "blue";
-}
-
-function testStyleModify() {
- div.style.color = "yellow";
- m = new M(function(records, observer) {
- is(records.length, 1, "number of records");
- is(records[0].type, "attributes", "record.type");
- is(records[0].attributeName, "style", "record.attributeName");
- isnot(div.getAttribute("style"), null, "style attribute after modification");
- observer.disconnect();
- m = null;
- div.removeAttribute("style");
- then(testStyleRead);
- });
- m.observe(div, { attributes: true });
- isnot(div.getAttribute("style"), null, "style attribute before modification");
- div.style.color = "blue";
-}
-
-function testStyleRead() {
- m = new M(function(records, observer) {
- is(records.length, 1, "number of records");
- is(records[0].type, "attributes", "record.type");
- is(records[0].attributeName, "data-test", "record.attributeName");
- is(div.getAttribute("style"), null, "style attribute after read");
- observer.disconnect();
- div.removeAttribute("data-test");
- m = null;
- then(testStyleRemoveProperty);
- });
- m.observe(div, { attributes: true });
- is(div.getAttribute("style"), null, "style attribute before read");
- var value = div.style.color; // shouldn't generate any mutation records
- div.setAttribute("data-test", "a");
-}
-
-function testStyleRemoveProperty() {
- div.style.color = "blue";
- m = new M(function(records, observer) {
- is(records.length, 1, "number of records");
- is(records[0].type, "attributes", "record.type");
- is(records[0].attributeName, "style", "record.attributeName");
- isnot(div.getAttribute("style"), null, "style attribute after successful removeProperty");
- observer.disconnect();
- m = null;
- div.removeAttribute("style");
- then(testStyleRemoveProperty2);
- });
- m.observe(div, { attributes: true });
- isnot(div.getAttribute("style"), null, "style attribute before successful removeProperty");
- div.style.removeProperty("color");
-}
-
-function testStyleRemoveProperty2() {
- m = new M(function(records, observer) {
- is(records.length, 1, "number of records");
- is(records[0].type, "attributes", "record.type");
- is(records[0].attributeName, "data-test", "record.attributeName");
- is(div.getAttribute("style"), null, "style attribute after unsuccessful removeProperty");
- observer.disconnect();
- m = null;
- div.removeAttribute("data-test");
- then(testAttributeRecordMerging1);
- });
- m.observe(div, { attributes: true });
- is(div.getAttribute("style"), null, "style attribute before unsuccessful removeProperty");
- div.style.removeProperty("color"); // shouldn't generate any mutation records
- div.setAttribute("data-test", "a");
-}
-
-function testAttributeRecordMerging1() {
- ok(true, "testAttributeRecordMerging1");
- var m = new M(function(records, observer) {
- is(records.length, 2);
- is(records[0].type, "attributes");
- is(records[0].target, div);
- is(records[0].attributeName, "foo");
- is(records[0].attributeNamespace, null);
- is(records[0].oldValue, null);
-
- is(records[1].type, "attributes");
- is(records[1].target, div.firstChild);
- is(records[1].attributeName, "foo");
- is(records[1].attributeNamespace, null);
- is(records[1].oldValue, null);
- observer.disconnect();
- div.innerHTML = "";
- div.removeAttribute("foo");
- then(testAttributeRecordMerging2);
- });
- m.observe(div, {
- attributes: true,
- subtree: true
- });
- SpecialPowers.wrap(m).mergeAttributeRecords = true;
-
- div.setAttribute("foo", "bar_1");
- div.setAttribute("foo", "bar_2");
- div.innerHTML = "<div></div>";
- div.firstChild.setAttribute("foo", "bar_1");
- div.firstChild.setAttribute("foo", "bar_2");
-}
-
-function testAttributeRecordMerging2() {
- ok(true, "testAttributeRecordMerging2");
- var m = new M(function(records, observer) {
- is(records.length, 2);
- is(records[0].type, "attributes");
- is(records[0].target, div);
- is(records[0].attributeName, "foo");
- is(records[0].attributeNamespace, null);
- is(records[0].oldValue, "initial");
-
- is(records[1].type, "attributes");
- is(records[1].target, div.firstChild);
- is(records[1].attributeName, "foo");
- is(records[1].attributeNamespace, null);
- is(records[1].oldValue, "initial");
- observer.disconnect();
- div.innerHTML = "";
- div.removeAttribute("foo");
- then(testAttributeRecordMerging3);
- });
-
- div.setAttribute("foo", "initial");
- div.innerHTML = "<div></div>";
- div.firstChild.setAttribute("foo", "initial");
- m.observe(div, {
- attributes: true,
- subtree: true,
- attributeOldValue: true
- });
- SpecialPowers.wrap(m).mergeAttributeRecords = true;
-
- div.setAttribute("foo", "bar_1");
- div.setAttribute("foo", "bar_2");
- div.firstChild.setAttribute("foo", "bar_1");
- div.firstChild.setAttribute("foo", "bar_2");
-}
-
-function testAttributeRecordMerging3() {
- ok(true, "testAttributeRecordMerging3");
- var m = new M(function(records, observer) {
- is(records.length, 4);
- is(records[0].type, "attributes");
- is(records[0].target, div);
- is(records[0].attributeName, "foo");
- is(records[0].attributeNamespace, null);
- is(records[0].oldValue, "initial");
-
- is(records[1].type, "attributes");
- is(records[1].target, div.firstChild);
- is(records[1].attributeName, "foo");
- is(records[1].attributeNamespace, null);
- is(records[1].oldValue, "initial");
-
- is(records[2].type, "attributes");
- is(records[2].target, div);
- is(records[2].attributeName, "foo");
- is(records[2].attributeNamespace, null);
- is(records[2].oldValue, "bar_1");
-
- is(records[3].type, "attributes");
- is(records[3].target, div.firstChild);
- is(records[3].attributeName, "foo");
- is(records[3].attributeNamespace, null);
- is(records[3].oldValue, "bar_1");
-
- observer.disconnect();
- div.innerHTML = "";
- div.removeAttribute("foo");
- then(testAttributeRecordMerging4);
- });
-
- div.setAttribute("foo", "initial");
- div.innerHTML = "<div></div>";
- div.firstChild.setAttribute("foo", "initial");
- m.observe(div, {
- attributes: true,
- subtree: true,
- attributeOldValue: true
- });
- SpecialPowers.wrap(m).mergeAttributeRecords = true;
-
- // No merging should happen.
- div.setAttribute("foo", "bar_1");
- div.firstChild.setAttribute("foo", "bar_1");
- div.setAttribute("foo", "bar_2");
- div.firstChild.setAttribute("foo", "bar_2");
-}
-
-function testAttributeRecordMerging4() {
- ok(true, "testAttributeRecordMerging4");
- var m = new M(function(records, observer) {
- });
-
- div.setAttribute("foo", "initial");
- div.innerHTML = "<div></div>";
- div.firstChild.setAttribute("foo", "initial");
- m.observe(div, {
- attributes: true,
- subtree: true,
- attributeOldValue: true
- });
- SpecialPowers.wrap(m).mergeAttributeRecords = true;
-
- div.setAttribute("foo", "bar_1");
- div.setAttribute("foo", "bar_2");
- div.firstChild.setAttribute("foo", "bar_1");
- div.firstChild.setAttribute("foo", "bar_2");
-
- var records = m.takeRecords();
-
- is(records.length, 2);
- is(records[0].type, "attributes");
- is(records[0].target, div);
- is(records[0].attributeName, "foo");
- is(records[0].attributeNamespace, null);
- is(records[0].oldValue, "initial");
-
- is(records[1].type, "attributes");
- is(records[1].target, div.firstChild);
- is(records[1].attributeName, "foo");
- is(records[1].attributeNamespace, null);
- is(records[1].oldValue, "initial");
- m.disconnect();
- div.innerHTML = "";
- div.removeAttribute("foo");
- then(testChromeOnly);
-}
-
-function testChromeOnly() {
- // Content can't access nativeAnonymousChildList
- try {
- var mo = new M(function(records, observer) { });
- mo.observe(div, { nativeAnonymousChildList: true });
- ok(false, "Should have thrown when trying to observe with chrome-only init");
- } catch (e) {
- ok(true, "Throws when trying to observe with chrome-only init");
- }
-
- then();
-}
-
-SimpleTest.waitForExplicitFinish();
-
-</script>
-</pre>
-<div id="log">
-</div>
-</body>
-</html>
diff --git a/dom/bindings/BindingUtils.h b/dom/bindings/BindingUtils.h
index 5cab835b3..12a2e370a 100644
--- a/dom/bindings/BindingUtils.h
+++ b/dom/bindings/BindingUtils.h
@@ -3071,21 +3071,21 @@ class GetCCParticipant
{
// Helper for GetCCParticipant for classes that participate in CC.
template<class U>
- static constexpr nsCycleCollectionParticipant*
+ static nsCycleCollectionParticipant*
GetHelper(int, typename U::NS_CYCLE_COLLECTION_INNERCLASS* dummy=nullptr)
{
return T::NS_CYCLE_COLLECTION_INNERCLASS::GetParticipant();
}
// Helper for GetCCParticipant for classes that don't participate in CC.
template<class U>
- static constexpr nsCycleCollectionParticipant*
+ static nsCycleCollectionParticipant*
GetHelper(double)
{
return nullptr;
}
public:
- static constexpr nsCycleCollectionParticipant*
+ static nsCycleCollectionParticipant*
Get()
{
// Passing int() here will try to call the GetHelper that takes an int as
@@ -3100,7 +3100,7 @@ template<class T>
class GetCCParticipant<T, true>
{
public:
- static constexpr nsCycleCollectionParticipant*
+ static nsCycleCollectionParticipant*
Get()
{
return nullptr;
@@ -3123,7 +3123,7 @@ EnumerateGlobal(JSContext* aCx, JS::Handle<JSObject*> aObj);
template <class T>
struct CreateGlobalOptions
{
- static constexpr ProtoAndIfaceCache::Kind ProtoAndIfaceCacheKind =
+ static const ProtoAndIfaceCache::Kind ProtoAndIfaceCacheKind =
ProtoAndIfaceCache::NonWindowLike;
static void TraceGlobal(JSTracer* aTrc, JSObject* aObj)
{
@@ -3140,7 +3140,7 @@ struct CreateGlobalOptions
template <>
struct CreateGlobalOptions<nsGlobalWindow>
{
- static constexpr ProtoAndIfaceCache::Kind ProtoAndIfaceCacheKind =
+ static const ProtoAndIfaceCache::Kind ProtoAndIfaceCacheKind =
ProtoAndIfaceCache::WindowLike;
static void TraceGlobal(JSTracer* aTrc, JSObject* aObj);
static bool PostCreateGlobal(JSContext* aCx, JS::Handle<JSObject*> aGlobal);
diff --git a/dom/bindings/Bindings.conf b/dom/bindings/Bindings.conf
index 941e65eff..f08094617 100644
--- a/dom/bindings/Bindings.conf
+++ b/dom/bindings/Bindings.conf
@@ -717,6 +717,21 @@ DOMInterfaces = {
},
},
+'ResizeObservation': {
+ 'nativeType': 'mozilla::dom::ResizeObservation',
+ 'headerFile': 'mozilla/dom/ResizeObserver.h',
+},
+
+'ResizeObserver': {
+ 'nativeType': 'mozilla::dom::ResizeObserver',
+ 'headerFile': 'mozilla/dom/ResizeObserver.h',
+},
+
+'ResizeObserverEntry': {
+ 'nativeType': 'mozilla::dom::ResizeObserverEntry',
+ 'headerFile': 'mozilla/dom/ResizeObserver.h',
+},
+
'Response': {
'binaryNames': { 'headers': 'headers_' },
},
diff --git a/dom/bindings/DOMJSClass.h b/dom/bindings/DOMJSClass.h
index 6e779840f..c97cf9322 100644
--- a/dom/bindings/DOMJSClass.h
+++ b/dom/bindings/DOMJSClass.h
@@ -210,7 +210,7 @@ struct NativePropertiesN {
const int32_t iteratorAliasMethodIndex;
- constexpr const NativePropertiesN<7>* Upcast() const {
+ const NativePropertiesN<7>* Upcast() const {
return reinterpret_cast<const NativePropertiesN<7>*>(this);
}
diff --git a/dom/bindings/GenerateCSS2PropertiesWebIDL.py b/dom/bindings/GenerateCSS2PropertiesWebIDL.py
index 57634494f..b1f2a6016 100644
--- a/dom/bindings/GenerateCSS2PropertiesWebIDL.py
+++ b/dom/bindings/GenerateCSS2PropertiesWebIDL.py
@@ -17,6 +17,7 @@ def generateLine(propName, extendedAttrs):
propName)
def generate(output, idlFilename, preprocessorHeader):
print(idlFilename)
+ sys.stdout.flush()
cpp = list(buildconfig.substs['CPP'])
cpp += shellutil.split(buildconfig.substs['ACDEFINES'])
cpp.append(preprocessorHeader)
diff --git a/dom/bindings/mozwebidlcodegen/__init__.py b/dom/bindings/mozwebidlcodegen/__init__.py
index 69f3f5e25..93b33012a 100644
--- a/dom/bindings/mozwebidlcodegen/__init__.py
+++ b/dom/bindings/mozwebidlcodegen/__init__.py
@@ -12,6 +12,7 @@ import hashlib
import json
import logging
import os
+import sys
from copy import deepcopy
@@ -270,6 +271,7 @@ class WebIDLCodegenManager(LoggingMixin):
for filename in sorted(changed_inputs):
basename = mozpath.basename(filename)
print basename
+ sys.stdout.flush()
result.inputs.add(filename)
written, deps = self._generate_build_files_for_webidl(filename)
result.created |= written[0]
diff --git a/dom/cache/DBSchema.cpp b/dom/cache/DBSchema.cpp
index 176e7b9d1..37510e2e1 100644
--- a/dom/cache/DBSchema.cpp
+++ b/dom/cache/DBSchema.cpp
@@ -2460,7 +2460,7 @@ Validate(mozIStorageConnection* aConn)
typedef nsresult (*MigrationFunc)(mozIStorageConnection*, bool&);
struct Migration
{
- constexpr Migration(int32_t aFromVersion, MigrationFunc aFunc)
+ Migration(int32_t aFromVersion, MigrationFunc aFunc)
: mFromVersion(aFromVersion)
, mFunc(aFunc)
{ }
diff --git a/dom/canvas/test/webgl-conf/checkout/deqp/temp_externs/webkit_css.js b/dom/canvas/test/webgl-conf/checkout/deqp/temp_externs/webkit_css.js
deleted file mode 100644
index 60841f8e2..000000000
--- a/dom/canvas/test/webgl-conf/checkout/deqp/temp_externs/webkit_css.js
+++ /dev/null
@@ -1,456 +0,0 @@
-/*
- * Copyright 2008 The Closure Compiler Authors
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-/**
- * @fileoverview Definitions for WebKit's custom CSS properties. Copied from:
- * {@link
- * http://trac.webkit.org/browser/trunk/Source/WebCore/css/CSSPropertyNames.in}
- *
- * If you make changes to this file, notice that every property appears
- * twice: once as an uppercase name and once as a lowercase name.
- * WebKit allows both. The uppercase version is preferred.
- *
- * @externs
- * @author nicksantos@google.com (Nick Santos)
- */
-
-/** @type {string} */ CSSProperties.prototype.WebkitAlignContent;
-/** @type {string} */ CSSProperties.prototype.WebkitAlignItems;
-/** @type {string} */ CSSProperties.prototype.WebkitAlignSelf;
-/** @type {string} */ CSSProperties.prototype.WebkitAnimation;
-/** @type {string} */ CSSProperties.prototype.WebkitAnimationDelay;
-/** @type {string} */ CSSProperties.prototype.WebkitAnimationDirection;
-/** @type {string} */ CSSProperties.prototype.WebkitAnimationDuration;
-/** @type {string} */ CSSProperties.prototype.WebkitAnimationFillMode;
-/** @type {string} */ CSSProperties.prototype.WebkitAnimationIterationCount;
-/** @type {string} */ CSSProperties.prototype.WebkitAnimationName;
-/** @type {string} */ CSSProperties.prototype.WebkitAnimationPlayState;
-/** @type {string} */ CSSProperties.prototype.WebkitAnimationTimingFunction;
-/** @type {string} */ CSSProperties.prototype.WebkitAppearance;
-/** @type {string} */ CSSProperties.prototype.WebkitAppRegion;
-/** @type {string} */ CSSProperties.prototype.WebkitAspectRatio;
-/** @type {string} */ CSSProperties.prototype.WebkitBackfaceVisibility;
-/** @type {string} */ CSSProperties.prototype.WebkitBackgroundClip;
-/** @type {string} */ CSSProperties.prototype.WebkitBackgroundComposite;
-/** @type {string} */ CSSProperties.prototype.WebkitBackgroundOrigin;
-/** @type {string} */ CSSProperties.prototype.WebkitBackgroundSize;
-/** @type {string} */ CSSProperties.prototype.WebkitBinding;
-/** @type {string} */ CSSProperties.prototype.WebkitBlendMode;
-/** @type {string} */ CSSProperties.prototype.WebkitBorderAfter;
-/** @type {string} */ CSSProperties.prototype.WebkitBorderAfterColor;
-/** @type {string} */ CSSProperties.prototype.WebkitBorderAfterStyle;
-/** @type {string} */ CSSProperties.prototype.WebkitBorderAfterWidth;
-/** @type {string} */ CSSProperties.prototype.WebkitBorderBefore;
-/** @type {string} */ CSSProperties.prototype.WebkitBorderBeforeColor;
-/** @type {string} */ CSSProperties.prototype.WebkitBorderBeforeStyle;
-/** @type {string} */ CSSProperties.prototype.WebkitBorderBeforeWidth;
-/** @type {string} */ CSSProperties.prototype.WebkitBorderBottomLeftRadius;
-/** @type {string} */ CSSProperties.prototype.WebkitBorderBottomRightRadius;
-/** @type {string} */ CSSProperties.prototype.WebkitBorderEnd;
-/** @type {string} */ CSSProperties.prototype.WebkitBorderEndColor;
-/** @type {string} */ CSSProperties.prototype.WebkitBorderEndStyle;
-/** @type {string} */ CSSProperties.prototype.WebkitBorderEndWidth;
-/** @type {string} */ CSSProperties.prototype.WebkitBorderFit;
-/** @type {string} */ CSSProperties.prototype.WebkitBorderHorizontalSpacing;
-/** @type {string} */ CSSProperties.prototype.WebkitBorderImage;
-/** @type {string} */ CSSProperties.prototype.WebkitBorderRadius;
-/** @type {string} */ CSSProperties.prototype.WebkitBorderStart;
-/** @type {string} */ CSSProperties.prototype.WebkitBorderStartColor;
-/** @type {string} */ CSSProperties.prototype.WebkitBorderStartStyle;
-/** @type {string} */ CSSProperties.prototype.WebkitBorderStartWidth;
-/** @type {string} */ CSSProperties.prototype.WebkitBorderTopLeftRadius;
-/** @type {string} */ CSSProperties.prototype.WebkitBorderTopRightRadius;
-/** @type {string} */ CSSProperties.prototype.WebkitBorderVerticalSpacing;
-/** @type {string} */ CSSProperties.prototype.WebkitBoxAlign;
-/** @type {string} */ CSSProperties.prototype.WebkitBoxDecorationBreak;
-/** @type {string} */ CSSProperties.prototype.WebkitBoxDirection;
-/** @type {string} */ CSSProperties.prototype.WebkitBoxFlex;
-/** @type {string} */ CSSProperties.prototype.WebkitBoxFlexGroup;
-/** @type {string} */ CSSProperties.prototype.WebkitBoxLines;
-/** @type {string} */ CSSProperties.prototype.WebkitBoxOrdinalGroup;
-/** @type {string} */ CSSProperties.prototype.WebkitBoxOrient;
-/** @type {string} */ CSSProperties.prototype.WebkitBoxPack;
-/** @type {string} */ CSSProperties.prototype.WebkitBoxReflect;
-/** @type {string} */ CSSProperties.prototype.WebkitBoxShadow;
-/** @type {string} */ CSSProperties.prototype.WebkitBoxSizing;
-/** @type {string} */ CSSProperties.prototype.WebkitColorCorrection;
-/** @type {string} */ CSSProperties.prototype.WebkitColumnAxis;
-/** @type {string} */ CSSProperties.prototype.WebkitColumnBreakAfter;
-/** @type {string} */ CSSProperties.prototype.WebkitColumnBreakBefore;
-/** @type {string} */ CSSProperties.prototype.WebkitColumnBreakInside;
-/** @type {string} */ CSSProperties.prototype.WebkitColumnCount;
-/** @type {string} */ CSSProperties.prototype.WebkitColumnGap;
-/** @type {string} */ CSSProperties.prototype.WebkitColumnProgression;
-/** @type {string} */ CSSProperties.prototype.WebkitColumnRule;
-/** @type {string} */ CSSProperties.prototype.WebkitColumnRuleColor;
-/** @type {string} */ CSSProperties.prototype.WebkitColumnRuleStyle;
-/** @type {string} */ CSSProperties.prototype.WebkitColumnRuleWidth;
-/** @type {string} */ CSSProperties.prototype.WebkitColumns;
-/** @type {string} */ CSSProperties.prototype.WebkitColumnSpan;
-/** @type {string} */ CSSProperties.prototype.WebkitColumnWidth;
-/** @type {string} */ CSSProperties.prototype.WebkitDashboardRegion;
-/** @type {string} */ CSSProperties.prototype.WebkitFilter;
-/** @type {string} */ CSSProperties.prototype.WebkitFlex;
-/** @type {string} */ CSSProperties.prototype.WebkitFlexBasis;
-/** @type {string} */ CSSProperties.prototype.WebkitFlexDirection;
-/** @type {string} */ CSSProperties.prototype.WebkitFlexFlow;
-/** @type {string} */ CSSProperties.prototype.WebkitFlexGrow;
-/** @type {string} */ CSSProperties.prototype.WebkitFlexShrink;
-/** @type {string} */ CSSProperties.prototype.WebkitFlexWrap;
-/** @type {string} */ CSSProperties.prototype.WebkitFlowFrom;
-/** @type {string} */ CSSProperties.prototype.WebkitFlowInto;
-/** @type {string} */ CSSProperties.prototype.WebkitFontSizeDelta;
-/** @type {string} */ CSSProperties.prototype.WebkitFontSmoothing;
-/** @type {string} */ CSSProperties.prototype.WebkitGridColumn;
-/** @type {string} */ CSSProperties.prototype.WebkitGridColumns;
-/** @type {string} */ CSSProperties.prototype.WebkitGridRow;
-/** @type {string} */ CSSProperties.prototype.WebkitGridRows;
-/** @type {string} */ CSSProperties.prototype.WebkitHighlight;
-/** @type {string} */ CSSProperties.prototype.WebkitHyphenateCharacter;
-/** @type {string} */ CSSProperties.prototype.WebkitHyphenateLimitAfter;
-/** @type {string} */ CSSProperties.prototype.WebkitHyphenateLimitBefore;
-/** @type {string} */ CSSProperties.prototype.WebkitHyphenateLimitLines;
-/** @type {string} */ CSSProperties.prototype.WebkitHyphens;
-/** @type {string} */ CSSProperties.prototype.WebkitJustifyContent;
-/** @type {string} */ CSSProperties.prototype.WebkitLineAlign;
-/** @type {string} */ CSSProperties.prototype.WebkitLineBoxContain;
-/** @type {string} */ CSSProperties.prototype.WebkitLineBreak;
-/** @type {string} */ CSSProperties.prototype.WebkitLineClamp;
-/** @type {string} */ CSSProperties.prototype.WebkitLineGrid;
-/** @type {string} */ CSSProperties.prototype.WebkitLineSnap;
-/** @type {string} */ CSSProperties.prototype.WebkitLocale;
-/** @type {string} */ CSSProperties.prototype.WebkitLogicalHeight;
-/** @type {string} */ CSSProperties.prototype.WebkitLogicalWidth;
-/** @type {string} */ CSSProperties.prototype.WebkitMarginAfter;
-/** @type {string} */ CSSProperties.prototype.WebkitMarginAfterCollapse;
-/** @type {string} */ CSSProperties.prototype.WebkitMarginBefore;
-/** @type {string} */ CSSProperties.prototype.WebkitMarginBeforeCollapse;
-/** @type {string} */ CSSProperties.prototype.WebkitMarginBottomCollapse;
-/** @type {string} */ CSSProperties.prototype.WebkitMarginCollapse;
-/** @type {string} */ CSSProperties.prototype.WebkitMarginEnd;
-/** @type {string} */ CSSProperties.prototype.WebkitMarginStart;
-/** @type {string} */ CSSProperties.prototype.WebkitMarginTopCollapse;
-/** @type {string} */ CSSProperties.prototype.WebkitMarquee;
-/** @type {string} */ CSSProperties.prototype.WebkitMarqueeDirection;
-/** @type {string} */ CSSProperties.prototype.WebkitMarqueeIncrement;
-/** @type {string} */ CSSProperties.prototype.WebkitMarqueeRepetition;
-/** @type {string} */ CSSProperties.prototype.WebkitMarqueeSpeed;
-/** @type {string} */ CSSProperties.prototype.WebkitMarqueeStyle;
-/** @type {string} */ CSSProperties.prototype.WebkitMask;
-/** @type {string} */ CSSProperties.prototype.WebkitMaskAttachment;
-/** @type {string} */ CSSProperties.prototype.WebkitMaskBoxImage;
-/** @type {string} */ CSSProperties.prototype.WebkitMaskBoxImageOutset;
-/** @type {string} */ CSSProperties.prototype.WebkitMaskBoxImageRepeat;
-/** @type {string} */ CSSProperties.prototype.WebkitMaskBoxImageSlice;
-/** @type {string} */ CSSProperties.prototype.WebkitMaskBoxImageSource;
-/** @type {string} */ CSSProperties.prototype.WebkitMaskBoxImageWidth;
-/** @type {string} */ CSSProperties.prototype.WebkitMaskClip;
-/** @type {string} */ CSSProperties.prototype.WebkitMaskComposite;
-/** @type {string} */ CSSProperties.prototype.WebkitMaskImage;
-/** @type {string} */ CSSProperties.prototype.WebkitMaskOrigin;
-/** @type {string} */ CSSProperties.prototype.WebkitMaskPosition;
-/** @type {string} */ CSSProperties.prototype.WebkitMaskPositionX;
-/** @type {string} */ CSSProperties.prototype.WebkitMaskPositionY;
-/** @type {string} */ CSSProperties.prototype.WebkitMaskRepeat;
-/** @type {string} */ CSSProperties.prototype.WebkitMaskRepeatX;
-/** @type {string} */ CSSProperties.prototype.WebkitMaskRepeatY;
-/** @type {string} */ CSSProperties.prototype.WebkitMaskSize;
-/** @type {string} */
-CSSProperties.prototype.WebkitMatchNearestMailBlockquoteColor;
-/** @type {string} */ CSSProperties.prototype.WebkitMaxLogicalHeight;
-/** @type {string} */ CSSProperties.prototype.WebkitMaxLogicalWidth;
-/** @type {string} */ CSSProperties.prototype.WebkitMinLogicalHeight;
-/** @type {string} */ CSSProperties.prototype.WebkitMinLogicalWidth;
-/** @type {string} */ CSSProperties.prototype.WebkitNbspMode;
-/** @type {string} */ CSSProperties.prototype.WebkitOrder;
-/** @type {string} */ CSSProperties.prototype.WebkitOverflowScrolling;
-/** @type {string} */ CSSProperties.prototype.WebkitPaddingAfter;
-/** @type {string} */ CSSProperties.prototype.WebkitPaddingBefore;
-/** @type {string} */ CSSProperties.prototype.WebkitPaddingEnd;
-/** @type {string} */ CSSProperties.prototype.WebkitPaddingStart;
-/** @type {string} */ CSSProperties.prototype.WebkitPerspective;
-/** @type {string} */ CSSProperties.prototype.WebkitPerspectiveOrigin;
-/** @type {string} */ CSSProperties.prototype.WebkitPerspectiveOriginX;
-/** @type {string} */ CSSProperties.prototype.WebkitPerspectiveOriginY;
-/** @type {string} */ CSSProperties.prototype.WebkitPrintColorAdjust;
-/** @type {string} */ CSSProperties.prototype.WebkitRegionBreakAfter;
-/** @type {string} */ CSSProperties.prototype.WebkitRegionBreakBefore;
-/** @type {string} */ CSSProperties.prototype.WebkitRegionBreakInside;
-/** @type {string} */ CSSProperties.prototype.WebkitRegionOverflow;
-/** @type {string} */ CSSProperties.prototype.WebkitRtlOrdering;
-/** @type {string} */ CSSProperties.prototype.WebkitRubyPosition;
-/** @type {string} */ CSSProperties.prototype.WebkitShapeInside;
-/** @type {string} */ CSSProperties.prototype.WebkitShapeMargin;
-/** @type {string} */ CSSProperties.prototype.WebkitShapeOutside;
-/** @type {string} */ CSSProperties.prototype.WebkitShapePadding;
-/** @type {string} */ CSSProperties.prototype.WebkitTapHighlightColor;
-/** @type {string} */ CSSProperties.prototype.WebkitTextAlignLast;
-/** @type {string} */ CSSProperties.prototype.WebkitTextCombine;
-/** @type {string} */ CSSProperties.prototype.WebkitTextDecorationLine;
-/** @type {string} */ CSSProperties.prototype.WebkitTextDecorationsInEffect;
-/** @type {string} */ CSSProperties.prototype.WebkitTextDecorationStyle;
-/** @type {string} */ CSSProperties.prototype.WebkitTextEmphasis;
-/** @type {string} */ CSSProperties.prototype.WebkitTextEmphasisColor;
-/** @type {string} */ CSSProperties.prototype.WebkitTextEmphasisPosition;
-/** @type {string} */ CSSProperties.prototype.WebkitTextEmphasisStyle;
-/** @type {string} */ CSSProperties.prototype.WebkitTextFillColor;
-/** @type {string} */ CSSProperties.prototype.WebkitTextOrientation;
-/** @type {string} */ CSSProperties.prototype.WebkitTextSecurity;
-/** @type {string} */ CSSProperties.prototype.WebkitTextSizeAdjust;
-/** @type {string} */ CSSProperties.prototype.WebkitTextStroke;
-/** @type {string} */ CSSProperties.prototype.WebkitTextStrokeColor;
-/** @type {string} */ CSSProperties.prototype.WebkitTextStrokeWidth;
-/** @type {string} */ CSSProperties.prototype.WebkitTransform;
-/** @type {string} */ CSSProperties.prototype.WebkitTransformOrigin;
-/** @type {string} */ CSSProperties.prototype.WebkitTransformOriginX;
-/** @type {string} */ CSSProperties.prototype.WebkitTransformOriginY;
-/** @type {string} */ CSSProperties.prototype.WebkitTransformOriginZ;
-/** @type {string} */ CSSProperties.prototype.WebkitTransformStyle;
-/** @type {string} */ CSSProperties.prototype.WebkitTransition;
-/** @type {string} */ CSSProperties.prototype.WebkitTransitionDelay;
-/** @type {string} */ CSSProperties.prototype.WebkitTransitionDuration;
-/** @type {string} */ CSSProperties.prototype.WebkitTransitionProperty;
-/** @type {string} */ CSSProperties.prototype.WebkitTransitionRepeatCount;
-/** @type {string} */ CSSProperties.prototype.WebkitTransitionTimingFunction;
-/** @type {string} */ CSSProperties.prototype.WebkitUserDrag;
-/** @type {string} */ CSSProperties.prototype.WebkitUserModify;
-/** @type {string} */ CSSProperties.prototype.WebkitUserSelect;
-/** @type {string} */ CSSProperties.prototype.WebkitWrap;
-/** @type {string} */ CSSProperties.prototype.WebkitWrapFlow;
-/** @type {string} */ CSSProperties.prototype.WebkitWrapThrough;
-/** @type {string} */ CSSProperties.prototype.WebkitWritingMode;
-
-// WebKit also adds bindings for the lowercase versions of these properties.
-// The uppercase version is preferred.
-
-/** @type {string} */ CSSProperties.prototype.webkitAlignContent;
-/** @type {string} */ CSSProperties.prototype.webkitAlignItems;
-/** @type {string} */ CSSProperties.prototype.webkitAlignSelf;
-/** @type {string} */ CSSProperties.prototype.webkitAnimation;
-/** @type {string} */ CSSProperties.prototype.webkitAnimationDelay;
-/** @type {string} */ CSSProperties.prototype.webkitAnimationDirection;
-/** @type {string} */ CSSProperties.prototype.webkitAnimationDuration;
-/** @type {string} */ CSSProperties.prototype.webkitAnimationFillMode;
-/** @type {string} */ CSSProperties.prototype.webkitAnimationIterationCount;
-/** @type {string} */ CSSProperties.prototype.webkitAnimationName;
-/** @type {string} */ CSSProperties.prototype.webkitAnimationPlayState;
-/** @type {string} */ CSSProperties.prototype.webkitAnimationTimingFunction;
-/** @type {string} */ CSSProperties.prototype.webkitAppearance;
-/** @type {string} */ CSSProperties.prototype.webkitAppRegion;
-/** @type {string} */ CSSProperties.prototype.webkitAspectRatio;
-/** @type {string} */ CSSProperties.prototype.webkitBackfaceVisibility;
-/** @type {string} */ CSSProperties.prototype.webkitBackgroundClip;
-/** @type {string} */ CSSProperties.prototype.webkitBackgroundComposite;
-/** @type {string} */ CSSProperties.prototype.webkitBackgroundOrigin;
-/** @type {string} */ CSSProperties.prototype.webkitBackgroundSize;
-/** @type {string} */ CSSProperties.prototype.webkitBinding;
-/** @type {string} */ CSSProperties.prototype.webkitBlendMode;
-/** @type {string} */ CSSProperties.prototype.webkitBorderAfter;
-/** @type {string} */ CSSProperties.prototype.webkitBorderAfterColor;
-/** @type {string} */ CSSProperties.prototype.webkitBorderAfterStyle;
-/** @type {string} */ CSSProperties.prototype.webkitBorderAfterWidth;
-/** @type {string} */ CSSProperties.prototype.webkitBorderBefore;
-/** @type {string} */ CSSProperties.prototype.webkitBorderBeforeColor;
-/** @type {string} */ CSSProperties.prototype.webkitBorderBeforeStyle;
-/** @type {string} */ CSSProperties.prototype.webkitBorderBeforeWidth;
-/** @type {string} */ CSSProperties.prototype.webkitBorderBottomLeftRadius;
-/** @type {string} */ CSSProperties.prototype.webkitBorderBottomRightRadius;
-/** @type {string} */ CSSProperties.prototype.webkitBorderEnd;
-/** @type {string} */ CSSProperties.prototype.webkitBorderEndColor;
-/** @type {string} */ CSSProperties.prototype.webkitBorderEndStyle;
-/** @type {string} */ CSSProperties.prototype.webkitBorderEndWidth;
-/** @type {string} */ CSSProperties.prototype.webkitBorderFit;
-/** @type {string} */ CSSProperties.prototype.webkitBorderHorizontalSpacing;
-/** @type {string} */ CSSProperties.prototype.webkitBorderImage;
-/** @type {string} */ CSSProperties.prototype.webkitBorderRadius;
-/** @type {string} */ CSSProperties.prototype.webkitBorderStart;
-/** @type {string} */ CSSProperties.prototype.webkitBorderStartColor;
-/** @type {string} */ CSSProperties.prototype.webkitBorderStartStyle;
-/** @type {string} */ CSSProperties.prototype.webkitBorderStartWidth;
-/** @type {string} */ CSSProperties.prototype.webkitBorderTopLeftRadius;
-/** @type {string} */ CSSProperties.prototype.webkitBorderTopRightRadius;
-/** @type {string} */ CSSProperties.prototype.webkitBorderVerticalSpacing;
-/** @type {string} */ CSSProperties.prototype.webkitBoxAlign;
-/** @type {string} */ CSSProperties.prototype.webkitBoxDecorationBreak;
-/** @type {string} */ CSSProperties.prototype.webkitBoxDirection;
-/** @type {string} */ CSSProperties.prototype.webkitBoxFlex;
-/** @type {string} */ CSSProperties.prototype.webkitBoxFlexGroup;
-/** @type {string} */ CSSProperties.prototype.webkitBoxLines;
-/** @type {string} */ CSSProperties.prototype.webkitBoxOrdinalGroup;
-/** @type {string} */ CSSProperties.prototype.webkitBoxOrient;
-/** @type {string} */ CSSProperties.prototype.webkitBoxPack;
-/** @type {string} */ CSSProperties.prototype.webkitBoxReflect;
-/** @type {string} */ CSSProperties.prototype.webkitBoxShadow;
-/** @type {string} */ CSSProperties.prototype.webkitBoxSizing;
-/** @type {string} */ CSSProperties.prototype.webkitColorCorrection;
-/** @type {string} */ CSSProperties.prototype.webkitColumnAxis;
-/** @type {string} */ CSSProperties.prototype.webkitColumnBreakAfter;
-/** @type {string} */ CSSProperties.prototype.webkitColumnBreakBefore;
-/** @type {string} */ CSSProperties.prototype.webkitColumnBreakInside;
-/** @type {string} */ CSSProperties.prototype.webkitColumnCount;
-/** @type {string} */ CSSProperties.prototype.webkitColumnGap;
-/** @type {string} */ CSSProperties.prototype.webkitColumnProgression;
-/** @type {string} */ CSSProperties.prototype.webkitColumnRule;
-/** @type {string} */ CSSProperties.prototype.webkitColumnRuleColor;
-/** @type {string} */ CSSProperties.prototype.webkitColumnRuleStyle;
-/** @type {string} */ CSSProperties.prototype.webkitColumnRuleWidth;
-/** @type {string} */ CSSProperties.prototype.webkitColumns;
-/** @type {string} */ CSSProperties.prototype.webkitColumnSpan;
-/** @type {string} */ CSSProperties.prototype.webkitColumnWidth;
-/** @type {string} */ CSSProperties.prototype.webkitDashboardRegion;
-/** @type {string} */ CSSProperties.prototype.webkitFilter;
-/** @type {string} */ CSSProperties.prototype.webkitFlex;
-/** @type {string} */ CSSProperties.prototype.webkitFlexBasis;
-/** @type {string} */ CSSProperties.prototype.webkitFlexDirection;
-/** @type {string} */ CSSProperties.prototype.webkitFlexFlow;
-/** @type {string} */ CSSProperties.prototype.webkitFlexGrow;
-/** @type {string} */ CSSProperties.prototype.webkitFlexShrink;
-/** @type {string} */ CSSProperties.prototype.webkitFlexWrap;
-/** @type {string} */ CSSProperties.prototype.webkitFlowFrom;
-/** @type {string} */ CSSProperties.prototype.webkitFlowInto;
-/** @type {string} */ CSSProperties.prototype.webkitFontSizeDelta;
-/** @type {string} */ CSSProperties.prototype.webkitFontSmoothing;
-/** @type {string} */ CSSProperties.prototype.webkitGridColumn;
-/** @type {string} */ CSSProperties.prototype.webkitGridColumns;
-/** @type {string} */ CSSProperties.prototype.webkitGridRow;
-/** @type {string} */ CSSProperties.prototype.webkitGridRows;
-/** @type {string} */ CSSProperties.prototype.webkitHighlight;
-/** @type {string} */ CSSProperties.prototype.webkitHyphenateCharacter;
-/** @type {string} */ CSSProperties.prototype.webkitHyphenateLimitAfter;
-/** @type {string} */ CSSProperties.prototype.webkitHyphenateLimitBefore;
-/** @type {string} */ CSSProperties.prototype.webkitHyphenateLimitLines;
-/** @type {string} */ CSSProperties.prototype.webkitHyphens;
-/** @type {string} */ CSSProperties.prototype.webkitJustifyContent;
-/** @type {string} */ CSSProperties.prototype.webkitLineAlign;
-/** @type {string} */ CSSProperties.prototype.webkitLineBoxContain;
-/** @type {string} */ CSSProperties.prototype.webkitLineBreak;
-/** @type {string} */ CSSProperties.prototype.webkitLineClamp;
-/** @type {string} */ CSSProperties.prototype.webkitLineGrid;
-/** @type {string} */ CSSProperties.prototype.webkitLineSnap;
-/** @type {string} */ CSSProperties.prototype.webkitLocale;
-/** @type {string} */ CSSProperties.prototype.webkitLogicalHeight;
-/** @type {string} */ CSSProperties.prototype.webkitLogicalWidth;
-/** @type {string} */ CSSProperties.prototype.webkitMarginAfter;
-/** @type {string} */ CSSProperties.prototype.webkitMarginAfterCollapse;
-/** @type {string} */ CSSProperties.prototype.webkitMarginBefore;
-/** @type {string} */ CSSProperties.prototype.webkitMarginBeforeCollapse;
-/** @type {string} */ CSSProperties.prototype.webkitMarginBottomCollapse;
-/** @type {string} */ CSSProperties.prototype.webkitMarginCollapse;
-/** @type {string} */ CSSProperties.prototype.webkitMarginEnd;
-/** @type {string} */ CSSProperties.prototype.webkitMarginStart;
-/** @type {string} */ CSSProperties.prototype.webkitMarginTopCollapse;
-/** @type {string} */ CSSProperties.prototype.webkitMarquee;
-/** @type {string} */ CSSProperties.prototype.webkitMarqueeDirection;
-/** @type {string} */ CSSProperties.prototype.webkitMarqueeIncrement;
-/** @type {string} */ CSSProperties.prototype.webkitMarqueeRepetition;
-/** @type {string} */ CSSProperties.prototype.webkitMarqueeSpeed;
-/** @type {string} */ CSSProperties.prototype.webkitMarqueeStyle;
-/** @type {string} */ CSSProperties.prototype.webkitMask;
-/** @type {string} */ CSSProperties.prototype.webkitMaskAttachment;
-/** @type {string} */ CSSProperties.prototype.webkitMaskBoxImage;
-/** @type {string} */ CSSProperties.prototype.webkitMaskBoxImageOutset;
-/** @type {string} */ CSSProperties.prototype.webkitMaskBoxImageRepeat;
-/** @type {string} */ CSSProperties.prototype.webkitMaskBoxImageSlice;
-/** @type {string} */ CSSProperties.prototype.webkitMaskBoxImageSource;
-/** @type {string} */ CSSProperties.prototype.webkitMaskBoxImageWidth;
-/** @type {string} */ CSSProperties.prototype.webkitMaskClip;
-/** @type {string} */ CSSProperties.prototype.webkitMaskComposite;
-/** @type {string} */ CSSProperties.prototype.webkitMaskImage;
-/** @type {string} */ CSSProperties.prototype.webkitMaskOrigin;
-/** @type {string} */ CSSProperties.prototype.webkitMaskPosition;
-/** @type {string} */ CSSProperties.prototype.webkitMaskPositionX;
-/** @type {string} */ CSSProperties.prototype.webkitMaskPositionY;
-/** @type {string} */ CSSProperties.prototype.webkitMaskRepeat;
-/** @type {string} */ CSSProperties.prototype.webkitMaskRepeatX;
-/** @type {string} */ CSSProperties.prototype.webkitMaskRepeatY;
-/** @type {string} */ CSSProperties.prototype.webkitMaskSize;
-/** @type {string} */
-CSSProperties.prototype.webkitMatchNearestMailBlockquoteColor;
-/** @type {string} */ CSSProperties.prototype.webkitMaxLogicalHeight;
-/** @type {string} */ CSSProperties.prototype.webkitMaxLogicalWidth;
-/** @type {string} */ CSSProperties.prototype.webkitMinLogicalHeight;
-/** @type {string} */ CSSProperties.prototype.webkitMinLogicalWidth;
-/** @type {string} */ CSSProperties.prototype.webkitNbspMode;
-/** @type {string} */ CSSProperties.prototype.webkitOrder;
-/** @type {string} */ CSSProperties.prototype.webkitOverflowScrolling;
-/** @type {string} */ CSSProperties.prototype.webkitPaddingAfter;
-/** @type {string} */ CSSProperties.prototype.webkitPaddingBefore;
-/** @type {string} */ CSSProperties.prototype.webkitPaddingEnd;
-/** @type {string} */ CSSProperties.prototype.webkitPaddingStart;
-/** @type {string} */ CSSProperties.prototype.webkitPerspective;
-/** @type {string} */ CSSProperties.prototype.webkitPerspectiveOrigin;
-/** @type {string} */ CSSProperties.prototype.webkitPerspectiveOriginX;
-/** @type {string} */ CSSProperties.prototype.webkitPerspectiveOriginY;
-/** @type {string} */ CSSProperties.prototype.webkitPrintColorAdjust;
-/** @type {string} */ CSSProperties.prototype.webkitRegionBreakAfter;
-/** @type {string} */ CSSProperties.prototype.webkitRegionBreakBefore;
-/** @type {string} */ CSSProperties.prototype.webkitRegionBreakInside;
-/** @type {string} */ CSSProperties.prototype.webkitRegionOverflow;
-/** @type {string} */ CSSProperties.prototype.webkitRtlOrdering;
-/** @type {string} */ CSSProperties.prototype.webkitRubyPosition;
-/** @type {string} */ CSSProperties.prototype.webkitShapeInside;
-/** @type {string} */ CSSProperties.prototype.webkitShapeMargin;
-/** @type {string} */ CSSProperties.prototype.webkitShapeOutside;
-/** @type {string} */ CSSProperties.prototype.webkitShapePadding;
-/** @type {string} */ CSSProperties.prototype.webkitTapHighlightColor;
-/** @type {string} */ CSSProperties.prototype.webkitTextAlignLast;
-/** @type {string} */ CSSProperties.prototype.webkitTextCombine;
-/** @type {string} */ CSSProperties.prototype.webkitTextDecorationLine;
-/** @type {string} */ CSSProperties.prototype.webkitTextDecorationsInEffect;
-/** @type {string} */ CSSProperties.prototype.webkitTextDecorationStyle;
-/** @type {string} */ CSSProperties.prototype.webkitTextEmphasis;
-/** @type {string} */ CSSProperties.prototype.webkitTextEmphasisColor;
-/** @type {string} */ CSSProperties.prototype.webkitTextEmphasisPosition;
-/** @type {string} */ CSSProperties.prototype.webkitTextEmphasisStyle;
-/** @type {string} */ CSSProperties.prototype.webkitTextFillColor;
-/** @type {string} */ CSSProperties.prototype.webkitTextOrientation;
-/** @type {string} */ CSSProperties.prototype.webkitTextSecurity;
-/** @type {string} */ CSSProperties.prototype.webkitTextSizeAdjust;
-/** @type {string} */ CSSProperties.prototype.webkitTextStroke;
-/** @type {string} */ CSSProperties.prototype.webkitTextStrokeColor;
-/** @type {string} */ CSSProperties.prototype.webkitTextStrokeWidth;
-/** @type {string} */ CSSProperties.prototype.webkitTransform;
-/** @type {string} */ CSSProperties.prototype.webkitTransformOrigin;
-/** @type {string} */ CSSProperties.prototype.webkitTransformOriginX;
-/** @type {string} */ CSSProperties.prototype.webkitTransformOriginY;
-/** @type {string} */ CSSProperties.prototype.webkitTransformOriginZ;
-/** @type {string} */ CSSProperties.prototype.webkitTransformStyle;
-/** @type {string} */ CSSProperties.prototype.webkitTransition;
-/** @type {string} */ CSSProperties.prototype.webkitTransitionDelay;
-/** @type {string} */ CSSProperties.prototype.webkitTransitionDuration;
-/** @type {string} */ CSSProperties.prototype.webkitTransitionProperty;
-/** @type {string} */ CSSProperties.prototype.webkitTransitionRepeatCount;
-/** @type {string} */ CSSProperties.prototype.webkitTransitionTimingFunction;
-/** @type {string} */ CSSProperties.prototype.webkitUserDrag;
-/** @type {string} */ CSSProperties.prototype.webkitUserModify;
-/** @type {string} */ CSSProperties.prototype.webkitUserSelect;
-/** @type {string} */ CSSProperties.prototype.webkitWrap;
-/** @type {string} */ CSSProperties.prototype.webkitWrapFlow;
-/** @type {string} */ CSSProperties.prototype.webkitWrapThrough;
-/** @type {string} */ CSSProperties.prototype.webkitWritingMode;
-
-/**
- * @constructor
- * @param {number} x
- * @param {number} y
- */
-function WebKitPoint(x, y) {}
-
-/** @type {number} */
-WebKitPoint.prototype.x;
-
-/** @type {number} */
-WebKitPoint.prototype.y;
diff --git a/dom/events/EventStates.h b/dom/events/EventStates.h
index 2672d2897..183070755 100644
--- a/dom/events/EventStates.h
+++ b/dom/events/EventStates.h
@@ -27,7 +27,7 @@ public:
typedef uint64_t InternalType;
typedef uint8_t ServoType;
- constexpr EventStates()
+ EventStates()
: mStates(0)
{
}
@@ -37,12 +37,12 @@ public:
// In that case, we could be sure that only macros at the end were creating
// EventStates instances with mStates set to something else than 0.
// Unfortunately, this constructor is needed at at least two places now.
- explicit constexpr EventStates(InternalType aStates)
+ explicit EventStates(InternalType aStates)
: mStates(aStates)
{
}
- EventStates constexpr operator|(const EventStates& aEventStates) const
+ EventStates operator|(const EventStates& aEventStates) const
{
return EventStates(mStates | aEventStates.mStates);
}
@@ -56,7 +56,7 @@ public:
// NOTE: calling if (eventStates1 & eventStates2) will not build.
// This might work correctly if operator bool() is defined
// but using HasState, HasAllStates or HasAtLeastOneOfStates is recommended.
- EventStates constexpr operator&(const EventStates& aEventStates) const
+ EventStates operator&(const EventStates& aEventStates) const
{
return EventStates(mStates & aEventStates.mStates);
}
diff --git a/dom/heapsnapshot/HeapSnapshot.cpp b/dom/heapsnapshot/HeapSnapshot.cpp
index 299a96a9c..668b7f5a5 100644
--- a/dom/heapsnapshot/HeapSnapshot.cpp
+++ b/dom/heapsnapshot/HeapSnapshot.cpp
@@ -1455,7 +1455,7 @@ HeapSnapshot::CreateUniqueCoreDumpFile(ErrorResult& rv,
class DeleteHeapSnapshotTempFileHelperChild
{
public:
- constexpr DeleteHeapSnapshotTempFileHelperChild() { }
+ DeleteHeapSnapshotTempFileHelperChild() { }
void operator()(PHeapSnapshotTempFileHelperChild* ptr) const {
Unused << NS_WARN_IF(!HeapSnapshotTempFileHelperChild::Send__delete__(ptr));
diff --git a/dom/html/HTMLDivElement.cpp b/dom/html/HTMLDivElement.cpp
index b56187e29..d5b587241 100644
--- a/dom/html/HTMLDivElement.cpp
+++ b/dom/html/HTMLDivElement.cpp
@@ -34,20 +34,6 @@ HTMLDivElement::ParseAttribute(int32_t aNamespaceID,
nsAttrValue& aResult)
{
if (aNamespaceID == kNameSpaceID_None) {
- if (mNodeInfo->Equals(nsGkAtoms::marquee)) {
- if ((aAttribute == nsGkAtoms::width) ||
- (aAttribute == nsGkAtoms::height)) {
- return aResult.ParseSpecialIntValue(aValue);
- }
- if (aAttribute == nsGkAtoms::bgcolor) {
- return aResult.ParseColor(aValue);
- }
- if ((aAttribute == nsGkAtoms::hspace) ||
- (aAttribute == nsGkAtoms::vspace)) {
- return aResult.ParseIntWithBounds(aValue, 0);
- }
- }
-
if (mNodeInfo->Equals(nsGkAtoms::div) &&
aAttribute == nsGkAtoms::align) {
return ParseDivAlignValue(aValue, aResult);
@@ -66,15 +52,6 @@ HTMLDivElement::MapAttributesIntoRule(const nsMappedAttributes* aAttributes,
nsGenericHTMLElement::MapCommonAttributesInto(aAttributes, aData);
}
-static void
-MapMarqueeAttributesIntoRule(const nsMappedAttributes* aAttributes, nsRuleData* aData)
-{
- nsGenericHTMLElement::MapImageMarginAttributeInto(aAttributes, aData);
- nsGenericHTMLElement::MapImageSizeAttributesInto(aAttributes, aData);
- nsGenericHTMLElement::MapCommonAttributesInto(aAttributes, aData);
- nsGenericHTMLElement::MapBGColorInto(aAttributes, aData);
-}
-
NS_IMETHODIMP_(bool)
HTMLDivElement::IsAttributeMapped(const nsIAtom* aAttribute) const
{
@@ -85,14 +62,6 @@ HTMLDivElement::IsAttributeMapped(const nsIAtom* aAttribute) const
};
return FindAttributeDependence(aAttribute, map);
}
- if (mNodeInfo->Equals(nsGkAtoms::marquee)) {
- static const MappedAttributeEntry* const map[] = {
- sImageMarginSizeAttributeMap,
- sBackgroundColorAttributeMap,
- sCommonAttributeMap
- };
- return FindAttributeDependence(aAttribute, map);
- }
return nsGenericHTMLElement::IsAttributeMapped(aAttribute);
}
@@ -103,9 +72,6 @@ HTMLDivElement::GetAttributeMappingFunction() const
if (mNodeInfo->Equals(nsGkAtoms::div)) {
return &MapAttributesIntoRule;
}
- if (mNodeInfo->Equals(nsGkAtoms::marquee)) {
- return &MapMarqueeAttributesIntoRule;
- }
return nsGenericHTMLElement::GetAttributeMappingFunction();
}
diff --git a/dom/html/HTMLTrackElement.cpp b/dom/html/HTMLTrackElement.cpp
index 758018f8d..59810a444 100644
--- a/dom/html/HTMLTrackElement.cpp
+++ b/dom/html/HTMLTrackElement.cpp
@@ -57,7 +57,7 @@ namespace mozilla {
namespace dom {
// Map html attribute string values to TextTrackKind enums.
-static constexpr nsAttrValue::EnumTable kKindTable[] = {
+static nsAttrValue::EnumTable kKindTable[] = {
{ "subtitles", static_cast<int16_t>(TextTrackKind::Subtitles) },
{ "captions", static_cast<int16_t>(TextTrackKind::Captions) },
{ "descriptions", static_cast<int16_t>(TextTrackKind::Descriptions) },
@@ -68,7 +68,7 @@ static constexpr nsAttrValue::EnumTable kKindTable[] = {
// Invalid values are treated as "metadata" in ParseAttribute, but if no value
// at all is specified, it's treated as "subtitles" in GetKind
-static constexpr const nsAttrValue::EnumTable* kKindTableInvalidValueDefault = &kKindTable[4];
+static const nsAttrValue::EnumTable* kKindTableInvalidValueDefault = &kKindTable[4];
class WindowDestroyObserver final : public nsIObserver
{
diff --git a/dom/html/nsHTMLDocument.cpp b/dom/html/nsHTMLDocument.cpp
index fc5268acc..b0747fb04 100644
--- a/dom/html/nsHTMLDocument.cpp
+++ b/dom/html/nsHTMLDocument.cpp
@@ -1511,6 +1511,9 @@ nsHTMLDocument::Open(JSContext* cx,
// document again otherwise the document could have a non-zero onload block
// count without the onload blocker request being in the loadgroup.
EnsureOnloadBlocker();
+
+ // Throw away loaded modules created for the previous global.
+ ScriptLoader()->ClearModuleMap();
}
// Step 8 - Clear all event listeners out of our DOM tree
diff --git a/dom/html/test/test_bug389797.html b/dom/html/test/test_bug389797.html
index 884348b12..373528c71 100644
--- a/dom/html/test/test_bug389797.html
+++ b/dom/html/test/test_bug389797.html
@@ -168,7 +168,6 @@ HTML_TAG("listing", "Pre");
HTML_TAG("main", "");
HTML_TAG("map", "Map");
HTML_TAG("mark", "");
-HTML_TAG("marquee", "Div");
HTML_TAG("menu", "Menu");
HTML_TAG("meta", "Meta");
HTML_TAG("meter", "Meter");
diff --git a/dom/html/test/test_documentAll.html b/dom/html/test/test_documentAll.html
index ec877acec..9db77d2fe 100644
--- a/dom/html/test/test_documentAll.html
+++ b/dom/html/test/test_documentAll.html
@@ -117,7 +117,7 @@ var elementNames =
'input','ins','isindex','kbd','keygen','label','li','legend','link','menu',
'multicol','noscript','noframes','object','spacer','table','td','td','th',
'thead','tfoot','tr','textarea','select','option','spacer','param',
- 'marquee','hr','title','hx','tt','u','ul','var','wbr','sub','sup','cite',
+ 'hr','title','hx','tt','u','ul','var','wbr','sub','sup','cite',
'code','q','nobr','ol','p','pre','s','samp','small','body','html','map',
'bdo','legend','listing','style','script','tbody','caption','meta',
'optgroup','button','span','strike','strong','td'].sort();
diff --git a/dom/indexedDB/ActorsParent.cpp b/dom/indexedDB/ActorsParent.cpp
index 74afef452..c7feb8d86 100644
--- a/dom/indexedDB/ActorsParent.cpp
+++ b/dom/indexedDB/ActorsParent.cpp
@@ -270,7 +270,7 @@ const uint32_t kDEBUGTransactionThreadSleepMS = 0;
#endif
template <size_t N>
-constexpr size_t
+size_t
LiteralStringLength(const char (&aArr)[N])
{
static_assert(N, "Zero-length string literal?!");
@@ -2905,11 +2905,11 @@ UpgradeKeyFunction::CopyAndUpgradeKeyBufferInternal(const uint8_t*& aSource,
MOZ_ASSERT(aDestination);
MOZ_ASSERT(aTagOffset <= Key::kMaxArrayCollapse);
- static constexpr uint8_t kOldNumberTag = 0x1;
- static constexpr uint8_t kOldDateTag = 0x2;
- static constexpr uint8_t kOldStringTag = 0x3;
- static constexpr uint8_t kOldArrayTag = 0x4;
- static constexpr uint8_t kOldMaxType = kOldArrayTag;
+ static uint8_t kOldNumberTag = 0x1;
+ static uint8_t kOldDateTag = 0x2;
+ static uint8_t kOldStringTag = 0x3;
+ static uint8_t kOldArrayTag = 0x4;
+ static uint8_t kOldMaxType = kOldArrayTag;
if (NS_WARN_IF(aRecursionDepth > Key::kMaxRecursionDepth)) {
IDB_REPORT_INTERNAL_ERR();
diff --git a/dom/media/MediaCache.cpp b/dom/media/MediaCache.cpp
index 37399f851..64523afcb 100644
--- a/dom/media/MediaCache.cpp
+++ b/dom/media/MediaCache.cpp
@@ -277,7 +277,7 @@ protected:
};
struct BlockOwner {
- constexpr BlockOwner() {}
+ BlockOwner() {}
// The stream that owns this block, or null if the block is free.
MediaCacheStream* mStream = nullptr;
diff --git a/dom/media/MediaStreamGraphImpl.h b/dom/media/MediaStreamGraphImpl.h
index c71975493..b3d7d8701 100644
--- a/dom/media/MediaStreamGraphImpl.h
+++ b/dom/media/MediaStreamGraphImpl.h
@@ -652,7 +652,7 @@ public:
* and boolean to control if we want input/output
*/
bool mInputWanted;
- int mInputDeviceID;
+ Atomic<int> mInputDeviceID;
bool mOutputWanted;
int mOutputDeviceID;
// Maps AudioDataListeners to a usecount of streams using the listener
diff --git a/dom/media/platforms/PDMFactory.h b/dom/media/platforms/PDMFactory.h
index 2b43fa1ab..a13c99ac0 100644
--- a/dom/media/platforms/PDMFactory.h
+++ b/dom/media/platforms/PDMFactory.h
@@ -49,10 +49,10 @@ public:
void SetCDMProxy(CDMProxy* aProxy);
#endif
- static constexpr int kYUV400 = 0;
- static constexpr int kYUV420 = 1;
- static constexpr int kYUV422 = 2;
- static constexpr int kYUV444 = 3;
+ static const int kYUV400 = 0;
+ static const int kYUV420 = 1;
+ static const int kYUV422 = 2;
+ static const int kYUV444 = 3;
private:
virtual ~PDMFactory();
diff --git a/dom/media/webaudio/blink/HRTFDatabaseLoader.cpp b/dom/media/webaudio/blink/HRTFDatabaseLoader.cpp
index 090e1b217..96c53b1cd 100644
--- a/dom/media/webaudio/blink/HRTFDatabaseLoader.cpp
+++ b/dom/media/webaudio/blink/HRTFDatabaseLoader.cpp
@@ -1,5 +1,6 @@
/*
* Copyright (C) 2010 Google Inc. All rights reserved.
+ * Copyright (C) 2020 M. Straver. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
@@ -72,6 +73,7 @@ HRTFDatabaseLoader::HRTFDatabaseLoader(float sampleRate)
, m_threadLock("HRTFDatabaseLoader")
, m_databaseLoaderThread(nullptr)
, m_databaseSampleRate(sampleRate)
+ , m_databaseLoaded(false)
{
MOZ_ASSERT(NS_IsMainThread());
}
@@ -164,6 +166,7 @@ void HRTFDatabaseLoader::load()
MOZ_ASSERT(!m_hrtfDatabase.get(), "Called twice");
// Load the default HRTF database.
m_hrtfDatabase = HRTFDatabase::create(m_databaseSampleRate);
+ m_databaseLoaded = true;
// Notifies the main thread of completion. See loadAsynchronously().
Release();
}
diff --git a/dom/media/webaudio/blink/HRTFDatabaseLoader.h b/dom/media/webaudio/blink/HRTFDatabaseLoader.h
index 50a875b18..4dfbd4fc8 100644
--- a/dom/media/webaudio/blink/HRTFDatabaseLoader.h
+++ b/dom/media/webaudio/blink/HRTFDatabaseLoader.h
@@ -1,5 +1,6 @@
/*
* Copyright (C) 2010 Google Inc. All rights reserved.
+ * Copyright (C) 2020 M. Straver. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
@@ -85,7 +86,12 @@ public:
// on any thread except m_databaseLoaderThread.
void waitForLoaderThreadCompletion();
- HRTFDatabase* database() { return m_hrtfDatabase.get(); }
+ HRTFDatabase* database() {
+ if (!m_databaseLoaded) {
+ return nullptr;
+ }
+ return m_hrtfDatabase.get();
+ }
float databaseSampleRate() const { return m_databaseSampleRate; }
@@ -141,6 +147,7 @@ private:
PRThread* m_databaseLoaderThread;
float m_databaseSampleRate;
+ mozilla::Atomic<bool> m_databaseLoaded;
};
} // namespace WebCore
diff --git a/dom/plugins/ipc/PluginModuleChild.cpp b/dom/plugins/ipc/PluginModuleChild.cpp
index f943dfc42..98c9cd494 100644
--- a/dom/plugins/ipc/PluginModuleChild.cpp
+++ b/dom/plugins/ipc/PluginModuleChild.cpp
@@ -40,8 +40,8 @@
#ifdef XP_WIN
#include "nsWindowsDllInterceptor.h"
#include "mozilla/widget/AudioSession.h"
-#include "WinUtils.h"
#include <knownfolders.h>
+#include <shlobj.h>
#endif
#ifdef MOZ_WIDGET_COCOA
@@ -1918,8 +1918,8 @@ GetLocalLowTempPath(size_t aLen, LPWSTR aPath)
{
NS_NAMED_LITERAL_STRING(tempname, "\\Temp");
LPWSTR path;
- if (SUCCEEDED(WinUtils::SHGetKnownFolderPath(FOLDERID_LocalAppDataLow, 0,
- nullptr, &path))) {
+ if (SUCCEEDED(SHGetKnownFolderPath(FOLDERID_LocalAppDataLow, 0,
+ nullptr, &path))) {
if (wcslen(path) + tempname.Length() < aLen) {
wcscpy(aPath, path);
wcscat(aPath, tempname.get());
diff --git a/dom/script/ModuleLoadRequest.h b/dom/script/ModuleLoadRequest.h
index eefb7dad5..4eac65090 100644
--- a/dom/script/ModuleLoadRequest.h
+++ b/dom/script/ModuleLoadRequest.h
@@ -56,7 +56,7 @@ public:
ModuleLoadRequest(nsIURI* aURI,
ModuleLoadRequest* aParent);
- bool IsTopLevel() const {
+ bool IsTopLevel() const override {
return mIsTopLevel;
}
diff --git a/dom/script/ScriptLoader.cpp b/dom/script/ScriptLoader.cpp
index 989301b91..362c27f3e 100644
--- a/dom/script/ScriptLoader.cpp
+++ b/dom/script/ScriptLoader.cpp
@@ -477,6 +477,11 @@ ScriptLoader::GetFetchedModule(nsIURI* aURL) const
return ms;
}
+void ScriptLoader::ClearModuleMap() {
+ MOZ_ASSERT(mFetchingModules.IsEmpty());
+ mFetchedModules.Clear();
+}
+
nsresult
ScriptLoader::ProcessFetchedModuleSource(ModuleLoadRequest* aRequest)
{
@@ -559,7 +564,9 @@ ScriptLoader::CreateModuleScript(ModuleLoadRequest* aRequest)
rv = nsJSUtils::CompileModule(cx, srcBuf, global, options, &module);
}
}
+
MOZ_ASSERT(NS_SUCCEEDED(rv) == (module != nullptr));
+
RefPtr<ModuleScript> moduleScript = new ModuleScript(this, aRequest->mBaseURL);
aRequest->mModuleScript = moduleScript;
@@ -979,7 +986,7 @@ ScriptLoader::StartLoad(ScriptLoadRequest *aRequest, const nsAString &aType,
if (aRequest->IsModuleRequest()) {
// Check whether the module has been fetched or is currently being fetched,
- // and if so wait for it.
+ // and if so wait for it rather than starting a new fetch.
ModuleLoadRequest* request = aRequest->AsModuleRequest();
if (ModuleMapContainsURL(request->mURI)) {
WaitForModuleFetch(request->mURI)
@@ -988,9 +995,6 @@ ScriptLoader::StartLoad(ScriptLoadRequest *aRequest, const nsAString &aType,
&ModuleLoadRequest::LoadFailed);
return NS_OK;
}
-
- // Otherwise put the URL in the module map and mark it as fetching.
- SetModuleFetchStarted(request);
}
nsContentPolicyType contentPolicyType = aRequest->IsPreload()
@@ -1103,7 +1107,16 @@ ScriptLoader::StartLoad(ScriptLoadRequest *aRequest, const nsAString &aType,
rv = NS_NewIncrementalStreamLoader(getter_AddRefs(loader), handler);
NS_ENSURE_SUCCESS(rv, rv);
- return channel->AsyncOpen2(loader);
+ rv = channel->AsyncOpen2(loader);
+ NS_ENSURE_SUCCESS(rv, rv);
+
+ if (aRequest->IsModuleRequest()) {
+ // We successfully started fetching a module so put its URL in the module
+ // map and mark it as fetching.
+ SetModuleFetchStarted(aRequest->AsModuleRequest());
+ }
+
+ return NS_OK;
}
bool
@@ -1355,8 +1368,8 @@ ScriptLoader::ProcessScriptElement(nsIScriptElement *aElement)
}
}
- // Should still be in loading stage of script.
- NS_ASSERTION(!request->InCompilingStage(),
+ // Should still be in loading stage of script unless we're loading a module.
+ NS_ASSERTION(!request->InCompilingStage() || request->IsModuleRequest(),
"Request should not yet be in compiling stage.");
request->mJSVersion = version;
@@ -1904,14 +1917,17 @@ ScriptLoader::FillCompileOptionsForRequest(const AutoJSAPI&jsapi,
aOptions->setMutedErrors(!subsumes);
}
- JSContext* cx = jsapi.cx();
- JS::Rooted<JS::Value> elementVal(cx);
- MOZ_ASSERT(aRequest->mElement);
- if (NS_SUCCEEDED(nsContentUtils::WrapNative(cx, aRequest->mElement,
- &elementVal,
- /* aAllowWrapping = */ true))) {
- MOZ_ASSERT(elementVal.isObject());
- aOptions->setElement(&elementVal.toObject());
+ if (!aRequest->IsModuleRequest()) {
+ // Only do this for classic scripts.
+ JSContext* cx = jsapi.cx();
+ JS::Rooted<JS::Value> elementVal(cx);
+ MOZ_ASSERT(aRequest->mElement);
+ if (NS_SUCCEEDED(nsContentUtils::WrapNative(cx, aRequest->mElement,
+ &elementVal,
+ /* aAllowWrapping = */ true))) {
+ MOZ_ASSERT(elementVal.isObject());
+ aOptions->setElement(&elementVal.toObject());
+ }
}
return NS_OK;
@@ -2373,7 +2389,7 @@ ScriptLoader::HandleLoadError(ScriptLoadRequest *aRequest, nsresult aResult) {
RefPtr<ScriptLoadRequest> req = mXSLTRequests.Steal(aRequest);
FireScriptAvailable(aResult, req);
}
- } else if (aRequest->IsModuleRequest()) {
+ } else if (aRequest->IsModuleRequest() && !aRequest->IsPreload()) {
ModuleLoadRequest* modReq = aRequest->AsModuleRequest();
MOZ_ASSERT(!modReq->IsTopLevel());
MOZ_ASSERT(!modReq->isInList());
@@ -2394,8 +2410,19 @@ ScriptLoader::HandleLoadError(ScriptLoadRequest *aRequest, nsresult aResult) {
FireScriptAvailable(aResult, aRequest);
ContinueParserAsync(aRequest);
mCurrentParserInsertedScript = oldParserInsertedScript;
+ } else if (aRequest->IsPreload()) {
+ if (aRequest->IsModuleRequest()) {
+ // If there is an error preloading modules, cancel the load request.
+ aRequest->Cancel();
+ }
+ if (aRequest->IsTopLevel()) {
+ MOZ_ALWAYS_TRUE(mPreloads.RemoveElement(aRequest, PreloadRequestComparator()));
+ }
+ MOZ_ASSERT(!aRequest->isInList());
} else {
- mPreloads.RemoveElement(aRequest, PreloadRequestComparator());
+ // This happens for blocking requests cancelled by ParsingComplete().
+ MOZ_ASSERT(aRequest->IsCanceled());
+ MOZ_ASSERT(!aRequest->isInList());
}
}
@@ -2424,6 +2451,18 @@ ScriptLoader::NumberOfProcessors()
return mNumberOfProcessors;
}
+static bool
+IsInternalURIScheme(nsIURI* uri)
+{
+ // Note: Extend this if other schemes need to be included.
+ bool isResource;
+ if (NS_SUCCEEDED(uri->SchemeIs("resource", &isResource)) && isResource) {
+ return true;
+ }
+
+ return false;
+}
+
nsresult
ScriptLoader::PrepareLoadedRequest(ScriptLoadRequest* aRequest,
nsIIncrementalStreamLoader* aLoader,
@@ -2511,7 +2550,17 @@ ScriptLoader::PrepareLoadedRequest(ScriptLoadRequest* aRequest,
return NS_ERROR_FAILURE;
}
- channel->GetURI(getter_AddRefs(request->mBaseURL));
+ nsCOMPtr<nsIURI> uri;
+ rv = channel->GetOriginalURI(getter_AddRefs(uri));
+ NS_ENSURE_SUCCESS(rv, rv);
+
+ // Fixup internal scheme URIs like resource:, because the channel URI
+ // will point to file: which won't be allowed to load.
+ if (uri && IsInternalURIScheme(uri)) {
+ request->mBaseURL = uri;
+ } else {
+ channel->GetURI(getter_AddRefs(request->mBaseURL));
+ }
// Attempt to compile off main thread.
rv = AttemptAsyncScriptCompile(request);
@@ -2576,13 +2625,15 @@ ScriptLoader::ParsingComplete(bool aTerminated)
}
void
-ScriptLoader::PreloadURI(nsIURI *aURI, const nsAString &aCharset,
+ScriptLoader::PreloadURI(nsIURI *aURI,
+ const nsAString &aCharset,
const nsAString &aType,
const nsAString &aCrossOrigin,
const nsAString& aIntegrity,
bool aScriptFromHead,
bool aAsync,
bool aDefer,
+ bool aNoModule,
const mozilla::net::ReferrerPolicy aReferrerPolicy)
{
NS_ENSURE_TRUE_VOID(mDocument);
@@ -2591,8 +2642,28 @@ ScriptLoader::PreloadURI(nsIURI *aURI, const nsAString &aCharset,
return;
}
- // TODO: Preload module scripts.
- if (mDocument->ModuleScriptsEnabled() && aType.LowerCaseEqualsASCII("module")) {
+ ScriptKind scriptKind = ScriptKind::Classic;
+
+ if (mDocument->ModuleScriptsEnabled()) {
+ // Don't load nomodule scripts.
+ if (aNoModule) {
+ return;
+ }
+
+ // Preload module scripts.
+ static const char kASCIIWhitespace[] = "\t\n\f\r ";
+
+ nsAutoString type(aType);
+ type.Trim(kASCIIWhitespace);
+ if (type.LowerCaseEqualsASCII("module")) {
+ scriptKind = ScriptKind::Module;
+ }
+ }
+
+ if (scriptKind == ScriptKind::Classic &&
+ !aType.IsEmpty() && !nsContentUtils::IsJavascriptMIMEType(aType)) {
+ // Unknown type (not type = module and not type = JS MIME type).
+ // Don't load it.
return;
}
@@ -2609,7 +2680,7 @@ ScriptLoader::PreloadURI(nsIURI *aURI, const nsAString &aCharset,
}
RefPtr<ScriptLoadRequest> request =
- CreateLoadRequest(ScriptKind::Classic, aURI, nullptr, 0,
+ CreateLoadRequest(scriptKind, aURI, nullptr, 0,
Element::StringToCORSMode(aCrossOrigin), sriMetadata,
aReferrerPolicy);
request->mIsInline = false;
diff --git a/dom/script/ScriptLoader.h b/dom/script/ScriptLoader.h
index ed1e6acbc..73f2a9258 100644
--- a/dom/script/ScriptLoader.h
+++ b/dom/script/ScriptLoader.h
@@ -173,6 +173,12 @@ public:
return mScriptMode == ScriptMode::eAsync;
}
+ virtual bool IsTopLevel() const
+ {
+ // Classic scripts are always top level.
+ return true;
+ }
+
void MaybeCancelOffThreadScript();
using super::getNext;
@@ -479,13 +485,15 @@ public:
* @param aIntegrity The expect hash url, if avail, of the request
* @param aScriptFromHead Whether or not the script was a child of head
*/
- virtual void PreloadURI(nsIURI *aURI, const nsAString &aCharset,
+ virtual void PreloadURI(nsIURI *aURI,
+ const nsAString &aCharset,
const nsAString &aType,
const nsAString &aCrossOrigin,
const nsAString& aIntegrity,
bool aScriptFromHead,
bool aAsync,
bool aDefer,
+ bool aNoModule,
const mozilla::net::ReferrerPolicy aReferrerPolicy);
/**
@@ -498,6 +506,12 @@ public:
return mPendingChildLoaders.AppendElement(aChild) != nullptr;
}
+ /*
+ * Clear the map of loaded modules. Called when a Document object is reused
+ * for a different global.
+ */
+ void ClearModuleMap();
+
private:
virtual ~ScriptLoader();
diff --git a/dom/security/test/csp/file_bug1312272.html b/dom/security/test/csp/file_bug1312272.html
deleted file mode 100644
index 18e0e5589..000000000
--- a/dom/security/test/csp/file_bug1312272.html
+++ /dev/null
@@ -1,13 +0,0 @@
-<!DOCTYPE HTML>
-<!-- Any copyright is dedicated to the Public Domain.
- http://creativecommons.org/publicdomain/zero/1.0/ -->
-<html>
-<head>
- <meta charset="utf-8">
- <title>marquee inline script tests for Bug 1312272</title>
-</head>
-<body>
-<marquee id="m" onstart="parent.postMessage('csp-violation-marquee-onstart', '*')">bug 1312272</marquee>
-<script src="file_bug1312272.js"></script>
-</body>
-</html>
diff --git a/dom/security/test/csp/file_strict_dynamic_script_events_xbl.html b/dom/security/test/csp/file_strict_dynamic_script_events_xbl.html
deleted file mode 100644
index 701ef3226..000000000
--- a/dom/security/test/csp/file_strict_dynamic_script_events_xbl.html
+++ /dev/null
@@ -1,14 +0,0 @@
-<!DOCTYPE HTML>
-<html>
-<head>
- <title>Bug 1316826 - 'strict-dynamic' blocking DOM event handlers</title>
-</head>
-<body>
-<div id="testdiv">blocked</div>
-
-<marquee onstart='document.getElementById("testdiv").innerHTML = "allowed";'>
- Bug 1316826
-</marquee>
-
-</body>
-</html>
diff --git a/dom/security/test/csp/test_strict_dynamic.html b/dom/security/test/csp/test_strict_dynamic.html
index 00e75143f..8f1b53f31 100644
--- a/dom/security/test/csp/test_strict_dynamic.html
+++ b/dom/security/test/csp/test_strict_dynamic.html
@@ -79,13 +79,6 @@ var tests = [
policy: "script-src 'strict-dynamic' 'nonce-foo'"
},
{
- // marquee is a special snowflake. Extra test for xbl things.
- desc: "strict-dynamic with DOM events should be blocked (XBL)",
- result: "blocked",
- file: "file_strict_dynamic_script_events_xbl.html",
- policy: "script-src 'strict-dynamic' 'nonce-foo'"
- },
- {
desc: "strict-dynamic with JS URLs should be blocked",
result: "blocked",
file: "file_strict_dynamic_js_url.html",
diff --git a/dom/smil/SMILBoolType.h b/dom/smil/SMILBoolType.h
index 608a09ccf..d0bbcf5ea 100644
--- a/dom/smil/SMILBoolType.h
+++ b/dom/smil/SMILBoolType.h
@@ -42,7 +42,7 @@ protected:
private:
// Private constructor: prevent instances beyond my singleton.
- constexpr SMILBoolType() {}
+ SMILBoolType() {}
};
} // namespace mozilla
diff --git a/dom/smil/SMILEnumType.h b/dom/smil/SMILEnumType.h
index b6cda3ff9..070ae60bb 100644
--- a/dom/smil/SMILEnumType.h
+++ b/dom/smil/SMILEnumType.h
@@ -43,7 +43,7 @@ protected:
private:
// Private constructor: prevent instances beyond my singleton.
- constexpr SMILEnumType() {}
+ SMILEnumType() {}
};
} // namespace mozilla
diff --git a/dom/smil/SMILIntegerType.h b/dom/smil/SMILIntegerType.h
index 39560cc79..bf8030b6e 100644
--- a/dom/smil/SMILIntegerType.h
+++ b/dom/smil/SMILIntegerType.h
@@ -38,7 +38,8 @@ public:
}
private:
- constexpr SMILIntegerType() {}
+ // Private constructor: prevent instances beyond my singleton.
+ SMILIntegerType() {}
};
} // namespace mozilla
diff --git a/dom/smil/SMILStringType.h b/dom/smil/SMILStringType.h
index 6f160cadb..6fb51b7d9 100644
--- a/dom/smil/SMILStringType.h
+++ b/dom/smil/SMILStringType.h
@@ -43,7 +43,7 @@ protected:
private:
// Private constructor: prevent instances beyond my singleton.
- constexpr SMILStringType() {}
+ SMILStringType() {}
};
} // namespace mozilla
diff --git a/dom/smil/nsSMILCSSValueType.h b/dom/smil/nsSMILCSSValueType.h
index 0c71605f0..0303e69e3 100644
--- a/dom/smil/nsSMILCSSValueType.h
+++ b/dom/smil/nsSMILCSSValueType.h
@@ -110,7 +110,7 @@ public:
private:
// Private constructor: prevent instances beyond my singleton.
- constexpr nsSMILCSSValueType() {}
+ nsSMILCSSValueType() {}
};
#endif // NS_SMILCSSVALUETYPE_H_
diff --git a/dom/smil/nsSMILFloatType.h b/dom/smil/nsSMILFloatType.h
index fd57e4a77..470e935d3 100644
--- a/dom/smil/nsSMILFloatType.h
+++ b/dom/smil/nsSMILFloatType.h
@@ -41,7 +41,7 @@ protected:
private:
// Private constructor: prevent instances beyond my singleton.
- constexpr nsSMILFloatType() {}
+ nsSMILFloatType() {}
};
#endif // NS_SMILFLOATTYPE_H_
diff --git a/dom/smil/nsSMILNullType.h b/dom/smil/nsSMILNullType.h
index d21610ff4..c668773ce 100644
--- a/dom/smil/nsSMILNullType.h
+++ b/dom/smil/nsSMILNullType.h
@@ -44,7 +44,7 @@ protected:
private:
// Private constructor: prevent instances beyond my singleton.
- constexpr nsSMILNullType() {}
+ nsSMILNullType() {}
};
#endif // NS_SMILNULLTYPE_H_
diff --git a/dom/svg/SVGIntegerPairSMILType.h b/dom/svg/SVGIntegerPairSMILType.h
index 52af5d3dc..ae62781fd 100644
--- a/dom/svg/SVGIntegerPairSMILType.h
+++ b/dom/svg/SVGIntegerPairSMILType.h
@@ -45,7 +45,7 @@ protected:
private:
// Private constructor: prevent instances beyond my singleton.
- constexpr SVGIntegerPairSMILType() {}
+ SVGIntegerPairSMILType() {}
};
} // namespace mozilla
diff --git a/dom/svg/SVGLengthListSMILType.h b/dom/svg/SVGLengthListSMILType.h
index 10321b585..2fbb84488 100644
--- a/dom/svg/SVGLengthListSMILType.h
+++ b/dom/svg/SVGLengthListSMILType.h
@@ -93,7 +93,7 @@ protected:
private:
// Private constructor: prevent instances beyond my singleton.
- constexpr SVGLengthListSMILType() {}
+ SVGLengthListSMILType() {}
};
} // namespace mozilla
diff --git a/dom/svg/SVGMotionSMILType.h b/dom/svg/SVGMotionSMILType.h
index 7529d796d..768c90093 100644
--- a/dom/svg/SVGMotionSMILType.h
+++ b/dom/svg/SVGMotionSMILType.h
@@ -78,7 +78,7 @@ public:
private:
// Private constructor: prevent instances beyond my singleton.
- constexpr SVGMotionSMILType() {}
+ SVGMotionSMILType() {}
};
} // namespace mozilla
diff --git a/dom/svg/SVGNumberListSMILType.h b/dom/svg/SVGNumberListSMILType.h
index 5e8db8afe..efdabdb14 100644
--- a/dom/svg/SVGNumberListSMILType.h
+++ b/dom/svg/SVGNumberListSMILType.h
@@ -47,7 +47,7 @@ protected:
private:
// Private constructor: prevent instances beyond my singleton.
- constexpr SVGNumberListSMILType() {}
+ SVGNumberListSMILType() {}
};
} // namespace mozilla
diff --git a/dom/svg/SVGNumberPairSMILType.h b/dom/svg/SVGNumberPairSMILType.h
index 0f90163f5..a88a0f5ac 100644
--- a/dom/svg/SVGNumberPairSMILType.h
+++ b/dom/svg/SVGNumberPairSMILType.h
@@ -40,7 +40,7 @@ protected:
private:
// Private constructor: prevent instances beyond my singleton.
- constexpr SVGNumberPairSMILType() {}
+ SVGNumberPairSMILType() {}
};
} // namespace mozilla
diff --git a/dom/svg/SVGOrientSMILType.h b/dom/svg/SVGOrientSMILType.h
index 6b30cbee0..904b37680 100644
--- a/dom/svg/SVGOrientSMILType.h
+++ b/dom/svg/SVGOrientSMILType.h
@@ -60,7 +60,7 @@ protected:
private:
// Private constructor: prevent instances beyond my singleton.
- constexpr SVGOrientSMILType() {}
+ SVGOrientSMILType() {}
};
} // namespace mozilla
diff --git a/dom/svg/SVGPathSegListSMILType.h b/dom/svg/SVGPathSegListSMILType.h
index 6856ef275..5e4e89141 100644
--- a/dom/svg/SVGPathSegListSMILType.h
+++ b/dom/svg/SVGPathSegListSMILType.h
@@ -51,7 +51,7 @@ protected:
private:
// Private constructor: prevent instances beyond my singleton.
- constexpr SVGPathSegListSMILType() {}
+ SVGPathSegListSMILType() {}
};
} // namespace mozilla
diff --git a/dom/svg/SVGPointListSMILType.h b/dom/svg/SVGPointListSMILType.h
index 6f58bd42e..053959553 100644
--- a/dom/svg/SVGPointListSMILType.h
+++ b/dom/svg/SVGPointListSMILType.h
@@ -47,7 +47,7 @@ protected:
private:
// Private constructor: prevent instances beyond my singleton.
- constexpr SVGPointListSMILType() {}
+ SVGPointListSMILType() {}
};
} // namespace mozilla
diff --git a/dom/svg/SVGTransformListSMILType.h b/dom/svg/SVGTransformListSMILType.h
index 526f9ba50..6572815a1 100644
--- a/dom/svg/SVGTransformListSMILType.h
+++ b/dom/svg/SVGTransformListSMILType.h
@@ -123,7 +123,7 @@ public:
private:
// Private constructor: prevent instances beyond my singleton.
- constexpr SVGTransformListSMILType() {}
+ SVGTransformListSMILType() {}
};
} // end namespace mozilla
diff --git a/dom/svg/SVGViewBoxSMILType.h b/dom/svg/SVGViewBoxSMILType.h
index f05f3928d..54b171263 100644
--- a/dom/svg/SVGViewBoxSMILType.h
+++ b/dom/svg/SVGViewBoxSMILType.h
@@ -40,7 +40,7 @@ protected:
private:
// Private constructor: prevent instances beyond my singleton.
- constexpr SVGViewBoxSMILType() {}
+ SVGViewBoxSMILType() {}
};
} // namespace mozilla
diff --git a/dom/tests/browser/browser_bug396843.js b/dom/tests/browser/browser_bug396843.js
index 84d7e3b83..a2281d1b8 100644
--- a/dom/tests/browser/browser_bug396843.js
+++ b/dom/tests/browser/browser_bug396843.js
@@ -72,7 +72,6 @@ function testInDocument(doc, documentID) {
HTML_TAG("link", "Link")
HTML_TAG("listing", "Span")
HTML_TAG("map", "Map")
- HTML_TAG("marquee", "Div")
HTML_TAG("menu", "Shared")
HTML_TAG("meta", "Meta")
HTML_TAG("multicol", "Unknown")
diff --git a/dom/tests/mochitest/bugs/mochitest.ini b/dom/tests/mochitest/bugs/mochitest.ini
index 3743c6782..6865ada88 100644
--- a/dom/tests/mochitest/bugs/mochitest.ini
+++ b/dom/tests/mochitest/bugs/mochitest.ini
@@ -145,5 +145,4 @@ skip-if = toolkit == 'android' #Windows can't change size on Android
skip-if = toolkit == 'android'
[test_bug1022869.html]
[test_bug1112040.html]
-[test_bug1160342_marquee.html]
[test_bug1171215.html]
diff --git a/dom/tests/mochitest/bugs/test_bug1160342_marquee.html b/dom/tests/mochitest/bugs/test_bug1160342_marquee.html
deleted file mode 100644
index 8da13478e..000000000
--- a/dom/tests/mochitest/bugs/test_bug1160342_marquee.html
+++ /dev/null
@@ -1,337 +0,0 @@
-<!DOCTYPE html>
-<html>
-<!--
-https://bugzilla.mozilla.org/show_bug.cgi?id=1160342
--->
-<head>
- <title>Test for Bug 411103</title>
- <script type="text/javascript" src="/tests/SimpleTest/SimpleTest.js"></script>
- <link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css" />
-</head>
-<body>
-<a target="_blank" href="https://bugzilla.mozilla.org/show_bug.cgi?id=1160342">Mozilla Bug 1160342</a>
-<p id="display"></p>
-<div id="content">
-<marquee id="a" style="border: 1px solid black;">marquee</marquee>
-</div>
-
-<pre id="test">
-<script class="testbody" type="text/javascript">
-/* The todos are cases where IE/Edge is throwing errors, but
- for Mozilla it was decided to not do that for now */
- var x=document.getElementById('a');
-
- SimpleTest.waitForExplicitFinish();
-
- setTimeout(function() {
- is(x.behavior, "scroll", "Wrong behavior value");
- x.setAttribute('behavior', 'alternate');
- is(x.behavior, "alternate", "Wrong behavior value");
- x.setAttribute('behavior', 'invalid');
- is(x.behavior, "scroll", "Wrong behavior value");;
- x.setAttribute('behavior', 'Scroll');
- is(x.behavior, "scroll", "Wrong behavior value");
- x.setAttribute('behavior', 'Slide');
- is(x.behavior, "slide", "Wrong behavior value");
- x.setAttribute('behavior', '');
- is(x.behavior, "scroll", "Wrong behavior value");
- x.setAttribute('behavior', 'slide');
- x.removeAttribute('behavior');
- is(x.behavior, "scroll", "Wrong behavior value");
- is(x.getAttribute('behavior'), null, "Wrong behavior attribute");
-
- x.behavior = 'alternate';
- is(x.behavior, "alternate", "Wrong behavior value");
- try {
- x.behavior = 'invalid';
- todo_is(false, true, "marquee.behavior = 'invalid' should throw");
- } catch(e) {
- ok(true, "Exception was raised");
- }
- is(x.behavior, "alternate", "Wrong behavior value");
- is(x.getAttribute('behavior'), "alternate", "Wrong behavior attribute");
- x.behavior = 'Slide';
- is(x.behavior, "slide", "Wrong behavior value");
- is(x.getAttribute('behavior'), "slide", "Wrong behavior attribute");
- try {
- x.behavior = 'invalid';
- todo_is(false, true, "marquee.behavior = 'invalid' should throw");
- } catch(e) {
- ok(true, "Exception was raised");
- }
- try {
- x.behavior = null;
- x.behavior = undefined;
- todo_is(false, true, "marquee.behavior = 'invalid' should throw");
- } catch(e) {
- ok(true, "Exception was raised");
- }
- is(x.behavior, "slide", "Wrong behavior value");
- is(x.getAttribute('behavior'), "slide", "Wrong behavior attribute");
- // This doesn't work in Mozilla due to chrome XBL security issues
- x.behavior = { toString: function _toString() { return "scroll"} }
- is(x.behavior, x.getAttribute('behavior'), "Wrong behavior value");
- x.behavior = 'scroll';
- is(x.behavior, "scroll", "Wrong behavior value");
-
- is(x.loop, -1, "Wrong loop value");
- x.setAttribute('loop', '1');
- is(x.loop, 1, "Wrong loop value");
- x.setAttribute('loop', 'invalid');
- is(x.loop, -1, "Wrong loop value");
- x.setAttribute('loop', '');
- is(x.loop, -1, "Wrong loop value");
- x.setAttribute('loop', '0');
- is(x.loop, -1, "Wrong loop value");
- x.setAttribute('loop', '1000');
- is(x.loop, 1000, "Wrong loop value");
- x.setAttribute('loop', '-0.123');
- is(x.loop, 1000, "Wrong loop value");
- x.setAttribute('loop', '-1.123');
- is(x.loop, -1, "Wrong loop value");
- x.setAttribute('loop', '-1');
- is(x.loop, -1, "Wrong loop value");
- x.setAttribute('loop', '1000');
- is(x.loop, 1000, "Wrong loop value");
- x.removeAttribute('loop');
- is(x.loop, -1, "Wrong loop value");
- is(x.getAttribute('loop'), null, "Wrong loop attribute");
-
- x.loop = 1;
- is(x.loop, 1, "Wrong loop value");
- is(x.getAttribute('loop'), "1", "Wrong loop attribute");
- try {
- x.loop = -2;
- todo_is(false, true, "marquee.loop = -2 should throw");
- } catch(e) {
- ok(true, "Exception was raised");
- }
- is(x.loop, 1, "Wrong loop value");
- is(x.getAttribute('loop'), "1", "Wrong loop attribute");
- try {
- x.loop = 'invalid';
- todo_is(false, true, ".loop = 'invalid' should throw");
- } catch(e) {
- ok(true, "Exception was raised");
- }
- is(x.loop, 1, "Wrong loop value");
- is(x.getAttribute('loop'), "1", "Wrong loop attribute");
- try {
- x.loop = null;
- todo_is(false, true, "marquee.loop = null should throw");
- } catch(e) {
- ok(true, "Exception was raised");
- }
- is(x.loop, 1, "Wrong loop value");
- is(x.getAttribute('loop'), "1", "Wrong loop attribute");
- x.loop = -1;
- is(x.loop, -1, "Wrong loop value");
- is(x.getAttribute('loop'), "-1", "Wrong loop attribute");
- x.loop = '100';
- is(x.loop, 100, "Wrong loop value");
- is(x.getAttribute('loop'), "100", "Wrong loop attribute");
- try {
- x.loop = -0.123;
- todo_is(false, true, "marquee.loop = null should throw");
- } catch(e) {
- ok(true, "Exception was raised");
- }
- is(x.loop, 100, "Wrong loop value");
- is(x.getAttribute('loop'), "100", "Wrong loop attribute");
- try {
- x.loop = 0;
- todo_is(false, true, "marquee.loop = null should throw");
- } catch(e) {
- ok(true, "Exception was raised");
- }
- is(x.loop, 100, "Wrong loop value");
- is(x.getAttribute('loop'), "100", "Wrong loop attribute");
- x.loop = -1.123;
- is(x.loop, -1, "Wrong loop value");
- is(x.getAttribute('loop'), "-1", "Wrong loop attribute");
-
-
- is(x.scrollAmount, 6, "Wrong scrollAmount value");
- x.setAttribute('scrollAmount', '1');
- is(x.scrollAmount, 1, "Wrong scrollAmount value");
- x.setAttribute('scrollAmount', 'invalid');
- is(x.scrollAmount, 6, "Wrong scrollAmount value");
- x.setAttribute('scrollAmount', '1000');
- is(x.scrollAmount, 1000, "Wrong scrollAmount value");
- x.setAttribute('scrollAmount', '-1');
- is(x.scrollAmount, 1000, "Wrong scrollAmount value");
- x.setAttribute('scrollAmount', '999');
- is(x.scrollAmount, 999, "Wrong scrollAmount value");
- x.setAttribute('scrollAmount', '');
- is(x.scrollAmount, 6, "Wrong scrollAmount value");
- x.setAttribute('scrollAmount', '999');
- x.removeAttribute('scrollAmount');
- is(x.scrollAmount, 6, "Wrong scrollAmount value");
- is(x.getAttribute('scrollamount'), null, "Wrong scrollamount attribute");
-
- x.scrollAmount = 1;
- is(x.scrollAmount, 1, "Wrong scrollAmount value");
- is(x.getAttribute('scrollamount'), "1", "Wrong scrolldelay attribute");
- try {
- x.scrollAmount = -2;
- todo_is(false, true, "marquee.scrollAmount = -2 should throw");
- } catch(e) {
- ok(true, "Exception was raised");
- }
- is(x.scrollAmount, 1, "Wrong scrollAmount value");
- is(x.getAttribute('scrollamount'), "1", "Wrong scrolldelay attribute");
- x.scrollAmount = 'invalid';
- is(x.scrollAmount, 0, "Wrong scrollAmount value");
- is(x.getAttribute('scrollamount'), "0", "Wrong scrolldelay attribute");
- x.scrollAmount = 1;
- x.scrollAmount = null;
- is(x.scrollAmount, 0, "Wrong scrollAmount value");
- is(x.getAttribute('scrollamount'), "0", "Wrong scrolldelay attribute");
- x.scrollAmount = '2';
- is(x.scrollAmount, 2, "Wrong scrollAmount value");
- is(x.getAttribute('scrollamount'), "2", "Wrong scrolldelay attribute");
-
-
- is(x.scrollDelay, 85, "Wrong scrollDelay value");
- x.setAttribute('scrollDelay', '1');
- is(x.scrollDelay, 1, "Wrong scrollDelay value");
- x.setAttribute('scrollDelay', 'invalid');
- is(x.scrollDelay, 85, "Wrong scrollDelay value");
- x.setAttribute('scrollDelay', '70');
- is(x.scrollDelay, 70, "Wrong scrollDelay value");
- x.setAttribute('scrollDelay', '59');
- is(x.scrollDelay, 59, "Wrong scrollDelay value");
- x.setAttribute('scrollDelay', '1000');
- is(x.scrollDelay, 1000, "Wrong scrollDelay value");
- x.setAttribute('scrollDelay', '-1');
- is(x.scrollDelay, 1000, "Wrong scrollDelay value");
- x.setAttribute('scrollDelay', '');
- is(x.scrollDelay, 85, "Wrong scrollDelay value");
- x.setAttribute('scrollDelay', '1000');
- x.removeAttribute('scrollDelay');
- is(x.scrollDelay, 85, "Wrong scrollDelay value");
- is(x.getAttribute('scrolldelay'), null, "Wrong scrolldelay attribute");
-
- x.scrollDelay = 100;
- is(x.scrollDelay, 100, "Wrong scrollDelay value");
- is(x.getAttribute('scrolldelay'), "100", "Wrong scrolldelay attribute");
- try {
- x.scrollDelay = -2;
- todo_is(false, true, "marquee.scrollDelay = -2 should throw");
- } catch(e) {
- ok(true, "Exception was raised");
- }
- is(x.scrollDelay, 100, "Wrong scrollDelay value");
- is(x.getAttribute('scrolldelay'), "100", "Wrong scrolldelay attribute");
- try {
- x.scrollDelay = 'invalid';
- todo_is(false, true, "marquee.scrollDelay = 'invalid' should throw");
- } catch(e) {
- ok(true, "Exception was raised");
- }
- is(x.scrollDelay, 100, "Wrong scrollDelay value");
- is(x.getAttribute('scrolldelay'), "100", "Wrong scrolldelay attribute");
- try {
- x.scrollDelay = null;
- todo_is(false, true, "marquee.scrollDelay = null should throw");
- } catch(e) {
- ok(true, "Exception was raised");
- }
- is(x.scrollDelay, 100, "Wrong scrollDelay value");
- is(x.getAttribute('scrolldelay'), "100", "Wrong scrolldelay attribute");
- try {
- x.scrollDelay = -1;
- todo_is(false, true, "marquee.scrollDelay = -1 should throw");
- } catch(e) {
- ok(true, "Exception was raised");
- }
- is(x.scrollDelay, 100, "Wrong scrollDelay value");
- is(x.getAttribute('scrolldelay'), "100", "Wrong scrolldelay attribute");
- x.scrollDelay = '50';
- is(x.scrollDelay, 50, "Wrong scrollDelay value");
- is(x.getAttribute('scrolldelay'), "50", "Wrong scrolldelay attribute");
-
-
- is(x.trueSpeed, false, "Wrong trueSpeed value");
- x.setAttribute('trueSpeed', '1');
- is(x.trueSpeed, true, "Wrong trueSpeed value");
- x.setAttribute('trueSpeed', 'false');
- is(x.trueSpeed, true, "Wrong trueSpeed value");
- x.setAttribute('trueSpeed', '');
- is(x.trueSpeed, true, "Wrong trueSpeed value");
- x.removeAttribute('trueSpeed');
- is(x.trueSpeed, false, "Wrong trueSpeed value");
- is(x.getAttribute('truespeed'), null, "Wrong truespeed attribute");
-
- x.trueSpeed = 1;
- is(x.trueSpeed, true, "Wrong trueSpeed value");
- is(x.getAttribute('truespeed'), "", "Wrong truespeed attribute");
- x.trueSpeed = -2;
- is(x.trueSpeed, true, "Wrong trueSpeed value");
- is(x.getAttribute('truespeed'), "", "Wrong truespeed attribute");
- x.trueSpeed = null;
- is(x.trueSpeed, false, "Wrong trueSpeed value");
- is(x.getAttribute('truespeed'), null, "Wrong truespeed attribute");
- x.trueSpeed = '100';
- is(x.trueSpeed, true, "Wrong trueSpeed value");
- is(x.getAttribute('truespeed'), "", "Wrong truespeed attribute");
-
-
- is(x.direction, "left", "Wrong direction value");
- x.setAttribute('direction', 'right');
- is(x.direction, "right", "Wrong direction value");
- x.setAttribute('direction', 'invalid');
- is(x.direction, "left", "Wrong direction value");
- x.setAttribute('direction', 'RIGHT');
- is(x.direction, "right", "Wrong direction value");
- x.setAttribute('direction', '');
- is(x.direction, "left", "Wrong direction value");
- x.setAttribute('direction', 'right');
- x.removeAttribute('direction');
- is(x.direction, "left", "Wrong direction value");
- is(x.getAttribute('direction'), null, "Wrong direction attribute");
- x.setAttribute('direction', 'up');
- is(x.direction, "up", "Wrong direction value");
- x.setAttribute('direction', 'down');
- is(x.direction, "down", "Wrong direction value");
- x.removeAttribute('direction');
- is(x.direction, "left", "Wrong direction value");
- is(x.getAttribute('direction'), null, "Wrong direction attribute");
-
- x.direction = 'right';
- is(x.direction, "right", "Wrong direction value");
- is(x.getAttribute('direction'), "right", "Wrong direction attribute");
- x.direction = 'up';
- is(x.direction, "up", "Wrong direction value");
- is(x.getAttribute('direction'), "up", "Wrong direction attribute");
- x.direction = 'down';
- is(x.direction, "down", "Wrong direction value");
- is(x.getAttribute('direction'), "down", "Wrong direction attribute");
- try {
- x.direction = 1;
- todo_is(false, true, "marquee.direction = 1 should throw");
- } catch(e) {
- ok(true, "Exception was raised");
- }
- is(x.direction, "down", "Wrong direction value");
- is(x.getAttribute('direction'), "down", "Wrong direction attribute");
- try {
- x.direction = null;
- todo_is(false, true, "marquee.direction = null should throw");
- } catch(e) {
- ok(true, "Exception was raised");
- }
- is(x.direction, "down", "Wrong direction value");
- is(x.getAttribute('direction'), "down", "Wrong direction attribute");
- // This doesn't work in Mozilla due to chrome XBL security issues
- x.direction = { toString: function _toString() { return "right"} }
- is(x.direction, x.getAttribute('direction'), "Wrong direction value");
- x.direction = 'left';
- is(x.direction, "left", "Wrong direction value");
- SimpleTest.finish();
- }, 0);
-
-</script>
-</pre>
-</body>
-</html>
diff --git a/dom/tests/mochitest/bugs/test_bug396843.html b/dom/tests/mochitest/bugs/test_bug396843.html
index 20dc53068..031843fd4 100644
--- a/dom/tests/mochitest/bugs/test_bug396843.html
+++ b/dom/tests/mochitest/bugs/test_bug396843.html
@@ -92,7 +92,6 @@ HTML_TAG("li", "LI")
HTML_TAG("link", "Link")
HTML_TAG("listing", "Span")
HTML_TAG("map", "Map")
-HTML_TAG("marquee", "Div")
HTML_TAG("menu", "Shared")
HTML_TAG("meta", "Meta")
HTML_TAG("multicol", "Unknown")
diff --git a/dom/webidl/MediaQueryList.webidl b/dom/webidl/MediaQueryList.webidl
index 519ddb0e5..af641a268 100644
--- a/dom/webidl/MediaQueryList.webidl
+++ b/dom/webidl/MediaQueryList.webidl
@@ -4,17 +4,21 @@
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
*
* The origin of this IDL file is
- * http://dev.w3.org/csswg/cssom-view/#the-mediaquerylist-interface
+ * https://drafts.csswg.org/cssom-view/#mediaquerylist
*
* Copyright © 2012 W3C® (MIT, ERCIM, Keio), All Rights Reserved. W3C
* liability, trademark and document use rules apply.
*/
-interface MediaQueryList {
+interface MediaQueryList : EventTarget {
readonly attribute DOMString media;
readonly attribute boolean matches;
- void addListener(MediaQueryListListener listener);
- void removeListener(MediaQueryListListener listener);
-};
-callback MediaQueryListListener = void (MediaQueryList list);
+ [Throws]
+ void addListener(EventListener? listener);
+
+ [Throws]
+ void removeListener(EventListener? listener);
+
+ attribute EventHandler onchange;
+};
diff --git a/dom/webidl/MediaQueryListEvent.webidl b/dom/webidl/MediaQueryListEvent.webidl
new file mode 100644
index 000000000..f3a66fb57
--- /dev/null
+++ b/dom/webidl/MediaQueryListEvent.webidl
@@ -0,0 +1,18 @@
+/* -*- Mode: IDL; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
+/* This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this file,
+ * You can obtain one at http://mozilla.org/MPL/2.0/.
+ *
+ * https://drafts.csswg.org/cssom-view/#mediaquerylistevent
+ */
+
+[Constructor(DOMString type, optional MediaQueryListEventInit eventInitDict)]
+interface MediaQueryListEvent : Event {
+ readonly attribute DOMString media;
+ readonly attribute boolean matches;
+};
+
+dictionary MediaQueryListEventInit : EventInit {
+ DOMString media = "";
+ boolean matches = false;
+};
diff --git a/dom/webidl/ResizeObserver.webidl b/dom/webidl/ResizeObserver.webidl
new file mode 100644
index 000000000..98700f53c
--- /dev/null
+++ b/dom/webidl/ResizeObserver.webidl
@@ -0,0 +1,39 @@
+/* -*- Mode: IDL; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
+/* This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this file,
+ * You can obtain one at http://mozilla.org/MPL/2.0/.
+ *
+ * The origin of this IDL file is
+ * https://wicg.github.io/ResizeObserver/
+ */
+
+[Constructor(ResizeObserverCallback callback),
+ Exposed=Window,
+ Pref="layout.css.resizeobserver.enabled"]
+interface ResizeObserver {
+ [Throws]
+ void observe(Element? target);
+ [Throws]
+ void unobserve(Element? target);
+ void disconnect();
+};
+
+callback ResizeObserverCallback = void (sequence<ResizeObserverEntry> entries, ResizeObserver observer);
+
+[Constructor(Element? target),
+ ChromeOnly,
+ Pref="layout.css.resizeobserver.enabled"]
+interface ResizeObserverEntry {
+ readonly attribute Element target;
+ readonly attribute DOMRectReadOnly? contentRect;
+};
+
+[Constructor(Element? target),
+ ChromeOnly,
+ Pref="layout.css.resizeobserver.enabled"]
+interface ResizeObservation {
+ readonly attribute Element target;
+ readonly attribute long broadcastWidth;
+ readonly attribute long broadcastHeight;
+ boolean isActive();
+};
diff --git a/dom/webidl/moz.build b/dom/webidl/moz.build
index 687e502fa..a4214caea 100644
--- a/dom/webidl/moz.build
+++ b/dom/webidl/moz.build
@@ -365,6 +365,7 @@ WEBIDL_FILES = [
'Range.webidl',
'Rect.webidl',
'Request.webidl',
+ 'ResizeObserver.webidl',
'Response.webidl',
'RGBColor.webidl',
'RTCStatsReport.webidl',
@@ -680,6 +681,7 @@ GENERATED_EVENTS_WEBIDL_FILES = [
'HashChangeEvent.webidl',
'HiddenPluginEvent.webidl',
'ImageCaptureErrorEvent.webidl',
+ 'MediaQueryListEvent.webidl',
'MediaStreamEvent.webidl',
'MediaStreamTrackEvent.webidl',
'MozSettingsEvent.webidl',
diff --git a/dom/xbl/crashtests/342954-1.xhtml b/dom/xbl/crashtests/342954-1.xhtml
deleted file mode 100644
index dbaa15384..000000000
--- a/dom/xbl/crashtests/342954-1.xhtml
+++ /dev/null
@@ -1,46 +0,0 @@
-<html xmlns="http://www.w3.org/1999/xhtml" xmlns:xbl="http://www.mozilla.org/xbl">
-
-
-<head>
-
-<script>
-<![CDATA[
-
-function boo()
-{
- s1 = document.getElementById("s1");
- marq = document.getElementById("marq");
- marqAnonymousSomething = document.getAnonymousNodes(marq)[0].childNodes[0];
-
- removeNode(marqAnonymousSomething);
- s1.appendChild(document.createElement("div"));
-}
-
-function removeNode(q1) { q1.parentNode.removeChild(q1); }
-
-]]>
-</script>
-
-<xbl:bindings id="marqueeBindings">
- <xbl:binding id="marquee-horizontal-12">
- <xbl:content>
- <div>
- <xbl:children/>
- </div>
- </xbl:content>
- </xbl:binding>
-</xbl:bindings>
-
-</head>
-
-
-<body onload="boo()">
-
-<span id="s1">Span</span>
-
-<div id="marq" style="-moz-binding: url('#marquee-horizontal-12');">Marquee</div>
-
-</body>
-
-
-</html>
diff --git a/dom/xbl/crashtests/342954-2-xbl.xml b/dom/xbl/crashtests/342954-2-xbl.xml
deleted file mode 100644
index 3e73f1355..000000000
--- a/dom/xbl/crashtests/342954-2-xbl.xml
+++ /dev/null
@@ -1,19 +0,0 @@
-<?xml version="1.0"?>
-
-<bindings id="marqueeBindings"
- xmlns="http://www.mozilla.org/xbl"
- xmlns:html="http://www.w3.org/1999/xhtml"
- xmlns:xul="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
- xmlns:xbl="http://www.mozilla.org/xbl">
-
- <binding id="marquee-horizontal-10">
-
- <content>
- <html:div>
- <children/>
- </html:div>
- </content>
-
- </binding>
-
-</bindings>
diff --git a/dom/xbl/crashtests/342954-2.xhtml b/dom/xbl/crashtests/342954-2.xhtml
deleted file mode 100644
index 4a250e31c..000000000
--- a/dom/xbl/crashtests/342954-2.xhtml
+++ /dev/null
@@ -1,29 +0,0 @@
-<html xmlns="http://www.w3.org/1999/xhtml">
-<head>
-<script>
-<![CDATA[
-
-function boo()
-{
- s1 = document.getElementById("s1");
- marq = document.getElementById("marq");
- marqAnonymousSomething = document.getAnonymousNodes(marq)[0].childNodes[0];
-
- removeNode(marqAnonymousSomething);
- s1.appendChild(document.createElement("div"));
-}
-
-function removeNode(q1) { q1.parentNode.removeChild(q1); }
-
-]]>
-</script>
-</head>
-
-<body onload="boo()">
-
-<span id="s1">Span</span>
-
-<div id="marq" style="-moz-binding: url('342954-2-xbl.xml#marquee-horizontal-10');">Marquee</div>
-
-</body>
-</html>
diff --git a/dom/xbl/crashtests/477878-1.html b/dom/xbl/crashtests/477878-1.html
deleted file mode 100644
index 17e4002b4..000000000
--- a/dom/xbl/crashtests/477878-1.html
+++ /dev/null
@@ -1,4 +0,0 @@
-<html>
-<head></head>
-<body><iframe style="display:none" src="data:text/html,<marquee>Marquee</marquee>" onload="this.style.display = '';"></iframe></body>
-</html>
diff --git a/dom/xbl/nsXBLMaybeCompiled.h b/dom/xbl/nsXBLMaybeCompiled.h
index d4b366b0e..ba66ec5d5 100644
--- a/dom/xbl/nsXBLMaybeCompiled.h
+++ b/dom/xbl/nsXBLMaybeCompiled.h
@@ -124,7 +124,7 @@ struct BarrierMethods<nsXBLMaybeCompiled<UncompiledT>>
template <class T>
struct IsHeapConstructibleType<nsXBLMaybeCompiled<T>>
{ // Yes, this is the exception to the rule. Sorry.
- static constexpr bool value = true;
+ static const bool value = true;
};
template <class UncompiledT>
diff --git a/editor/libeditor/HTMLEditUtils.cpp b/editor/libeditor/HTMLEditUtils.cpp
index 0adc5d511..098a908f1 100644
--- a/editor/libeditor/HTMLEditUtils.cpp
+++ b/editor/libeditor/HTMLEditUtils.cpp
@@ -688,7 +688,6 @@ static const ElementInfo kElements[eHTMLTag_userdefined] = {
ELEM(main, true, true, GROUP_BLOCK, GROUP_FLOW_ELEMENT),
ELEM(map, true, true, GROUP_SPECIAL, GROUP_BLOCK | GROUP_MAP_CONTENT),
ELEM(mark, true, true, GROUP_PHRASE, GROUP_INLINE_ELEMENT),
- ELEM(marquee, false, false, GROUP_NONE, GROUP_NONE),
ELEM(menu, true, true, GROUP_BLOCK, GROUP_LI | GROUP_FLOW_ELEMENT),
ELEM(menuitem, false, false, GROUP_NONE, GROUP_NONE),
ELEM(meta, false, false, GROUP_HEAD_CONTENT, GROUP_NONE),
diff --git a/gfx/thebes/gfxWindowsPlatform.cpp b/gfx/thebes/gfxWindowsPlatform.cpp
index 82e36efe2..4a94a751b 100755
--- a/gfx/thebes/gfxWindowsPlatform.cpp
+++ b/gfx/thebes/gfxWindowsPlatform.cpp
@@ -39,8 +39,6 @@
#include "DeviceManagerD3D9.h"
#include "mozilla/layers/ReadbackManagerD3D11.h"
-#include "WinUtils.h"
-
#include "gfxDWriteFontList.h"
#include "gfxDWriteFonts.h"
#include "gfxDWriteCommon.h"
@@ -59,6 +57,7 @@
#include "nsMemory.h"
+#include <dwmapi.h>
#include <d3d11.h>
#include "nsIMemoryReporter.h"
@@ -1633,10 +1632,9 @@ gfxWindowsPlatform::InitGPUProcessSupport()
bool
gfxWindowsPlatform::DwmCompositionEnabled()
{
- MOZ_ASSERT(WinUtils::dwmIsCompositionEnabledPtr);
BOOL dwmEnabled = false;
- if (FAILED(WinUtils::dwmIsCompositionEnabledPtr(&dwmEnabled))) {
+ if (FAILED(DwmIsCompositionEnabled(&dwmEnabled))) {
return false;
}
@@ -1671,7 +1669,7 @@ public:
DWM_TIMING_INFO vblankTime;
// Make sure to init the cbSize, otherwise GetCompositionTiming will fail
vblankTime.cbSize = sizeof(DWM_TIMING_INFO);
- HRESULT hr = WinUtils::dwmGetCompositionTimingInfoPtr(0, &vblankTime);
+ HRESULT hr = DwmGetCompositionTimingInfo(0, &vblankTime);
if (SUCCEEDED(hr)) {
UNSIGNED_RATIO refreshRate = vblankTime.rateRefresh;
// We get the rate in hertz / time, but we want the rate in ms.
@@ -1756,7 +1754,7 @@ public:
// Make sure to init the cbSize, otherwise
// GetCompositionTiming will fail
vblankTime.cbSize = sizeof(DWM_TIMING_INFO);
- HRESULT hr = WinUtils::dwmGetCompositionTimingInfoPtr(0, &vblankTime);
+ HRESULT hr = DwmGetCompositionTimingInfo(0, &vblankTime);
if (!SUCCEEDED(hr)) {
return vsync;
}
@@ -1838,7 +1836,7 @@ public:
// Using WaitForVBlank, the whole system dies because WaitForVBlank
// only works if it's run on the same thread as the Present();
- HRESULT hr = WinUtils::dwmFlushProcPtr();
+ HRESULT hr = DwmFlush();
if (!SUCCEEDED(hr)) {
// DWMFlush isn't working, fallback to software vsync.
ScheduleSoftwareVsync(TimeStamp::Now());
@@ -1918,13 +1916,9 @@ already_AddRefed<mozilla::gfx::VsyncSource>
gfxWindowsPlatform::CreateHardwareVsyncSource()
{
MOZ_RELEASE_ASSERT(NS_IsMainThread(), "GFX: Not in main thread.");
- if (!WinUtils::dwmIsCompositionEnabledPtr) {
- NS_WARNING("Dwm composition not available, falling back to software vsync");
- return gfxPlatform::CreateHardwareVsyncSource();
- }
BOOL dwmEnabled = false;
- WinUtils::dwmIsCompositionEnabledPtr(&dwmEnabled);
+ DwmIsCompositionEnabled(&dwmEnabled);
if (!dwmEnabled) {
NS_WARNING("DWM not enabled, falling back to software vsync");
return gfxPlatform::CreateHardwareVsyncSource();
diff --git a/js/src/builtin/Object.cpp b/js/src/builtin/Object.cpp
index bfcc8d20e..d3001b69e 100644
--- a/js/src/builtin/Object.cpp
+++ b/js/src/builtin/Object.cpp
@@ -1239,6 +1239,7 @@ static const JSFunctionSpec object_static_methods[] = {
JS_FN("isFrozen", obj_isFrozen, 1, 0),
JS_FN("seal", obj_seal, 1, 0),
JS_FN("isSealed", obj_isSealed, 1, 0),
+ JS_SELF_HOSTED_FN("fromEntries", "ObjectFromEntries", 1, 0),
JS_FS_END
};
diff --git a/js/src/builtin/Object.js b/js/src/builtin/Object.js
index 9ed1be0e1..c4739037e 100644
--- a/js/src/builtin/Object.js
+++ b/js/src/builtin/Object.js
@@ -202,3 +202,21 @@ function ObjectLookupGetter(name) {
// Step 3.d. (implicit)
}
+
+// Stage 4 draft 2020-09-06 https://tc39.github.io/proposal-object-from-entries/
+// Object.fromEntries (iterable)
+function ObjectFromEntries(iter) {
+ // We omit the usual step number comments here because they don't help.
+ // This implementation inlines AddEntriesFromIterator and
+ // CreateDataPropertyOnObject, so it looks more like the polyfill
+ // than the step-by-step spec algorithm.
+ const obj = {};
+
+ for (const pair of allowContentIter(iter)) {
+ if (!IsObject(pair))
+ ThrowTypeError(JSMSG_INVALID_MAP_ITERABLE, "Object.fromEntries");
+ _DefineDataProperty(obj, pair[0], pair[1]);
+ }
+
+ return obj;
+}
diff --git a/js/src/jsapi.cpp b/js/src/jsapi.cpp
index 69a3ba2ac..c0f0e61cc 100644
--- a/js/src/jsapi.cpp
+++ b/js/src/jsapi.cpp
@@ -4708,7 +4708,7 @@ JS::ModuleInstantiate(JSContext* cx, JS::HandleObject moduleArg)
{
AssertHeapIsIdle(cx);
CHECK_REQUEST(cx);
- assertSameCompartment(cx, moduleArg);
+ releaseAssertSameCompartment(cx, moduleArg);
return ModuleObject::Instantiate(cx, moduleArg.as<ModuleObject>());
}
@@ -4717,7 +4717,7 @@ JS::ModuleEvaluate(JSContext* cx, JS::HandleObject moduleArg)
{
AssertHeapIsIdle(cx);
CHECK_REQUEST(cx);
- assertSameCompartment(cx, moduleArg);
+ releaseAssertSameCompartment(cx, moduleArg);
return ModuleObject::Evaluate(cx, moduleArg.as<ModuleObject>());
}
@@ -6204,7 +6204,7 @@ JS_SetPendingException(JSContext* cx, HandleValue value)
{
AssertHeapIsIdle(cx);
CHECK_REQUEST(cx);
- assertSameCompartment(cx, value);
+ releaseAssertSameCompartment(cx, value);
cx->setPendingException(value);
}
diff --git a/js/xpconnect/tests/chrome/test_xrayToJS.xul b/js/xpconnect/tests/chrome/test_xrayToJS.xul
index 38f3f447d..d1cc3e26c 100644
--- a/js/xpconnect/tests/chrome/test_xrayToJS.xul
+++ b/js/xpconnect/tests/chrome/test_xrayToJS.xul
@@ -190,9 +190,9 @@ https://bugzilla.mozilla.org/show_bug.cgi?id=933681
constructorProps(["setPrototypeOf", "getOwnPropertyDescriptor", "getOwnPropertyDescriptors",
"keys", "is", "defineProperty", "defineProperties", "create",
"getOwnPropertyNames", "getOwnPropertySymbols",
- "preventExtensions", "freeze", "isFrozen", "seal",
+ "preventExtensions", "freeze", "fromEntries", "isFrozen", "seal",
"isSealed", "assign", "getPrototypeOf", "values",
- "entries", "isExtensible"])
+ "entries", "isExtensible"]);
gPrototypeProperties['Array'] =
["length", "toSource", "toString", "toLocaleString", "join", "reverse", "sort", "push",
"pop", "shift", "unshift", "splice", "concat", "slice", "lastIndexOf", "indexOf",
diff --git a/layout/base/crashtests/265027-1.html b/layout/base/crashtests/265027-1.html
deleted file mode 100644
index 9b455da41..000000000
--- a/layout/base/crashtests/265027-1.html
+++ /dev/null
@@ -1,19 +0,0 @@
-<HTML>
-<HEAD>
-<MARQUEE>
-<TABLE>
-<MARQUEE HEIGHT=100000000>
-<MARQUEE HEIGHT=100000000>
-<MARQUEE HEIGHT=100000000>
-<MARQUEE HEIGHT=100000000>
-<MARQUEE HEIGHT=100000000>
-<MARQUEE HEIGHT=100000000>
-<MARQUEE HEIGHT=100000000>
-<MARQUEE HEIGHT=100000000>
-<MARQUEE HEIGHT=100000000>
-<MARQUEE HEIGHT=100000000>
-<MARQUEE HEIGHT=100000000>
-<TBODY>
-Attack of the marquees!
-
-
diff --git a/layout/base/crashtests/265986-1.html b/layout/base/crashtests/265986-1.html
deleted file mode 100644
index 8d4ca290f..000000000
--- a/layout/base/crashtests/265986-1.html
+++ /dev/null
@@ -1,10 +0,0 @@
-<!DOCTYPE HTML PUBLIC '-//W3C//DTD HTML 4.0 Transitional//EN'>
-<HTML>
-<HEAD>
-</HEAD>
-<BODY>
-<IFRAME STYLE="MARGIN:99999999999px; PADDING:-99999999999px;"></IFRAME>
-<APPLET STYLE="HEIGHT:9999999999pt; float:left; MARGIN:-99999999999px; border:99999999999px solid blue;"></APPLET>
-<MARQUEE STYLE=" WIDTH:9999999999px;">W</MARQUEE>
-</BODY>
-</HTML>
diff --git a/layout/base/crashtests/265999-1.html b/layout/base/crashtests/265999-1.html
deleted file mode 100644
index 7e6e3d416..000000000
--- a/layout/base/crashtests/265999-1.html
+++ /dev/null
@@ -1,8 +0,0 @@
-<!DOCTYPE HTML PUBLIC '-//W3C//DTD HTML 4.0 Transitional//EN'>
-<HTML>
-<HEAD>
-</HEAD>
-<BODY>
-<MARQUEE STYLE="HEIGHT:9999999999px; float:right; border:99999999999px solid blue;"></MARQUEE>
-</BODY>
-</HTML>
diff --git a/layout/base/crashtests/367498-2.html b/layout/base/crashtests/367498-2.html
deleted file mode 100644
index 2c85ac0a4..000000000
--- a/layout/base/crashtests/367498-2.html
+++ /dev/null
@@ -1,14 +0,0 @@
-<html><head>
-</head><body>
-<marquee>
-<div style="border: 1px solid black; -moz-border-radius: 2em;">
-<marquee>
-<span style="display: -moz-grid-line;">
-<select></select>
-</span>
-</marquee>
-</div>
-</marquee>
-
-</body>
-</html>
diff --git a/layout/base/crashtests/404491-1.html b/layout/base/crashtests/404491-1.html
deleted file mode 100644
index 540a0f6a1..000000000
--- a/layout/base/crashtests/404491-1.html
+++ /dev/null
@@ -1,5 +0,0 @@
-<html>
-<body>
-<marquee><marquee></marquee><img></marquee>
-</body>
-</html>
diff --git a/layout/base/crashtests/580129-1.html b/layout/base/crashtests/580129-1.html
deleted file mode 100644
index 228051b5a..000000000
--- a/layout/base/crashtests/580129-1.html
+++ /dev/null
@@ -1,19 +0,0 @@
-<html>
-<head>
-<script>
-
-function boom()
-{
- var a = document.documentElement;
- var b = document.createElementNS("http://www.w3.org/1999/xhtml", "body");
- b.setAttributeNS(null, "style", "-moz-column-width: 20em;");
- a.innerHTML = "<frameset>";
- b.innerHTML = "<dd><marquee>x";
- document.removeChild(a);
- document.appendChild(b);
-}
-
-</script>
-</head>
-<body onload="boom();"></body>
-</html>
diff --git a/layout/base/crashtests/580494-1.html b/layout/base/crashtests/580494-1.html
deleted file mode 100644
index c76125f74..000000000
--- a/layout/base/crashtests/580494-1.html
+++ /dev/null
@@ -1 +0,0 @@
-<html><body><marquee><video></video></marquee></body></html> \ No newline at end of file
diff --git a/layout/base/crashtests/597924-1.html b/layout/base/crashtests/597924-1.html
deleted file mode 100644
index d855997ee..000000000
--- a/layout/base/crashtests/597924-1.html
+++ /dev/null
@@ -1,16 +0,0 @@
-<!DOCTYPE html>
-<html>
-<head>
-<script>
-
-function boom()
-{
- document.getElementById("s").appendChild(document.createElement("div"));
- var marq = document.getElementById("f").contentDocument.documentElement;
- marq.behavior = "alternate";
-}
-
-</script>
-</head>
-<body onload="boom();"><span id="s"></span><iframe src="data:text/xml,%3Cmarquee%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F1999%2Fxhtml%22%3EX%3C%2Fmarquee%3E" id="f"></iframe></body>
-</html>
diff --git a/layout/base/nsCSSFrameConstructor.cpp b/layout/base/nsCSSFrameConstructor.cpp
index 6642a090d..d28e60740 100644
--- a/layout/base/nsCSSFrameConstructor.cpp
+++ b/layout/base/nsCSSFrameConstructor.cpp
@@ -2614,7 +2614,8 @@ nsCSSFrameConstructor::ConstructDocElementFrame(Element* aDocEle
newFrame = frameItems.FirstChild();
NS_ASSERTION(frameItems.OnlyChild(), "multiple root element frames");
} else {
- MOZ_ASSERT(display->mDisplay == StyleDisplay::Block,
+ MOZ_ASSERT(display->mDisplay == StyleDisplay::Block ||
+ display->mDisplay == StyleDisplay::FlowRoot,
"Unhandled display type for root element");
contentFrame = NS_NewBlockFormattingContext(mPresShell, styleContext);
nsFrameItems frameItems;
@@ -4758,6 +4759,7 @@ nsCSSFrameConstructor::FindDisplayData(const nsStyleDisplay* aDisplay,
static const FrameConstructionDataByDisplay sDisplayData[] = {
FCDATA_FOR_DISPLAY(StyleDisplay::None, UNREACHABLE_FCDATA()),
FCDATA_FOR_DISPLAY(StyleDisplay::Block, UNREACHABLE_FCDATA()),
+ FCDATA_FOR_DISPLAY(StyleDisplay::FlowRoot, UNREACHABLE_FCDATA()),
// To keep the hash table small don't add inline frames (they're
// typically things like FONT and B), because we can quickly
// find them if we need to.
@@ -4943,7 +4945,7 @@ nsCSSFrameConstructor::ConstructNonScrollableBlockWithConstructor(
StyleDisplay::InlineBlock == aDisplay->mDisplay ||
clipPaginatedOverflow) &&
!aParentFrame->IsSVGText()) {
- flags = NS_BLOCK_FLOAT_MGR | NS_BLOCK_MARGIN_ROOT;
+ flags = NS_BLOCK_FORMATTING_CONTEXT_STATE_BITS;
if (clipPaginatedOverflow) {
flags |= NS_BLOCK_CLIP_PAGINATED_OVERFLOW;
}
@@ -5112,7 +5114,7 @@ nsCSSFrameConstructor::FlushAccumulatedBlock(nsFrameConstructorState& aState,
// is not a suitable block.
nsContainerFrame* blockFrame =
NS_NewMathMLmathBlockFrame(mPresShell, blockContext);
- blockFrame->AddStateBits(NS_BLOCK_FLOAT_MGR | NS_BLOCK_MARGIN_ROOT);
+ blockFrame->AddStateBits(NS_BLOCK_FORMATTING_CONTEXT_STATE_BITS);
InitAndRestoreFrame(aState, aContent, aParentFrame, blockFrame);
ReparentFrames(this, blockFrame, aBlockItems);
diff --git a/layout/base/nsLayoutUtils.cpp b/layout/base/nsLayoutUtils.cpp
index 5de6f2013..9b204d734 100644
--- a/layout/base/nsLayoutUtils.cpp
+++ b/layout/base/nsLayoutUtils.cpp
@@ -149,6 +149,7 @@ using namespace mozilla::gfx;
#define GRID_ENABLED_PREF_NAME "layout.css.grid.enabled"
#define GRID_TEMPLATE_SUBGRID_ENABLED_PREF_NAME "layout.css.grid-template-subgrid-value.enabled"
#define WEBKIT_PREFIXES_ENABLED_PREF_NAME "layout.css.prefixes.webkit"
+#define DISPLAY_FLOW_ROOT_ENABLED_PREF_NAME "layout.css.display-flow-root.enabled"
#define DISPLAY_CONTENTS_ENABLED_PREF_NAME "layout.css.display-contents.enabled"
#define TEXT_ALIGN_UNSAFE_ENABLED_PREF_NAME "layout.css.text-align-unsafe-value.enabled"
#define FLOAT_LOGICAL_VALUES_ENABLED_PREF_NAME "layout.css.float-logical-values.enabled"
@@ -314,6 +315,37 @@ WebkitPrefixEnabledPrefChangeCallback(const char* aPrefName, void* aClosure)
}
}
+// When the pref "layout.css.display-flow-root.enabled" changes, this function is
+// invoked to let us update kDisplayKTable, to selectively disable or restore
+// the entries for "flow-root" in that table.
+static void
+DisplayFlowRootEnabledPrefChangeCallback(const char* aPrefName, void* aClosure)
+{
+ NS_ASSERTION(strcmp(aPrefName, DISPLAY_FLOW_ROOT_ENABLED_PREF_NAME) == 0,
+ "Did you misspell " DISPLAY_FLOW_ROOT_ENABLED_PREF_NAME " ?");
+
+ static bool sIsDisplayFlowRootKeywordIndexInitialized;
+ static int32_t sIndexOfFlowRootInDisplayTable;
+ bool isDisplayFlowRootEnabled =
+ Preferences::GetBool(DISPLAY_FLOW_ROOT_ENABLED_PREF_NAME, false);
+
+ if (!sIsDisplayFlowRootKeywordIndexInitialized) {
+ // First run: find the position of "flow-root" in kDisplayKTable.
+ sIndexOfFlowRootInDisplayTable =
+ nsCSSProps::FindIndexOfKeyword(eCSSKeyword_flow_root,
+ nsCSSProps::kDisplayKTable);
+ sIsDisplayFlowRootKeywordIndexInitialized = true;
+ }
+
+ // OK -- now, stomp on or restore the "flow-root" entry in kDisplayKTable,
+ // depending on whether the pref is enabled vs. disabled.
+ if (sIndexOfFlowRootInDisplayTable >= 0) {
+ nsCSSProps::kDisplayKTable[sIndexOfFlowRootInDisplayTable].mKeyword =
+ isDisplayFlowRootEnabled ? eCSSKeyword_flow_root : eCSSKeyword_UNKNOWN;
+ }
+}
+
+
// When the pref "layout.css.display-contents.enabled" changes, this function is
// invoked to let us update kDisplayKTable, to selectively disable or restore
// the entries for "contents" in that table.
@@ -7635,6 +7667,8 @@ static const PrefCallbacks kPrefCallbacks[] = {
WebkitPrefixEnabledPrefChangeCallback },
{ TEXT_ALIGN_UNSAFE_ENABLED_PREF_NAME,
TextAlignUnsafeEnabledPrefChangeCallback },
+ { DISPLAY_FLOW_ROOT_ENABLED_PREF_NAME,
+ DisplayFlowRootEnabledPrefChangeCallback },
{ DISPLAY_CONTENTS_ENABLED_PREF_NAME,
DisplayContentsEnabledPrefChangeCallback },
{ FLOAT_LOGICAL_VALUES_ENABLED_PREF_NAME,
diff --git a/layout/base/nsPresContext.cpp b/layout/base/nsPresContext.cpp
index befb5deb2..1d90b967a 100644
--- a/layout/base/nsPresContext.cpp
+++ b/layout/base/nsPresContext.cpp
@@ -1931,33 +1931,13 @@ nsPresContext::MediaFeatureValuesChanged(nsRestyleHint aRestyleHint,
if (!PR_CLIST_IS_EMPTY(mDocument->MediaQueryLists())) {
// We build a list of all the notifications we're going to send
- // before we send any of them. (The spec says the notifications
- // should be a queued task, so any removals that happen during the
- // notifications shouldn't affect what gets notified.) Furthermore,
- // we hold strong pointers to everything we're going to make
- // notification calls to, since each notification involves calling
- // arbitrary script that might otherwise destroy these objects, or,
- // for that matter, |this|.
- //
- // Note that we intentionally send the notifications to media query
- // list in the order they were created and, for each list, to the
- // listeners in the order added.
- nsTArray<MediaQueryList::HandleChangeData> notifyList;
+ // before we send any of them.
for (PRCList *l = PR_LIST_HEAD(mDocument->MediaQueryLists());
l != mDocument->MediaQueryLists(); l = PR_NEXT_LINK(l)) {
+ nsAutoMicroTask mt;
MediaQueryList *mql = static_cast<MediaQueryList*>(l);
- mql->MediumFeaturesChanged(notifyList);
+ mql->MaybeNotify();
}
-
- if (!notifyList.IsEmpty()) {
- for (uint32_t i = 0, i_end = notifyList.Length(); i != i_end; ++i) {
- nsAutoMicroTask mt;
- MediaQueryList::HandleChangeData &d = notifyList[i];
- d.callback->Call(*d.mql);
- }
- }
-
- // NOTE: When |notifyList| goes out of scope, our destructor could run.
}
}
diff --git a/layout/base/nsPresShell.cpp b/layout/base/nsPresShell.cpp
index 63f512af4..0544a69a4 100644
--- a/layout/base/nsPresShell.cpp
+++ b/layout/base/nsPresShell.cpp
@@ -9090,6 +9090,11 @@ PresShell::DidDoReflow(bool aInterruptible)
docShell->NotifyReflowObservers(aInterruptible, mLastReflowStart, now);
}
+ // Notify resize observers on reflow.
+ if (!mPresContext->HasPendingInterrupt()) {
+ mDocument->ScheduleResizeObserversNotification();
+ }
+
if (sSynthMouseMove) {
SynthesizeMouseMove(false);
}
diff --git a/layout/forms/nsLegendFrame.cpp b/layout/forms/nsLegendFrame.cpp
index 95efc2c87..b985ed8fc 100644
--- a/layout/forms/nsLegendFrame.cpp
+++ b/layout/forms/nsLegendFrame.cpp
@@ -24,9 +24,7 @@ NS_NewLegendFrame(nsIPresShell* aPresShell, nsStyleContext* aContext)
#endif
nsIFrame* f = new (aPresShell) nsLegendFrame(aContext);
- if (f) {
- f->AddStateBits(NS_BLOCK_FLOAT_MGR | NS_BLOCK_MARGIN_ROOT);
- }
+ f->AddStateBits(NS_BLOCK_FORMATTING_CONTEXT_STATE_BITS);
return f;
}
diff --git a/layout/generic/ReflowInput.cpp b/layout/generic/ReflowInput.cpp
index 78eca8c6c..e55b629e3 100644
--- a/layout/generic/ReflowInput.cpp
+++ b/layout/generic/ReflowInput.cpp
@@ -844,6 +844,7 @@ ReflowInput::InitFrameType(nsIAtom* aFrameType)
case StyleDisplay::Flex:
case StyleDisplay::WebkitBox:
case StyleDisplay::Grid:
+ case StyleDisplay::FlowRoot:
case StyleDisplay::RubyTextContainer:
frameType = NS_CSS_FRAME_TYPE_BLOCK;
break;
diff --git a/layout/generic/crashtests/265867-1.html b/layout/generic/crashtests/265867-1.html
deleted file mode 100644
index e9da8c7f6..000000000
--- a/layout/generic/crashtests/265867-1.html
+++ /dev/null
@@ -1,11 +0,0 @@
-<HTML>
-<HEAD>
-</HEAD>
-<BODY>
-<BODY STYLE="FLOAT:RIGHT;"></BODY>
-<MARQUEE STYLE="MARGIN:99999999999px;"></MARQUEE>
-<B STYLE="FLOAT:RIGHT; PADDING:99999999999px;"></B>
-</BODY>
-</HTML>
-
-
diff --git a/layout/generic/crashtests/348510-1.html b/layout/generic/crashtests/348510-1.html
deleted file mode 100644
index 6e00e71f1..000000000
--- a/layout/generic/crashtests/348510-1.html
+++ /dev/null
@@ -1,7 +0,0 @@
-<marquee>
-<a>
-<object>
-<dd>
-<form>
-</object>
-aaaaaaa
diff --git a/layout/generic/crashtests/348510-2.html b/layout/generic/crashtests/348510-2.html
deleted file mode 100644
index 8f8c998cf..000000000
--- a/layout/generic/crashtests/348510-2.html
+++ /dev/null
@@ -1,7 +0,0 @@
-<listing>
-<marquee>
-<aa>
-<object>
-<fieldset>
-</object>
-a \ No newline at end of file
diff --git a/layout/generic/crashtests/363722-1.html b/layout/generic/crashtests/363722-1.html
deleted file mode 100644
index f83671c5a..000000000
--- a/layout/generic/crashtests/363722-1.html
+++ /dev/null
@@ -1,9 +0,0 @@
-<html>
-<body>
- <marquee style="background: yellow;">
- <marquee style="background: lightgreen;">
- I am a double-marquee.
- </marquee>
- </marquee>
-</body>
-</html>
diff --git a/layout/generic/crashtests/363722-2.html b/layout/generic/crashtests/363722-2.html
deleted file mode 100644
index 1a12a227e..000000000
--- a/layout/generic/crashtests/363722-2.html
+++ /dev/null
@@ -1,10 +0,0 @@
-<html>
-<body>
- <marquee style="background: yellow;">
- [inside OUTER marquee]
- <marquee style="background: lightgreen;">
- [inside INNER marquee]
- </marquee>
- </marquee>
-</body>
-</html>
diff --git a/layout/generic/crashtests/370866-1.xhtml b/layout/generic/crashtests/370866-1.xhtml
deleted file mode 100644
index dbc673cc4..000000000
--- a/layout/generic/crashtests/370866-1.xhtml
+++ /dev/null
@@ -1,14 +0,0 @@
-<html xmlns="http://www.w3.org/1999/xhtml">
-
-<head>
-</head>
-
-<body>
-
-<table style="display: -moz-deck;"><tbody><tr><td>
- <span style="position: relative;"><marquee><marquee><span style="position: absolute;">X</span></marquee></marquee></span>
-</td></tr></tbody></table>
-
-</body>
-
-</html>
diff --git a/layout/generic/crashtests/379917-1.xhtml b/layout/generic/crashtests/379917-1.xhtml
deleted file mode 100644
index a99bd7f4a..000000000
--- a/layout/generic/crashtests/379917-1.xhtml
+++ /dev/null
@@ -1,35 +0,0 @@
-<html xmlns="http://www.w3.org/1999/xhtml"
- xmlns:math="http://www.w3.org/1998/Math/MathML"
- class="reftest-wait">
-<head>
-<script>
-
-// This testcase uses long timeouts to make sure the marquee has a chance to animate.
-
-function boom()
-{
- var div1 = document.getElementById("div1");
- var marquee = document.getElementById("marquee");
-
- div1.parentNode.removeChild(div1);
- marquee.width = 4;
-
- setTimeout(done, 100);
-}
-
-function done()
-{
- document.documentElement.removeAttribute("class");
-}
-
-</script>
-</head>
-
-<body onload="setTimeout(boom, 100);">
-
-<math:math><div id="div1"/>x&#1506;</math:math>
-<marquee id="marquee">m</marquee>
-<div/>
-
-</body>
-</html>
diff --git a/layout/generic/crashtests/398332-3.html b/layout/generic/crashtests/398332-3.html
deleted file mode 100644
index 991aa6d3d..000000000
--- a/layout/generic/crashtests/398332-3.html
+++ /dev/null
@@ -1,4 +0,0 @@
-<marquee style="position: relative; right: 20%;">"Ë”Öqü®Û;<span style="position: relative; word-spacing: -100px;"><span style="position: absolute;">
-<style>span::before { content:"before textbefore textbefore textbefore textbefore textbefore text"; }</style>
-
-
diff --git a/layout/generic/crashtests/421671.html b/layout/generic/crashtests/421671.html
deleted file mode 100644
index e3919e635..000000000
--- a/layout/generic/crashtests/421671.html
+++ /dev/null
@@ -1,202 +0,0 @@
-<marquee>
-<xmp style="-moz-column-count: 99999999">
-
-<a>
-
-<a>
-
-<a>
-
-<a>
-
-<a>
-
-<a>
-
-<a>
-
-<a>
-
-<a>
-
-<a>
-
-<a>
-
-<a>
-
-<a>
-
-<a>
-
-<a>
-
-<a>
-
-<a>
-
-<a>
-
-<a>
-
-<a>
-
-<a>
-
-<a>
-<a>
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-<a>
-<a>
-<a>
-<a>
-
-<a>
-<a>
-
-<a>
-<a> \ No newline at end of file
diff --git a/layout/generic/crashtests/619021.html b/layout/generic/crashtests/619021.html
deleted file mode 100644
index 586c0f2db..000000000
--- a/layout/generic/crashtests/619021.html
+++ /dev/null
@@ -1,5 +0,0 @@
-<foo> <marquee> <marquee> <marquee> <marquee> <marquee> <marquee>
-<foo> <marquee> <foo> <marquee> <foo> <object> <marquee> <foo>
-<marquee> <marquee> <foo> <foo> <marquee> <marquee> <foo> <marquee>
-<marquee> <marquee> <foo> <marquee> <foo> <foo> <marquee> <marquee>
-<marquee> </marquee> <foo> <foo> <pre>
diff --git a/layout/generic/crashtests/724235.html b/layout/generic/crashtests/724235.html
deleted file mode 100644
index 7054a99f5..000000000
--- a/layout/generic/crashtests/724235.html
+++ /dev/null
@@ -1,28 +0,0 @@
-<!DOCTYPE html>
-<html>
-<head>
-<title>Testcase for bug 724235</title>
-</head>
-
-<body onload="setTimeout(function(){m=document.getElementsByTagName('marquee')[0]; m.style.fontSize='72px'},0)">
-
-<a href="#">
-
-<center>
-
-<marquee>This is a marquee ... </marquee>
-
-<table>
- <tr>
- <td><a href="#">click me to CRASH!</a></td>
- </tr>
-</table>
-
-<iframe></iframe>
-
-<script>document.body.offsetHeight;</script>
-
-<a href="#"></a>
-
-
-</body></html>
diff --git a/layout/generic/nsBlockFrame.cpp b/layout/generic/nsBlockFrame.cpp
index 57838207d..41437c8f8 100644
--- a/layout/generic/nsBlockFrame.cpp
+++ b/layout/generic/nsBlockFrame.cpp
@@ -305,7 +305,7 @@ NS_NewBlockFormattingContext(nsIPresShell* aPresShell,
nsStyleContext* aStyleContext)
{
nsBlockFrame* blockFrame = NS_NewBlockFrame(aPresShell, aStyleContext);
- blockFrame->AddStateBits(NS_BLOCK_FLOAT_MGR | NS_BLOCK_MARGIN_ROOT);
+ blockFrame->AddStateBits(NS_BLOCK_FORMATTING_CONTEXT_STATE_BITS);
return blockFrame;
}
@@ -6896,10 +6896,11 @@ nsBlockFrame::Init(nsIContent* aContent,
// (http://dev.w3.org/csswg/css-writing-modes/#block-flow)
// If the box has contain: paint (or contain: strict), then it should also
// establish a formatting context.
- if ((GetParent() && StyleVisibility()->mWritingMode !=
+ if (StyleDisplay()->mDisplay == mozilla::StyleDisplay::FlowRoot ||
+ (GetParent() && StyleVisibility()->mWritingMode !=
GetParent()->StyleVisibility()->mWritingMode) ||
StyleDisplay()->IsContainPaint()) {
- AddStateBits(NS_BLOCK_FLOAT_MGR | NS_BLOCK_MARGIN_ROOT);
+ AddStateBits(NS_BLOCK_FORMATTING_CONTEXT_STATE_BITS);
}
if ((GetStateBits() &
diff --git a/layout/generic/nsFrameStateBits.h b/layout/generic/nsFrameStateBits.h
index f8b1e541c..ba43e37d4 100644
--- a/layout/generic/nsFrameStateBits.h
+++ b/layout/generic/nsFrameStateBits.h
@@ -483,6 +483,9 @@ FRAME_STATE_BIT(Block, 22, NS_BLOCK_MARGIN_ROOT)
// used to reserve space for the floated frames.
FRAME_STATE_BIT(Block, 23, NS_BLOCK_FLOAT_MGR)
+// For setting the relevant bits on a block formatting context:
+#define NS_BLOCK_FORMATTING_CONTEXT_STATE_BITS (NS_BLOCK_FLOAT_MGR | NS_BLOCK_MARGIN_ROOT)
+
FRAME_STATE_BIT(Block, 24, NS_BLOCK_HAS_LINE_CURSOR)
FRAME_STATE_BIT(Block, 25, NS_BLOCK_HAS_OVERFLOW_LINES)
diff --git a/layout/generic/nsHTMLParts.h b/layout/generic/nsHTMLParts.h
index 89a7a6edd..b11d49e08 100644
--- a/layout/generic/nsHTMLParts.h
+++ b/layout/generic/nsHTMLParts.h
@@ -27,8 +27,7 @@ class nsTableColFrame;
// These are all the block specific frame bits, they are copied from
// the prev-in-flow to a newly created next-in-flow, except for the
// NS_BLOCK_FLAGS_NON_INHERITED_MASK bits below.
-#define NS_BLOCK_FLAGS_MASK (NS_BLOCK_MARGIN_ROOT | \
- NS_BLOCK_FLOAT_MGR | \
+#define NS_BLOCK_FLAGS_MASK (NS_BLOCK_FORMATTING_CONTEXT_STATE_BITS | \
NS_BLOCK_CLIP_PAGINATED_OVERFLOW | \
NS_BLOCK_HAS_FIRST_LETTER_STYLE | \
NS_BLOCK_FRAME_HAS_OUTSIDE_BULLET | \
diff --git a/layout/inspector/inDOMUtils.cpp b/layout/inspector/inDOMUtils.cpp
index e212e20df..2095fb775 100644
--- a/layout/inspector/inDOMUtils.cpp
+++ b/layout/inspector/inDOMUtils.cpp
@@ -846,7 +846,7 @@ PropertySupportsVariant(nsCSSPropertyID aPropertyID, uint32_t aVariant)
case eCSSProperty_grid_row_end:
case eCSSProperty_font_weight:
case eCSSProperty_initial_letter:
- supported = VARIANT_NUMBER;
+ supported = VARIANT_NUMBER | VARIANT_OPACITY;
break;
default:
@@ -909,7 +909,7 @@ inDOMUtils::CssPropertySupportsType(const nsAString& aProperty, uint32_t aType,
break;
case TYPE_NUMBER:
// Include integers under "number"?
- variant = VARIANT_NUMBER | VARIANT_INTEGER;
+ variant = VARIANT_NUMBER | VARIANT_INTEGER | VARIANT_OPACITY;
break;
default:
// Unknown type
diff --git a/layout/reftests/bidi/logicalmarquee.html b/layout/reftests/bidi/logicalmarquee.html
deleted file mode 100644
index cb13827de..000000000
--- a/layout/reftests/bidi/logicalmarquee.html
+++ /dev/null
@@ -1,11 +0,0 @@
-<!DOCTYPE HTML>
-<html>
- <head>
- <meta http-equiv="Content-type" content="text/html; charset=iso-8859-8-i">
- <title>Marquee in Logical Hebrew</title>
- </head>
-
- <body>
- <marquee scrollamount="0" behavior="alternate" direction="right">&#x05E2;&#x05D3; &#x05E9;&#x05D9;&#x05E4;&#x05D5;&#x05D7; &#x05D4;&#x05D9;&#x05D5;&#x05DD; &#x05D5;&#x05E0;&#x05E1;&#x05D5; &#x05D4;&#x05E6;&#x05DC;&#x05D9;&#x05DC;&#x05D9;&#x05DD;</marquee>
- </body>
-</html>
diff --git a/layout/reftests/bidi/marquee-ref.html b/layout/reftests/bidi/marquee-ref.html
deleted file mode 100644
index d8778dc88..000000000
--- a/layout/reftests/bidi/marquee-ref.html
+++ /dev/null
@@ -1,11 +0,0 @@
-<!DOCTYPE HTML>
-<html>
- <head>
- <meta http-equiv="Content-type" content="text/html; charset=iso-8859-8-i">
- <title>Marquee in Logical Hebrew</title>
- </head>
-
- <body>
- <div dir="rtl" align="left">&#x05E2;&#x05D3; &#x05E9;&#x05D9;&#x05E4;&#x05D5;&#x05D7; &#x05D4;&#x05D9;&#x05D5;&#x05DD; &#x05D5;&#x05E0;&#x05E1;&#x05D5; &#x05D4;&#x05E6;&#x05DC;&#x05D9;&#x05DC;&#x05D9;&#x05DD;</div>
- </body>
-</html>
diff --git a/layout/reftests/bidi/reftest-stylo.list b/layout/reftests/bidi/reftest-stylo.list
index b6a48f9ca..d0a854e7f 100644
--- a/layout/reftests/bidi/reftest-stylo.list
+++ b/layout/reftests/bidi/reftest-stylo.list
@@ -21,9 +21,6 @@ skip == bidiSVG-03.svg bidiSVG-03.svg
== bidiSVG-04.svg bidiSVG-04.svg
== bidiSVG-05.svg bidiSVG-05.svg
random-if(/^Windows\x20NT\x205\.1/.test(http.oscpu)) HTTP(..) == bidiMirroring.svg bidiMirroring.svg
-fuzzy-if(Android,9,134) random-if(layersGPUAccelerated) == visualmarquee.html visualmarquee.html
-fuzzy-if(Android,9,134) random-if(layersGPUAccelerated) == logicalmarquee.html logicalmarquee.html
-== visualmarquee.html visualmarquee.html
# test for glyph mirroring in right-to-left text
== mirroring-01.html mirroring-01.html
# quote marks are not supposed to mirror, but Unicode 5.0 said they should, so some systems do it
diff --git a/layout/reftests/bidi/reftest.list b/layout/reftests/bidi/reftest.list
index eeabd0beb..5044e657f 100644
--- a/layout/reftests/bidi/reftest.list
+++ b/layout/reftests/bidi/reftest.list
@@ -18,9 +18,6 @@ random-if(cocoaWidget) == bidi-006-j.html bidi-006-ref.html # bug 734313
fuzzy-if(skiaContent,1,1) == bidiSVG-04.svg bidiSVG-04-ref.svg
== bidiSVG-05.svg bidiSVG-05-ref.svg
random-if(/^Windows\x20NT\x205\.1/.test(http.oscpu)) HTTP(..) == bidiMirroring.svg bidiMirroring-ref.svg
-fuzzy-if(Android,9,134) random-if(layersGPUAccelerated) == visualmarquee.html marquee-ref.html
-fuzzy-if(Android,9,134) random-if(layersGPUAccelerated) == logicalmarquee.html marquee-ref.html
-== visualmarquee.html logicalmarquee.html
# test for glyph mirroring in right-to-left text
== mirroring-01.html mirroring-01-ref.html
# quote marks are not supposed to mirror, but Unicode 5.0 said they should, so some systems do it
diff --git a/layout/reftests/bidi/visualmarquee.html b/layout/reftests/bidi/visualmarquee.html
deleted file mode 100644
index 932fd775a..000000000
--- a/layout/reftests/bidi/visualmarquee.html
+++ /dev/null
@@ -1,11 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
-<html>
- <head>
- <meta http-equiv="Content-type" content="text/html; charset=iso-8859-8">
- <title>Marquee in Visual Hebrew</title>
- </head>
-
- <body>
- <marquee scrollamount="0" behavior="alternate" direction="right">&#x05DD;&#x05D9;&#x05DC;&#x05D9;&#x05DC;&#x05E6;&#x05D4; &#x05D5;&#x05E1;&#x05E0;&#x05D5; &#x05DD;&#x05D5;&#x05D9;&#x05D4; &#x05D7;&#x05D5;&#x05E4;&#x05D9;&#x05E9; &#x05D3;&#x05E2;</marquee>
- </body>
-</html>
diff --git a/layout/reftests/marquee/1160342-1.html b/layout/reftests/marquee/1160342-1.html
deleted file mode 100644
index 85e7215fb..000000000
--- a/layout/reftests/marquee/1160342-1.html
+++ /dev/null
@@ -1,10 +0,0 @@
-<html>
-<head>
-<title>Bug 1160342 - Implement marquee using mutation observers</title>
-</head>
-<body onload="document.getElementById('a').setAttribute('behavior', 'alternate')">
-<marquee id="a" scrollamount=0 direction=right>
-This text should be visible
-</marquee>
-</body>
-</html>
diff --git a/layout/reftests/marquee/1160342-2.html b/layout/reftests/marquee/1160342-2.html
deleted file mode 100644
index 99b288568..000000000
--- a/layout/reftests/marquee/1160342-2.html
+++ /dev/null
@@ -1,10 +0,0 @@
-<html>
-<head>
-<title>Bug 1160342 - Implement marquee using mutation observers</title>
-</head>
-<body onload="document.getElementById('a').setAttribute('direction', 'right')">
-<marquee id="a" behavior=alternate scrollamount=0>
-This text should be visible
-</marquee>
-</body>
-</html>
diff --git a/layout/reftests/marquee/1160342-ref.html b/layout/reftests/marquee/1160342-ref.html
deleted file mode 100644
index d56c90642..000000000
--- a/layout/reftests/marquee/1160342-ref.html
+++ /dev/null
@@ -1,10 +0,0 @@
-<html>
-<head>
-<title>Bug 1160342 - Implement marquee using mutation observers</title>
-</head>
-<body>
-<marquee id="a" behavior=alternate scrollamount=0 direction=right>
-This text should be visible
-</marquee>
-</body>
-</html>
diff --git a/layout/reftests/marquee/166591-dynamic-1-ref.html b/layout/reftests/marquee/166591-dynamic-1-ref.html
deleted file mode 100644
index a9bed7d5f..000000000
--- a/layout/reftests/marquee/166591-dynamic-1-ref.html
+++ /dev/null
@@ -1,6 +0,0 @@
-<html><head>
-</head>
-<body>
-<div id="test"><marquee behavior="alternate" scrollamount="0">dynamic marquee</marquee></div>
-</body>
-</html> \ No newline at end of file
diff --git a/layout/reftests/marquee/166591-dynamic-1.html b/layout/reftests/marquee/166591-dynamic-1.html
deleted file mode 100644
index 278b2a37b..000000000
--- a/layout/reftests/marquee/166591-dynamic-1.html
+++ /dev/null
@@ -1,11 +0,0 @@
-<html><head>
-<script>
-function init() {
- document.getElementById('test').innerHTML = '<marquee behavior="alternate" scrollamount="0">dynamic marquee</marquee>';
-}
-</script>
-</head>
-<body onload="init();">
-<div id="test"></div>
-</body>
-</html> \ No newline at end of file
diff --git a/layout/reftests/marquee/336736-1-ref.html b/layout/reftests/marquee/336736-1-ref.html
deleted file mode 100644
index 116e5ade2..000000000
--- a/layout/reftests/marquee/336736-1-ref.html
+++ /dev/null
@@ -1,5 +0,0 @@
-<html>
-<body>
-<div style="background: green; width: 50px">&nbsp;</div>
-</body>
-</html>
diff --git a/layout/reftests/marquee/336736-1a.html b/layout/reftests/marquee/336736-1a.html
deleted file mode 100644
index fb54f3060..000000000
--- a/layout/reftests/marquee/336736-1a.html
+++ /dev/null
@@ -1,13 +0,0 @@
-<html>
-<body dir="rtl">
-<!-- The "alternate" behavior is necessary for the
- marquee text to start out on the screen. -->
-<marquee
- direction="right"
- scrollamount="0"
- behavior="alternate"
->
-<div style="background: green; width: 50px">&nbsp;</div>
-</marquee>
-</body>
-</html>
diff --git a/layout/reftests/marquee/336736-1b.html b/layout/reftests/marquee/336736-1b.html
deleted file mode 100644
index 85338167c..000000000
--- a/layout/reftests/marquee/336736-1b.html
+++ /dev/null
@@ -1,13 +0,0 @@
-<html>
-<body>
-<!-- The "alternate" behavior is necessary for the
- marquee text to start out on the screen. -->
-<marquee
- direction="right"
- scrollamount="0"
- behavior="alternate"
->
-<div style="background: green; width: 50px">&nbsp;</div>
-</marquee>
-</body>
-</html>
diff --git a/layout/reftests/marquee/406073-1-ref.html b/layout/reftests/marquee/406073-1-ref.html
deleted file mode 100644
index 751bb5db7..000000000
--- a/layout/reftests/marquee/406073-1-ref.html
+++ /dev/null
@@ -1,11 +0,0 @@
-<html class="reftest-wait">
-<body style="border:3px solid;" onload="setTimeout(doe, 0)">
-<marquee behavior="alternate" scrollamount="100"><span style="background-color: lime;">marquee</span></marquee>
- <script>
- function doe() {
- document.getElementsByTagName('marquee')[0].stop();
- document.documentElement.className = "";
- }
- </script>
-</body>
-</html>
diff --git a/layout/reftests/marquee/406073-1.html b/layout/reftests/marquee/406073-1.html
deleted file mode 100644
index 01787afda..000000000
--- a/layout/reftests/marquee/406073-1.html
+++ /dev/null
@@ -1,23 +0,0 @@
-<html class="reftest-wait">
-<body style="border:3px solid;" onload="setTimeout(doe, 0)">
-<marquee behavior="alternate" scrollamount="100"><span style="background-color: lime;">marquee</span></marquee>
- <script>
- function doe() {
- document.getElementsByTagName('marquee')[0].stop();
- document.getElementsByTagName('marquee')[0].start();
- document.getElementsByTagName('marquee')[0].stop();
- document.getElementsByTagName('marquee')[0].start();
- document.getElementsByTagName('marquee')[0].stop();
- document.getElementsByTagName('marquee')[0].start();
- document.getElementsByTagName('marquee')[0].stop();
- document.getElementsByTagName('marquee')[0].start();
- document.getElementsByTagName('marquee')[0].stop();
- document.getElementsByTagName('marquee')[0].start();
- document.getElementsByTagName('marquee')[0].stop();
- document.getElementsByTagName('marquee')[0].start();
- document.getElementsByTagName('marquee')[0].stop();
- document.documentElement.className = "";
- }
- </script>
-</body>
-</html>
diff --git a/layout/reftests/marquee/407016-2-ref.html b/layout/reftests/marquee/407016-2-ref.html
deleted file mode 100644
index 25fee1b7d..000000000
--- a/layout/reftests/marquee/407016-2-ref.html
+++ /dev/null
@@ -1,5 +0,0 @@
-<html>
-<body>
-<div style="background-color: lime; height: 50px;"></div>
-</body>
-</html>
diff --git a/layout/reftests/marquee/407016-2.html b/layout/reftests/marquee/407016-2.html
deleted file mode 100644
index 65e1273b9..000000000
--- a/layout/reftests/marquee/407016-2.html
+++ /dev/null
@@ -1,7 +0,0 @@
-<html>
-<body>
-<marquee scrollamount="0" style="height: 50px; background-color: lime;">
-<div style="width: 9999px;">&nbsp;</div>
-</marquee>
-</body>
-</html>
diff --git a/layout/reftests/marquee/413027-4-ref.html b/layout/reftests/marquee/413027-4-ref.html
deleted file mode 100644
index 22fdd42e6..000000000
--- a/layout/reftests/marquee/413027-4-ref.html
+++ /dev/null
@@ -1,10 +0,0 @@
-<html><head>
-<title>Testcase for bug 413027 - Marquee height is sized too small, clipping text vertically</title>
-</head>
-<body>
-
-<div style="background-color: lime; width: 600px; float:left;">
- <div style="margin: 100px 0px; padding-left: 2px;">text</div>
-</div>
-
-</body></html>
diff --git a/layout/reftests/marquee/413027-4.html b/layout/reftests/marquee/413027-4.html
deleted file mode 100644
index d57f2f121..000000000
--- a/layout/reftests/marquee/413027-4.html
+++ /dev/null
@@ -1,15 +0,0 @@
-<html><head>
-<title>Testcase for bug 413027 - Marquee height is sized too small, clipping text vertically</title>
-</head>
-<body>
-
-<marquee scrollamount="0" behavior="alternate" direction="right" style="background-color: lime; width: 600px;">
-<div>
-<!-- padding-left used to avoid risk of an antialiasing pixel that may
- project to the left of the origin, causing a spurious test failure
- (see bugs 476927, 475968) -->
- <div style="margin: 100px 0px; padding-left: 2px;">text</div>
-</div>
-</marquee>
-
-</body></html>
diff --git a/layout/reftests/marquee/425247-1-ref.html b/layout/reftests/marquee/425247-1-ref.html
deleted file mode 100644
index 3b3a84d41..000000000
--- a/layout/reftests/marquee/425247-1-ref.html
+++ /dev/null
@@ -1,9 +0,0 @@
-<html><head>
-<title>Bug 425247 – Marquee with uppercase UP or DOWN as direction doesn't work properly</title>
-</head>
-<body>
-<marquee direction="up" bgcolor="magenta" behavior="alternate" scrollamount="0">
-<marquee bgcolor="yellow" behavior="alternate" scrollamount="0">marquee up</marquee>
-</marquee>
-</body>
-</html> \ No newline at end of file
diff --git a/layout/reftests/marquee/425247-1.html b/layout/reftests/marquee/425247-1.html
deleted file mode 100644
index dfa5021c4..000000000
--- a/layout/reftests/marquee/425247-1.html
+++ /dev/null
@@ -1,9 +0,0 @@
-<html><head>
-<title>Bug 425247 – Marquee with uppercase UP or DOWN as direction doesn't work properly</title>
-</head>
-<body>
-<MARQUEE DIRECTION=UP BGCOLOR=MAGENTA BEHAVIOR=ALTERNATE SCROLLAMOUNT=0>
-<MARQUEE BGCOLOR=YELLOW BEHAVIOR=ALTERNATE SCROLLAMOUNT=0>marquee up</MARQUEE>
-</MARQUEE>
-</body>
-</html> \ No newline at end of file
diff --git a/layout/reftests/marquee/425247-2-ref.html b/layout/reftests/marquee/425247-2-ref.html
deleted file mode 100644
index 564d74979..000000000
--- a/layout/reftests/marquee/425247-2-ref.html
+++ /dev/null
@@ -1,9 +0,0 @@
-<html><head>
-<title>Bug 425247 – Marquee with uppercase UP or DOWN as direction doesn't work properly</title>
-</head>
-<body>
-<marquee direction="down" bgcolor="magenta" behavior="alternate" scrollamount="0">
-<marquee bgcolor="yellow" behavior="alternate" scrollamount="0">marquee down</marquee>
-</marquee>
-</body>
-</html> \ No newline at end of file
diff --git a/layout/reftests/marquee/425247-2.html b/layout/reftests/marquee/425247-2.html
deleted file mode 100644
index 4cb66b901..000000000
--- a/layout/reftests/marquee/425247-2.html
+++ /dev/null
@@ -1,9 +0,0 @@
-<html><head>
-<title>Bug 425247 – Marquee with uppercase UP or DOWN as direction doesn't work properly</title>
-</head>
-<body>
-<MARQUEE DIRECTION=DOWN BGCOLOR=MAGENTA BEHAVIOR=ALTERNATE SCROLLAMOUNT=0>
-<MARQUEE BGCOLOR=YELLOW BEHAVIOR=ALTERNATE SCROLLAMOUNT=0>marquee down</MARQUEE>
-</MARQUEE>
-</body>
-</html> \ No newline at end of file
diff --git a/layout/reftests/marquee/429849-1-ref.html b/layout/reftests/marquee/429849-1-ref.html
deleted file mode 100644
index 3b9c3166e..000000000
--- a/layout/reftests/marquee/429849-1-ref.html
+++ /dev/null
@@ -1,10 +0,0 @@
-<html>
-<head>
-<title>Bug 429849 – marquee text not on one line , part of this line on top and second part on bottom</title>
-</head>
-<body>
-<marquee behavior=alternate scrollamount=0 direction=right>
-This text should be on one line
-</marquee>
-</body>
-</html>
diff --git a/layout/reftests/marquee/429849-1.html b/layout/reftests/marquee/429849-1.html
deleted file mode 100644
index 6b1757fd0..000000000
--- a/layout/reftests/marquee/429849-1.html
+++ /dev/null
@@ -1,10 +0,0 @@
-<html>
-<head>
-<title>Bug 429849 – marquee text not on one line , part of this line on top and second part on bottom</title>
-</head>
-<body>
-<marquee behavior=alternate scrollamount=0 direction=right>
-This text <script>document.body.offsetHeight;</script>should be on one line
-</marquee>
-</body>
-</html>
diff --git a/layout/reftests/marquee/reftest-stylo.list b/layout/reftests/marquee/reftest-stylo.list
deleted file mode 100644
index 26c77acf9..000000000
--- a/layout/reftests/marquee/reftest-stylo.list
+++ /dev/null
@@ -1,16 +0,0 @@
-# DO NOT EDIT! This is a auto-generated temporary list for Stylo testing
-random-if((B2G&&browserIsRemote)||Mulet) == 166591-dynamic-1.html 166591-dynamic-1.html
-# Initial mulet triage: parity with B2G/B2G Desktop
-skip-if(B2G) fuzzy-if(Android,8,50) == 336736-1a.html 336736-1a.html
-# Bug 1168747 for random b2g timeouts
-skip-if(B2G) fuzzy-if(Android,8,50) == 336736-1b.html 336736-1b.html
-# Bug 1168747 for random b2g timeouts
-== 406073-1.html 406073-1.html
-== 407016-2.html 407016-2.html
-fuzzy-if(Android,8,220) == 413027-4.html 413027-4.html
-fuzzy-if(Android,8,30) == 425247-1.html 425247-1.html
-fuzzy-if(Android,8,30) == 425247-2.html 425247-2.html
-random == 429849-1.html 429849-1.html
-# bug 432288
-== 1160342-1.html 1160342-1.html
-== 1160342-2.html 1160342-2.html
diff --git a/layout/reftests/marquee/reftest.list b/layout/reftests/marquee/reftest.list
deleted file mode 100644
index f033b4634..000000000
--- a/layout/reftests/marquee/reftest.list
+++ /dev/null
@@ -1,11 +0,0 @@
-== 166591-dynamic-1.html 166591-dynamic-1-ref.html
-fuzzy-if(Android,8,50) == 336736-1a.html 336736-1-ref.html
-fuzzy-if(Android,8,50) == 336736-1b.html 336736-1-ref.html
-== 406073-1.html 406073-1-ref.html
-== 407016-2.html 407016-2-ref.html
-fuzzy-if(Android,8,220) == 413027-4.html 413027-4-ref.html
-fuzzy-if(Android,8,30) == 425247-1.html 425247-1-ref.html
-fuzzy-if(Android,8,30) == 425247-2.html 425247-2-ref.html
-random == 429849-1.html 429849-1-ref.html # bug 432288
-== 1160342-1.html 1160342-ref.html
-== 1160342-2.html 1160342-ref.html
diff --git a/layout/reftests/moz.build b/layout/reftests/moz.build
index d486e5639..3ab3d4246 100644
--- a/layout/reftests/moz.build
+++ b/layout/reftests/moz.build
@@ -201,8 +201,6 @@ with Files('list-item/**'):
BUG_COMPONENT = ('Core', 'Layout: Block and Inline')
with Files('margin-collapsing/**'):
BUG_COMPONENT = ('Core', 'Layout: Block and Inline')
-with Files('marquee/**'):
- BUG_COMPONENT = ('Core', 'CSS Parsing and Computation')
with Files('mathml/**'):
BUG_COMPONENT = ('Core', 'MathML')
with Files('native-theme/**'):
diff --git a/layout/reftests/reftest-stylo.list b/layout/reftests/reftest-stylo.list
index 7d4078f22..54afc3dac 100644
--- a/layout/reftests/reftest-stylo.list
+++ b/layout/reftests/reftest-stylo.list
@@ -249,9 +249,6 @@ include mathml/reftest-stylo.list
# margin-collapsing
include margin-collapsing/reftest-stylo.list
-# marquee/
-include marquee/reftest-stylo.list
-
# native-theme/
# skipping for B2G since something around radio-nonnative.html makes the whole suite hang
skip-if(B2G||Android||Mulet) include native-theme/reftest-stylo.list
diff --git a/layout/reftests/reftest.list b/layout/reftests/reftest.list
index b2da025d5..b06eba58e 100644
--- a/layout/reftests/reftest.list
+++ b/layout/reftests/reftest.list
@@ -247,9 +247,6 @@ include mathml/reftest.list
# margin-collapsing
include margin-collapsing/reftest.list
-# marquee/
-include marquee/reftest.list
-
# native-theme/
# (no XUL theme on Android)
skip-if(Android) include native-theme/reftest.list
diff --git a/layout/reftests/writing-mode/reftest-stylo.list b/layout/reftests/writing-mode/reftest-stylo.list
index 5574d9b5b..76f6813e6 100644
--- a/layout/reftests/writing-mode/reftest-stylo.list
+++ b/layout/reftests/writing-mode/reftest-stylo.list
@@ -65,8 +65,6 @@ HTTP(..) == 1115916-1-vertical-metrics.html 1115916-1-vertical-metrics.html
== ua-style-sheet-border-3.html ua-style-sheet-border-3.html
== ua-style-sheet-border-4.html ua-style-sheet-border-4.html
== ua-style-sheet-border-5.html ua-style-sheet-border-5.html
-== ua-style-sheet-size-1.html ua-style-sheet-size-1.html
-== ua-style-sheet-size-2.html ua-style-sheet-size-2.html
== ua-style-sheet-fieldset-1.html ua-style-sheet-fieldset-1.html
skip-if(Android||B2G||Mulet||(winWidget&&!/^Windows\x20NT\x205\.1/.test(http.oscpu))) == ua-style-sheet-textarea-1.html ua-style-sheet-textarea-1.html
diff --git a/layout/reftests/writing-mode/reftest.list b/layout/reftests/writing-mode/reftest.list
index b670dbd13..13c58d2cb 100644
--- a/layout/reftests/writing-mode/reftest.list
+++ b/layout/reftests/writing-mode/reftest.list
@@ -58,8 +58,6 @@ fuzzy(116,94) fuzzy-if(winWidget,135,124) HTTP(..) == 1115916-1-vertical-metrics
== ua-style-sheet-border-3.html ua-style-sheet-border-3-ref.html
== ua-style-sheet-border-4.html ua-style-sheet-border-4-ref.html
== ua-style-sheet-border-5.html ua-style-sheet-border-5-ref.html
-== ua-style-sheet-size-1.html ua-style-sheet-size-1-ref.html
-== ua-style-sheet-size-2.html ua-style-sheet-size-2-ref.html
== ua-style-sheet-fieldset-1.html ua-style-sheet-fieldset-1-ref.html
skip-if(Android||(winWidget&&!/^Windows\x20NT\x205\.1/.test(http.oscpu))) == ua-style-sheet-textarea-1.html ua-style-sheet-textarea-1a-ref.html
diff --git a/layout/reftests/writing-mode/ua-style-sheet-size-1-ref.html b/layout/reftests/writing-mode/ua-style-sheet-size-1-ref.html
deleted file mode 100644
index 06f6d5700..000000000
--- a/layout/reftests/writing-mode/ua-style-sheet-size-1-ref.html
+++ /dev/null
@@ -1,22 +0,0 @@
-<!DOCTYPE html>
-<meta charset=utf-8>
-<title>Test for logical margins on marquee elements in the UA style sheet</title>
-<style>
-.v-rl { writing-mode: vertical-rl; }
-.ltr, .rtl, .v-rl { border: 1px solid blue; padding: 16px; }
-marquee { background-color: yellow; color: transparent; }
-.ltr marquee { width: -moz-available; height: auto; }
-.rtl marquee { width: -moz-available; height: auto; }
-.v-rl marquee { width: auto; height: -moz-available; }
-</style>
-<div class=ltr>
- <marquee>A</marquee>
-</div>
-<div class=rtl dir=rtl>
- <marquee>A</marquee>
-</div>
-<!-- disabled until bug 1132308
-<div class=v-rl>
- <marquee>A</marquee>
-</div>
--->
diff --git a/layout/reftests/writing-mode/ua-style-sheet-size-1.html b/layout/reftests/writing-mode/ua-style-sheet-size-1.html
deleted file mode 100644
index 754908501..000000000
--- a/layout/reftests/writing-mode/ua-style-sheet-size-1.html
+++ /dev/null
@@ -1,19 +0,0 @@
-<!DOCTYPE html>
-<meta charset=utf-8>
-<title>Test for logical sizes on marquee elements in the UA style sheet</title>
-<style>
-.v-rl { writing-mode: vertical-rl; }
-.ltr, .rtl, .v-rl { border: 1px solid blue; padding: 16px; }
-marquee { background-color: yellow; color: transparent; }
-</style>
-<div class=ltr>
- <marquee>A</marquee>
-</div>
-<div class=rtl dir=rtl>
- <marquee>A</marquee>
-</div>
-<!-- disabled until bug 1132308
-<div class=v-rl>
- <marquee>A</marquee>
-</div>
--->
diff --git a/layout/reftests/writing-mode/ua-style-sheet-size-2-ref.html b/layout/reftests/writing-mode/ua-style-sheet-size-2-ref.html
deleted file mode 100644
index 3c53326ba..000000000
--- a/layout/reftests/writing-mode/ua-style-sheet-size-2-ref.html
+++ /dev/null
@@ -1,22 +0,0 @@
-<!DOCTYPE html>
-<meta charset=utf-8>
-<title>Test for logical margins on marquee elements in the UA style sheet</title>
-<style>
-.v-rl { writing-mode: vertical-rl; }
-.ltr, .rtl, .v-rl { border: 1px solid blue; padding: 16px; }
-marquee { background-color: yellow; color: transparent; }
-.ltr marquee { width: -moz-available; height: 200px; }
-.rtl marquee { width: -moz-available; height: 200px; }
-.v-rl marquee { width: 200px; height: -moz-available; }
-</style>
-<div class=ltr>
- <marquee direction=down>A</marquee>
-</div>
-<div class=rtl dir=rtl>
- <marquee direction=down>A</marquee>
-</div>
-<!-- disabled until bug 1132308
-<div class=v-rl>
- <marquee direction=down>A</marquee>
-</div>
--->
diff --git a/layout/reftests/writing-mode/ua-style-sheet-size-2.html b/layout/reftests/writing-mode/ua-style-sheet-size-2.html
deleted file mode 100644
index 1c0be6f4b..000000000
--- a/layout/reftests/writing-mode/ua-style-sheet-size-2.html
+++ /dev/null
@@ -1,19 +0,0 @@
-<!DOCTYPE html>
-<meta charset=utf-8>
-<title>Test for logical sizes on marquee elements in the UA style sheet</title>
-<style>
-.v-rl { writing-mode: vertical-rl; }
-.ltr, .rtl, .v-rl { border: 1px solid blue; padding: 16px; }
-marquee { background-color: yellow; color: transparent; }
-</style>
-<div class=ltr>
- <marquee direction=down>A</marquee>
-</div>
-<div class=rtl dir=rtl>
- <marquee direction=down>A</marquee>
-</div>
-<!-- disabled until bug 1132308
-<div class=v-rl>
- <marquee direction=down>A</marquee>
-</div>
--->
diff --git a/layout/style/Loader.cpp b/layout/style/Loader.cpp
index df523174d..a06dd3737 100644
--- a/layout/style/Loader.cpp
+++ b/layout/style/Loader.cpp
@@ -2272,7 +2272,6 @@ Loader::LoadChildSheet(StyleSheet* aParentSheet,
state = eSheetComplete;
} else {
bool isAlternate;
- bool isExplicitlyEnabled;
const nsSubstring& empty = EmptyString();
// For now, use CORS_NONE for child sheets
rv = CreateSheet(aURL, nullptr, principal,
@@ -2282,8 +2281,9 @@ Loader::LoadChildSheet(StyleSheet* aParentSheet,
parentData ? parentData->mSyncLoad : false,
false, empty, state, &isAlternate, &sheet);
NS_ENSURE_SUCCESS(rv, rv);
-
- PrepareSheet(sheet, empty, empty, aMedia, nullptr, isAlternate, isExplicitlyEnabled);
+ // For now, child sheets are not explicitly enabled (seventh argument is
+ // always false here).
+ PrepareSheet(sheet, empty, empty, aMedia, nullptr, isAlternate, false);
}
rv = InsertChildSheet(sheet, aParentSheet, aParentRule);
@@ -2396,7 +2396,6 @@ Loader::InternalLoadNonDocumentSheet(nsIURI* aURL,
StyleSheetState state;
bool isAlternate;
- bool isExplicitlyEnabled;
RefPtr<StyleSheet> sheet;
bool syncLoad = (aObserver == nullptr);
const nsSubstring& empty = EmptyString();
@@ -2406,7 +2405,10 @@ Loader::InternalLoadNonDocumentSheet(nsIURI* aURL,
false, empty, state, &isAlternate, &sheet);
NS_ENSURE_SUCCESS(rv, rv);
- PrepareSheet(sheet, empty, empty, nullptr, nullptr, isAlternate, isExplicitlyEnabled);
+ // Sheets can only be explicitly enabled after creation and preparation, so
+ // we always pass false for the initial value of the explicitly enabled flag
+ // when calling PrepareSheet.
+ PrepareSheet(sheet, empty, empty, nullptr, nullptr, isAlternate, false);
if (state == eSheetComplete) {
LOG((" Sheet already complete"));
diff --git a/layout/style/MediaQueryList.cpp b/layout/style/MediaQueryList.cpp
index db3781b76..5838645be 100644
--- a/layout/style/MediaQueryList.cpp
+++ b/layout/style/MediaQueryList.cpp
@@ -1,5 +1,4 @@
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
-/* vim: set shiftwidth=2 tabstop=8 autoindent cindent expandtab: */
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
@@ -7,19 +6,26 @@
/* implements DOM interface for querying and observing media queries */
#include "mozilla/dom/MediaQueryList.h"
+#include "mozilla/dom/MediaQueryListEvent.h"
+#include "mozilla/dom/EventTarget.h"
+#include "mozilla/dom/EventTargetBinding.h"
#include "nsPresContext.h"
#include "nsIMediaList.h"
#include "nsCSSParser.h"
#include "nsIDocument.h"
+// Fixed event target type
+#define ONCHANGE_STRING NS_LITERAL_STRING("change")
+
namespace mozilla {
namespace dom {
MediaQueryList::MediaQueryList(nsIDocument *aDocument,
const nsAString &aMediaQueryList)
- : mDocument(aDocument),
- mMediaList(new nsMediaList),
- mMatchesValid(false)
+ : mDocument(aDocument)
+ , mMediaList(new nsMediaList)
+ , mMatchesValid(false)
+ , mIsKeptAlive(false)
{
PR_INIT_CLIST(this);
@@ -36,30 +42,24 @@ MediaQueryList::~MediaQueryList()
NS_IMPL_CYCLE_COLLECTION_CLASS(MediaQueryList)
-NS_IMPL_CYCLE_COLLECTION_TRAVERSE_BEGIN(MediaQueryList)
+NS_IMPL_CYCLE_COLLECTION_TRAVERSE_BEGIN_INHERITED(MediaQueryList, DOMEventTargetHelper)
NS_IMPL_CYCLE_COLLECTION_TRAVERSE(mDocument)
- NS_IMPL_CYCLE_COLLECTION_TRAVERSE(mCallbacks)
NS_IMPL_CYCLE_COLLECTION_TRAVERSE_END
-NS_IMPL_CYCLE_COLLECTION_UNLINK_BEGIN(MediaQueryList)
+NS_IMPL_CYCLE_COLLECTION_UNLINK_BEGIN_INHERITED(MediaQueryList, DOMEventTargetHelper)
if (tmp->mDocument) {
PR_REMOVE_LINK(tmp);
NS_IMPL_CYCLE_COLLECTION_UNLINK(mDocument)
}
- tmp->RemoveAllListeners();
+ tmp->Disconnect();
NS_IMPL_CYCLE_COLLECTION_UNLINK_PRESERVED_WRAPPER
NS_IMPL_CYCLE_COLLECTION_UNLINK_END
-NS_IMPL_CYCLE_COLLECTION_TRACE_WRAPPERCACHE(MediaQueryList)
-
-NS_INTERFACE_MAP_BEGIN(MediaQueryList)
- NS_WRAPPERCACHE_INTERFACE_MAP_ENTRY
- NS_INTERFACE_MAP_ENTRY(nsISupports)
- NS_INTERFACE_MAP_ENTRIES_CYCLE_COLLECTION(MediaQueryList)
-NS_INTERFACE_MAP_END
+NS_INTERFACE_MAP_BEGIN_CYCLE_COLLECTION_INHERITED(MediaQueryList)
+NS_INTERFACE_MAP_END_INHERITING(DOMEventTargetHelper)
-NS_IMPL_CYCLE_COLLECTING_ADDREF(MediaQueryList)
-NS_IMPL_CYCLE_COLLECTING_RELEASE(MediaQueryList)
+NS_IMPL_ADDREF_INHERITED(MediaQueryList, DOMEventTargetHelper)
+NS_IMPL_RELEASE_INHERITED(MediaQueryList, DOMEventTargetHelper)
void
MediaQueryList::GetMedia(nsAString &aMedia)
@@ -80,57 +80,124 @@ MediaQueryList::Matches()
}
void
-MediaQueryList::AddListener(MediaQueryListListener& aListener)
+MediaQueryList::AddListener(EventListener* aListener, ErrorResult& aRv)
{
- if (!HasListeners()) {
- // When we have listeners, the pres context owns a reference to
- // this. This is a cyclic reference that can only be broken by
- // cycle collection.
- NS_ADDREF_THIS();
+ if (!aListener) {
+ return;
}
+ AddEventListenerOptionsOrBoolean options;
+ options.SetAsBoolean() = false;
+
+ AddEventListener(ONCHANGE_STRING, aListener, options, Nullable<bool>(), aRv);
+}
+
+void
+MediaQueryList::AddEventListener(const nsAString& aType,
+ EventListener* aCallback,
+ const AddEventListenerOptionsOrBoolean& aOptions,
+ const dom::Nullable<bool>& aWantsUntrusted,
+ ErrorResult& aRv)
+{
if (!mMatchesValid) {
MOZ_ASSERT(!HasListeners(),
"when listeners present, must keep mMatches current");
RecomputeMatches();
}
- for (uint32_t i = 0; i < mCallbacks.Length(); ++i) {
- if (aListener == *mCallbacks[i]) {
- // Already registered
- return;
- }
+ DOMEventTargetHelper::AddEventListener(aType, aCallback, aOptions,
+ aWantsUntrusted, aRv);
+
+ if (aRv.Failed()) {
+ return;
}
- if (!mCallbacks.AppendElement(&aListener, fallible)) {
- if (!HasListeners()) {
- // Append failed; undo the AddRef above.
- NS_RELEASE_THIS();
- }
+ UpdateMustKeepAlive();
+}
+
+void
+MediaQueryList::RemoveListener(EventListener* aListener, ErrorResult& aRv)
+{
+ if (!aListener) {
+ return;
}
+
+ EventListenerOptionsOrBoolean options;
+ options.SetAsBoolean() = false;
+
+ RemoveEventListener(ONCHANGE_STRING, aListener, options, aRv);
}
void
-MediaQueryList::RemoveListener(MediaQueryListListener& aListener)
-{
- for (uint32_t i = 0; i < mCallbacks.Length(); ++i) {
- if (aListener == *mCallbacks[i]) {
- mCallbacks.RemoveElementAt(i);
- if (!HasListeners()) {
- // See NS_ADDREF_THIS() in AddListener.
- NS_RELEASE_THIS();
- }
- break;
- }
+MediaQueryList::RemoveEventListener(const nsAString& aType,
+ EventListener* aCallback,
+ const EventListenerOptionsOrBoolean& aOptions,
+ ErrorResult& aRv)
+{
+ DOMEventTargetHelper::RemoveEventListener(aType, aCallback, aOptions, aRv);
+
+ if (aRv.Failed()) {
+ return;
+ }
+
+ UpdateMustKeepAlive();
+}
+
+EventHandlerNonNull*
+MediaQueryList::GetOnchange()
+{
+ if (NS_IsMainThread()) {
+ return GetEventHandler(nsGkAtoms::onchange, EmptyString());
+ }
+ return GetEventHandler(nullptr, ONCHANGE_STRING);
+}
+
+void
+MediaQueryList::SetOnchange(EventHandlerNonNull* aCallback)
+{
+ if (NS_IsMainThread()) {
+ SetEventHandler(nsGkAtoms::onchange, EmptyString(), aCallback);
+ } else {
+ SetEventHandler(nullptr, ONCHANGE_STRING, aCallback);
}
+
+ UpdateMustKeepAlive();
}
void
-MediaQueryList::RemoveAllListeners()
+MediaQueryList::UpdateMustKeepAlive()
{
- bool hadListeners = HasListeners();
- mCallbacks.Clear();
- if (hadListeners) {
+ bool toKeepAlive = HasListeners();
+ if (toKeepAlive == mIsKeptAlive) {
+ return;
+ }
+
+ // When we have listeners, the pres context owns a reference to
+ // this. This is a cyclic reference that can only be broken by
+ // cycle collection.
+
+ mIsKeptAlive = toKeepAlive;
+
+ if (toKeepAlive) {
+ NS_ADDREF_THIS();
+ } else {
+ NS_RELEASE_THIS();
+ }
+}
+
+bool
+MediaQueryList::HasListeners()
+{
+ return HasListenersFor(ONCHANGE_STRING);
+}
+
+void
+MediaQueryList::Disconnect()
+{
+ DisconnectFromOwner();
+
+ if (mIsKeptAlive) {
+ mIsKeptAlive = false;
// See NS_ADDREF_THIS() in AddListener.
NS_RELEASE_THIS();
}
@@ -169,27 +236,6 @@ MediaQueryList::RecomputeMatches()
mMatchesValid = true;
}
-void
-MediaQueryList::MediumFeaturesChanged(
- nsTArray<HandleChangeData>& aListenersToNotify)
-{
- mMatchesValid = false;
-
- if (HasListeners()) {
- bool oldMatches = mMatches;
- RecomputeMatches();
- if (mMatches != oldMatches) {
- for (uint32_t i = 0, i_end = mCallbacks.Length(); i != i_end; ++i) {
- HandleChangeData *d = aListenersToNotify.AppendElement(fallible);
- if (d) {
- d->mql = this;
- d->callback = mCallbacks[i];
- }
- }
- }
- }
-}
-
nsISupports*
MediaQueryList::GetParentObject() const
{
@@ -202,5 +248,36 @@ MediaQueryList::WrapObject(JSContext* aCx, JS::Handle<JSObject*> aGivenProto)
return MediaQueryListBinding::Wrap(aCx, this, aGivenProto);
}
+void
+MediaQueryList::MaybeNotify()
+{
+ mMatchesValid = false;
+
+ if (!HasListeners()) {
+ return;
+ }
+
+ bool oldMatches = mMatches;
+ RecomputeMatches();
+
+ // No need to notify the change.
+ if (mMatches == oldMatches) {
+ return;
+ }
+
+ MediaQueryListEventInit init;
+ init.mBubbles = false;
+ init.mCancelable = false;
+ init.mMatches = mMatches;
+ mMediaList->GetText(init.mMedia);
+
+ RefPtr<MediaQueryListEvent> event =
+ MediaQueryListEvent::Constructor(this, ONCHANGE_STRING, init);
+ event->SetTrusted(true);
+
+ bool dummy;
+ DispatchEvent(event, &dummy);
+}
+
} // namespace dom
} // namespace mozilla
diff --git a/layout/style/MediaQueryList.h b/layout/style/MediaQueryList.h
index 5ba568528..d2acb34c1 100644
--- a/layout/style/MediaQueryList.h
+++ b/layout/style/MediaQueryList.h
@@ -16,6 +16,7 @@
#include "prclist.h"
#include "mozilla/Attributes.h"
#include "nsWrapperCache.h"
+#include "mozilla/DOMEventTargetHelper.h"
#include "mozilla/dom/MediaQueryListBinding.h"
class nsIDocument;
@@ -24,8 +25,7 @@ class nsMediaList;
namespace mozilla {
namespace dom {
-class MediaQueryList final : public nsISupports,
- public nsWrapperCache,
+class MediaQueryList final : public DOMEventTargetHelper,
public PRCList
{
public:
@@ -37,33 +37,45 @@ private:
~MediaQueryList();
public:
- NS_DECL_CYCLE_COLLECTING_ISUPPORTS
- NS_DECL_CYCLE_COLLECTION_SCRIPT_HOLDER_CLASS(MediaQueryList)
+ NS_DECL_ISUPPORTS_INHERITED
+ NS_DECL_CYCLE_COLLECTION_CLASS_INHERITED(MediaQueryList, DOMEventTargetHelper)
nsISupports* GetParentObject() const;
- struct HandleChangeData {
- RefPtr<MediaQueryList> mql;
- RefPtr<mozilla::dom::MediaQueryListListener> callback;
- };
-
- // Appends listeners that need notification to aListenersToNotify
- void MediumFeaturesChanged(nsTArray<HandleChangeData>& aListenersToNotify);
-
- bool HasListeners() const { return !mCallbacks.IsEmpty(); }
-
- void RemoveAllListeners();
+ void MaybeNotify();
JSObject* WrapObject(JSContext* aCx, JS::Handle<JSObject*> aGivenProto) override;
// WebIDL methods
void GetMedia(nsAString& aMedia);
bool Matches();
- void AddListener(mozilla::dom::MediaQueryListListener& aListener);
- void RemoveListener(mozilla::dom::MediaQueryListListener& aListener);
+ void AddListener(EventListener* aListener, ErrorResult& aRv);
+ void RemoveListener(EventListener* aListener, ErrorResult& aRv);
+
+ EventHandlerNonNull* GetOnchange();
+ void SetOnchange(EventHandlerNonNull* aCallback);
+
+ using nsIDOMEventTarget::AddEventListener;
+ using nsIDOMEventTarget::RemoveEventListener;
+
+ virtual void AddEventListener(const nsAString& aType,
+ EventListener* aCallback,
+ const AddEventListenerOptionsOrBoolean& aOptions,
+ const Nullable<bool>& aWantsUntrusted,
+ ErrorResult& aRv) override;
+ virtual void RemoveEventListener(const nsAString& aType,
+ EventListener* aCallback,
+ const EventListenerOptionsOrBoolean& aOptions,
+ ErrorResult& aRv) override;
+
+ bool HasListeners();
+
+ void Disconnect();
private:
void RecomputeMatches();
+
+ void UpdateMustKeepAlive();
// We only need a pointer to the document to support lazy
// reevaluation following dynamic changes. However, this lazy
@@ -84,7 +96,7 @@ private:
RefPtr<nsMediaList> mMediaList;
bool mMatches;
bool mMatchesValid;
- nsTArray<RefPtr<mozilla::dom::MediaQueryListListener>> mCallbacks;
+ bool mIsKeptAlive;
};
} // namespace dom
diff --git a/layout/style/contenteditable.css b/layout/style/contenteditable.css
index c550bc7c9..6d569f75e 100644
--- a/layout/style/contenteditable.css
+++ b/layout/style/contenteditable.css
@@ -80,15 +80,6 @@ input[contenteditable="true"][type="file"] {
-moz-user-focus: none !important;
}
-/* emulation of non-standard HTML <marquee> tag */
-marquee:-moz-read-write {
- -moz-binding: url('chrome://xbl-marquee/content/xbl-marquee.xml#marquee-horizontal-editable');
-}
-
-marquee[direction="up"]:-moz-read-write, marquee[direction="down"]:-moz-read-write {
- -moz-binding: url('chrome://xbl-marquee/content/xbl-marquee.xml#marquee-vertical-editable');
-}
-
*|*:-moz-read-write > input[type="hidden"],
input[contenteditable="true"][type="hidden"] {
border: 1px solid black !important;
diff --git a/layout/style/moz.build b/layout/style/moz.build
index ff06b5101..bdc86ee99 100644
--- a/layout/style/moz.build
+++ b/layout/style/moz.build
@@ -19,7 +19,6 @@ with Files('CSSRuleList.*'):
with Files('nsDOM*'):
BUG_COMPONENT = ('Core', 'DOM: CSS Object Model')
-DIRS += ['xbl-marquee']
TEST_DIRS += ['test']
XPIDL_SOURCES += [
diff --git a/layout/style/nsCSSKeywordList.h b/layout/style/nsCSSKeywordList.h
index 34a46ffce..9045da9ff 100644
--- a/layout/style/nsCSSKeywordList.h
+++ b/layout/style/nsCSSKeywordList.h
@@ -285,6 +285,7 @@ CSS_KEY(flex, flex)
CSS_KEY(flex-end, flex_end)
CSS_KEY(flex-start, flex_start)
CSS_KEY(flip, flip)
+CSS_KEY(flow-root, flow_root)
CSS_KEY(forwards, forwards)
CSS_KEY(fraktur, fraktur)
CSS_KEY(from-image, from_image)
diff --git a/layout/style/nsCSSParser.cpp b/layout/style/nsCSSParser.cpp
index 556e35406..1525c5f9a 100644
--- a/layout/style/nsCSSParser.cpp
+++ b/layout/style/nsCSSParser.cpp
@@ -1300,7 +1300,7 @@ protected:
}
bool ParseNonNegativeNumber(nsCSSValue& aValue)
{
- return ParseSingleTokenNonNegativeVariant(aValue, VARIANT_NUMBER, nullptr);
+ return ParseSingleTokenNonNegativeVariant(aValue, VARIANT_NUMBER | VARIANT_OPACITY, nullptr);
}
// Helpers for some common ParseSingleTokenOneOrLargerVariant calls.
@@ -1310,7 +1310,7 @@ protected:
}
bool ParseOneOrLargerNumber(nsCSSValue& aValue)
{
- return ParseSingleTokenOneOrLargerVariant(aValue, VARIANT_NUMBER, nullptr);
+ return ParseSingleTokenOneOrLargerVariant(aValue, VARIANT_NUMBER | VARIANT_OPACITY, nullptr);
}
// http://dev.w3.org/csswg/css-values/#custom-idents
@@ -5941,8 +5941,6 @@ CSSParserImpl::ParseAttributeSelector(int32_t& aDataMask,
"language",
"defer",
"type",
- // additional attributes not in HTML4
- "direction", // marquee
nullptr
};
short i = 0;
@@ -7791,6 +7789,7 @@ CSSParserImpl::ParseNonNegativeVariant(nsCSSValue& aValue,
VARIANT_NUMBER |
VARIANT_LENGTH |
VARIANT_PERCENT |
+ VARIANT_OPACITY |
VARIANT_INTEGER)) == 0,
"need to update code below to handle additional variants");
@@ -7831,6 +7830,7 @@ CSSParserImpl::ParseOneOrLargerVariant(nsCSSValue& aValue,
// that we specifically handle.
MOZ_ASSERT((aVariantMask & ~(VARIANT_ALL_NONNUMERIC |
VARIANT_NUMBER |
+ VARIANT_OPACITY |
VARIANT_INTEGER)) == 0,
"need to update code below to handle additional variants");
@@ -7959,9 +7959,9 @@ CSSParserImpl::ParseVariant(nsCSSValue& aValue,
}
}
}
- // Check VARIANT_NUMBER and VARIANT_INTEGER before VARIANT_LENGTH or
- // VARIANT_ZERO_ANGLE.
- if (((aVariantMask & VARIANT_NUMBER) != 0) &&
+ // Check VARIANT_NUMBER, number tokens for VARIANT_OPACITY, and
+ // VARIANT_INTEGER before VARIANT_LENGTH or VARIANT_ZERO_ANGLE.
+ if (((aVariantMask & (VARIANT_NUMBER | VARIANT_OPACITY)) != 0) &&
(eCSSToken_Number == tk->mType)) {
aValue.SetFloatValue(tk->mNumber, eCSSUnit_Number);
return CSSParseResult::Ok;
@@ -7971,6 +7971,7 @@ CSSParserImpl::ParseVariant(nsCSSValue& aValue,
aValue.SetIntValue(tk->mInteger, eCSSUnit_Integer);
return CSSParseResult::Ok;
}
+
if (((aVariantMask & (VARIANT_LENGTH | VARIANT_ANGLE |
VARIANT_FREQUENCY | VARIANT_TIME)) != 0 &&
eCSSToken_Dimension == tk->mType) ||
@@ -7996,6 +7997,15 @@ CSSParserImpl::ParseVariant(nsCSSValue& aValue,
aValue.SetPercentValue(tk->mNumber);
return CSSParseResult::Ok;
}
+ // We need to store eCSSToken_Percentage in eCSSUnit_Number in order to
+ // serialize opacity according to spec. All percentage tokens are stored
+ // as floats, so no type conversion is needed to make this possible.
+ // Percentage tokens have to be evaluated later than number tokens.
+ if (((aVariantMask & VARIANT_OPACITY) != 0) &&
+ (eCSSToken_Percentage == tk->mType)) {
+ aValue.SetFloatValue(tk->mNumber, eCSSUnit_Number);
+ return CSSParseResult::Ok;
+ }
if (mUnitlessLengthQuirk) { // NONSTANDARD: Nav interprets unitless numbers as px
if (((aVariantMask & VARIANT_LENGTH) != 0) &&
(eCSSToken_Number == tk->mType)) {
@@ -8474,7 +8484,7 @@ CSSParserImpl::ParseImageRect(nsCSSValue& aImage)
break;
}
- static const int32_t VARIANT_SIDE = VARIANT_NUMBER | VARIANT_PERCENT;
+ static const int32_t VARIANT_SIDE = VARIANT_NUMBER | VARIANT_PERCENT | VARIANT_OPACITY;
if (!ParseSingleTokenNonNegativeVariant(top, VARIANT_SIDE, nullptr) ||
!ExpectSymbol(',', true) ||
!ParseSingleTokenNonNegativeVariant(right, VARIANT_SIDE, nullptr) ||
@@ -10883,7 +10893,7 @@ CSSParserImpl::ParseWebkitGradientColorStop(nsCSSValueGradient* aGradient)
if (mToken.mIdent.LowerCaseEqualsLiteral("color-stop")) {
// Parse stop location, followed by comma.
if (!ParseSingleTokenVariant(stop->mLocation,
- VARIANT_NUMBER | VARIANT_PERCENT,
+ VARIANT_NUMBER | VARIANT_PERCENT | VARIANT_OPACITY,
nullptr) ||
!ExpectSymbol(',', true)) {
SkipUntil(')'); // Skip to end of color-stop(...) expression.
@@ -15318,17 +15328,17 @@ CSSParserImpl::ParseFontFeatureSettings(nsCSSValue& aValue)
return true;
}
-bool
-CSSParserImpl::ParseFontVariationSettings(nsCSSValue& aValue)
-{
- // TODO: Actually implement this.
-
- // This stub is here because websites insist on considering this
- // very hardware-dependent and O.S.-variable low-level font-control
- // as a "critical feature" which it isn't as there is 0 guarantee
- // that font variation settings are supported or honored by any
- // operating system used by the client.
- return true;
+bool
+CSSParserImpl::ParseFontVariationSettings(nsCSSValue& aValue)
+{
+ // TODO: Actually implement this.
+
+ // This stub is here because websites insist on considering this
+ // very hardware-dependent and O.S.-variable low-level font-control
+ // as a "critical feature" which it isn't as there is 0 guarantee
+ // that font variation settings are supported or honored by any
+ // operating system used by the client.
+ return true;
}
bool
@@ -16046,7 +16056,7 @@ static bool GetFunctionParseInformation(nsCSSKeyword aToken,
{VARIANT_LBCALC, VARIANT_LBCALC, VARIANT_LBCALC},
{VARIANT_ANGLE_OR_ZERO},
{VARIANT_ANGLE_OR_ZERO, VARIANT_ANGLE_OR_ZERO},
- {VARIANT_NUMBER},
+ {VARIANT_NUMBER|VARIANT_OPACITY},
{VARIANT_LENGTH|VARIANT_NONNEGATIVE_DIMENSION},
{VARIANT_LB|VARIANT_NONNEGATIVE_DIMENSION},
{VARIANT_NUMBER, VARIANT_NUMBER},
@@ -17628,7 +17638,7 @@ CSSParserImpl::ParseScrollSnapPoints(nsCSSValue& aValue, nsCSSPropertyID aPropID
nsCSSKeywords::LookupKeyword(mToken.mIdent) == eCSSKeyword_repeat) {
nsCSSValue lengthValue;
if (ParseNonNegativeVariant(lengthValue,
- VARIANT_LENGTH | VARIANT_PERCENT | VARIANT_CALC,
+ VARIANT_LENGTH | VARIANT_PERCENT | VARIANT_OPACITY | VARIANT_CALC,
nullptr) != CSSParseResult::Ok) {
REPORT_UNEXPECTED(PEExpectedNonnegativeNP);
SkipUntil(')');
diff --git a/layout/style/nsCSSPropList.h b/layout/style/nsCSSPropList.h
index f62aa3827..890019245 100644
--- a/layout/style/nsCSSPropList.h
+++ b/layout/style/nsCSSPropList.h
@@ -1703,7 +1703,7 @@ CSS_PROP_SVG(
FillOpacity,
CSS_PROPERTY_PARSE_VALUE,
"",
- VARIANT_HN | VARIANT_OPENTYPE_SVG_KEYWORD,
+ VARIANT_INHERIT | VARIANT_OPACITY | VARIANT_OPENTYPE_SVG_KEYWORD,
kContextOpacityKTable,
offsetof(nsStyleSVG, mFillOpacity),
eStyleAnimType_float)
@@ -1841,7 +1841,7 @@ CSS_PROP_SVGRESET(
FloodOpacity,
CSS_PROPERTY_PARSE_VALUE,
"",
- VARIANT_HN,
+ VARIANT_INHERIT | VARIANT_OPACITY,
nullptr,
offsetof(nsStyleSVGReset, mFloodOpacity),
eStyleAnimType_float)
@@ -3070,7 +3070,7 @@ CSS_PROP_EFFECTS(
CSS_PROPERTY_CAN_ANIMATE_ON_COMPOSITOR |
CSS_PROPERTY_CREATES_STACKING_CONTEXT,
"",
- VARIANT_HN,
+ VARIANT_INHERIT | VARIANT_OPACITY,
nullptr,
offsetof(nsStyleEffects, mOpacity),
eStyleAnimType_float)
@@ -3761,7 +3761,7 @@ CSS_PROP_SVGRESET(
StopOpacity,
CSS_PROPERTY_PARSE_VALUE,
"",
- VARIANT_HN,
+ VARIANT_INHERIT | VARIANT_OPACITY,
nullptr,
offsetof(nsStyleSVGReset, mStopOpacity),
eStyleAnimType_float)
@@ -3836,7 +3836,7 @@ CSS_PROP_SVG(
StrokeOpacity,
CSS_PROPERTY_PARSE_VALUE,
"",
- VARIANT_HN | VARIANT_OPENTYPE_SVG_KEYWORD,
+ VARIANT_INHERIT | VARIANT_OPACITY | VARIANT_OPENTYPE_SVG_KEYWORD,
kContextOpacityKTable,
offsetof(nsStyleSVG, mStrokeOpacity),
eStyleAnimType_float)
diff --git a/layout/style/nsCSSProps.cpp b/layout/style/nsCSSProps.cpp
index ac2978c27..24c97cf33 100644
--- a/layout/style/nsCSSProps.cpp
+++ b/layout/style/nsCSSProps.cpp
@@ -1345,6 +1345,9 @@ KTableEntry nsCSSProps::kDisplayKTable[] = {
// The next entry is controlled by the layout.css.display-contents.enabled
// pref.
{ eCSSKeyword_contents, StyleDisplay::Contents },
+ // The next entry is controlled by the layout.css.display-flow-root.enabled
+ // pref.
+ { eCSSKeyword_flow_root, StyleDisplay::FlowRoot },
{ eCSSKeyword_UNKNOWN, -1 }
};
diff --git a/layout/style/nsCSSProps.h b/layout/style/nsCSSProps.h
index aabbac07a..34d457c08 100644
--- a/layout/style/nsCSSProps.h
+++ b/layout/style/nsCSSProps.h
@@ -43,6 +43,7 @@
#define VARIANT_IDENTIFIER 0x002000 // D
#define VARIANT_IDENTIFIER_NO_INHERIT 0x004000 // like above, but excluding
// 'inherit' and 'initial'
+#define VARIANT_OPACITY 0x008000 // Take floats and percents as input, output float.
#define VARIANT_AUTO 0x010000 // A
#define VARIANT_INHERIT 0x020000 // H eCSSUnit_Initial, eCSSUnit_Inherit, eCSSUnit_Unset
#define VARIANT_NONE 0x040000 // O
diff --git a/layout/style/nsRuleNode.cpp b/layout/style/nsRuleNode.cpp
index 1a451a2ef..036d97f86 100644
--- a/layout/style/nsRuleNode.cpp
+++ b/layout/style/nsRuleNode.cpp
@@ -250,6 +250,7 @@ nsRuleNode::EnsureBlockDisplay(StyleDisplay& display,
case StyleDisplay::Flex:
case StyleDisplay::WebkitBox:
case StyleDisplay::Grid:
+ case StyleDisplay::FlowRoot:
// do not muck with these at all - already blocks
// This is equivalent to nsStyleDisplay::IsBlockOutside. (XXX Maybe we
// should just call that?)
@@ -293,6 +294,7 @@ nsRuleNode::EnsureInlineDisplay(StyleDisplay& display)
// see if the display value is already inline
switch (display) {
case StyleDisplay::Block:
+ case StyleDisplay::FlowRoot:
display = StyleDisplay::InlineBlock;
break;
case StyleDisplay::Table:
diff --git a/layout/style/nsStyleConsts.h b/layout/style/nsStyleConsts.h
index 6d207aec9..f54387aa8 100644
--- a/layout/style/nsStyleConsts.h
+++ b/layout/style/nsStyleConsts.h
@@ -524,6 +524,7 @@ enum class FillMode : uint32_t;
enum class StyleDisplay : uint8_t {
None = 0,
Block,
+ FlowRoot,
Inline,
InlineBlock,
ListItem,
diff --git a/layout/style/nsStyleStruct.h b/layout/style/nsStyleStruct.h
index 4bda817dd..f49cdc43e 100644
--- a/layout/style/nsStyleStruct.h
+++ b/layout/style/nsStyleStruct.h
@@ -2890,7 +2890,8 @@ struct MOZ_NEEDS_MEMMOVABLE_MEMBERS nsStyleDisplay
return mozilla::StyleDisplay::Block == mDisplay ||
mozilla::StyleDisplay::ListItem == mDisplay ||
mozilla::StyleDisplay::InlineBlock == mDisplay ||
- mozilla::StyleDisplay::TableCaption == mDisplay;
+ mozilla::StyleDisplay::TableCaption == mDisplay ||
+ mozilla::StyleDisplay::FlowRoot == mDisplay;
// Should TABLE_CELL be included here? They have
// block frames nested inside of them.
// (But please audit all callers before changing.)
@@ -2902,7 +2903,8 @@ struct MOZ_NEEDS_MEMMOVABLE_MEMBERS nsStyleDisplay
mozilla::StyleDisplay::WebkitBox == mDisplay ||
mozilla::StyleDisplay::Grid == mDisplay ||
mozilla::StyleDisplay::ListItem == mDisplay ||
- mozilla::StyleDisplay::Table == mDisplay;
+ mozilla::StyleDisplay::Table == mDisplay ||
+ mozilla::StyleDisplay::FlowRoot == mDisplay;
}
static bool IsDisplayTypeInlineOutside(mozilla::StyleDisplay aDisplay) {
diff --git a/layout/style/res/html.css b/layout/style/res/html.css
index 44e41c8d0..b975bf0c9 100644
--- a/layout/style/res/html.css
+++ b/layout/style/res/html.css
@@ -64,7 +64,6 @@ legend,
li,
listing,
main,
-marquee,
menu,
nav,
noframes,
@@ -819,25 +818,9 @@ dialog:not([open]) {
display: none;
}
-/* emulation of non-standard HTML <marquee> tag */
-marquee {
- inline-size: -moz-available;
- display: inline-block;
- vertical-align: text-bottom;
- text-align: start;
- -moz-binding: url('chrome://xbl-marquee/content/xbl-marquee.xml#marquee-horizontal');
-}
-
-marquee[direction="up"], marquee[direction="down"] {
- -moz-binding: url('chrome://xbl-marquee/content/xbl-marquee.xml#marquee-vertical');
- block-size: 200px;
-}
-
/* PRINT ONLY rules follow */
@media print {
- marquee { -moz-binding: none; }
-
}
/* Ruby */
diff --git a/layout/style/test/property_database.js b/layout/style/test/property_database.js
index c75f7b498..bc4383630 100644
--- a/layout/style/test/property_database.js
+++ b/layout/style/test/property_database.js
@@ -3540,7 +3540,7 @@ var gCSSProperties = {
inherited: false,
type: CSS_TYPE_LONGHAND,
initial_values: [ "1", "17", "397.376", "3e1", "3e+1", "3e0", "3e+0", "3e-0" ],
- other_values: [ "0", "0.4", "0.0000", "-3", "3e-1" ],
+ other_values: [ "0", "0.4", "0.0000", "-3", "3e-1" "-100%", "50%" ],
invalid_values: [ "0px", "1px" ]
},
"-moz-orient": {
@@ -4272,8 +4272,8 @@ var gCSSProperties = {
domProp: "fillOpacity",
inherited: true,
type: CSS_TYPE_LONGHAND,
- initial_values: [ "1", "2.8", "1.000", "context-fill-opacity", "context-stroke-opacity" ],
- other_values: [ "0", "0.3", "-7.3" ],
+ initial_values: [ "1", "2.8", "1.000", "300%", "context-fill-opacity", "context-stroke-opacity" ],
+ other_values: [ "0", "0.3", "-7.3", "-100%", "50%" ],
invalid_values: []
},
"fill-rule": {
@@ -4305,8 +4305,8 @@ var gCSSProperties = {
domProp: "floodOpacity",
inherited: false,
type: CSS_TYPE_LONGHAND,
- initial_values: [ "1", "2.8", "1.000" ],
- other_values: [ "0", "0.3", "-7.3" ],
+ initial_values: [ "1", "2.8", "1.000", "300%" ],
+ other_values: [ "0", "0.3", "-7.3", "-100%", "50%" ],
invalid_values: []
},
"image-rendering": {
@@ -4380,8 +4380,8 @@ var gCSSProperties = {
domProp: "stopOpacity",
inherited: false,
type: CSS_TYPE_LONGHAND,
- initial_values: [ "1", "2.8", "1.000" ],
- other_values: [ "0", "0.3", "-7.3" ],
+ initial_values: [ "1", "2.8", "1.000", "300%" ],
+ other_values: [ "0", "0.3", "-7.3", "-100%", "50%" ],
invalid_values: []
},
"stroke": {
@@ -4436,8 +4436,8 @@ var gCSSProperties = {
domProp: "strokeOpacity",
inherited: true,
type: CSS_TYPE_LONGHAND,
- initial_values: [ "1", "2.8", "1.000", "context-fill-opacity", "context-stroke-opacity" ],
- other_values: [ "0", "0.3", "-7.3" ],
+ initial_values: [ "1", "2.8", "1.000", "300%", "context-fill-opacity", "context-stroke-opacity" ],
+ other_values: [ "0", "0.3", "-7.3", "-100%", "50% ],
invalid_values: []
},
"stroke-width": {
@@ -7892,6 +7892,10 @@ if (IsCSSPropertyPrefEnabled("layout.css.background-clip-text.enabled")) {
);
}
+if (IsCSSPropertyPrefEnabled("layout.css.display-flow-root.enabled")) {
+ gCSSProperties["display"].other_values.push("flow-root");
+}
+
// Copy aliased properties' fields from their alias targets.
for (var prop in gCSSProperties) {
var entry = gCSSProperties[prop];
diff --git a/layout/style/xbl-marquee/jar.mn b/layout/style/xbl-marquee/jar.mn
deleted file mode 100644
index 9247cb4a1..000000000
--- a/layout/style/xbl-marquee/jar.mn
+++ /dev/null
@@ -1,8 +0,0 @@
-# This Source Code Form is subject to the terms of the Mozilla Public
-# License, v. 2.0. If a copy of the MPL was not distributed with this
-# file, You can obtain one at http://mozilla.org/MPL/2.0/.
-
-toolkit.jar:
-% content xbl-marquee %content/xbl-marquee/ contentaccessible=yes
- content/xbl-marquee/xbl-marquee.xml
- content/xbl-marquee/xbl-marquee.css
diff --git a/layout/style/xbl-marquee/moz.build b/layout/style/xbl-marquee/moz.build
deleted file mode 100644
index eb4454d28..000000000
--- a/layout/style/xbl-marquee/moz.build
+++ /dev/null
@@ -1,7 +0,0 @@
-# -*- Mode: python; indent-tabs-mode: nil; tab-width: 40 -*-
-# vim: set filetype=python:
-# This Source Code Form is subject to the terms of the Mozilla Public
-# License, v. 2.0. If a copy of the MPL was not distributed with this
-# file, You can obtain one at http://mozilla.org/MPL/2.0/.
-
-JAR_MANIFESTS += ['jar.mn'] \ No newline at end of file
diff --git a/layout/style/xbl-marquee/xbl-marquee.css b/layout/style/xbl-marquee/xbl-marquee.css
deleted file mode 100644
index e6d3ee94b..000000000
--- a/layout/style/xbl-marquee/xbl-marquee.css
+++ /dev/null
@@ -1,12 +0,0 @@
-/* This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this
- * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
-
-/* PRINT ONLY rules */
-@media print {
-
- marquee > * > * {
- margin: 0 !important;
- padding: 0 !important;
- } /* This hack is needed until bug 119078 gets fixed */
-}
diff --git a/layout/style/xbl-marquee/xbl-marquee.xml b/layout/style/xbl-marquee/xbl-marquee.xml
deleted file mode 100644
index bb837624d..000000000
--- a/layout/style/xbl-marquee/xbl-marquee.xml
+++ /dev/null
@@ -1,733 +0,0 @@
-<?xml version="1.0"?>
-<!-- This Source Code Form is subject to the terms of the Mozilla Public
- - License, v. 2.0. If a copy of the MPL was not distributed with this
- - file, You can obtain one at http://mozilla.org/MPL/2.0/. -->
-
-<bindings id="marqueeBindings"
- xmlns="http://www.mozilla.org/xbl"
- xmlns:html="http://www.w3.org/1999/xhtml"
- xmlns:xul="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
- xmlns:xbl="http://www.mozilla.org/xbl">
-
-
- <binding id="marquee" bindToUntrustedContent="true">
-
- <resources>
- <stylesheet src="chrome://xbl-marquee/content/xbl-marquee.css"/>
- </resources>
- <implementation>
-
- <property name="scrollAmount" exposeToUntrustedContent="true">
- <getter>
- <![CDATA[
- this._mutationActor(this._mutationObserver.takeRecords());
- return this._scrollAmount;
- ]]>
- </getter>
- <setter>
- <![CDATA[
- var val = parseInt(val);
- if (val < 0) {
- return;
- }
- if (isNaN(val)) {
- val = 0;
- }
- this.setAttribute("scrollamount", val);
- ]]>
- </setter>
- </property>
-
- <property name="scrollDelay" exposeToUntrustedContent="true">
- <getter>
- <![CDATA[
- this._mutationActor(this._mutationObserver.takeRecords());
- var val = parseInt(this.getAttribute("scrolldelay"));
-
- if (val <= 0 || isNaN(val)) {
- return this._scrollDelay;
- }
-
- return val;
- ]]>
- </getter>
- <setter>
- var val = parseInt(val);
- if (val > 0 ) {
- this.setAttribute("scrolldelay", val);
- }
- </setter>
- </property>
-
- <property name="trueSpeed" exposeToUntrustedContent="true">
- <getter>
- <![CDATA[
- if (!this.hasAttribute("truespeed")) {
- return false;
- }
-
- return true;
- ]]>
- </getter>
- <setter>
- <![CDATA[
- if (val) {
- this.setAttribute("truespeed", "");
- } else {
- this.removeAttribute('truespeed');
- }
- ]]>
- </setter>
- </property>
-
- <property name="direction" exposeToUntrustedContent="true">
- <getter>
- this._mutationActor(this._mutationObserver.takeRecords());
- return this._direction;
- </getter>
- <setter>
- <![CDATA[
- if (typeof val == 'string') {
- val = val.toLowerCase();
- } else {
- return;
- }
- if (val != 'left' && val != 'right' && val != 'up' && val != 'down') {
- val = 'left';
- }
-
- this.setAttribute("direction", val);
- ]]>
- </setter>
- </property>
-
- <property name="behavior" exposeToUntrustedContent="true">
- <getter>
- this._mutationActor(this._mutationObserver.takeRecords());
- return this._behavior;
- </getter>
- <setter>
- if (typeof val == 'string') {
- val = val.toLowerCase();
- }
- if (val == "alternate" || val == "slide" || val == 'scroll') {
- this.setAttribute("behavior", val);
- }
- </setter>
- </property>
-
-
- <property name="loop" exposeToUntrustedContent="true">
- <getter>
- <![CDATA[
- this._mutationActor(this._mutationObserver.takeRecords());
- return this._loop;
- ]]>
- </getter>
- <setter>
- <![CDATA[
- var val = parseInt(val);
- if (val == -1 || val > 0) {
- this.setAttribute("loop", val);
- }
- ]]>
- </setter>
- </property>
-
-
- <property name="onstart" exposeToUntrustedContent="true">
- <getter>
- return this.getAttribute("onstart");
- </getter>
- <setter>
- this._setEventListener("start", val, true);
- this.setAttribute("onstart", val);
- </setter>
- </property>
-
- <property name="onfinish" exposeToUntrustedContent="true">
- <getter>
- return this.getAttribute("onfinish");
- </getter>
- <setter>
- this._setEventListener("finish", val, true);
- this.setAttribute("onfinish", val);
- </setter>
- </property>
-
- <property name="onbounce" exposeToUntrustedContent="true">
- <getter>
- return this.getAttribute("onbounce");
- </getter>
- <setter>
- this._setEventListener("bounce", val, true);
- this.setAttribute("onbounce", val);
- </setter>
- </property>
-
- <property name="outerDiv"
- onget="return document.getAnonymousNodes(this)[0]"
- />
-
- <property name="innerDiv"
- onget="return document.getAnonymousElementByAttribute(this, 'class', 'innerDiv');"
- />
-
- <property name="height" exposeToUntrustedContent="true"
- onget="return this.getAttribute('height');"
- onset="this.setAttribute('height', val);"
- />
-
- <property name="width" exposeToUntrustedContent="true"
- onget="return this.getAttribute('width');"
- onset="this.setAttribute('width', val);"
- />
-
- <method name="_set_scrollDelay">
- <parameter name="aValue"/>
- <body>
- <![CDATA[
- aValue = parseInt(aValue);
- if (aValue <= 0) {
- return;
- } else if (isNaN(aValue)) {
- this._scrollDelay = 85;
- } else if (aValue < 60) {
- if (this.trueSpeed == true) {
- this._scrollDelay = aValue;
- } else {
- this._scrollDelay = 60;
- }
- } else {
- this._scrollDelay = aValue;
- }
- ]]>
- </body>
- </method>
-
- <method name="_set_scrollAmount">
- <parameter name="aValue"/>
- <body>
- <![CDATA[
- aValue = parseInt(aValue);
- if (isNaN(aValue)) {
- this._scrollAmount = 6;
- } else if (aValue < 0) {
- return;
- } else {
- this._scrollAmount = aValue;
- }
- ]]>
- </body>
- </method>
-
- <method name="_set_behavior">
- <parameter name="aValue"/>
- <body>
- <![CDATA[
- if (typeof aValue == 'string') {
- aValue = aValue.toLowerCase();
- }
- if (aValue != 'alternate' && aValue != 'slide' && aValue != 'scroll') {
- this._behavior = 'scroll';
- } else {
- this._behavior = aValue;
- }
- ]]>
- </body>
- </method>
-
- <method name="_set_direction">
- <parameter name="aValue"/>
- <body>
- <![CDATA[
- if (typeof aValue == 'string') {
- aValue = aValue.toLowerCase();
- }
- if (aValue != 'left' && aValue != 'right' && aValue != 'up' && aValue != 'down') {
- aValue = 'left';
- }
-
- if (aValue != this._direction) {
- this.startNewDirection = true;
- }
- this._direction = aValue;
- ]]>
- </body>
- </method>
-
- <method name="_set_loop">
- <parameter name="aValue"/>
- <body>
- <![CDATA[
- var aValue = parseInt(aValue);
- if (aValue == 0) {
- return;
- }
- if (isNaN(aValue) || aValue <= -1) {
- aValue = -1;
- }
- this._loop = aValue;
- ]]>
- </body>
- </method>
-
- <method name="_setEventListener">
- <parameter name="aName"/>
- <parameter name="aValue"/>
- <parameter name="aIgnoreNextCall"/>
- <body>
- <![CDATA[
- // _setEventListener is only used for setting the attribute event
- // handlers, which we want to ignore if our document is sandboxed
- // without the allow-scripts keyword.
- if (document.hasScriptsBlockedBySandbox) {
- return true;
- }
-
- // attribute event handlers should only be added if the
- // document's CSP allows it.
- if (!document.inlineScriptAllowedByCSP) {
- return true;
- }
-
- if (this._ignoreNextCall) {
- return this._ignoreNextCall = false;
- }
-
- if (aIgnoreNextCall) {
- this._ignoreNextCall = true;
- }
-
- if (typeof this["_on" + aName] == 'function') {
- this.removeEventListener(aName, this["_on" + aName], false);
- }
-
- switch (typeof aValue)
- {
- case "function":
- this["_on" + aName] = aValue;
- this.addEventListener(aName, this["_on" + aName], false);
- break;
-
- case "string":
- if (!aIgnoreNextCall) {
- try {
- // Function Xrays make this simple and safe. \o/
- this["_on" + aName] = new window.Function("event", aValue);
- }
- catch(e) {
- return false;
- }
- this.addEventListener(aName, this["_on" + aName], false);
- }
- else {
- this["_on" + aName] = aValue;
- }
- break;
-
- case "object":
- this["_on" + aName] = aValue;
- break;
-
- default:
- this._ignoreNextCall = false;
- throw new Error("Invalid argument for Marquee::on" + aName);
- }
- return true;
- ]]>
- </body>
- </method>
-
- <method name="_fireEvent">
- <parameter name="aName"/>
- <parameter name="aBubbles"/>
- <parameter name="aCancelable"/>
- <body>
- <![CDATA[
- var e = document.createEvent("Events");
- e.initEvent(aName, aBubbles, aCancelable);
- this.dispatchEvent(e);
- ]]>
- </body>
- </method>
-
- <method name="start" exposeToUntrustedContent="true">
- <body>
- <![CDATA[
- if (this.runId == 0) {
- var myThis = this;
- var lambda = function myTimeOutFunction(){myThis._doMove(false);}
- this.runId = window.setTimeout(lambda, this._scrollDelay - this._deltaStartStop);
- this._deltaStartStop = 0;
- }
- ]]>
- </body>
- </method>
-
- <method name="stop" exposeToUntrustedContent="true">
- <body>
- <![CDATA[
- if (this.runId != 0) {
- this._deltaStartStop = Date.now()- this._lastMoveDate;
- clearTimeout(this.runId);
- }
-
- this.runId = 0;
- ]]>
- </body>
- </method>
-
- <method name="_doMove">
- <parameter name="aResetPosition"/>
- <body>
- <![CDATA[
- this._lastMoveDate = Date.now();
-
- //startNewDirection is true at first load and whenever the direction is changed
- if (this.startNewDirection) {
- this.startNewDirection = false; //we only want this to run once every scroll direction change
-
- var corrvalue = 0;
-
- switch (this._direction)
- {
- case "up":
- var height = document.defaultView.getComputedStyle(this, "").height;
- this.outerDiv.style.height = height;
- if (this.originalHeight > this.outerDiv.offsetHeight) {
- corrvalue = this.originalHeight - this.outerDiv.offsetHeight;
- }
- this.innerDiv.style.padding = height + " 0";
- this.dirsign = 1;
- this.startAt = (this._behavior == 'alternate') ? (this.originalHeight - corrvalue) : 0;
- this.stopAt = (this._behavior == 'alternate' || this._behavior == 'slide') ?
- (parseInt(height) + corrvalue) : (this.originalHeight + parseInt(height));
- break;
-
- case "down":
- var height = document.defaultView.getComputedStyle(this, "").height;
- this.outerDiv.style.height = height;
- if (this.originalHeight > this.outerDiv.offsetHeight) {
- corrvalue = this.originalHeight - this.outerDiv.offsetHeight;
- }
- this.innerDiv.style.padding = height + " 0";
- this.dirsign = -1;
- this.startAt = (this._behavior == 'alternate') ?
- (parseInt(height) + corrvalue) : (this.originalHeight + parseInt(height));
- this.stopAt = (this._behavior == 'alternate' || this._behavior == 'slide') ?
- (this.originalHeight - corrvalue) : 0;
- break;
-
- case "right":
- if (this.innerDiv.offsetWidth > this.outerDiv.offsetWidth) {
- corrvalue = this.innerDiv.offsetWidth - this.outerDiv.offsetWidth;
- }
- this.dirsign = -1;
- this.stopAt = (this._behavior == 'alternate' || this._behavior == 'slide') ?
- (this.innerDiv.offsetWidth - corrvalue) : 0;
- this.startAt = this.outerDiv.offsetWidth + ((this._behavior == 'alternate') ?
- corrvalue : (this.innerDiv.offsetWidth + this.stopAt));
- break;
-
- case "left":
- default:
- if (this.innerDiv.offsetWidth > this.outerDiv.offsetWidth) {
- corrvalue = this.innerDiv.offsetWidth - this.outerDiv.offsetWidth;
- }
- this.dirsign = 1;
- this.startAt = (this._behavior == 'alternate') ? (this.innerDiv.offsetWidth - corrvalue) : 0;
- this.stopAt = this.outerDiv.offsetWidth +
- ((this._behavior == 'alternate' || this._behavior == 'slide') ?
- corrvalue : (this.innerDiv.offsetWidth + this.startAt));
- }
-
- if (aResetPosition) {
- this.newPosition = this.startAt;
- this._fireEvent("start", false, false);
- }
- } //end if
-
- this.newPosition = this.newPosition + (this.dirsign * this._scrollAmount);
-
- if ((this.dirsign == 1 && this.newPosition > this.stopAt) ||
- (this.dirsign == -1 && this.newPosition < this.stopAt))
- {
- switch (this._behavior)
- {
- case 'alternate':
- // lets start afresh
- this.startNewDirection = true;
-
- // swap direction
- const swap = {left: "right", down: "up", up: "down", right: "left"};
- this._direction = swap[this._direction];
- this.newPosition = this.stopAt;
-
- if ((this._direction == "up") || (this._direction == "down")) {
- this.outerDiv.scrollTop = this.newPosition;
- } else {
- this.outerDiv.scrollLeft = this.newPosition;
- }
-
- if (this._loop != 1) {
- this._fireEvent("bounce", false, true);
- }
- break;
-
- case 'slide':
- if (this._loop > 1) {
- this.newPosition = this.startAt;
- }
- break;
-
- default:
- this.newPosition = this.startAt;
-
- if ((this._direction == "up") || (this._direction == "down")) {
- this.outerDiv.scrollTop = this.newPosition;
- } else {
- this.outerDiv.scrollLeft = this.newPosition;
- }
-
- //dispatch start event, even when this._loop == 1, comp. with IE6
- this._fireEvent("start", false, false);
- }
-
- if (this._loop > 1) {
- this._loop--;
- } else if (this._loop == 1) {
- if ((this._direction == "up") || (this._direction == "down")) {
- this.outerDiv.scrollTop = this.stopAt;
- } else {
- this.outerDiv.scrollLeft = this.stopAt;
- }
- this.stop();
- this._fireEvent("finish", false, true);
- return;
- }
- }
- else {
- if ((this._direction == "up") || (this._direction == "down")) {
- this.outerDiv.scrollTop = this.newPosition;
- } else {
- this.outerDiv.scrollLeft = this.newPosition;
- }
- }
-
- var myThis = this;
- var lambda = function myTimeOutFunction(){myThis._doMove(false);}
- this.runId = window.setTimeout(lambda, this._scrollDelay);
- ]]>
- </body>
- </method>
-
- <method name="init">
- <body>
- <![CDATA[
- this.stop();
-
- if ((this._direction != "up") && (this._direction != "down")) {
- var width = window.getComputedStyle(this, "").width;
- this.innerDiv.parentNode.style.margin = '0 ' + width;
-
- //XXX Adding the margin sometimes causes the marquee to widen,
- // see testcase from bug bug 364434:
- // https://bugzilla.mozilla.org/attachment.cgi?id=249233
- // Just add a fixed width with current marquee's width for now
- if (width != window.getComputedStyle(this, "").width) {
- var width = window.getComputedStyle(this, "").width;
- this.outerDiv.style.width = width;
- this.innerDiv.parentNode.style.margin = '0 ' + width;
- }
- }
- else {
- // store the original height before we add padding
- this.innerDiv.style.padding = 0;
- this.originalHeight = this.innerDiv.offsetHeight;
- }
-
- this._doMove(true);
- ]]>
- </body>
- </method>
-
- <method name="_mutationActor">
- <parameter name="aMutations"/>
- <body>
- <![CDATA[
- while (aMutations.length > 0) {
- var mutation = aMutations.shift();
- var attrName = mutation.attributeName.toLowerCase();
- var oldValue = mutation.oldValue;
- var target = mutation.target;
- var newValue = target.getAttribute(attrName);
-
- if (oldValue != newValue) {
- switch (attrName) {
- case "loop":
- target._set_loop(newValue);
- if (target.rundId == 0) {
- target.start();
- }
- break;
- case "scrollamount":
- target._set_scrollAmount(newValue);
- break;
- case "scrolldelay":
- target._set_scrollDelay(newValue);
- target.stop();
- target.start();
- break;
- case "truespeed":
- //needed to update target._scrollDelay
- var myThis = target;
- var lambda = function() {myThis._set_scrollDelay(myThis.getAttribute('scrolldelay'));}
- window.setTimeout(lambda, 0);
- break;
- case "behavior":
- target._set_behavior(newValue);
- target.startNewDirection = true;
- if ((oldValue == "slide" && target.newPosition == target.stopAt) ||
- newValue == "alternate" || newValue == "slide") {
- target.stop();
- target._doMove(true);
- }
- break;
- case "direction":
- if (!newValue) {
- newValue = "left";
- }
- target._set_direction(newValue);
- break;
- case "width":
- case "height":
- target.startNewDirection = true;
- break;
- case "onstart":
- target._setEventListener("start", newValue);
- break;
- case "onfinish":
- target._setEventListener("finish", newValue);
- break;
- case "onbounce":
- target._setEventListener("bounce", newValue);
- break;
- }
- }
- }
- ]]>
- </body>
- </method>
-
- <constructor>
- <![CDATA[
- // Set up state.
- this._scrollAmount = 6;
- this._scrollDelay = 85;
- this._direction = "left";
- this._behavior = "scroll";
- this._loop = -1;
- this.dirsign = 1;
- this.startAt = 0;
- this.stopAt = 0;
- this.newPosition = 0;
- this.runId = 0;
- this.originalHeight = 0;
- this.startNewDirection = true;
-
- // hack needed to fix js error, see bug 386470
- var myThis = this;
- var lambda = function myScopeFunction() { if (myThis.init) myThis.init(); }
-
- this._set_direction(this.getAttribute('direction'));
- this._set_behavior(this.getAttribute('behavior'));
- this._set_scrollDelay(this.getAttribute('scrolldelay'));
- this._set_scrollAmount(this.getAttribute('scrollamount'));
- this._set_loop(this.getAttribute('loop'));
- this._setEventListener("start", this.getAttribute("onstart"));
- this._setEventListener("finish", this.getAttribute("onfinish"));
- this._setEventListener("bounce", this.getAttribute("onbounce"));
- this.startNewDirection = true;
-
- this._mutationObserver = new MutationObserver(this._mutationActor);
- this._mutationObserver.observe(this, { attributes: true,
- attributeOldValue: true,
- attributeFilter: ['loop', 'scrollamount', 'scrolldelay', '', 'truespeed', 'behavior',
- 'direction', 'width', 'height', 'onstart', 'onfinish', 'onbounce'] });
-
- // init needs to be run after the page has loaded in order to calculate
- // the correct height/width
- if (document.readyState == "complete") {
- lambda();
- } else {
- window.addEventListener("load", lambda, false);
- }
- ]]>
- </constructor>
- </implementation>
-
- </binding>
-
- <binding id="marquee-horizontal" bindToUntrustedContent="true"
- extends="chrome://xbl-marquee/content/xbl-marquee.xml#marquee"
- inheritstyle="false">
-
- <!-- White-space isn't allowed because a marquee could be
- inside 'white-space: pre' -->
- <content>
- <html:div style="display: -moz-box; overflow: hidden; width: -moz-available;"
- ><html:div style="display: -moz-box;"
- ><html:div class="innerDiv" style="display: table; border-spacing: 0;"
- ><html:div
- ><children
- /></html:div
- ></html:div
- ></html:div
- ></html:div>
- </content>
-
- </binding>
-
- <binding id="marquee-vertical" bindToUntrustedContent="true"
- extends="chrome://xbl-marquee/content/xbl-marquee.xml#marquee"
- inheritstyle="false">
-
- <!-- White-space isn't allowed because a marquee could be
- inside 'white-space: pre' -->
- <content>
- <html:div style="overflow: hidden; width: -moz-available;"
- ><html:div class="innerDiv"
- ><children
- /></html:div
- ></html:div>
- </content>
-
- </binding>
-
- <binding id="marquee-horizontal-editable" bindToUntrustedContent="true"
- inheritstyle="false">
-
- <!-- White-space isn't allowed because a marquee could be
- inside 'white-space: pre' -->
- <content>
- <html:div style="display: inline-block; overflow: auto; width: -moz-available;"
- ><children
- /></html:div>
- </content>
-
- </binding>
-
- <binding id="marquee-vertical-editable" bindToUntrustedContent="true"
- inheritstyle="false">
-
- <!-- White-space isn't allowed because a marquee could be
- inside 'white-space: pre' -->
- <content>
- <html:div style="overflow: auto; height: inherit; width: -moz-available;"
- ><children/></html:div>
- </content>
-
- </binding>
-
-</bindings>
diff --git a/layout/svg/nsCSSClipPathInstance.cpp b/layout/svg/nsCSSClipPathInstance.cpp
index 01f7de248..e923eaa0e 100644
--- a/layout/svg/nsCSSClipPathInstance.cpp
+++ b/layout/svg/nsCSSClipPathInstance.cpp
@@ -59,7 +59,7 @@ nsCSSClipPathInstance::HitTestBasicShapeClip(nsIFrame* aFrame,
RefPtr<Path> path = instance.CreateClipPath(drawTarget);
float pixelRatio = float(nsPresContext::AppUnitsPerCSSPixel()) /
aFrame->PresContext()->AppUnitsPerDevPixel();
- return path->ContainsPoint(ToPoint(aPoint) * pixelRatio, Matrix());
+ return path ? path->ContainsPoint(ToPoint(aPoint) * pixelRatio, Matrix()) : false;
}
already_AddRefed<Path>
diff --git a/layout/xul/nsXULLabelFrame.cpp b/layout/xul/nsXULLabelFrame.cpp
index 22b875461..41e7e4d76 100644
--- a/layout/xul/nsXULLabelFrame.cpp
+++ b/layout/xul/nsXULLabelFrame.cpp
@@ -16,9 +16,7 @@ nsIFrame*
NS_NewXULLabelFrame(nsIPresShell* aPresShell, nsStyleContext* aContext)
{
nsXULLabelFrame* it = new (aPresShell) nsXULLabelFrame(aContext);
-
- it->AddStateBits(NS_BLOCK_FLOAT_MGR | NS_BLOCK_MARGIN_ROOT);
-
+ it->AddStateBits(NS_BLOCK_FORMATTING_CONTEXT_STATE_BITS);
return it;
}
diff --git a/modules/libpref/init/all.js b/modules/libpref/init/all.js
index 672f18e22..bed6d0d01 100644
--- a/modules/libpref/init/all.js
+++ b/modules/libpref/init/all.js
@@ -2609,6 +2609,9 @@ pref("layout.css.grid-template-subgrid-value.enabled", false);
// Is support for CSS contain enabled?
pref("layout.css.contain.enabled", false);
+// Is support for CSS display:flow-root enabled?
+pref("layout.css.display-flow-root.enabled", true);
+
// Is support for CSS display:contents enabled?
pref("layout.css.display-contents.enabled", true);
@@ -2652,6 +2655,9 @@ pref("layout.css.font-loading-api.enabled", true);
// Should stray control characters be rendered visibly?
pref("layout.css.control-characters.visible", false);
+// Is support for ResizeObservers enabled?
+pref("layout.css.resizeobserver.enabled", true);
+
// pref for which side vertical scrollbars should be on
// 0 = end-side in UI direction
// 1 = end-side in document/content direction
diff --git a/parser/html/java/htmlparser/src/nu/validator/htmlparser/impl/AttributeName.java b/parser/html/java/htmlparser/src/nu/validator/htmlparser/impl/AttributeName.java
index 48d82036c..c349c82a5 100644
--- a/parser/html/java/htmlparser/src/nu/validator/htmlparser/impl/AttributeName.java
+++ b/parser/html/java/htmlparser/src/nu/validator/htmlparser/impl/AttributeName.java
@@ -980,6 +980,7 @@ public final class AttributeName
public static final AttributeName ONREPEAT = new AttributeName(ALL_NO_NS, SAME_LOCAL("onrepeat"), ALL_NO_PREFIX, NCNAME_HTML | NCNAME_FOREIGN | NCNAME_LANG);
public static final AttributeName ONSELECT = new AttributeName(ALL_NO_NS, SAME_LOCAL("onselect"), ALL_NO_PREFIX, NCNAME_HTML | NCNAME_FOREIGN | NCNAME_LANG);
public static final AttributeName NOTATION = new AttributeName(ALL_NO_NS, SAME_LOCAL("notation"), ALL_NO_PREFIX, NCNAME_HTML | NCNAME_FOREIGN | NCNAME_LANG);
+ public static final AttributeName NOMODULE = new AttributeName(ALL_NO_NS, SAME_LOCAL("nomodule"), ALL_NO_PREFIX, NCNAME_HTML | NCNAME_FOREIGN | NCNAME_LANG | CASE_FOLDED | BOOLEAN);
public static final AttributeName NORESIZE = new AttributeName(ALL_NO_NS, SAME_LOCAL("noresize"), ALL_NO_PREFIX, NCNAME_HTML | NCNAME_FOREIGN | NCNAME_LANG | CASE_FOLDED | BOOLEAN);
public static final AttributeName MANIFEST = new AttributeName(ALL_NO_NS, SAME_LOCAL("manifest"), ALL_NO_PREFIX, NCNAME_HTML | NCNAME_FOREIGN | NCNAME_LANG);
public static final AttributeName MATHSIZE = new AttributeName(ALL_NO_NS, SAME_LOCAL("mathsize"), ALL_NO_PREFIX, NCNAME_HTML | NCNAME_FOREIGN | NCNAME_LANG);
@@ -1564,6 +1565,7 @@ public final class AttributeName
ONREPEAT,
ONSELECT,
NOTATION,
+ NOMODULE,
NORESIZE,
MANIFEST,
MATHSIZE,
@@ -2149,6 +2151,7 @@ public final class AttributeName
280686710,
280689066,
282736758,
+ 283095348,
283110901,
283275116,
283823226,
diff --git a/parser/html/java/htmlparser/src/nu/validator/htmlparser/impl/ElementName.java b/parser/html/java/htmlparser/src/nu/validator/htmlparser/impl/ElementName.java
index ee0493318..e96e0ad80 100644
--- a/parser/html/java/htmlparser/src/nu/validator/htmlparser/impl/ElementName.java
+++ b/parser/html/java/htmlparser/src/nu/validator/htmlparser/impl/ElementName.java
@@ -690,7 +690,6 @@ public final class ElementName
public static final ElementName LISTING = new ElementName("listing", "listing", TreeBuilder.PRE_OR_LISTING | SPECIAL);
public static final ElementName MFENCED = new ElementName("mfenced", "mfenced", TreeBuilder.OTHER);
public static final ElementName MPADDED = new ElementName("mpadded", "mpadded", TreeBuilder.OTHER);
- public static final ElementName MARQUEE = new ElementName("marquee", "marquee", TreeBuilder.MARQUEE_OR_APPLET | SPECIAL | SCOPING);
public static final ElementName MACTION = new ElementName("maction", "maction", TreeBuilder.OTHER);
public static final ElementName MSUBSUP = new ElementName("msubsup", "msubsup", TreeBuilder.OTHER);
public static final ElementName NOEMBED = new ElementName("noembed", "noembed", TreeBuilder.NOEMBED | SPECIAL);
@@ -1089,7 +1088,6 @@ public final class ElementName
LISTING,
MFENCED,
MPADDED,
- MARQUEE,
MACTION,
MSUBSUP,
NOEMBED,
@@ -1489,7 +1487,6 @@ public final class ElementName
247707956,
248648814,
248648836,
- 248682161,
248986932,
249058914,
249697357,
diff --git a/parser/html/nsHtml5AtomList.h b/parser/html/nsHtml5AtomList.h
index ce9fcd682..3341a13e7 100644
--- a/parser/html/nsHtml5AtomList.h
+++ b/parser/html/nsHtml5AtomList.h
@@ -338,6 +338,7 @@ HTML5_ATOM(onsubmit, "onsubmit")
HTML5_ATOM(onrepeat, "onrepeat")
HTML5_ATOM(onselect, "onselect")
HTML5_ATOM(notation, "notation")
+HTML5_ATOM(nomodule, "nomodule")
HTML5_ATOM(noresize, "noresize")
HTML5_ATOM(manifest, "manifest")
HTML5_ATOM(mathsize, "mathsize")
@@ -940,7 +941,6 @@ HTML5_ATOM(logbase, "logbase")
HTML5_ATOM(listing, "listing")
HTML5_ATOM(mfenced, "mfenced")
HTML5_ATOM(mpadded, "mpadded")
-HTML5_ATOM(marquee, "marquee")
HTML5_ATOM(maction, "maction")
HTML5_ATOM(msubsup, "msubsup")
HTML5_ATOM(picture, "picture")
diff --git a/parser/html/nsHtml5AttributeName.cpp b/parser/html/nsHtml5AttributeName.cpp
index 7e1cb7dd0..4cd0ce5e2 100644
--- a/parser/html/nsHtml5AttributeName.cpp
+++ b/parser/html/nsHtml5AttributeName.cpp
@@ -458,6 +458,7 @@ nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONSUBMIT = nullptr;
nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONREPEAT = nullptr;
nsHtml5AttributeName* nsHtml5AttributeName::ATTR_ONSELECT = nullptr;
nsHtml5AttributeName* nsHtml5AttributeName::ATTR_NOTATION = nullptr;
+nsHtml5AttributeName* nsHtml5AttributeName::ATTR_NOMODULE = nullptr;
nsHtml5AttributeName* nsHtml5AttributeName::ATTR_NORESIZE = nullptr;
nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MANIFEST = nullptr;
nsHtml5AttributeName* nsHtml5AttributeName::ATTR_MATHSIZE = nullptr;
@@ -781,7 +782,7 @@ nsHtml5AttributeName* nsHtml5AttributeName::ATTR_GLYPH_ORIENTATION_VERTICAL = nu
nsHtml5AttributeName* nsHtml5AttributeName::ATTR_COLOR_INTERPOLATION_FILTERS = nullptr;
nsHtml5AttributeName* nsHtml5AttributeName::ATTR_GLYPH_ORIENTATION_HORIZONTAL = nullptr;
nsHtml5AttributeName** nsHtml5AttributeName::ATTRIBUTE_NAMES = 0;
-static int32_t const ATTRIBUTE_HASHES_DATA[] = { 1153, 1383, 1601, 1793, 1827, 1857, 68600, 69146, 69177, 70237, 70270, 71572, 71669, 72415, 72444, 74846, 74904, 74943, 75001, 75276, 75590, 84742, 84839, 85575, 85963, 85992, 87204, 88074, 88171, 89130, 89163, 3207892, 3283895, 3284791, 3338752, 3358197, 3369562, 3539124, 3562402, 3574260, 3670335, 3696933, 3721879, 135280021, 135346322, 136317019, 136475749, 136548517, 136652214, 136884919, 136902418, 136942992, 137292068, 139120259, 139785574, 142250603, 142314056, 142331176, 142519584, 144752417, 145106895, 146147200, 146765926, 148805544, 149655723, 149809441, 150018784, 150445028, 150813181, 150923321, 152528754, 152536216, 152647366, 152962785, 155219321, 155654904, 157317483, 157350248, 157437941, 157447478, 157604838, 157685404, 157894402, 158315188, 166078431, 169409980, 169700259, 169856932, 170007032, 170409695, 170466488, 170513710, 170608367, 173028944, 173896963, 176090625, 176129212, 179390001, 179489057, 179627464, 179840468, 179849042, 180004216, 181779081, 183027151, 183645319, 183698797, 185922012, 185997252, 188312483, 188675799, 190977533, 190992569, 191006194, 191033518, 191038774, 191096249, 191166163, 191194426, 191443343, 191522106, 191568039, 200104642, 202506661, 202537381, 202602917, 203070590, 203120766, 203389054, 203690071, 203971238, 203986524, 209040857, 209125756, 212055489, 212322418, 212746849, 213002877, 213055164, 213088023, 213259873, 213273386, 213435118, 213437318, 213438231, 213493071, 213532268, 213542834, 213584431, 213659891, 215285828, 215880731, 216112976, 216684637, 217369699, 217565298, 217576549, 218186795, 219743185, 220082234, 221623802, 221986406, 222283890, 223089542, 223138630, 223311265, 224431494, 224547358, 224587256, 224589550, 224655650, 224785518, 224810917, 224813302, 225126263, 225429618, 225432950, 225440869, 236107233, 236709921, 236838947, 237117095, 237143271, 237172455, 237209953, 237354143, 237372743, 237668065, 237703073, 237714273, 239743521, 240512803, 240522627, 240560417, 240656513, 241015715, 241062755, 241065383, 243523041, 245865199, 246261793, 246556195, 246774817, 246923491, 246928419, 246981667, 247014847, 247058369, 247112833, 247118177, 247119137, 247128739, 247316903, 249533729, 250235623, 250269543, 251402351, 252339047, 253260911, 253293679, 254844367, 255547879, 256077281, 256345377, 258124199, 258354465, 258605063, 258744193, 258845603, 258856961, 258926689, 269869248, 270174334, 270709417, 270778994, 270781796, 271102503, 271478858, 271490090, 272870654, 273335275, 273369140, 273924313, 274108530, 274116736, 276818662, 277476156, 279156579, 279349675, 280108533, 280128712, 280132869, 280162403, 280280292, 280413430, 280506130, 280677397, 280678580, 280686710, 280689066, 282736758, 283110901, 283275116, 283823226, 283890012, 284479340, 284606461, 286700477, 286798916, 290055764, 291557706, 291665349, 291804100, 292138018, 292166446, 292418738, 292451039, 300298041, 300374839, 300597935, 303073389, 303083839, 303266673, 303354997, 303430688, 303576261, 303724281, 303819694, 304242723, 304382625, 306247792, 307227811, 307468786, 307724489, 310252031, 310358241, 310373094, 310833159, 311015256, 313357609, 313683893, 313701861, 313706996, 313707317, 313710350, 313795700, 314027746, 314038181, 314091299, 314205627, 314233813, 316741830, 316797986, 317486755, 317794164, 320076137, 322657125, 322887778, 323506876, 323572412, 323605180, 325060058, 325320188, 325398738, 325541490, 325671619, 333868843, 336806130, 337212108, 337282686, 337285434, 337585223, 338036037, 338298087, 338566051, 340943551, 341190970, 342995704, 343352124, 343912673, 344585053, 346977248, 347218098, 347262163, 347278576, 347438191, 347655959, 347684788, 347726430, 347727772, 347776035, 347776629, 349500753, 350880161, 350887073, 353384123, 355496998, 355906922, 355979793, 356545959, 358637867, 358905016, 359164318, 359247286, 359350571, 359579447, 365560330, 367399355, 367420285, 367510727, 368013212, 370234760, 370353345, 370710317, 371074566, 371122285, 371194213, 371448425, 371448430, 371545055, 371593469, 371596922, 371758751, 371964792, 372151328, 376550136, 376710172, 376795771, 376826271, 376906556, 380514830, 380774774, 380775037, 381030322, 381136500, 381281631, 381282269, 381285504, 381330595, 381331422, 381335911, 381336484, 383907298, 383917408, 384595009, 384595013, 387799894, 387823201, 392581647, 392584937, 392742684, 392906485, 393003349, 400644707, 400973830, 404428547, 404432113, 404432865, 404469244, 404478897, 404694860, 406887479, 408294949, 408789955, 410022510, 410467324, 410586448, 410945965, 411845275, 414327152, 414327932, 414329781, 414346257, 414346439, 414639928, 414835998, 414894517, 414986533, 417465377, 417465381, 417492216, 418259232, 419310946, 420103495, 420242342, 420380455, 420658662, 420717432, 423183880, 424539259, 425929170, 425972964, 426050649, 426126450, 426142833, 426607922, 437289840, 437347469, 437412335, 437423943, 437455540, 437462252, 437597991, 437617485, 437986305, 437986507, 437986828, 437987072, 438015591, 438034813, 438038966, 438179623, 438347971, 438483573, 438547062, 438895551, 441592676, 442032555, 443548979, 447881379, 447881655, 447881895, 447887844, 448416189, 448445746, 448449012, 450942191, 452816744, 453668677, 454434495, 456610076, 456642844, 456738709, 457544600, 459451897, 459680944, 468058810, 468083581, 470964084, 471470955, 471567278, 472267822, 481177859, 481210627, 481435874, 481455115, 481485378, 481490218, 485105638, 486005878, 486383494, 487988916, 488103783, 490661867, 491574090, 491578272, 492891370, 493041952, 493441205, 493582844, 493716979, 504577572, 504740359, 505091638, 505592418, 505656212, 509516275, 514998531, 515571132, 515594682, 518712698, 521362273, 526592419, 526807354, 527348842, 538294791, 544689535, 545535009, 548544752, 548563346, 548595116, 551679010, 558034099, 560329411, 560356209, 560671018, 560671152, 560692590, 560845442, 569212097, 569474241, 572252718, 575326764, 576174758, 576190819, 582099184, 582099438, 582372519, 582558889, 586552164, 591325418, 594231990, 594243961, 605711268, 615672071, 616086845, 621792370, 624879850, 627432831, 640040548, 654392808, 658675477, 659420283, 672891587, 694768102, 705890982, 725543146, 759097578, 761686526, 795383908, 878105336, 908643300, 945213471 };
+static int32_t const ATTRIBUTE_HASHES_DATA[] = { 1153, 1383, 1601, 1793, 1827, 1857, 68600, 69146, 69177, 70237, 70270, 71572, 71669, 72415, 72444, 74846, 74904, 74943, 75001, 75276, 75590, 84742, 84839, 85575, 85963, 85992, 87204, 88074, 88171, 89130, 89163, 3207892, 3283895, 3284791, 3338752, 3358197, 3369562, 3539124, 3562402, 3574260, 3670335, 3696933, 3721879, 135280021, 135346322, 136317019, 136475749, 136548517, 136652214, 136884919, 136902418, 136942992, 137292068, 139120259, 139785574, 142250603, 142314056, 142331176, 142519584, 144752417, 145106895, 146147200, 146765926, 148805544, 149655723, 149809441, 150018784, 150445028, 150813181, 150923321, 152528754, 152536216, 152647366, 152962785, 155219321, 155654904, 157317483, 157350248, 157437941, 157447478, 157604838, 157685404, 157894402, 158315188, 166078431, 169409980, 169700259, 169856932, 170007032, 170409695, 170466488, 170513710, 170608367, 173028944, 173896963, 176090625, 176129212, 179390001, 179489057, 179627464, 179840468, 179849042, 180004216, 181779081, 183027151, 183645319, 183698797, 185922012, 185997252, 188312483, 188675799, 190977533, 190992569, 191006194, 191033518, 191038774, 191096249, 191166163, 191194426, 191443343, 191522106, 191568039, 200104642, 202506661, 202537381, 202602917, 203070590, 203120766, 203389054, 203690071, 203971238, 203986524, 209040857, 209125756, 212055489, 212322418, 212746849, 213002877, 213055164, 213088023, 213259873, 213273386, 213435118, 213437318, 213438231, 213493071, 213532268, 213542834, 213584431, 213659891, 215285828, 215880731, 216112976, 216684637, 217369699, 217565298, 217576549, 218186795, 219743185, 220082234, 221623802, 221986406, 222283890, 223089542, 223138630, 223311265, 224431494, 224547358, 224587256, 224589550, 224655650, 224785518, 224810917, 224813302, 225126263, 225429618, 225432950, 225440869, 236107233, 236709921, 236838947, 237117095, 237143271, 237172455, 237209953, 237354143, 237372743, 237668065, 237703073, 237714273, 239743521, 240512803, 240522627, 240560417, 240656513, 241015715, 241062755, 241065383, 243523041, 245865199, 246261793, 246556195, 246774817, 246923491, 246928419, 246981667, 247014847, 247058369, 247112833, 247118177, 247119137, 247128739, 247316903, 249533729, 250235623, 250269543, 251402351, 252339047, 253260911, 253293679, 254844367, 255547879, 256077281, 256345377, 258124199, 258354465, 258605063, 258744193, 258845603, 258856961, 258926689, 269869248, 270174334, 270709417, 270778994, 270781796, 271102503, 271478858, 271490090, 272870654, 273335275, 273369140, 273924313, 274108530, 274116736, 276818662, 277476156, 279156579, 279349675, 280108533, 280128712, 280132869, 280162403, 280280292, 280413430, 280506130, 280677397, 280678580, 280686710, 280689066, 282736758, 283095348, 283110901, 283275116, 283823226, 283890012, 284479340, 284606461, 286700477, 286798916, 290055764, 291557706, 291665349, 291804100, 292138018, 292166446, 292418738, 292451039, 300298041, 300374839, 300597935, 303073389, 303083839, 303266673, 303354997, 303430688, 303576261, 303724281, 303819694, 304242723, 304382625, 306247792, 307227811, 307468786, 307724489, 310252031, 310358241, 310373094, 310833159, 311015256, 313357609, 313683893, 313701861, 313706996, 313707317, 313710350, 313795700, 314027746, 314038181, 314091299, 314205627, 314233813, 316741830, 316797986, 317486755, 317794164, 320076137, 322657125, 322887778, 323506876, 323572412, 323605180, 325060058, 325320188, 325398738, 325541490, 325671619, 333868843, 336806130, 337212108, 337282686, 337285434, 337585223, 338036037, 338298087, 338566051, 340943551, 341190970, 342995704, 343352124, 343912673, 344585053, 346977248, 347218098, 347262163, 347278576, 347438191, 347655959, 347684788, 347726430, 347727772, 347776035, 347776629, 349500753, 350880161, 350887073, 353384123, 355496998, 355906922, 355979793, 356545959, 358637867, 358905016, 359164318, 359247286, 359350571, 359579447, 365560330, 367399355, 367420285, 367510727, 368013212, 370234760, 370353345, 370710317, 371074566, 371122285, 371194213, 371448425, 371448430, 371545055, 371593469, 371596922, 371758751, 371964792, 372151328, 376550136, 376710172, 376795771, 376826271, 376906556, 380514830, 380774774, 380775037, 381030322, 381136500, 381281631, 381282269, 381285504, 381330595, 381331422, 381335911, 381336484, 383907298, 383917408, 384595009, 384595013, 387799894, 387823201, 392581647, 392584937, 392742684, 392906485, 393003349, 400644707, 400973830, 404428547, 404432113, 404432865, 404469244, 404478897, 404694860, 406887479, 408294949, 408789955, 410022510, 410467324, 410586448, 410945965, 411845275, 414327152, 414327932, 414329781, 414346257, 414346439, 414639928, 414835998, 414894517, 414986533, 417465377, 417465381, 417492216, 418259232, 419310946, 420103495, 420242342, 420380455, 420658662, 420717432, 423183880, 424539259, 425929170, 425972964, 426050649, 426126450, 426142833, 426607922, 437289840, 437347469, 437412335, 437423943, 437455540, 437462252, 437597991, 437617485, 437986305, 437986507, 437986828, 437987072, 438015591, 438034813, 438038966, 438179623, 438347971, 438483573, 438547062, 438895551, 441592676, 442032555, 443548979, 447881379, 447881655, 447881895, 447887844, 448416189, 448445746, 448449012, 450942191, 452816744, 453668677, 454434495, 456610076, 456642844, 456738709, 457544600, 459451897, 459680944, 468058810, 468083581, 470964084, 471470955, 471567278, 472267822, 481177859, 481210627, 481435874, 481455115, 481485378, 481490218, 485105638, 486005878, 486383494, 487988916, 488103783, 490661867, 491574090, 491578272, 492891370, 493041952, 493441205, 493582844, 493716979, 504577572, 504740359, 505091638, 505592418, 505656212, 509516275, 514998531, 515571132, 515594682, 518712698, 521362273, 526592419, 526807354, 527348842, 538294791, 544689535, 545535009, 548544752, 548563346, 548595116, 551679010, 558034099, 560329411, 560356209, 560671018, 560671152, 560692590, 560845442, 569212097, 569474241, 572252718, 575326764, 576174758, 576190819, 582099184, 582099438, 582372519, 582558889, 586552164, 591325418, 594231990, 594243961, 605711268, 615672071, 616086845, 621792370, 624879850, 627432831, 640040548, 654392808, 658675477, 659420283, 672891587, 694768102, 705890982, 725543146, 759097578, 761686526, 795383908, 878105336, 908643300, 945213471 };
staticJArray<int32_t,int32_t> nsHtml5AttributeName::ATTRIBUTE_HASHES = { ATTRIBUTE_HASHES_DATA, MOZ_ARRAY_LENGTH(ATTRIBUTE_HASHES_DATA) };
void
nsHtml5AttributeName::initializeStatics()
@@ -1079,6 +1080,7 @@ nsHtml5AttributeName::initializeStatics()
ATTR_ONREPEAT = new nsHtml5AttributeName(ALL_NO_NS, SAME_LOCAL(nsHtml5Atoms::onrepeat), ALL_NO_PREFIX);
ATTR_ONSELECT = new nsHtml5AttributeName(ALL_NO_NS, SAME_LOCAL(nsHtml5Atoms::onselect), ALL_NO_PREFIX);
ATTR_NOTATION = new nsHtml5AttributeName(ALL_NO_NS, SAME_LOCAL(nsHtml5Atoms::notation), ALL_NO_PREFIX);
+ ATTR_NOMODULE = new nsHtml5AttributeName(ALL_NO_NS, SAME_LOCAL(nsHtml5Atoms::nomodule), ALL_NO_PREFIX);
ATTR_NORESIZE = new nsHtml5AttributeName(ALL_NO_NS, SAME_LOCAL(nsHtml5Atoms::noresize), ALL_NO_PREFIX);
ATTR_MANIFEST = new nsHtml5AttributeName(ALL_NO_NS, SAME_LOCAL(nsHtml5Atoms::manifest), ALL_NO_PREFIX);
ATTR_MATHSIZE = new nsHtml5AttributeName(ALL_NO_NS, SAME_LOCAL(nsHtml5Atoms::mathsize), ALL_NO_PREFIX);
@@ -1401,7 +1403,7 @@ nsHtml5AttributeName::initializeStatics()
ATTR_GLYPH_ORIENTATION_VERTICAL = new nsHtml5AttributeName(ALL_NO_NS, SAME_LOCAL(nsHtml5Atoms::glyph_orientation_vertical), ALL_NO_PREFIX);
ATTR_COLOR_INTERPOLATION_FILTERS = new nsHtml5AttributeName(ALL_NO_NS, SAME_LOCAL(nsHtml5Atoms::color_interpolation_filters), ALL_NO_PREFIX);
ATTR_GLYPH_ORIENTATION_HORIZONTAL = new nsHtml5AttributeName(ALL_NO_NS, SAME_LOCAL(nsHtml5Atoms::glyph_orientation_horizontal), ALL_NO_PREFIX);
- ATTRIBUTE_NAMES = new nsHtml5AttributeName*[583];
+ ATTRIBUTE_NAMES = new nsHtml5AttributeName*[584];
ATTRIBUTE_NAMES[0] = ATTR_D;
ATTRIBUTE_NAMES[1] = ATTR_K;
ATTRIBUTE_NAMES[2] = ATTR_R;
@@ -1663,328 +1665,329 @@ nsHtml5AttributeName::initializeStatics()
ATTRIBUTE_NAMES[258] = ATTR_ONREPEAT;
ATTRIBUTE_NAMES[259] = ATTR_ONSELECT;
ATTRIBUTE_NAMES[260] = ATTR_NOTATION;
- ATTRIBUTE_NAMES[261] = ATTR_NORESIZE;
- ATTRIBUTE_NAMES[262] = ATTR_MANIFEST;
- ATTRIBUTE_NAMES[263] = ATTR_MATHSIZE;
- ATTRIBUTE_NAMES[264] = ATTR_MULTIPLE;
- ATTRIBUTE_NAMES[265] = ATTR_LONGDESC;
- ATTRIBUTE_NAMES[266] = ATTR_LANGUAGE;
- ATTRIBUTE_NAMES[267] = ATTR_TEMPLATE;
- ATTRIBUTE_NAMES[268] = ATTR_TABINDEX;
- ATTRIBUTE_NAMES[269] = ATTR_PROPERTY;
- ATTRIBUTE_NAMES[270] = ATTR_READONLY;
- ATTRIBUTE_NAMES[271] = ATTR_SELECTED;
- ATTRIBUTE_NAMES[272] = ATTR_ROWLINES;
- ATTRIBUTE_NAMES[273] = ATTR_SEAMLESS;
- ATTRIBUTE_NAMES[274] = ATTR_ROWALIGN;
- ATTRIBUTE_NAMES[275] = ATTR_STRETCHY;
- ATTRIBUTE_NAMES[276] = ATTR_REQUIRED;
- ATTRIBUTE_NAMES[277] = ATTR_XML_BASE;
- ATTRIBUTE_NAMES[278] = ATTR_XML_LANG;
- ATTRIBUTE_NAMES[279] = ATTR_X_HEIGHT;
- ATTRIBUTE_NAMES[280] = ATTR_ARIA_OWNS;
- ATTRIBUTE_NAMES[281] = ATTR_AUTOFOCUS;
- ATTRIBUTE_NAMES[282] = ATTR_ARIA_SORT;
- ATTRIBUTE_NAMES[283] = ATTR_ACCESSKEY;
- ATTRIBUTE_NAMES[284] = ATTR_ARIA_BUSY;
- ATTRIBUTE_NAMES[285] = ATTR_ARIA_GRAB;
- ATTRIBUTE_NAMES[286] = ATTR_AMPLITUDE;
- ATTRIBUTE_NAMES[287] = ATTR_ARIA_LIVE;
- ATTRIBUTE_NAMES[288] = ATTR_CLIP_RULE;
- ATTRIBUTE_NAMES[289] = ATTR_CLIP_PATH;
- ATTRIBUTE_NAMES[290] = ATTR_EQUALROWS;
- ATTRIBUTE_NAMES[291] = ATTR_ELEVATION;
- ATTRIBUTE_NAMES[292] = ATTR_DIRECTION;
- ATTRIBUTE_NAMES[293] = ATTR_DRAGGABLE;
- ATTRIBUTE_NAMES[294] = ATTR_FILL_RULE;
- ATTRIBUTE_NAMES[295] = ATTR_FONTSTYLE;
- ATTRIBUTE_NAMES[296] = ATTR_FONT_SIZE;
- ATTRIBUTE_NAMES[297] = ATTR_KEYSYSTEM;
- ATTRIBUTE_NAMES[298] = ATTR_KEYPOINTS;
- ATTRIBUTE_NAMES[299] = ATTR_HIDEFOCUS;
- ATTRIBUTE_NAMES[300] = ATTR_ONMESSAGE;
- ATTRIBUTE_NAMES[301] = ATTR_INTERCEPT;
- ATTRIBUTE_NAMES[302] = ATTR_ONDRAGEND;
- ATTRIBUTE_NAMES[303] = ATTR_ONMOVEEND;
- ATTRIBUTE_NAMES[304] = ATTR_ONINVALID;
- ATTRIBUTE_NAMES[305] = ATTR_INTEGRITY;
- ATTRIBUTE_NAMES[306] = ATTR_ONKEYDOWN;
- ATTRIBUTE_NAMES[307] = ATTR_ONFOCUSIN;
- ATTRIBUTE_NAMES[308] = ATTR_ONMOUSEUP;
- ATTRIBUTE_NAMES[309] = ATTR_INPUTMODE;
- ATTRIBUTE_NAMES[310] = ATTR_ONROWEXIT;
- ATTRIBUTE_NAMES[311] = ATTR_MATHCOLOR;
- ATTRIBUTE_NAMES[312] = ATTR_MASKUNITS;
- ATTRIBUTE_NAMES[313] = ATTR_MAXLENGTH;
- ATTRIBUTE_NAMES[314] = ATTR_LINEBREAK;
- ATTRIBUTE_NAMES[315] = ATTR_TRANSFORM;
- ATTRIBUTE_NAMES[316] = ATTR_V_HANGING;
- ATTRIBUTE_NAMES[317] = ATTR_VALUETYPE;
- ATTRIBUTE_NAMES[318] = ATTR_POINTSATZ;
- ATTRIBUTE_NAMES[319] = ATTR_POINTSATX;
- ATTRIBUTE_NAMES[320] = ATTR_POINTSATY;
- ATTRIBUTE_NAMES[321] = ATTR_SYMMETRIC;
- ATTRIBUTE_NAMES[322] = ATTR_SCROLLING;
- ATTRIBUTE_NAMES[323] = ATTR_REPEATDUR;
- ATTRIBUTE_NAMES[324] = ATTR_SELECTION;
- ATTRIBUTE_NAMES[325] = ATTR_SEPARATOR;
- ATTRIBUTE_NAMES[326] = ATTR_XML_SPACE;
- ATTRIBUTE_NAMES[327] = ATTR_AUTOSUBMIT;
- ATTRIBUTE_NAMES[328] = ATTR_ALPHABETIC;
- ATTRIBUTE_NAMES[329] = ATTR_ACTIONTYPE;
- ATTRIBUTE_NAMES[330] = ATTR_ACCUMULATE;
- ATTRIBUTE_NAMES[331] = ATTR_ARIA_LEVEL;
- ATTRIBUTE_NAMES[332] = ATTR_COLUMNSPAN;
- ATTRIBUTE_NAMES[333] = ATTR_CAP_HEIGHT;
- ATTRIBUTE_NAMES[334] = ATTR_BACKGROUND;
- ATTRIBUTE_NAMES[335] = ATTR_GLYPH_NAME;
- ATTRIBUTE_NAMES[336] = ATTR_GROUPALIGN;
- ATTRIBUTE_NAMES[337] = ATTR_FONTFAMILY;
- ATTRIBUTE_NAMES[338] = ATTR_FONTWEIGHT;
- ATTRIBUTE_NAMES[339] = ATTR_FONT_STYLE;
- ATTRIBUTE_NAMES[340] = ATTR_KEYSPLINES;
- ATTRIBUTE_NAMES[341] = ATTR_HTTP_EQUIV;
- ATTRIBUTE_NAMES[342] = ATTR_ONACTIVATE;
- ATTRIBUTE_NAMES[343] = ATTR_OCCURRENCE;
- ATTRIBUTE_NAMES[344] = ATTR_IRRELEVANT;
- ATTRIBUTE_NAMES[345] = ATTR_ONDBLCLICK;
- ATTRIBUTE_NAMES[346] = ATTR_ONDRAGDROP;
- ATTRIBUTE_NAMES[347] = ATTR_ONKEYPRESS;
- ATTRIBUTE_NAMES[348] = ATTR_ONROWENTER;
- ATTRIBUTE_NAMES[349] = ATTR_ONDRAGOVER;
- ATTRIBUTE_NAMES[350] = ATTR_ONFOCUSOUT;
- ATTRIBUTE_NAMES[351] = ATTR_ONMOUSEOUT;
- ATTRIBUTE_NAMES[352] = ATTR_NUMOCTAVES;
- ATTRIBUTE_NAMES[353] = ATTR_MARKER_MID;
- ATTRIBUTE_NAMES[354] = ATTR_MARKER_END;
- ATTRIBUTE_NAMES[355] = ATTR_TEXTLENGTH;
- ATTRIBUTE_NAMES[356] = ATTR_VISIBILITY;
- ATTRIBUTE_NAMES[357] = ATTR_VIEWTARGET;
- ATTRIBUTE_NAMES[358] = ATTR_VERT_ADV_Y;
- ATTRIBUTE_NAMES[359] = ATTR_PATHLENGTH;
- ATTRIBUTE_NAMES[360] = ATTR_REPEAT_MAX;
- ATTRIBUTE_NAMES[361] = ATTR_RADIOGROUP;
- ATTRIBUTE_NAMES[362] = ATTR_STOP_COLOR;
- ATTRIBUTE_NAMES[363] = ATTR_SEPARATORS;
- ATTRIBUTE_NAMES[364] = ATTR_REPEAT_MIN;
- ATTRIBUTE_NAMES[365] = ATTR_ROWSPACING;
- ATTRIBUTE_NAMES[366] = ATTR_ZOOMANDPAN;
- ATTRIBUTE_NAMES[367] = ATTR_XLINK_TYPE;
- ATTRIBUTE_NAMES[368] = ATTR_XLINK_ROLE;
- ATTRIBUTE_NAMES[369] = ATTR_XLINK_HREF;
- ATTRIBUTE_NAMES[370] = ATTR_XLINK_SHOW;
- ATTRIBUTE_NAMES[371] = ATTR_ACCENTUNDER;
- ATTRIBUTE_NAMES[372] = ATTR_ARIA_SECRET;
- ATTRIBUTE_NAMES[373] = ATTR_ARIA_ATOMIC;
- ATTRIBUTE_NAMES[374] = ATTR_ARIA_HIDDEN;
- ATTRIBUTE_NAMES[375] = ATTR_ARIA_FLOWTO;
- ATTRIBUTE_NAMES[376] = ATTR_ARABIC_FORM;
- ATTRIBUTE_NAMES[377] = ATTR_CELLPADDING;
- ATTRIBUTE_NAMES[378] = ATTR_CELLSPACING;
- ATTRIBUTE_NAMES[379] = ATTR_COLUMNWIDTH;
- ATTRIBUTE_NAMES[380] = ATTR_CROSSORIGIN;
- ATTRIBUTE_NAMES[381] = ATTR_COLUMNALIGN;
- ATTRIBUTE_NAMES[382] = ATTR_COLUMNLINES;
- ATTRIBUTE_NAMES[383] = ATTR_CONTEXTMENU;
- ATTRIBUTE_NAMES[384] = ATTR_BASEPROFILE;
- ATTRIBUTE_NAMES[385] = ATTR_FONT_FAMILY;
- ATTRIBUTE_NAMES[386] = ATTR_FRAMEBORDER;
- ATTRIBUTE_NAMES[387] = ATTR_FILTERUNITS;
- ATTRIBUTE_NAMES[388] = ATTR_FLOOD_COLOR;
- ATTRIBUTE_NAMES[389] = ATTR_FONT_WEIGHT;
- ATTRIBUTE_NAMES[390] = ATTR_HORIZ_ADV_X;
- ATTRIBUTE_NAMES[391] = ATTR_ONDRAGLEAVE;
- ATTRIBUTE_NAMES[392] = ATTR_ONMOUSEMOVE;
- ATTRIBUTE_NAMES[393] = ATTR_ORIENTATION;
- ATTRIBUTE_NAMES[394] = ATTR_ONMOUSEDOWN;
- ATTRIBUTE_NAMES[395] = ATTR_ONMOUSEOVER;
- ATTRIBUTE_NAMES[396] = ATTR_ONDRAGENTER;
- ATTRIBUTE_NAMES[397] = ATTR_IDEOGRAPHIC;
- ATTRIBUTE_NAMES[398] = ATTR_ONBEFORECUT;
- ATTRIBUTE_NAMES[399] = ATTR_ONFORMINPUT;
- ATTRIBUTE_NAMES[400] = ATTR_ONDRAGSTART;
- ATTRIBUTE_NAMES[401] = ATTR_ONMOVESTART;
- ATTRIBUTE_NAMES[402] = ATTR_MARKERUNITS;
- ATTRIBUTE_NAMES[403] = ATTR_MATHVARIANT;
- ATTRIBUTE_NAMES[404] = ATTR_MARGINWIDTH;
- ATTRIBUTE_NAMES[405] = ATTR_MARKERWIDTH;
- ATTRIBUTE_NAMES[406] = ATTR_TEXT_ANCHOR;
- ATTRIBUTE_NAMES[407] = ATTR_TABLEVALUES;
- ATTRIBUTE_NAMES[408] = ATTR_SCRIPTLEVEL;
- ATTRIBUTE_NAMES[409] = ATTR_REPEATCOUNT;
- ATTRIBUTE_NAMES[410] = ATTR_STITCHTILES;
- ATTRIBUTE_NAMES[411] = ATTR_STARTOFFSET;
- ATTRIBUTE_NAMES[412] = ATTR_SCROLLDELAY;
- ATTRIBUTE_NAMES[413] = ATTR_XMLNS_XLINK;
- ATTRIBUTE_NAMES[414] = ATTR_XLINK_TITLE;
- ATTRIBUTE_NAMES[415] = ATTR_ARIA_INVALID;
- ATTRIBUTE_NAMES[416] = ATTR_ARIA_PRESSED;
- ATTRIBUTE_NAMES[417] = ATTR_ARIA_CHECKED;
- ATTRIBUTE_NAMES[418] = ATTR_AUTOCOMPLETE;
- ATTRIBUTE_NAMES[419] = ATTR_ARIA_SETSIZE;
- ATTRIBUTE_NAMES[420] = ATTR_ARIA_CHANNEL;
- ATTRIBUTE_NAMES[421] = ATTR_EQUALCOLUMNS;
- ATTRIBUTE_NAMES[422] = ATTR_DISPLAYSTYLE;
- ATTRIBUTE_NAMES[423] = ATTR_DATAFORMATAS;
- ATTRIBUTE_NAMES[424] = ATTR_FILL_OPACITY;
- ATTRIBUTE_NAMES[425] = ATTR_FONT_VARIANT;
- ATTRIBUTE_NAMES[426] = ATTR_FONT_STRETCH;
- ATTRIBUTE_NAMES[427] = ATTR_FRAMESPACING;
- ATTRIBUTE_NAMES[428] = ATTR_KERNELMATRIX;
- ATTRIBUTE_NAMES[429] = ATTR_ONDEACTIVATE;
- ATTRIBUTE_NAMES[430] = ATTR_ONROWSDELETE;
- ATTRIBUTE_NAMES[431] = ATTR_ONMOUSELEAVE;
- ATTRIBUTE_NAMES[432] = ATTR_ONFORMCHANGE;
- ATTRIBUTE_NAMES[433] = ATTR_ONCELLCHANGE;
- ATTRIBUTE_NAMES[434] = ATTR_ONMOUSEWHEEL;
- ATTRIBUTE_NAMES[435] = ATTR_ONMOUSEENTER;
- ATTRIBUTE_NAMES[436] = ATTR_ONAFTERPRINT;
- ATTRIBUTE_NAMES[437] = ATTR_ONBEFORECOPY;
- ATTRIBUTE_NAMES[438] = ATTR_MARGINHEIGHT;
- ATTRIBUTE_NAMES[439] = ATTR_MARKERHEIGHT;
- ATTRIBUTE_NAMES[440] = ATTR_MARKER_START;
- ATTRIBUTE_NAMES[441] = ATTR_MATHEMATICAL;
- ATTRIBUTE_NAMES[442] = ATTR_LENGTHADJUST;
- ATTRIBUTE_NAMES[443] = ATTR_UNSELECTABLE;
- ATTRIBUTE_NAMES[444] = ATTR_UNICODE_BIDI;
- ATTRIBUTE_NAMES[445] = ATTR_UNITS_PER_EM;
- ATTRIBUTE_NAMES[446] = ATTR_WORD_SPACING;
- ATTRIBUTE_NAMES[447] = ATTR_WRITING_MODE;
- ATTRIBUTE_NAMES[448] = ATTR_V_ALPHABETIC;
- ATTRIBUTE_NAMES[449] = ATTR_PATTERNUNITS;
- ATTRIBUTE_NAMES[450] = ATTR_SPREADMETHOD;
- ATTRIBUTE_NAMES[451] = ATTR_SURFACESCALE;
- ATTRIBUTE_NAMES[452] = ATTR_STROKE_WIDTH;
- ATTRIBUTE_NAMES[453] = ATTR_REPEAT_START;
- ATTRIBUTE_NAMES[454] = ATTR_STDDEVIATION;
- ATTRIBUTE_NAMES[455] = ATTR_STOP_OPACITY;
- ATTRIBUTE_NAMES[456] = ATTR_ARIA_CONTROLS;
- ATTRIBUTE_NAMES[457] = ATTR_ARIA_HASPOPUP;
- ATTRIBUTE_NAMES[458] = ATTR_ACCENT_HEIGHT;
- ATTRIBUTE_NAMES[459] = ATTR_ARIA_VALUENOW;
- ATTRIBUTE_NAMES[460] = ATTR_ARIA_RELEVANT;
- ATTRIBUTE_NAMES[461] = ATTR_ARIA_POSINSET;
- ATTRIBUTE_NAMES[462] = ATTR_ARIA_VALUEMAX;
- ATTRIBUTE_NAMES[463] = ATTR_ARIA_READONLY;
- ATTRIBUTE_NAMES[464] = ATTR_ARIA_SELECTED;
- ATTRIBUTE_NAMES[465] = ATTR_ARIA_REQUIRED;
- ATTRIBUTE_NAMES[466] = ATTR_ARIA_EXPANDED;
- ATTRIBUTE_NAMES[467] = ATTR_ARIA_DISABLED;
- ATTRIBUTE_NAMES[468] = ATTR_ATTRIBUTETYPE;
- ATTRIBUTE_NAMES[469] = ATTR_ATTRIBUTENAME;
- ATTRIBUTE_NAMES[470] = ATTR_ARIA_DATATYPE;
- ATTRIBUTE_NAMES[471] = ATTR_ARIA_VALUEMIN;
- ATTRIBUTE_NAMES[472] = ATTR_BASEFREQUENCY;
- ATTRIBUTE_NAMES[473] = ATTR_COLUMNSPACING;
- ATTRIBUTE_NAMES[474] = ATTR_COLOR_PROFILE;
- ATTRIBUTE_NAMES[475] = ATTR_CLIPPATHUNITS;
- ATTRIBUTE_NAMES[476] = ATTR_DEFINITIONURL;
- ATTRIBUTE_NAMES[477] = ATTR_GRADIENTUNITS;
- ATTRIBUTE_NAMES[478] = ATTR_FLOOD_OPACITY;
- ATTRIBUTE_NAMES[479] = ATTR_ONAFTERUPDATE;
- ATTRIBUTE_NAMES[480] = ATTR_ONERRORUPDATE;
- ATTRIBUTE_NAMES[481] = ATTR_ONBEFOREPASTE;
- ATTRIBUTE_NAMES[482] = ATTR_ONLOSECAPTURE;
- ATTRIBUTE_NAMES[483] = ATTR_ONCONTEXTMENU;
- ATTRIBUTE_NAMES[484] = ATTR_ONSELECTSTART;
- ATTRIBUTE_NAMES[485] = ATTR_ONBEFOREPRINT;
- ATTRIBUTE_NAMES[486] = ATTR_MOVABLELIMITS;
- ATTRIBUTE_NAMES[487] = ATTR_LINETHICKNESS;
- ATTRIBUTE_NAMES[488] = ATTR_UNICODE_RANGE;
- ATTRIBUTE_NAMES[489] = ATTR_THINMATHSPACE;
- ATTRIBUTE_NAMES[490] = ATTR_VERT_ORIGIN_X;
- ATTRIBUTE_NAMES[491] = ATTR_VERT_ORIGIN_Y;
- ATTRIBUTE_NAMES[492] = ATTR_V_IDEOGRAPHIC;
- ATTRIBUTE_NAMES[493] = ATTR_PRESERVEALPHA;
- ATTRIBUTE_NAMES[494] = ATTR_SCRIPTMINSIZE;
- ATTRIBUTE_NAMES[495] = ATTR_SPECIFICATION;
- ATTRIBUTE_NAMES[496] = ATTR_XLINK_ACTUATE;
- ATTRIBUTE_NAMES[497] = ATTR_XLINK_ARCROLE;
- ATTRIBUTE_NAMES[498] = ATTR_ACCEPT_CHARSET;
- ATTRIBUTE_NAMES[499] = ATTR_ALIGNMENTSCOPE;
- ATTRIBUTE_NAMES[500] = ATTR_ARIA_MULTILINE;
- ATTRIBUTE_NAMES[501] = ATTR_BASELINE_SHIFT;
- ATTRIBUTE_NAMES[502] = ATTR_HORIZ_ORIGIN_X;
- ATTRIBUTE_NAMES[503] = ATTR_HORIZ_ORIGIN_Y;
- ATTRIBUTE_NAMES[504] = ATTR_ONBEFOREUPDATE;
- ATTRIBUTE_NAMES[505] = ATTR_ONFILTERCHANGE;
- ATTRIBUTE_NAMES[506] = ATTR_ONROWSINSERTED;
- ATTRIBUTE_NAMES[507] = ATTR_ONBEFOREUNLOAD;
- ATTRIBUTE_NAMES[508] = ATTR_MATHBACKGROUND;
- ATTRIBUTE_NAMES[509] = ATTR_LETTER_SPACING;
- ATTRIBUTE_NAMES[510] = ATTR_LIGHTING_COLOR;
- ATTRIBUTE_NAMES[511] = ATTR_THICKMATHSPACE;
- ATTRIBUTE_NAMES[512] = ATTR_TEXT_RENDERING;
- ATTRIBUTE_NAMES[513] = ATTR_V_MATHEMATICAL;
- ATTRIBUTE_NAMES[514] = ATTR_POINTER_EVENTS;
- ATTRIBUTE_NAMES[515] = ATTR_PRIMITIVEUNITS;
- ATTRIBUTE_NAMES[516] = ATTR_REFERRERPOLICY;
- ATTRIBUTE_NAMES[517] = ATTR_SYSTEMLANGUAGE;
- ATTRIBUTE_NAMES[518] = ATTR_STROKE_LINECAP;
- ATTRIBUTE_NAMES[519] = ATTR_SUBSCRIPTSHIFT;
- ATTRIBUTE_NAMES[520] = ATTR_STROKE_OPACITY;
- ATTRIBUTE_NAMES[521] = ATTR_ARIA_DROPEFFECT;
- ATTRIBUTE_NAMES[522] = ATTR_ARIA_LABELLEDBY;
- ATTRIBUTE_NAMES[523] = ATTR_ARIA_TEMPLATEID;
- ATTRIBUTE_NAMES[524] = ATTR_COLOR_RENDERING;
- ATTRIBUTE_NAMES[525] = ATTR_CONTENTEDITABLE;
- ATTRIBUTE_NAMES[526] = ATTR_DIFFUSECONSTANT;
- ATTRIBUTE_NAMES[527] = ATTR_ONDATAAVAILABLE;
- ATTRIBUTE_NAMES[528] = ATTR_ONCONTROLSELECT;
- ATTRIBUTE_NAMES[529] = ATTR_IMAGE_RENDERING;
- ATTRIBUTE_NAMES[530] = ATTR_MEDIUMMATHSPACE;
- ATTRIBUTE_NAMES[531] = ATTR_TEXT_DECORATION;
- ATTRIBUTE_NAMES[532] = ATTR_SHAPE_RENDERING;
- ATTRIBUTE_NAMES[533] = ATTR_STROKE_LINEJOIN;
- ATTRIBUTE_NAMES[534] = ATTR_REPEAT_TEMPLATE;
- ATTRIBUTE_NAMES[535] = ATTR_ARIA_DESCRIBEDBY;
- ATTRIBUTE_NAMES[536] = ATTR_FONT_SIZE_ADJUST;
- ATTRIBUTE_NAMES[537] = ATTR_KERNELUNITLENGTH;
- ATTRIBUTE_NAMES[538] = ATTR_ONBEFOREACTIVATE;
- ATTRIBUTE_NAMES[539] = ATTR_ONPROPERTYCHANGE;
- ATTRIBUTE_NAMES[540] = ATTR_ONDATASETCHANGED;
- ATTRIBUTE_NAMES[541] = ATTR_MASKCONTENTUNITS;
- ATTRIBUTE_NAMES[542] = ATTR_PATTERNTRANSFORM;
- ATTRIBUTE_NAMES[543] = ATTR_REQUIREDFEATURES;
- ATTRIBUTE_NAMES[544] = ATTR_RENDERING_INTENT;
- ATTRIBUTE_NAMES[545] = ATTR_SPECULAREXPONENT;
- ATTRIBUTE_NAMES[546] = ATTR_SPECULARCONSTANT;
- ATTRIBUTE_NAMES[547] = ATTR_SUPERSCRIPTSHIFT;
- ATTRIBUTE_NAMES[548] = ATTR_STROKE_DASHARRAY;
- ATTRIBUTE_NAMES[549] = ATTR_XCHANNELSELECTOR;
- ATTRIBUTE_NAMES[550] = ATTR_YCHANNELSELECTOR;
- ATTRIBUTE_NAMES[551] = ATTR_ARIA_AUTOCOMPLETE;
- ATTRIBUTE_NAMES[552] = ATTR_ENABLE_BACKGROUND;
- ATTRIBUTE_NAMES[553] = ATTR_DOMINANT_BASELINE;
- ATTRIBUTE_NAMES[554] = ATTR_GRADIENTTRANSFORM;
- ATTRIBUTE_NAMES[555] = ATTR_ONBEFORDEACTIVATE;
- ATTRIBUTE_NAMES[556] = ATTR_ONDATASETCOMPLETE;
- ATTRIBUTE_NAMES[557] = ATTR_OVERLINE_POSITION;
- ATTRIBUTE_NAMES[558] = ATTR_ONBEFOREEDITFOCUS;
- ATTRIBUTE_NAMES[559] = ATTR_LIMITINGCONEANGLE;
- ATTRIBUTE_NAMES[560] = ATTR_VERYTHINMATHSPACE;
- ATTRIBUTE_NAMES[561] = ATTR_STROKE_DASHOFFSET;
- ATTRIBUTE_NAMES[562] = ATTR_STROKE_MITERLIMIT;
- ATTRIBUTE_NAMES[563] = ATTR_ALIGNMENT_BASELINE;
- ATTRIBUTE_NAMES[564] = ATTR_ONREADYSTATECHANGE;
- ATTRIBUTE_NAMES[565] = ATTR_OVERLINE_THICKNESS;
- ATTRIBUTE_NAMES[566] = ATTR_UNDERLINE_POSITION;
- ATTRIBUTE_NAMES[567] = ATTR_VERYTHICKMATHSPACE;
- ATTRIBUTE_NAMES[568] = ATTR_REQUIREDEXTENSIONS;
- ATTRIBUTE_NAMES[569] = ATTR_COLOR_INTERPOLATION;
- ATTRIBUTE_NAMES[570] = ATTR_UNDERLINE_THICKNESS;
- ATTRIBUTE_NAMES[571] = ATTR_PRESERVEASPECTRATIO;
- ATTRIBUTE_NAMES[572] = ATTR_PATTERNCONTENTUNITS;
- ATTRIBUTE_NAMES[573] = ATTR_ARIA_MULTISELECTABLE;
- ATTRIBUTE_NAMES[574] = ATTR_SCRIPTSIZEMULTIPLIER;
- ATTRIBUTE_NAMES[575] = ATTR_ARIA_ACTIVEDESCENDANT;
- ATTRIBUTE_NAMES[576] = ATTR_VERYVERYTHINMATHSPACE;
- ATTRIBUTE_NAMES[577] = ATTR_VERYVERYTHICKMATHSPACE;
- ATTRIBUTE_NAMES[578] = ATTR_STRIKETHROUGH_POSITION;
- ATTRIBUTE_NAMES[579] = ATTR_STRIKETHROUGH_THICKNESS;
- ATTRIBUTE_NAMES[580] = ATTR_GLYPH_ORIENTATION_VERTICAL;
- ATTRIBUTE_NAMES[581] = ATTR_COLOR_INTERPOLATION_FILTERS;
- ATTRIBUTE_NAMES[582] = ATTR_GLYPH_ORIENTATION_HORIZONTAL;
+ ATTRIBUTE_NAMES[261] = ATTR_NOMODULE;
+ ATTRIBUTE_NAMES[262] = ATTR_NORESIZE;
+ ATTRIBUTE_NAMES[263] = ATTR_MANIFEST;
+ ATTRIBUTE_NAMES[264] = ATTR_MATHSIZE;
+ ATTRIBUTE_NAMES[265] = ATTR_MULTIPLE;
+ ATTRIBUTE_NAMES[266] = ATTR_LONGDESC;
+ ATTRIBUTE_NAMES[267] = ATTR_LANGUAGE;
+ ATTRIBUTE_NAMES[268] = ATTR_TEMPLATE;
+ ATTRIBUTE_NAMES[269] = ATTR_TABINDEX;
+ ATTRIBUTE_NAMES[270] = ATTR_PROPERTY;
+ ATTRIBUTE_NAMES[271] = ATTR_READONLY;
+ ATTRIBUTE_NAMES[272] = ATTR_SELECTED;
+ ATTRIBUTE_NAMES[273] = ATTR_ROWLINES;
+ ATTRIBUTE_NAMES[274] = ATTR_SEAMLESS;
+ ATTRIBUTE_NAMES[275] = ATTR_ROWALIGN;
+ ATTRIBUTE_NAMES[276] = ATTR_STRETCHY;
+ ATTRIBUTE_NAMES[277] = ATTR_REQUIRED;
+ ATTRIBUTE_NAMES[278] = ATTR_XML_BASE;
+ ATTRIBUTE_NAMES[279] = ATTR_XML_LANG;
+ ATTRIBUTE_NAMES[280] = ATTR_X_HEIGHT;
+ ATTRIBUTE_NAMES[281] = ATTR_ARIA_OWNS;
+ ATTRIBUTE_NAMES[282] = ATTR_AUTOFOCUS;
+ ATTRIBUTE_NAMES[283] = ATTR_ARIA_SORT;
+ ATTRIBUTE_NAMES[284] = ATTR_ACCESSKEY;
+ ATTRIBUTE_NAMES[285] = ATTR_ARIA_BUSY;
+ ATTRIBUTE_NAMES[286] = ATTR_ARIA_GRAB;
+ ATTRIBUTE_NAMES[287] = ATTR_AMPLITUDE;
+ ATTRIBUTE_NAMES[288] = ATTR_ARIA_LIVE;
+ ATTRIBUTE_NAMES[289] = ATTR_CLIP_RULE;
+ ATTRIBUTE_NAMES[290] = ATTR_CLIP_PATH;
+ ATTRIBUTE_NAMES[291] = ATTR_EQUALROWS;
+ ATTRIBUTE_NAMES[292] = ATTR_ELEVATION;
+ ATTRIBUTE_NAMES[293] = ATTR_DIRECTION;
+ ATTRIBUTE_NAMES[294] = ATTR_DRAGGABLE;
+ ATTRIBUTE_NAMES[295] = ATTR_FILL_RULE;
+ ATTRIBUTE_NAMES[296] = ATTR_FONTSTYLE;
+ ATTRIBUTE_NAMES[297] = ATTR_FONT_SIZE;
+ ATTRIBUTE_NAMES[298] = ATTR_KEYSYSTEM;
+ ATTRIBUTE_NAMES[299] = ATTR_KEYPOINTS;
+ ATTRIBUTE_NAMES[300] = ATTR_HIDEFOCUS;
+ ATTRIBUTE_NAMES[301] = ATTR_ONMESSAGE;
+ ATTRIBUTE_NAMES[302] = ATTR_INTERCEPT;
+ ATTRIBUTE_NAMES[303] = ATTR_ONDRAGEND;
+ ATTRIBUTE_NAMES[304] = ATTR_ONMOVEEND;
+ ATTRIBUTE_NAMES[305] = ATTR_ONINVALID;
+ ATTRIBUTE_NAMES[306] = ATTR_INTEGRITY;
+ ATTRIBUTE_NAMES[307] = ATTR_ONKEYDOWN;
+ ATTRIBUTE_NAMES[308] = ATTR_ONFOCUSIN;
+ ATTRIBUTE_NAMES[309] = ATTR_ONMOUSEUP;
+ ATTRIBUTE_NAMES[310] = ATTR_INPUTMODE;
+ ATTRIBUTE_NAMES[311] = ATTR_ONROWEXIT;
+ ATTRIBUTE_NAMES[312] = ATTR_MATHCOLOR;
+ ATTRIBUTE_NAMES[313] = ATTR_MASKUNITS;
+ ATTRIBUTE_NAMES[314] = ATTR_MAXLENGTH;
+ ATTRIBUTE_NAMES[315] = ATTR_LINEBREAK;
+ ATTRIBUTE_NAMES[316] = ATTR_TRANSFORM;
+ ATTRIBUTE_NAMES[317] = ATTR_V_HANGING;
+ ATTRIBUTE_NAMES[318] = ATTR_VALUETYPE;
+ ATTRIBUTE_NAMES[319] = ATTR_POINTSATZ;
+ ATTRIBUTE_NAMES[320] = ATTR_POINTSATX;
+ ATTRIBUTE_NAMES[321] = ATTR_POINTSATY;
+ ATTRIBUTE_NAMES[322] = ATTR_SYMMETRIC;
+ ATTRIBUTE_NAMES[323] = ATTR_SCROLLING;
+ ATTRIBUTE_NAMES[324] = ATTR_REPEATDUR;
+ ATTRIBUTE_NAMES[325] = ATTR_SELECTION;
+ ATTRIBUTE_NAMES[326] = ATTR_SEPARATOR;
+ ATTRIBUTE_NAMES[327] = ATTR_XML_SPACE;
+ ATTRIBUTE_NAMES[328] = ATTR_AUTOSUBMIT;
+ ATTRIBUTE_NAMES[329] = ATTR_ALPHABETIC;
+ ATTRIBUTE_NAMES[330] = ATTR_ACTIONTYPE;
+ ATTRIBUTE_NAMES[331] = ATTR_ACCUMULATE;
+ ATTRIBUTE_NAMES[332] = ATTR_ARIA_LEVEL;
+ ATTRIBUTE_NAMES[333] = ATTR_COLUMNSPAN;
+ ATTRIBUTE_NAMES[334] = ATTR_CAP_HEIGHT;
+ ATTRIBUTE_NAMES[335] = ATTR_BACKGROUND;
+ ATTRIBUTE_NAMES[336] = ATTR_GLYPH_NAME;
+ ATTRIBUTE_NAMES[337] = ATTR_GROUPALIGN;
+ ATTRIBUTE_NAMES[338] = ATTR_FONTFAMILY;
+ ATTRIBUTE_NAMES[339] = ATTR_FONTWEIGHT;
+ ATTRIBUTE_NAMES[340] = ATTR_FONT_STYLE;
+ ATTRIBUTE_NAMES[341] = ATTR_KEYSPLINES;
+ ATTRIBUTE_NAMES[342] = ATTR_HTTP_EQUIV;
+ ATTRIBUTE_NAMES[343] = ATTR_ONACTIVATE;
+ ATTRIBUTE_NAMES[344] = ATTR_OCCURRENCE;
+ ATTRIBUTE_NAMES[345] = ATTR_IRRELEVANT;
+ ATTRIBUTE_NAMES[346] = ATTR_ONDBLCLICK;
+ ATTRIBUTE_NAMES[347] = ATTR_ONDRAGDROP;
+ ATTRIBUTE_NAMES[348] = ATTR_ONKEYPRESS;
+ ATTRIBUTE_NAMES[349] = ATTR_ONROWENTER;
+ ATTRIBUTE_NAMES[350] = ATTR_ONDRAGOVER;
+ ATTRIBUTE_NAMES[351] = ATTR_ONFOCUSOUT;
+ ATTRIBUTE_NAMES[352] = ATTR_ONMOUSEOUT;
+ ATTRIBUTE_NAMES[353] = ATTR_NUMOCTAVES;
+ ATTRIBUTE_NAMES[354] = ATTR_MARKER_MID;
+ ATTRIBUTE_NAMES[355] = ATTR_MARKER_END;
+ ATTRIBUTE_NAMES[356] = ATTR_TEXTLENGTH;
+ ATTRIBUTE_NAMES[357] = ATTR_VISIBILITY;
+ ATTRIBUTE_NAMES[358] = ATTR_VIEWTARGET;
+ ATTRIBUTE_NAMES[359] = ATTR_VERT_ADV_Y;
+ ATTRIBUTE_NAMES[360] = ATTR_PATHLENGTH;
+ ATTRIBUTE_NAMES[361] = ATTR_REPEAT_MAX;
+ ATTRIBUTE_NAMES[362] = ATTR_RADIOGROUP;
+ ATTRIBUTE_NAMES[363] = ATTR_STOP_COLOR;
+ ATTRIBUTE_NAMES[364] = ATTR_SEPARATORS;
+ ATTRIBUTE_NAMES[365] = ATTR_REPEAT_MIN;
+ ATTRIBUTE_NAMES[366] = ATTR_ROWSPACING;
+ ATTRIBUTE_NAMES[367] = ATTR_ZOOMANDPAN;
+ ATTRIBUTE_NAMES[368] = ATTR_XLINK_TYPE;
+ ATTRIBUTE_NAMES[369] = ATTR_XLINK_ROLE;
+ ATTRIBUTE_NAMES[370] = ATTR_XLINK_HREF;
+ ATTRIBUTE_NAMES[371] = ATTR_XLINK_SHOW;
+ ATTRIBUTE_NAMES[372] = ATTR_ACCENTUNDER;
+ ATTRIBUTE_NAMES[373] = ATTR_ARIA_SECRET;
+ ATTRIBUTE_NAMES[374] = ATTR_ARIA_ATOMIC;
+ ATTRIBUTE_NAMES[375] = ATTR_ARIA_HIDDEN;
+ ATTRIBUTE_NAMES[376] = ATTR_ARIA_FLOWTO;
+ ATTRIBUTE_NAMES[377] = ATTR_ARABIC_FORM;
+ ATTRIBUTE_NAMES[378] = ATTR_CELLPADDING;
+ ATTRIBUTE_NAMES[379] = ATTR_CELLSPACING;
+ ATTRIBUTE_NAMES[380] = ATTR_COLUMNWIDTH;
+ ATTRIBUTE_NAMES[381] = ATTR_CROSSORIGIN;
+ ATTRIBUTE_NAMES[382] = ATTR_COLUMNALIGN;
+ ATTRIBUTE_NAMES[383] = ATTR_COLUMNLINES;
+ ATTRIBUTE_NAMES[384] = ATTR_CONTEXTMENU;
+ ATTRIBUTE_NAMES[385] = ATTR_BASEPROFILE;
+ ATTRIBUTE_NAMES[386] = ATTR_FONT_FAMILY;
+ ATTRIBUTE_NAMES[387] = ATTR_FRAMEBORDER;
+ ATTRIBUTE_NAMES[388] = ATTR_FILTERUNITS;
+ ATTRIBUTE_NAMES[389] = ATTR_FLOOD_COLOR;
+ ATTRIBUTE_NAMES[390] = ATTR_FONT_WEIGHT;
+ ATTRIBUTE_NAMES[391] = ATTR_HORIZ_ADV_X;
+ ATTRIBUTE_NAMES[392] = ATTR_ONDRAGLEAVE;
+ ATTRIBUTE_NAMES[393] = ATTR_ONMOUSEMOVE;
+ ATTRIBUTE_NAMES[394] = ATTR_ORIENTATION;
+ ATTRIBUTE_NAMES[395] = ATTR_ONMOUSEDOWN;
+ ATTRIBUTE_NAMES[396] = ATTR_ONMOUSEOVER;
+ ATTRIBUTE_NAMES[397] = ATTR_ONDRAGENTER;
+ ATTRIBUTE_NAMES[398] = ATTR_IDEOGRAPHIC;
+ ATTRIBUTE_NAMES[399] = ATTR_ONBEFORECUT;
+ ATTRIBUTE_NAMES[400] = ATTR_ONFORMINPUT;
+ ATTRIBUTE_NAMES[401] = ATTR_ONDRAGSTART;
+ ATTRIBUTE_NAMES[402] = ATTR_ONMOVESTART;
+ ATTRIBUTE_NAMES[403] = ATTR_MARKERUNITS;
+ ATTRIBUTE_NAMES[404] = ATTR_MATHVARIANT;
+ ATTRIBUTE_NAMES[405] = ATTR_MARGINWIDTH;
+ ATTRIBUTE_NAMES[406] = ATTR_MARKERWIDTH;
+ ATTRIBUTE_NAMES[407] = ATTR_TEXT_ANCHOR;
+ ATTRIBUTE_NAMES[408] = ATTR_TABLEVALUES;
+ ATTRIBUTE_NAMES[409] = ATTR_SCRIPTLEVEL;
+ ATTRIBUTE_NAMES[410] = ATTR_REPEATCOUNT;
+ ATTRIBUTE_NAMES[411] = ATTR_STITCHTILES;
+ ATTRIBUTE_NAMES[412] = ATTR_STARTOFFSET;
+ ATTRIBUTE_NAMES[413] = ATTR_SCROLLDELAY;
+ ATTRIBUTE_NAMES[414] = ATTR_XMLNS_XLINK;
+ ATTRIBUTE_NAMES[415] = ATTR_XLINK_TITLE;
+ ATTRIBUTE_NAMES[416] = ATTR_ARIA_INVALID;
+ ATTRIBUTE_NAMES[417] = ATTR_ARIA_PRESSED;
+ ATTRIBUTE_NAMES[418] = ATTR_ARIA_CHECKED;
+ ATTRIBUTE_NAMES[419] = ATTR_AUTOCOMPLETE;
+ ATTRIBUTE_NAMES[420] = ATTR_ARIA_SETSIZE;
+ ATTRIBUTE_NAMES[421] = ATTR_ARIA_CHANNEL;
+ ATTRIBUTE_NAMES[422] = ATTR_EQUALCOLUMNS;
+ ATTRIBUTE_NAMES[423] = ATTR_DISPLAYSTYLE;
+ ATTRIBUTE_NAMES[424] = ATTR_DATAFORMATAS;
+ ATTRIBUTE_NAMES[425] = ATTR_FILL_OPACITY;
+ ATTRIBUTE_NAMES[426] = ATTR_FONT_VARIANT;
+ ATTRIBUTE_NAMES[427] = ATTR_FONT_STRETCH;
+ ATTRIBUTE_NAMES[428] = ATTR_FRAMESPACING;
+ ATTRIBUTE_NAMES[429] = ATTR_KERNELMATRIX;
+ ATTRIBUTE_NAMES[430] = ATTR_ONDEACTIVATE;
+ ATTRIBUTE_NAMES[431] = ATTR_ONROWSDELETE;
+ ATTRIBUTE_NAMES[432] = ATTR_ONMOUSELEAVE;
+ ATTRIBUTE_NAMES[433] = ATTR_ONFORMCHANGE;
+ ATTRIBUTE_NAMES[434] = ATTR_ONCELLCHANGE;
+ ATTRIBUTE_NAMES[435] = ATTR_ONMOUSEWHEEL;
+ ATTRIBUTE_NAMES[436] = ATTR_ONMOUSEENTER;
+ ATTRIBUTE_NAMES[437] = ATTR_ONAFTERPRINT;
+ ATTRIBUTE_NAMES[438] = ATTR_ONBEFORECOPY;
+ ATTRIBUTE_NAMES[439] = ATTR_MARGINHEIGHT;
+ ATTRIBUTE_NAMES[440] = ATTR_MARKERHEIGHT;
+ ATTRIBUTE_NAMES[441] = ATTR_MARKER_START;
+ ATTRIBUTE_NAMES[442] = ATTR_MATHEMATICAL;
+ ATTRIBUTE_NAMES[443] = ATTR_LENGTHADJUST;
+ ATTRIBUTE_NAMES[444] = ATTR_UNSELECTABLE;
+ ATTRIBUTE_NAMES[445] = ATTR_UNICODE_BIDI;
+ ATTRIBUTE_NAMES[446] = ATTR_UNITS_PER_EM;
+ ATTRIBUTE_NAMES[447] = ATTR_WORD_SPACING;
+ ATTRIBUTE_NAMES[448] = ATTR_WRITING_MODE;
+ ATTRIBUTE_NAMES[449] = ATTR_V_ALPHABETIC;
+ ATTRIBUTE_NAMES[450] = ATTR_PATTERNUNITS;
+ ATTRIBUTE_NAMES[451] = ATTR_SPREADMETHOD;
+ ATTRIBUTE_NAMES[452] = ATTR_SURFACESCALE;
+ ATTRIBUTE_NAMES[453] = ATTR_STROKE_WIDTH;
+ ATTRIBUTE_NAMES[454] = ATTR_REPEAT_START;
+ ATTRIBUTE_NAMES[455] = ATTR_STDDEVIATION;
+ ATTRIBUTE_NAMES[456] = ATTR_STOP_OPACITY;
+ ATTRIBUTE_NAMES[457] = ATTR_ARIA_CONTROLS;
+ ATTRIBUTE_NAMES[458] = ATTR_ARIA_HASPOPUP;
+ ATTRIBUTE_NAMES[459] = ATTR_ACCENT_HEIGHT;
+ ATTRIBUTE_NAMES[460] = ATTR_ARIA_VALUENOW;
+ ATTRIBUTE_NAMES[461] = ATTR_ARIA_RELEVANT;
+ ATTRIBUTE_NAMES[462] = ATTR_ARIA_POSINSET;
+ ATTRIBUTE_NAMES[463] = ATTR_ARIA_VALUEMAX;
+ ATTRIBUTE_NAMES[464] = ATTR_ARIA_READONLY;
+ ATTRIBUTE_NAMES[465] = ATTR_ARIA_SELECTED;
+ ATTRIBUTE_NAMES[466] = ATTR_ARIA_REQUIRED;
+ ATTRIBUTE_NAMES[467] = ATTR_ARIA_EXPANDED;
+ ATTRIBUTE_NAMES[468] = ATTR_ARIA_DISABLED;
+ ATTRIBUTE_NAMES[469] = ATTR_ATTRIBUTETYPE;
+ ATTRIBUTE_NAMES[470] = ATTR_ATTRIBUTENAME;
+ ATTRIBUTE_NAMES[471] = ATTR_ARIA_DATATYPE;
+ ATTRIBUTE_NAMES[472] = ATTR_ARIA_VALUEMIN;
+ ATTRIBUTE_NAMES[473] = ATTR_BASEFREQUENCY;
+ ATTRIBUTE_NAMES[474] = ATTR_COLUMNSPACING;
+ ATTRIBUTE_NAMES[475] = ATTR_COLOR_PROFILE;
+ ATTRIBUTE_NAMES[476] = ATTR_CLIPPATHUNITS;
+ ATTRIBUTE_NAMES[477] = ATTR_DEFINITIONURL;
+ ATTRIBUTE_NAMES[478] = ATTR_GRADIENTUNITS;
+ ATTRIBUTE_NAMES[479] = ATTR_FLOOD_OPACITY;
+ ATTRIBUTE_NAMES[480] = ATTR_ONAFTERUPDATE;
+ ATTRIBUTE_NAMES[481] = ATTR_ONERRORUPDATE;
+ ATTRIBUTE_NAMES[482] = ATTR_ONBEFOREPASTE;
+ ATTRIBUTE_NAMES[483] = ATTR_ONLOSECAPTURE;
+ ATTRIBUTE_NAMES[484] = ATTR_ONCONTEXTMENU;
+ ATTRIBUTE_NAMES[485] = ATTR_ONSELECTSTART;
+ ATTRIBUTE_NAMES[486] = ATTR_ONBEFOREPRINT;
+ ATTRIBUTE_NAMES[487] = ATTR_MOVABLELIMITS;
+ ATTRIBUTE_NAMES[488] = ATTR_LINETHICKNESS;
+ ATTRIBUTE_NAMES[489] = ATTR_UNICODE_RANGE;
+ ATTRIBUTE_NAMES[490] = ATTR_THINMATHSPACE;
+ ATTRIBUTE_NAMES[491] = ATTR_VERT_ORIGIN_X;
+ ATTRIBUTE_NAMES[492] = ATTR_VERT_ORIGIN_Y;
+ ATTRIBUTE_NAMES[493] = ATTR_V_IDEOGRAPHIC;
+ ATTRIBUTE_NAMES[494] = ATTR_PRESERVEALPHA;
+ ATTRIBUTE_NAMES[495] = ATTR_SCRIPTMINSIZE;
+ ATTRIBUTE_NAMES[496] = ATTR_SPECIFICATION;
+ ATTRIBUTE_NAMES[497] = ATTR_XLINK_ACTUATE;
+ ATTRIBUTE_NAMES[498] = ATTR_XLINK_ARCROLE;
+ ATTRIBUTE_NAMES[499] = ATTR_ACCEPT_CHARSET;
+ ATTRIBUTE_NAMES[500] = ATTR_ALIGNMENTSCOPE;
+ ATTRIBUTE_NAMES[501] = ATTR_ARIA_MULTILINE;
+ ATTRIBUTE_NAMES[502] = ATTR_BASELINE_SHIFT;
+ ATTRIBUTE_NAMES[503] = ATTR_HORIZ_ORIGIN_X;
+ ATTRIBUTE_NAMES[504] = ATTR_HORIZ_ORIGIN_Y;
+ ATTRIBUTE_NAMES[505] = ATTR_ONBEFOREUPDATE;
+ ATTRIBUTE_NAMES[506] = ATTR_ONFILTERCHANGE;
+ ATTRIBUTE_NAMES[507] = ATTR_ONROWSINSERTED;
+ ATTRIBUTE_NAMES[508] = ATTR_ONBEFOREUNLOAD;
+ ATTRIBUTE_NAMES[509] = ATTR_MATHBACKGROUND;
+ ATTRIBUTE_NAMES[510] = ATTR_LETTER_SPACING;
+ ATTRIBUTE_NAMES[511] = ATTR_LIGHTING_COLOR;
+ ATTRIBUTE_NAMES[512] = ATTR_THICKMATHSPACE;
+ ATTRIBUTE_NAMES[513] = ATTR_TEXT_RENDERING;
+ ATTRIBUTE_NAMES[514] = ATTR_V_MATHEMATICAL;
+ ATTRIBUTE_NAMES[515] = ATTR_POINTER_EVENTS;
+ ATTRIBUTE_NAMES[516] = ATTR_PRIMITIVEUNITS;
+ ATTRIBUTE_NAMES[517] = ATTR_REFERRERPOLICY;
+ ATTRIBUTE_NAMES[518] = ATTR_SYSTEMLANGUAGE;
+ ATTRIBUTE_NAMES[519] = ATTR_STROKE_LINECAP;
+ ATTRIBUTE_NAMES[520] = ATTR_SUBSCRIPTSHIFT;
+ ATTRIBUTE_NAMES[521] = ATTR_STROKE_OPACITY;
+ ATTRIBUTE_NAMES[522] = ATTR_ARIA_DROPEFFECT;
+ ATTRIBUTE_NAMES[523] = ATTR_ARIA_LABELLEDBY;
+ ATTRIBUTE_NAMES[524] = ATTR_ARIA_TEMPLATEID;
+ ATTRIBUTE_NAMES[525] = ATTR_COLOR_RENDERING;
+ ATTRIBUTE_NAMES[526] = ATTR_CONTENTEDITABLE;
+ ATTRIBUTE_NAMES[527] = ATTR_DIFFUSECONSTANT;
+ ATTRIBUTE_NAMES[528] = ATTR_ONDATAAVAILABLE;
+ ATTRIBUTE_NAMES[529] = ATTR_ONCONTROLSELECT;
+ ATTRIBUTE_NAMES[530] = ATTR_IMAGE_RENDERING;
+ ATTRIBUTE_NAMES[531] = ATTR_MEDIUMMATHSPACE;
+ ATTRIBUTE_NAMES[532] = ATTR_TEXT_DECORATION;
+ ATTRIBUTE_NAMES[533] = ATTR_SHAPE_RENDERING;
+ ATTRIBUTE_NAMES[534] = ATTR_STROKE_LINEJOIN;
+ ATTRIBUTE_NAMES[535] = ATTR_REPEAT_TEMPLATE;
+ ATTRIBUTE_NAMES[536] = ATTR_ARIA_DESCRIBEDBY;
+ ATTRIBUTE_NAMES[537] = ATTR_FONT_SIZE_ADJUST;
+ ATTRIBUTE_NAMES[538] = ATTR_KERNELUNITLENGTH;
+ ATTRIBUTE_NAMES[539] = ATTR_ONBEFOREACTIVATE;
+ ATTRIBUTE_NAMES[540] = ATTR_ONPROPERTYCHANGE;
+ ATTRIBUTE_NAMES[541] = ATTR_ONDATASETCHANGED;
+ ATTRIBUTE_NAMES[542] = ATTR_MASKCONTENTUNITS;
+ ATTRIBUTE_NAMES[543] = ATTR_PATTERNTRANSFORM;
+ ATTRIBUTE_NAMES[544] = ATTR_REQUIREDFEATURES;
+ ATTRIBUTE_NAMES[545] = ATTR_RENDERING_INTENT;
+ ATTRIBUTE_NAMES[546] = ATTR_SPECULAREXPONENT;
+ ATTRIBUTE_NAMES[547] = ATTR_SPECULARCONSTANT;
+ ATTRIBUTE_NAMES[548] = ATTR_SUPERSCRIPTSHIFT;
+ ATTRIBUTE_NAMES[549] = ATTR_STROKE_DASHARRAY;
+ ATTRIBUTE_NAMES[550] = ATTR_XCHANNELSELECTOR;
+ ATTRIBUTE_NAMES[551] = ATTR_YCHANNELSELECTOR;
+ ATTRIBUTE_NAMES[552] = ATTR_ARIA_AUTOCOMPLETE;
+ ATTRIBUTE_NAMES[553] = ATTR_ENABLE_BACKGROUND;
+ ATTRIBUTE_NAMES[554] = ATTR_DOMINANT_BASELINE;
+ ATTRIBUTE_NAMES[555] = ATTR_GRADIENTTRANSFORM;
+ ATTRIBUTE_NAMES[556] = ATTR_ONBEFORDEACTIVATE;
+ ATTRIBUTE_NAMES[557] = ATTR_ONDATASETCOMPLETE;
+ ATTRIBUTE_NAMES[558] = ATTR_OVERLINE_POSITION;
+ ATTRIBUTE_NAMES[559] = ATTR_ONBEFOREEDITFOCUS;
+ ATTRIBUTE_NAMES[560] = ATTR_LIMITINGCONEANGLE;
+ ATTRIBUTE_NAMES[561] = ATTR_VERYTHINMATHSPACE;
+ ATTRIBUTE_NAMES[562] = ATTR_STROKE_DASHOFFSET;
+ ATTRIBUTE_NAMES[563] = ATTR_STROKE_MITERLIMIT;
+ ATTRIBUTE_NAMES[564] = ATTR_ALIGNMENT_BASELINE;
+ ATTRIBUTE_NAMES[565] = ATTR_ONREADYSTATECHANGE;
+ ATTRIBUTE_NAMES[566] = ATTR_OVERLINE_THICKNESS;
+ ATTRIBUTE_NAMES[567] = ATTR_UNDERLINE_POSITION;
+ ATTRIBUTE_NAMES[568] = ATTR_VERYTHICKMATHSPACE;
+ ATTRIBUTE_NAMES[569] = ATTR_REQUIREDEXTENSIONS;
+ ATTRIBUTE_NAMES[570] = ATTR_COLOR_INTERPOLATION;
+ ATTRIBUTE_NAMES[571] = ATTR_UNDERLINE_THICKNESS;
+ ATTRIBUTE_NAMES[572] = ATTR_PRESERVEASPECTRATIO;
+ ATTRIBUTE_NAMES[573] = ATTR_PATTERNCONTENTUNITS;
+ ATTRIBUTE_NAMES[574] = ATTR_ARIA_MULTISELECTABLE;
+ ATTRIBUTE_NAMES[575] = ATTR_SCRIPTSIZEMULTIPLIER;
+ ATTRIBUTE_NAMES[576] = ATTR_ARIA_ACTIVEDESCENDANT;
+ ATTRIBUTE_NAMES[577] = ATTR_VERYVERYTHINMATHSPACE;
+ ATTRIBUTE_NAMES[578] = ATTR_VERYVERYTHICKMATHSPACE;
+ ATTRIBUTE_NAMES[579] = ATTR_STRIKETHROUGH_POSITION;
+ ATTRIBUTE_NAMES[580] = ATTR_STRIKETHROUGH_THICKNESS;
+ ATTRIBUTE_NAMES[581] = ATTR_GLYPH_ORIENTATION_VERTICAL;
+ ATTRIBUTE_NAMES[582] = ATTR_COLOR_INTERPOLATION_FILTERS;
+ ATTRIBUTE_NAMES[583] = ATTR_GLYPH_ORIENTATION_HORIZONTAL;
}
void
@@ -2259,6 +2262,7 @@ nsHtml5AttributeName::releaseStatics()
delete ATTR_ONREPEAT;
delete ATTR_ONSELECT;
delete ATTR_NOTATION;
+ delete ATTR_NOMODULE;
delete ATTR_NORESIZE;
delete ATTR_MANIFEST;
delete ATTR_MATHSIZE;
diff --git a/parser/html/nsHtml5AttributeName.h b/parser/html/nsHtml5AttributeName.h
index e12fb35cc..179dc649f 100644
--- a/parser/html/nsHtml5AttributeName.h
+++ b/parser/html/nsHtml5AttributeName.h
@@ -355,6 +355,7 @@ class nsHtml5AttributeName
static nsHtml5AttributeName* ATTR_ONREPEAT;
static nsHtml5AttributeName* ATTR_ONSELECT;
static nsHtml5AttributeName* ATTR_NOTATION;
+ static nsHtml5AttributeName* ATTR_NOMODULE;
static nsHtml5AttributeName* ATTR_NORESIZE;
static nsHtml5AttributeName* ATTR_MANIFEST;
static nsHtml5AttributeName* ATTR_MATHSIZE;
diff --git a/parser/html/nsHtml5ElementName.cpp b/parser/html/nsHtml5ElementName.cpp
index f997f4781..614df1ea0 100644
--- a/parser/html/nsHtml5ElementName.cpp
+++ b/parser/html/nsHtml5ElementName.cpp
@@ -414,7 +414,6 @@ nsHtml5ElementName* nsHtml5ElementName::ELT_LOGBASE = nullptr;
nsHtml5ElementName* nsHtml5ElementName::ELT_LISTING = nullptr;
nsHtml5ElementName* nsHtml5ElementName::ELT_MFENCED = nullptr;
nsHtml5ElementName* nsHtml5ElementName::ELT_MPADDED = nullptr;
-nsHtml5ElementName* nsHtml5ElementName::ELT_MARQUEE = nullptr;
nsHtml5ElementName* nsHtml5ElementName::ELT_MACTION = nullptr;
nsHtml5ElementName* nsHtml5ElementName::ELT_MSUBSUP = nullptr;
nsHtml5ElementName* nsHtml5ElementName::ELT_NOEMBED = nullptr;
@@ -536,7 +535,7 @@ nsHtml5ElementName* nsHtml5ElementName::ELT_FESPECULARLIGHTING = nullptr;
nsHtml5ElementName* nsHtml5ElementName::ELT_DOMAINOFAPPLICATION = nullptr;
nsHtml5ElementName* nsHtml5ElementName::ELT_FECOMPONENTTRANSFER = nullptr;
nsHtml5ElementName** nsHtml5ElementName::ELEMENT_NAMES = 0;
-static int32_t const ELEMENT_HASHES_DATA[] = { 1057, 1090, 1255, 1321, 1552, 1585, 1651, 1717, 68162, 68899, 69059, 69764, 70020, 70276, 71077, 71205, 72134, 72232, 72264, 72296, 72328, 72360, 72392, 73351, 74312, 75209, 78124, 78284, 78476, 79149, 79309, 79341, 79469, 81295, 81487, 82224, 84050, 84498, 84626, 86164, 86292, 86612, 86676, 87445, 3183041, 3186241, 3198017, 3218722, 3226754, 3247715, 3256803, 3263971, 3264995, 3289252, 3291332, 3295524, 3299620, 3326725, 3379303, 3392679, 3448233, 3460553, 3461577, 3510347, 3546604, 3552364, 3556524, 3576461, 3586349, 3588141, 3590797, 3596333, 3622062, 3625454, 3627054, 3675728, 3739282, 3749042, 3771059, 3771571, 3776211, 3782323, 3782963, 3784883, 3785395, 3788979, 3815476, 3839605, 3885110, 3917911, 3948984, 3951096, 135304769, 135858241, 136498210, 136906434, 137138658, 137512995, 137531875, 137548067, 137629283, 137645539, 137646563, 137775779, 138529956, 138615076, 139040932, 140954086, 141179366, 141690439, 142738600, 143013512, 146979116, 147175724, 147475756, 147902637, 147936877, 148017645, 148131885, 148228141, 148229165, 148309165, 148317229, 148395629, 148551853, 148618829, 149076462, 149490158, 149572782, 151277616, 151639440, 153268914, 153486514, 153563314, 153750706, 153763314, 153914034, 154406067, 154417459, 154600979, 154678323, 154680979, 154866835, 155366708, 155375188, 155391572, 155465780, 155869364, 158045494, 168988979, 169321621, 169652752, 173151309, 174240818, 174247297, 174669292, 175391532, 176638123, 177380397, 177879204, 177886734, 180753473, 181020073, 181503558, 181686320, 181999237, 181999311, 182048201, 182074866, 182078003, 182083764, 182920847, 184716457, 184976961, 185145071, 187281445, 187872052, 188100653, 188875944, 188919873, 188920457, 189107250, 189203987, 189371817, 189414886, 189567458, 190266670, 191318187, 191337609, 202479203, 202493027, 202835587, 202843747, 203013219, 203036048, 203045987, 203177552, 203898516, 204648562, 205067918, 205078130, 205096654, 205689142, 205690439, 205766017, 205988909, 207213161, 207794484, 207800999, 208023602, 208213644, 208213647, 210261490, 210310273, 210940978, 213325049, 213946445, 214055079, 215125040, 215134273, 215135028, 215237420, 215418148, 215553166, 215553394, 215563858, 215627949, 215754324, 217529652, 217713834, 217732628, 218731945, 221417045, 221424946, 221493746, 221515401, 221658189, 221908140, 221910626, 221921586, 222659762, 225001091, 236105833, 236113965, 236194995, 236195427, 236206132, 236206387, 236211683, 236212707, 236381647, 236571826, 237124271, 238210544, 238270764, 238435405, 238501172, 239224867, 239257644, 239710497, 240307721, 241208789, 241241557, 241318060, 241319404, 241343533, 241344069, 241405397, 241765845, 243864964, 244502085, 244946220, 245109902, 247647266, 247707956, 248648814, 248648836, 248682161, 248986932, 249058914, 249697357, 251841204, 252132601, 252135604, 252317348, 255007012, 255278388, 255641645, 256365156, 257566121, 269763372, 271202790, 271863856, 272049197, 272127474, 274339449, 274939471, 275388004, 275388005, 275388006, 275977800, 278267602, 278513831, 278712622, 281613765, 281683369, 282120228, 282250732, 282498697, 282508942, 283743649, 283787570, 284710386, 285391148, 285478533, 285854898, 285873762, 286931113, 288964227, 289445441, 289591340, 289689648, 291671489, 303512884, 305319975, 305610036, 305764101, 308448294, 308675890, 312085683, 312264750, 315032867, 316391000, 317331042, 317902135, 318950711, 319447220, 321499182, 322538804, 323145200, 337067316, 337826293, 339905989, 340833697, 341457068, 342310196, 345302593, 349554733, 349771471, 349786245, 350819405, 356072847, 370349192, 373962798, 375558638, 375574835, 376053993, 383276530, 383373833, 383407586, 384439906, 386079012, 404133513, 404307343, 407031852, 408072233, 409112005, 409608425, 409713793, 409771500, 419040932, 437730612, 439529766, 442616365, 442813037, 443157674, 443295316, 450118444, 450482697, 456789668, 459935396, 471217869, 474073645, 476230702, 476665218, 476717289, 483014825, 485083298, 489306281, 538364390, 540675748, 543819186, 543958612, 576960820, 577242548, 610515252, 642202932, 644420819 };
+static int32_t const ELEMENT_HASHES_DATA[] = { 1057, 1090, 1255, 1321, 1552, 1585, 1651, 1717, 68162, 68899, 69059, 69764, 70020, 70276, 71077, 71205, 72134, 72232, 72264, 72296, 72328, 72360, 72392, 73351, 74312, 75209, 78124, 78284, 78476, 79149, 79309, 79341, 79469, 81295, 81487, 82224, 84050, 84498, 84626, 86164, 86292, 86612, 86676, 87445, 3183041, 3186241, 3198017, 3218722, 3226754, 3247715, 3256803, 3263971, 3264995, 3289252, 3291332, 3295524, 3299620, 3326725, 3379303, 3392679, 3448233, 3460553, 3461577, 3510347, 3546604, 3552364, 3556524, 3576461, 3586349, 3588141, 3590797, 3596333, 3622062, 3625454, 3627054, 3675728, 3739282, 3749042, 3771059, 3771571, 3776211, 3782323, 3782963, 3784883, 3785395, 3788979, 3815476, 3839605, 3885110, 3917911, 3948984, 3951096, 135304769, 135858241, 136498210, 136906434, 137138658, 137512995, 137531875, 137548067, 137629283, 137645539, 137646563, 137775779, 138529956, 138615076, 139040932, 140954086, 141179366, 141690439, 142738600, 143013512, 146979116, 147175724, 147475756, 147902637, 147936877, 148017645, 148131885, 148228141, 148229165, 148309165, 148317229, 148395629, 148551853, 148618829, 149076462, 149490158, 149572782, 151277616, 151639440, 153268914, 153486514, 153563314, 153750706, 153763314, 153914034, 154406067, 154417459, 154600979, 154678323, 154680979, 154866835, 155366708, 155375188, 155391572, 155465780, 155869364, 158045494, 168988979, 169321621, 169652752, 173151309, 174240818, 174247297, 174669292, 175391532, 176638123, 177380397, 177879204, 177886734, 180753473, 181020073, 181503558, 181686320, 181999237, 181999311, 182048201, 182074866, 182078003, 182083764, 182920847, 184716457, 184976961, 185145071, 187281445, 187872052, 188100653, 188875944, 188919873, 188920457, 189107250, 189203987, 189371817, 189414886, 189567458, 190266670, 191318187, 191337609, 202479203, 202493027, 202835587, 202843747, 203013219, 203036048, 203045987, 203177552, 203898516, 204648562, 205067918, 205078130, 205096654, 205689142, 205690439, 205766017, 205988909, 207213161, 207794484, 207800999, 208023602, 208213644, 208213647, 210261490, 210310273, 210940978, 213325049, 213946445, 214055079, 215125040, 215134273, 215135028, 215237420, 215418148, 215553166, 215553394, 215563858, 215627949, 215754324, 217529652, 217713834, 217732628, 218731945, 221417045, 221424946, 221493746, 221515401, 221658189, 221908140, 221910626, 221921586, 222659762, 225001091, 236105833, 236113965, 236194995, 236195427, 236206132, 236206387, 236211683, 236212707, 236381647, 236571826, 237124271, 238210544, 238270764, 238435405, 238501172, 239224867, 239257644, 239710497, 240307721, 241208789, 241241557, 241318060, 241319404, 241343533, 241344069, 241405397, 241765845, 243864964, 244502085, 244946220, 245109902, 247647266, 247707956, 248648814, 248648836, 248986932, 249058914, 249697357, 251841204, 252132601, 252135604, 252317348, 255007012, 255278388, 255641645, 256365156, 257566121, 269763372, 271202790, 271863856, 272049197, 272127474, 274339449, 274939471, 275388004, 275388005, 275388006, 275977800, 278267602, 278513831, 278712622, 281613765, 281683369, 282120228, 282250732, 282498697, 282508942, 283743649, 283787570, 284710386, 285391148, 285478533, 285854898, 285873762, 286931113, 288964227, 289445441, 289591340, 289689648, 291671489, 303512884, 305319975, 305610036, 305764101, 308448294, 308675890, 312085683, 312264750, 315032867, 316391000, 317331042, 317902135, 318950711, 319447220, 321499182, 322538804, 323145200, 337067316, 337826293, 339905989, 340833697, 341457068, 342310196, 345302593, 349554733, 349771471, 349786245, 350819405, 356072847, 370349192, 373962798, 375558638, 375574835, 376053993, 383276530, 383373833, 383407586, 384439906, 386079012, 404133513, 404307343, 407031852, 408072233, 409112005, 409608425, 409713793, 409771500, 419040932, 437730612, 439529766, 442616365, 442813037, 443157674, 443295316, 450118444, 450482697, 456789668, 459935396, 471217869, 474073645, 476230702, 476665218, 476717289, 483014825, 485083298, 489306281, 538364390, 540675748, 543819186, 543958612, 576960820, 577242548, 610515252, 642202932, 644420819 };
staticJArray<int32_t,int32_t> nsHtml5ElementName::ELEMENT_HASHES = { ELEMENT_HASHES_DATA, MOZ_ARRAY_LENGTH(ELEMENT_HASHES_DATA) };
void
nsHtml5ElementName::initializeStatics()
@@ -819,7 +818,6 @@ nsHtml5ElementName::initializeStatics()
ELT_LISTING = new nsHtml5ElementName(nsHtml5Atoms::listing, nsHtml5Atoms::listing, NS_HTML5TREE_BUILDER_PRE_OR_LISTING | NS_HTML5ELEMENT_NAME_SPECIAL);
ELT_MFENCED = new nsHtml5ElementName(nsHtml5Atoms::mfenced, nsHtml5Atoms::mfenced, NS_HTML5TREE_BUILDER_OTHER);
ELT_MPADDED = new nsHtml5ElementName(nsHtml5Atoms::mpadded, nsHtml5Atoms::mpadded, NS_HTML5TREE_BUILDER_OTHER);
- ELT_MARQUEE = new nsHtml5ElementName(nsHtml5Atoms::marquee, nsHtml5Atoms::marquee, NS_HTML5TREE_BUILDER_MARQUEE_OR_APPLET | NS_HTML5ELEMENT_NAME_SPECIAL | NS_HTML5ELEMENT_NAME_SCOPING);
ELT_MACTION = new nsHtml5ElementName(nsHtml5Atoms::maction, nsHtml5Atoms::maction, NS_HTML5TREE_BUILDER_OTHER);
ELT_MSUBSUP = new nsHtml5ElementName(nsHtml5Atoms::msubsup, nsHtml5Atoms::msubsup, NS_HTML5TREE_BUILDER_OTHER);
ELT_NOEMBED = new nsHtml5ElementName(nsHtml5Atoms::noembed, nsHtml5Atoms::noembed, NS_HTML5TREE_BUILDER_NOEMBED | NS_HTML5ELEMENT_NAME_SPECIAL);
@@ -940,7 +938,7 @@ nsHtml5ElementName::initializeStatics()
ELT_FESPECULARLIGHTING = new nsHtml5ElementName(nsHtml5Atoms::fespecularlighting, nsHtml5Atoms::feSpecularLighting, NS_HTML5TREE_BUILDER_OTHER);
ELT_DOMAINOFAPPLICATION = new nsHtml5ElementName(nsHtml5Atoms::domainofapplication, nsHtml5Atoms::domainofapplication, NS_HTML5TREE_BUILDER_OTHER);
ELT_FECOMPONENTTRANSFER = new nsHtml5ElementName(nsHtml5Atoms::fecomponenttransfer, nsHtml5Atoms::feComponentTransfer, NS_HTML5TREE_BUILDER_OTHER);
- ELEMENT_NAMES = new nsHtml5ElementName*[398];
+ ELEMENT_NAMES = new nsHtml5ElementName*[397];
ELEMENT_NAMES[0] = ELT_A;
ELEMENT_NAMES[1] = ELT_B;
ELEMENT_NAMES[2] = ELT_G;
@@ -1218,127 +1216,126 @@ nsHtml5ElementName::initializeStatics()
ELEMENT_NAMES[274] = ELT_LISTING;
ELEMENT_NAMES[275] = ELT_MFENCED;
ELEMENT_NAMES[276] = ELT_MPADDED;
- ELEMENT_NAMES[277] = ELT_MARQUEE;
- ELEMENT_NAMES[278] = ELT_MACTION;
- ELEMENT_NAMES[279] = ELT_MSUBSUP;
- ELEMENT_NAMES[280] = ELT_NOEMBED;
- ELEMENT_NAMES[281] = ELT_PICTURE;
- ELEMENT_NAMES[282] = ELT_POLYGON;
- ELEMENT_NAMES[283] = ELT_PATTERN;
- ELEMENT_NAMES[284] = ELT_PRODUCT;
- ELEMENT_NAMES[285] = ELT_SETDIFF;
- ELEMENT_NAMES[286] = ELT_SECTION;
- ELEMENT_NAMES[287] = ELT_SUMMARY;
- ELEMENT_NAMES[288] = ELT_TENDSTO;
- ELEMENT_NAMES[289] = ELT_UPLIMIT;
- ELEMENT_NAMES[290] = ELT_ALTGLYPH;
- ELEMENT_NAMES[291] = ELT_BASEFONT;
- ELEMENT_NAMES[292] = ELT_CLIPPATH;
- ELEMENT_NAMES[293] = ELT_CODOMAIN;
- ELEMENT_NAMES[294] = ELT_COLGROUP;
- ELEMENT_NAMES[295] = ELT_EMPTYSET;
- ELEMENT_NAMES[296] = ELT_FACTOROF;
- ELEMENT_NAMES[297] = ELT_FIELDSET;
- ELEMENT_NAMES[298] = ELT_FRAMESET;
- ELEMENT_NAMES[299] = ELT_FEOFFSET;
- ELEMENT_NAMES[300] = ELT_GLYPHREF;
- ELEMENT_NAMES[301] = ELT_INTERVAL;
- ELEMENT_NAMES[302] = ELT_INTEGERS;
- ELEMENT_NAMES[303] = ELT_INFINITY;
- ELEMENT_NAMES[304] = ELT_LISTENER;
- ELEMENT_NAMES[305] = ELT_LOWLIMIT;
- ELEMENT_NAMES[306] = ELT_METADATA;
- ELEMENT_NAMES[307] = ELT_MENCLOSE;
- ELEMENT_NAMES[308] = ELT_MENUITEM;
- ELEMENT_NAMES[309] = ELT_MPHANTOM;
- ELEMENT_NAMES[310] = ELT_NOFRAMES;
- ELEMENT_NAMES[311] = ELT_NOSCRIPT;
- ELEMENT_NAMES[312] = ELT_OPTGROUP;
- ELEMENT_NAMES[313] = ELT_POLYLINE;
- ELEMENT_NAMES[314] = ELT_PREFETCH;
- ELEMENT_NAMES[315] = ELT_PROGRESS;
- ELEMENT_NAMES[316] = ELT_PRSUBSET;
- ELEMENT_NAMES[317] = ELT_QUOTIENT;
- ELEMENT_NAMES[318] = ELT_SELECTOR;
- ELEMENT_NAMES[319] = ELT_TEXTAREA;
- ELEMENT_NAMES[320] = ELT_TEMPLATE;
- ELEMENT_NAMES[321] = ELT_TEXTPATH;
- ELEMENT_NAMES[322] = ELT_VARIANCE;
- ELEMENT_NAMES[323] = ELT_ANIMATION;
- ELEMENT_NAMES[324] = ELT_CONJUGATE;
- ELEMENT_NAMES[325] = ELT_CONDITION;
- ELEMENT_NAMES[326] = ELT_COMPLEXES;
- ELEMENT_NAMES[327] = ELT_FONT_FACE;
- ELEMENT_NAMES[328] = ELT_FACTORIAL;
- ELEMENT_NAMES[329] = ELT_INTERSECT;
- ELEMENT_NAMES[330] = ELT_IMAGINARY;
- ELEMENT_NAMES[331] = ELT_LAPLACIAN;
- ELEMENT_NAMES[332] = ELT_MATRIXROW;
- ELEMENT_NAMES[333] = ELT_NOTSUBSET;
- ELEMENT_NAMES[334] = ELT_OTHERWISE;
- ELEMENT_NAMES[335] = ELT_PIECEWISE;
- ELEMENT_NAMES[336] = ELT_PLAINTEXT;
- ELEMENT_NAMES[337] = ELT_RATIONALS;
- ELEMENT_NAMES[338] = ELT_SEMANTICS;
- ELEMENT_NAMES[339] = ELT_TRANSPOSE;
- ELEMENT_NAMES[340] = ELT_ANNOTATION;
- ELEMENT_NAMES[341] = ELT_BLOCKQUOTE;
- ELEMENT_NAMES[342] = ELT_DIVERGENCE;
- ELEMENT_NAMES[343] = ELT_EULERGAMMA;
- ELEMENT_NAMES[344] = ELT_EQUIVALENT;
- ELEMENT_NAMES[345] = ELT_FIGCAPTION;
- ELEMENT_NAMES[346] = ELT_IMAGINARYI;
- ELEMENT_NAMES[347] = ELT_MALIGNMARK;
- ELEMENT_NAMES[348] = ELT_MUNDEROVER;
- ELEMENT_NAMES[349] = ELT_MLABELEDTR;
- ELEMENT_NAMES[350] = ELT_NOTANUMBER;
- ELEMENT_NAMES[351] = ELT_SOLIDCOLOR;
- ELEMENT_NAMES[352] = ELT_ALTGLYPHDEF;
- ELEMENT_NAMES[353] = ELT_DETERMINANT;
- ELEMENT_NAMES[354] = ELT_FEMERGENODE;
- ELEMENT_NAMES[355] = ELT_FECOMPOSITE;
- ELEMENT_NAMES[356] = ELT_FESPOTLIGHT;
- ELEMENT_NAMES[357] = ELT_MALIGNGROUP;
- ELEMENT_NAMES[358] = ELT_MPRESCRIPTS;
- ELEMENT_NAMES[359] = ELT_MOMENTABOUT;
- ELEMENT_NAMES[360] = ELT_NOTPRSUBSET;
- ELEMENT_NAMES[361] = ELT_PARTIALDIFF;
- ELEMENT_NAMES[362] = ELT_ALTGLYPHITEM;
- ELEMENT_NAMES[363] = ELT_ANIMATECOLOR;
- ELEMENT_NAMES[364] = ELT_DATATEMPLATE;
- ELEMENT_NAMES[365] = ELT_EXPONENTIALE;
- ELEMENT_NAMES[366] = ELT_FETURBULENCE;
- ELEMENT_NAMES[367] = ELT_FEPOINTLIGHT;
- ELEMENT_NAMES[368] = ELT_FEDROPSHADOW;
- ELEMENT_NAMES[369] = ELT_FEMORPHOLOGY;
- ELEMENT_NAMES[370] = ELT_OUTERPRODUCT;
- ELEMENT_NAMES[371] = ELT_ANIMATEMOTION;
- ELEMENT_NAMES[372] = ELT_COLOR_PROFILE;
- ELEMENT_NAMES[373] = ELT_FONT_FACE_SRC;
- ELEMENT_NAMES[374] = ELT_FONT_FACE_URI;
- ELEMENT_NAMES[375] = ELT_FOREIGNOBJECT;
- ELEMENT_NAMES[376] = ELT_FECOLORMATRIX;
- ELEMENT_NAMES[377] = ELT_MISSING_GLYPH;
- ELEMENT_NAMES[378] = ELT_MMULTISCRIPTS;
- ELEMENT_NAMES[379] = ELT_SCALARPRODUCT;
- ELEMENT_NAMES[380] = ELT_VECTORPRODUCT;
- ELEMENT_NAMES[381] = ELT_ANNOTATION_XML;
- ELEMENT_NAMES[382] = ELT_DEFINITION_SRC;
- ELEMENT_NAMES[383] = ELT_FONT_FACE_NAME;
- ELEMENT_NAMES[384] = ELT_FEGAUSSIANBLUR;
- ELEMENT_NAMES[385] = ELT_FEDISTANTLIGHT;
- ELEMENT_NAMES[386] = ELT_LINEARGRADIENT;
- ELEMENT_NAMES[387] = ELT_NATURALNUMBERS;
- ELEMENT_NAMES[388] = ELT_RADIALGRADIENT;
- ELEMENT_NAMES[389] = ELT_ANIMATETRANSFORM;
- ELEMENT_NAMES[390] = ELT_CARTESIANPRODUCT;
- ELEMENT_NAMES[391] = ELT_FONT_FACE_FORMAT;
- ELEMENT_NAMES[392] = ELT_FECONVOLVEMATRIX;
- ELEMENT_NAMES[393] = ELT_FEDIFFUSELIGHTING;
- ELEMENT_NAMES[394] = ELT_FEDISPLACEMENTMAP;
- ELEMENT_NAMES[395] = ELT_FESPECULARLIGHTING;
- ELEMENT_NAMES[396] = ELT_DOMAINOFAPPLICATION;
- ELEMENT_NAMES[397] = ELT_FECOMPONENTTRANSFER;
+ ELEMENT_NAMES[277] = ELT_MACTION;
+ ELEMENT_NAMES[278] = ELT_MSUBSUP;
+ ELEMENT_NAMES[279] = ELT_NOEMBED;
+ ELEMENT_NAMES[280] = ELT_PICTURE;
+ ELEMENT_NAMES[281] = ELT_POLYGON;
+ ELEMENT_NAMES[282] = ELT_PATTERN;
+ ELEMENT_NAMES[283] = ELT_PRODUCT;
+ ELEMENT_NAMES[284] = ELT_SETDIFF;
+ ELEMENT_NAMES[285] = ELT_SECTION;
+ ELEMENT_NAMES[286] = ELT_SUMMARY;
+ ELEMENT_NAMES[287] = ELT_TENDSTO;
+ ELEMENT_NAMES[288] = ELT_UPLIMIT;
+ ELEMENT_NAMES[289] = ELT_ALTGLYPH;
+ ELEMENT_NAMES[290] = ELT_BASEFONT;
+ ELEMENT_NAMES[291] = ELT_CLIPPATH;
+ ELEMENT_NAMES[292] = ELT_CODOMAIN;
+ ELEMENT_NAMES[293] = ELT_COLGROUP;
+ ELEMENT_NAMES[294] = ELT_EMPTYSET;
+ ELEMENT_NAMES[295] = ELT_FACTOROF;
+ ELEMENT_NAMES[296] = ELT_FIELDSET;
+ ELEMENT_NAMES[297] = ELT_FRAMESET;
+ ELEMENT_NAMES[298] = ELT_FEOFFSET;
+ ELEMENT_NAMES[299] = ELT_GLYPHREF;
+ ELEMENT_NAMES[300] = ELT_INTERVAL;
+ ELEMENT_NAMES[301] = ELT_INTEGERS;
+ ELEMENT_NAMES[302] = ELT_INFINITY;
+ ELEMENT_NAMES[303] = ELT_LISTENER;
+ ELEMENT_NAMES[304] = ELT_LOWLIMIT;
+ ELEMENT_NAMES[305] = ELT_METADATA;
+ ELEMENT_NAMES[306] = ELT_MENCLOSE;
+ ELEMENT_NAMES[307] = ELT_MENUITEM;
+ ELEMENT_NAMES[308] = ELT_MPHANTOM;
+ ELEMENT_NAMES[309] = ELT_NOFRAMES;
+ ELEMENT_NAMES[310] = ELT_NOSCRIPT;
+ ELEMENT_NAMES[311] = ELT_OPTGROUP;
+ ELEMENT_NAMES[312] = ELT_POLYLINE;
+ ELEMENT_NAMES[313] = ELT_PREFETCH;
+ ELEMENT_NAMES[314] = ELT_PROGRESS;
+ ELEMENT_NAMES[315] = ELT_PRSUBSET;
+ ELEMENT_NAMES[316] = ELT_QUOTIENT;
+ ELEMENT_NAMES[317] = ELT_SELECTOR;
+ ELEMENT_NAMES[318] = ELT_TEXTAREA;
+ ELEMENT_NAMES[319] = ELT_TEMPLATE;
+ ELEMENT_NAMES[320] = ELT_TEXTPATH;
+ ELEMENT_NAMES[321] = ELT_VARIANCE;
+ ELEMENT_NAMES[322] = ELT_ANIMATION;
+ ELEMENT_NAMES[323] = ELT_CONJUGATE;
+ ELEMENT_NAMES[324] = ELT_CONDITION;
+ ELEMENT_NAMES[325] = ELT_COMPLEXES;
+ ELEMENT_NAMES[326] = ELT_FONT_FACE;
+ ELEMENT_NAMES[327] = ELT_FACTORIAL;
+ ELEMENT_NAMES[328] = ELT_INTERSECT;
+ ELEMENT_NAMES[329] = ELT_IMAGINARY;
+ ELEMENT_NAMES[330] = ELT_LAPLACIAN;
+ ELEMENT_NAMES[331] = ELT_MATRIXROW;
+ ELEMENT_NAMES[332] = ELT_NOTSUBSET;
+ ELEMENT_NAMES[333] = ELT_OTHERWISE;
+ ELEMENT_NAMES[334] = ELT_PIECEWISE;
+ ELEMENT_NAMES[335] = ELT_PLAINTEXT;
+ ELEMENT_NAMES[336] = ELT_RATIONALS;
+ ELEMENT_NAMES[337] = ELT_SEMANTICS;
+ ELEMENT_NAMES[338] = ELT_TRANSPOSE;
+ ELEMENT_NAMES[339] = ELT_ANNOTATION;
+ ELEMENT_NAMES[340] = ELT_BLOCKQUOTE;
+ ELEMENT_NAMES[341] = ELT_DIVERGENCE;
+ ELEMENT_NAMES[342] = ELT_EULERGAMMA;
+ ELEMENT_NAMES[343] = ELT_EQUIVALENT;
+ ELEMENT_NAMES[344] = ELT_FIGCAPTION;
+ ELEMENT_NAMES[345] = ELT_IMAGINARYI;
+ ELEMENT_NAMES[346] = ELT_MALIGNMARK;
+ ELEMENT_NAMES[347] = ELT_MUNDEROVER;
+ ELEMENT_NAMES[348] = ELT_MLABELEDTR;
+ ELEMENT_NAMES[349] = ELT_NOTANUMBER;
+ ELEMENT_NAMES[350] = ELT_SOLIDCOLOR;
+ ELEMENT_NAMES[351] = ELT_ALTGLYPHDEF;
+ ELEMENT_NAMES[352] = ELT_DETERMINANT;
+ ELEMENT_NAMES[353] = ELT_FEMERGENODE;
+ ELEMENT_NAMES[354] = ELT_FECOMPOSITE;
+ ELEMENT_NAMES[355] = ELT_FESPOTLIGHT;
+ ELEMENT_NAMES[356] = ELT_MALIGNGROUP;
+ ELEMENT_NAMES[357] = ELT_MPRESCRIPTS;
+ ELEMENT_NAMES[358] = ELT_MOMENTABOUT;
+ ELEMENT_NAMES[359] = ELT_NOTPRSUBSET;
+ ELEMENT_NAMES[360] = ELT_PARTIALDIFF;
+ ELEMENT_NAMES[361] = ELT_ALTGLYPHITEM;
+ ELEMENT_NAMES[362] = ELT_ANIMATECOLOR;
+ ELEMENT_NAMES[363] = ELT_DATATEMPLATE;
+ ELEMENT_NAMES[364] = ELT_EXPONENTIALE;
+ ELEMENT_NAMES[365] = ELT_FETURBULENCE;
+ ELEMENT_NAMES[366] = ELT_FEPOINTLIGHT;
+ ELEMENT_NAMES[367] = ELT_FEDROPSHADOW;
+ ELEMENT_NAMES[368] = ELT_FEMORPHOLOGY;
+ ELEMENT_NAMES[369] = ELT_OUTERPRODUCT;
+ ELEMENT_NAMES[370] = ELT_ANIMATEMOTION;
+ ELEMENT_NAMES[371] = ELT_COLOR_PROFILE;
+ ELEMENT_NAMES[372] = ELT_FONT_FACE_SRC;
+ ELEMENT_NAMES[373] = ELT_FONT_FACE_URI;
+ ELEMENT_NAMES[374] = ELT_FOREIGNOBJECT;
+ ELEMENT_NAMES[375] = ELT_FECOLORMATRIX;
+ ELEMENT_NAMES[376] = ELT_MISSING_GLYPH;
+ ELEMENT_NAMES[377] = ELT_MMULTISCRIPTS;
+ ELEMENT_NAMES[378] = ELT_SCALARPRODUCT;
+ ELEMENT_NAMES[379] = ELT_VECTORPRODUCT;
+ ELEMENT_NAMES[380] = ELT_ANNOTATION_XML;
+ ELEMENT_NAMES[381] = ELT_DEFINITION_SRC;
+ ELEMENT_NAMES[382] = ELT_FONT_FACE_NAME;
+ ELEMENT_NAMES[383] = ELT_FEGAUSSIANBLUR;
+ ELEMENT_NAMES[384] = ELT_FEDISTANTLIGHT;
+ ELEMENT_NAMES[385] = ELT_LINEARGRADIENT;
+ ELEMENT_NAMES[386] = ELT_NATURALNUMBERS;
+ ELEMENT_NAMES[387] = ELT_RADIALGRADIENT;
+ ELEMENT_NAMES[388] = ELT_ANIMATETRANSFORM;
+ ELEMENT_NAMES[389] = ELT_CARTESIANPRODUCT;
+ ELEMENT_NAMES[390] = ELT_FONT_FACE_FORMAT;
+ ELEMENT_NAMES[391] = ELT_FECONVOLVEMATRIX;
+ ELEMENT_NAMES[392] = ELT_FEDIFFUSELIGHTING;
+ ELEMENT_NAMES[393] = ELT_FEDISPLACEMENTMAP;
+ ELEMENT_NAMES[394] = ELT_FESPECULARLIGHTING;
+ ELEMENT_NAMES[395] = ELT_DOMAINOFAPPLICATION;
+ ELEMENT_NAMES[396] = ELT_FECOMPONENTTRANSFER;
}
void
@@ -1622,7 +1619,6 @@ nsHtml5ElementName::releaseStatics()
delete ELT_LISTING;
delete ELT_MFENCED;
delete ELT_MPADDED;
- delete ELT_MARQUEE;
delete ELT_MACTION;
delete ELT_MSUBSUP;
delete ELT_NOEMBED;
diff --git a/parser/html/nsHtml5ElementName.h b/parser/html/nsHtml5ElementName.h
index 99c6de323..db4427be9 100644
--- a/parser/html/nsHtml5ElementName.h
+++ b/parser/html/nsHtml5ElementName.h
@@ -358,7 +358,6 @@ class nsHtml5ElementName
static nsHtml5ElementName* ELT_LISTING;
static nsHtml5ElementName* ELT_MFENCED;
static nsHtml5ElementName* ELT_MPADDED;
- static nsHtml5ElementName* ELT_MARQUEE;
static nsHtml5ElementName* ELT_MACTION;
static nsHtml5ElementName* ELT_MSUBSUP;
static nsHtml5ElementName* ELT_NOEMBED;
diff --git a/parser/html/nsHtml5SpeculativeLoad.cpp b/parser/html/nsHtml5SpeculativeLoad.cpp
index 7bae0699f..35c11b739 100644
--- a/parser/html/nsHtml5SpeculativeLoad.cpp
+++ b/parser/html/nsHtml5SpeculativeLoad.cpp
@@ -52,17 +52,27 @@ nsHtml5SpeculativeLoad::Perform(nsHtml5TreeOpExecutor* aExecutor)
case eSpeculativeLoadScript:
aExecutor->PreloadScript(mUrl, mCharset, mTypeOrCharsetSourceOrDocumentMode,
mCrossOrigin, mIntegrity, false,
- mIsAsync, mIsDefer);
+ mIsAsync, mIsDefer, false);
break;
case eSpeculativeLoadScriptFromHead:
aExecutor->PreloadScript(mUrl, mCharset, mTypeOrCharsetSourceOrDocumentMode,
mCrossOrigin, mIntegrity, true,
- mIsAsync, mIsDefer);
+ mIsAsync, mIsDefer, false);
+ break;
+ case eSpeculativeLoadNoModuleScript:
+ aExecutor->PreloadScript(mUrl, mCharset, mTypeOrCharsetSourceOrDocumentMode,
+ mCrossOrigin, mIntegrity, false,
+ mIsAsync, mIsDefer, true);
+ break;
+ case eSpeculativeLoadNoModuleScriptFromHead:
+ aExecutor->PreloadScript(mUrl, mCharset, mTypeOrCharsetSourceOrDocumentMode,
+ mCrossOrigin, mIntegrity, true,
+ mIsAsync, mIsDefer, true);
break;
case eSpeculativeLoadStyle:
aExecutor->PreloadStyle(mUrl, mCharset, mCrossOrigin, mIntegrity);
break;
- case eSpeculativeLoadManifest:
+ case eSpeculativeLoadManifest:
aExecutor->ProcessOfflineManifest(mUrl);
break;
case eSpeculativeLoadSetDocumentCharset: {
diff --git a/parser/html/nsHtml5SpeculativeLoad.h b/parser/html/nsHtml5SpeculativeLoad.h
index fcc84de4f..1f4a61741 100644
--- a/parser/html/nsHtml5SpeculativeLoad.h
+++ b/parser/html/nsHtml5SpeculativeLoad.h
@@ -10,7 +10,8 @@
class nsHtml5TreeOpExecutor;
-enum eHtml5SpeculativeLoad {
+enum eHtml5SpeculativeLoad
+{
#ifdef DEBUG
eSpeculativeLoadUninitialized,
#endif
@@ -23,6 +24,8 @@ enum eHtml5SpeculativeLoad {
eSpeculativeLoadPictureSource,
eSpeculativeLoadScript,
eSpeculativeLoadScriptFromHead,
+ eSpeculativeLoadNoModuleScript,
+ eSpeculativeLoadNoModuleScriptFromHead,
eSpeculativeLoadStyle,
eSpeculativeLoadManifest,
eSpeculativeLoadSetDocumentCharset,
@@ -130,12 +133,18 @@ class nsHtml5SpeculativeLoad {
nsHtml5String aIntegrity,
bool aParserInHead,
bool aAsync,
- bool aDefer)
+ bool aDefer,
+ bool aNoModule)
{
NS_PRECONDITION(mOpCode == eSpeculativeLoadUninitialized,
"Trying to reinitialize a speculative load!");
- mOpCode = aParserInHead ?
- eSpeculativeLoadScriptFromHead : eSpeculativeLoadScript;
+ if (aNoModule) {
+ mOpCode = aParserInHead ? eSpeculativeLoadNoModuleScriptFromHead
+ : eSpeculativeLoadNoModuleScript;
+ } else {
+ mOpCode = aParserInHead ? eSpeculativeLoadScriptFromHead
+ : eSpeculativeLoadScript;
+ }
aUrl.ToString(mUrl);
aCharset.ToString(mCharset);
aType.ToString(mTypeOrCharsetSourceOrDocumentMode);
diff --git a/parser/html/nsHtml5TreeBuilderCppSupplement.h b/parser/html/nsHtml5TreeBuilderCppSupplement.h
index 9709396c7..51966077c 100644
--- a/parser/html/nsHtml5TreeBuilderCppSupplement.h
+++ b/parser/html/nsHtml5TreeBuilderCppSupplement.h
@@ -171,6 +171,8 @@ nsHtml5TreeBuilder::createElement(int32_t aNamespace, nsIAtom* aName,
aAttributes->contains(nsHtml5AttributeName::ATTR_ASYNC);
bool defer =
aAttributes->contains(nsHtml5AttributeName::ATTR_DEFER);
+ bool noModule =
+ aAttributes->contains(nsHtml5AttributeName::ATTR_NOMODULE);
mSpeculativeLoadQueue.AppendElement()->InitScript(
url,
charset,
@@ -179,7 +181,8 @@ nsHtml5TreeBuilder::createElement(int32_t aNamespace, nsIAtom* aName,
integrity,
mode == NS_HTML5TREE_BUILDER_IN_HEAD,
async,
- defer);
+ defer,
+ noModule);
mCurrentHtmlScriptIsAsyncOrDefer = async || defer;
}
} else if (nsHtml5Atoms::link == aName) {
@@ -285,7 +288,8 @@ nsHtml5TreeBuilder::createElement(int32_t aNamespace, nsIAtom* aName,
integrity,
mode == NS_HTML5TREE_BUILDER_IN_HEAD,
false /* async */,
- false /* defer */);
+ false /* defer */,
+ false /* noModule */);
}
} else if (nsHtml5Atoms::style == aName) {
nsHtml5TreeOperation* treeOp = mOpQueue.AppendElement();
@@ -918,6 +922,9 @@ nsHtml5TreeBuilder::elementPopped(int32_t aNamespace, nsIAtom* aName, nsIContent
}
if (aNamespace == kNameSpaceID_SVG) {
if (aName == nsHtml5Atoms::svg) {
+ if (!scriptingEnabled || mPreventScriptExecution) {
+ return;
+ }
if (mBuilder) {
nsHtml5TreeOperation::SvgLoad(static_cast<nsIContent*>(aElement));
return;
diff --git a/parser/html/nsHtml5TreeOpExecutor.cpp b/parser/html/nsHtml5TreeOpExecutor.cpp
index 9be7f3b0d..cd5c68913 100644
--- a/parser/html/nsHtml5TreeOpExecutor.cpp
+++ b/parser/html/nsHtml5TreeOpExecutor.cpp
@@ -923,14 +923,16 @@ nsHtml5TreeOpExecutor::PreloadScript(const nsAString& aURL,
const nsAString& aIntegrity,
bool aScriptFromHead,
bool aAsync,
- bool aDefer)
+ bool aDefer,
+ bool aNoModule)
{
nsCOMPtr<nsIURI> uri = ConvertIfNotPreloadedYet(aURL);
if (!uri) {
return;
}
mDocument->ScriptLoader()->PreloadURI(uri, aCharset, aType, aCrossOrigin,
- aIntegrity, aScriptFromHead, aAsync, aDefer,
+ aIntegrity, aScriptFromHead, aAsync,
+ aDefer, aNoModule,
mSpeculationReferrerPolicy);
}
diff --git a/parser/html/nsHtml5TreeOpExecutor.h b/parser/html/nsHtml5TreeOpExecutor.h
index 64a5daa96..878f359c5 100644
--- a/parser/html/nsHtml5TreeOpExecutor.h
+++ b/parser/html/nsHtml5TreeOpExecutor.h
@@ -251,7 +251,8 @@ class nsHtml5TreeOpExecutor final : public nsHtml5DocumentBuilder,
const nsAString& aIntegrity,
bool aScriptFromHead,
bool aAsync,
- bool aDefer);
+ bool aDefer,
+ bool aNoModule);
void PreloadStyle(const nsAString& aURL, const nsAString& aCharset,
const nsAString& aCrossOrigin,
diff --git a/parser/htmlparser/nsElementTable.cpp b/parser/htmlparser/nsElementTable.cpp
index 5c69726d1..5ce18aded 100644
--- a/parser/htmlparser/nsElementTable.cpp
+++ b/parser/htmlparser/nsElementTable.cpp
@@ -320,10 +320,6 @@ const nsHTMLElement gHTMLElements[] = {
/*parent,leaf*/ kSpecial, false
},
{
- /*tag*/ eHTMLTag_marquee,
- /*parent,leaf*/ kSpecial, false
- },
- {
/*tag*/ eHTMLTag_menu,
/*parent,leaf*/ kList, false
},
diff --git a/parser/htmlparser/nsHTMLTagList.h b/parser/htmlparser/nsHTMLTagList.h
index 7e1e207cc..62e1d2eb3 100644
--- a/parser/htmlparser/nsHTMLTagList.h
+++ b/parser/htmlparser/nsHTMLTagList.h
@@ -110,7 +110,6 @@ HTML_TAG(listing, Pre)
HTML_HTMLELEMENT_TAG(main)
HTML_TAG(map, Map)
HTML_HTMLELEMENT_TAG(mark)
-HTML_TAG(marquee, Div)
HTML_TAG(menu, Menu)
HTML_TAG(menuitem, MenuItem)
HTML_TAG(meta, Meta)
diff --git a/security/certverifier/CertVerifier.cpp b/security/certverifier/CertVerifier.cpp
index 1139ecae5..7f47de14f 100644
--- a/security/certverifier/CertVerifier.cpp
+++ b/security/certverifier/CertVerifier.cpp
@@ -422,7 +422,7 @@ CertVerifier::VerifyCert(CERTCertificate* cert, SECCertificateUsage usage,
SHA1Mode::Allowed,
NetscapeStepUpPolicy::NeverMatch,
originAttributes,
- builtChain, nullptr);
+ builtChain);
rv = BuildCertChain(trustDomain, certDER, time,
EndEntityOrCA::MustBeEndEntity,
KeyUsage::digitalSignature,
@@ -489,8 +489,7 @@ CertVerifier::VerifyCert(CERTCertificate* cert, SECCertificateUsage usage,
mCertShortLifetimeInDays, mPinningMode, MIN_RSA_BITS,
ValidityCheckingMode::CheckForEV,
sha1ModeConfigurations[i], mNetscapeStepUpPolicy,
- originAttributes, builtChain,
- hostname);
+ originAttributes, builtChain);
rv = BuildCertChainForOneKeyUsage(trustDomain, certDER, time,
KeyUsage::digitalSignature,// (EC)DHE
KeyUsage::keyEncipherment, // RSA
@@ -572,8 +571,7 @@ CertVerifier::VerifyCert(CERTCertificate* cert, SECCertificateUsage usage,
ValidityCheckingMode::CheckingOff,
sha1ModeConfigurations[j],
mNetscapeStepUpPolicy,
- originAttributes, builtChain,
- hostname);
+ originAttributes, builtChain);
rv = BuildCertChainForOneKeyUsage(trustDomain, certDER, time,
KeyUsage::digitalSignature,//(EC)DHE
KeyUsage::keyEncipherment,//RSA
@@ -635,7 +633,7 @@ CertVerifier::VerifyCert(CERTCertificate* cert, SECCertificateUsage usage,
pinningDisabled, MIN_RSA_BITS_WEAK,
ValidityCheckingMode::CheckingOff,
SHA1Mode::Allowed, mNetscapeStepUpPolicy,
- originAttributes, builtChain, nullptr);
+ originAttributes, builtChain);
rv = BuildCertChain(trustDomain, certDER, time,
EndEntityOrCA::MustBeCA, KeyUsage::keyCertSign,
KeyPurposeId::id_kp_serverAuth,
@@ -651,7 +649,7 @@ CertVerifier::VerifyCert(CERTCertificate* cert, SECCertificateUsage usage,
ValidityCheckingMode::CheckingOff,
SHA1Mode::Allowed,
NetscapeStepUpPolicy::NeverMatch,
- originAttributes, builtChain, nullptr);
+ originAttributes, builtChain);
rv = BuildCertChain(trustDomain, certDER, time,
EndEntityOrCA::MustBeEndEntity,
KeyUsage::digitalSignature,
@@ -678,7 +676,7 @@ CertVerifier::VerifyCert(CERTCertificate* cert, SECCertificateUsage usage,
ValidityCheckingMode::CheckingOff,
SHA1Mode::Allowed,
NetscapeStepUpPolicy::NeverMatch,
- originAttributes, builtChain, nullptr);
+ originAttributes, builtChain);
rv = BuildCertChain(trustDomain, certDER, time,
EndEntityOrCA::MustBeEndEntity,
KeyUsage::keyEncipherment, // RSA
@@ -702,7 +700,7 @@ CertVerifier::VerifyCert(CERTCertificate* cert, SECCertificateUsage usage,
ValidityCheckingMode::CheckingOff,
SHA1Mode::Allowed,
NetscapeStepUpPolicy::NeverMatch,
- originAttributes, builtChain, nullptr);
+ originAttributes, builtChain);
rv = BuildCertChain(trustDomain, certDER, time,
EndEntityOrCA::MustBeEndEntity,
KeyUsage::digitalSignature,
@@ -735,7 +733,7 @@ CertVerifier::VerifyCert(CERTCertificate* cert, SECCertificateUsage usage,
ValidityCheckingMode::CheckingOff,
SHA1Mode::Allowed,
NetscapeStepUpPolicy::NeverMatch,
- originAttributes, builtChain, nullptr);
+ originAttributes, builtChain);
rv = BuildCertChain(sslTrust, certDER, time, endEntityOrCA,
keyUsage, eku, CertPolicyId::anyPolicy,
stapledOCSPResponse);
@@ -747,7 +745,7 @@ CertVerifier::VerifyCert(CERTCertificate* cert, SECCertificateUsage usage,
ValidityCheckingMode::CheckingOff,
SHA1Mode::Allowed,
NetscapeStepUpPolicy::NeverMatch,
- originAttributes, builtChain, nullptr);
+ originAttributes, builtChain);
rv = BuildCertChain(emailTrust, certDER, time, endEntityOrCA,
keyUsage, eku, CertPolicyId::anyPolicy,
stapledOCSPResponse);
@@ -761,8 +759,7 @@ CertVerifier::VerifyCert(CERTCertificate* cert, SECCertificateUsage usage,
ValidityCheckingMode::CheckingOff,
SHA1Mode::Allowed,
NetscapeStepUpPolicy::NeverMatch,
- originAttributes, builtChain,
- nullptr);
+ originAttributes, builtChain);
rv = BuildCertChain(objectSigningTrust, certDER, time,
endEntityOrCA, keyUsage, eku,
CertPolicyId::anyPolicy, stapledOCSPResponse);
diff --git a/security/certverifier/NSSCertDBTrustDomain.cpp b/security/certverifier/NSSCertDBTrustDomain.cpp
index fff75ee88..a8ecbf1d1 100644
--- a/security/certverifier/NSSCertDBTrustDomain.cpp
+++ b/security/certverifier/NSSCertDBTrustDomain.cpp
@@ -58,8 +58,7 @@ NSSCertDBTrustDomain::NSSCertDBTrustDomain(SECTrustType certDBTrustType,
CertVerifier::SHA1Mode sha1Mode,
NetscapeStepUpPolicy netscapeStepUpPolicy,
const NeckoOriginAttributes& originAttributes,
- UniqueCERTCertList& builtChain,
- /*optional*/ const char* hostname)
+ UniqueCERTCertList& builtChain)
: mCertDBTrustType(certDBTrustType)
, mOCSPFetching(ocspFetching)
, mOCSPCache(ocspCache)
@@ -73,7 +72,6 @@ NSSCertDBTrustDomain::NSSCertDBTrustDomain(SECTrustType certDBTrustType,
, mNetscapeStepUpPolicy(netscapeStepUpPolicy)
, mOriginAttributes(originAttributes)
, mBuiltChain(builtChain)
- , mHostname(hostname)
, mCertBlocklist(do_GetService(NS_CERTBLOCKLIST_CONTRACTID))
, mOCSPStaplingStatus(CertVerifier::OCSP_STAPLING_NEVER_CHECKED)
, mSCTListFromCertificate()
diff --git a/security/certverifier/NSSCertDBTrustDomain.h b/security/certverifier/NSSCertDBTrustDomain.h
index becf29eee..50e2c8adc 100644
--- a/security/certverifier/NSSCertDBTrustDomain.h
+++ b/security/certverifier/NSSCertDBTrustDomain.h
@@ -83,8 +83,7 @@ public:
CertVerifier::SHA1Mode sha1Mode,
NetscapeStepUpPolicy netscapeStepUpPolicy,
const NeckoOriginAttributes& originAttributes,
- UniqueCERTCertList& builtChain,
- /*optional*/ const char* hostname = nullptr);
+ UniqueCERTCertList& builtChain);
virtual Result FindIssuer(mozilla::pkix::Input encodedIssuerName,
IssuerChecker& checker,
@@ -187,7 +186,6 @@ private:
NetscapeStepUpPolicy mNetscapeStepUpPolicy;
const NeckoOriginAttributes& mOriginAttributes;
UniqueCERTCertList& mBuiltChain; // non-owning
- const char* mHostname; // non-owning - only used for pinning checks
nsCOMPtr<nsICertBlocklist> mCertBlocklist;
CertVerifier::OCSPStaplingStatus mOCSPStaplingStatus;
// Certificate Transparency data extracted during certificate verification
diff --git a/testing/mozbase/mozlog/mozlog/formatters/html/xmlgen.py b/testing/mozbase/mozlog/mozlog/formatters/html/xmlgen.py
index e545e9a7d..e5998cda3 100644
--- a/testing/mozbase/mozlog/mozlog/formatters/html/xmlgen.py
+++ b/testing/mozbase/mozlog/mozlog/formatters/html/xmlgen.py
@@ -106,7 +106,7 @@ class html(Namespace):
'colgroup,comment,dd,del,dfn,dir,div,dl,dt,em,embed,'
'fieldset,font,form,frameset,h1,h2,h3,h4,h5,h6,head,html,'
'i,iframe,img,input,ins,kbd,label,legend,li,link,listing,'
- 'map,marquee,menu,meta,multicol,nobr,noembed,noframes,'
+ 'map,menu,meta,multicol,nobr,noembed,noframes,'
'noscript,object,ol,optgroup,option,p,pre,q,s,script,'
'select,small,span,strike,strong,style,sub,sup,table,'
'tbody,td,textarea,tfoot,th,thead,title,tr,tt,u,ul,xmp,'
diff --git a/testing/web-platform/tests/dom/nodes/Node-cloneNode.html b/testing/web-platform/tests/dom/nodes/Node-cloneNode.html
index 9fb939f7e..644a614fb 100644
--- a/testing/web-platform/tests/dom/nodes/Node-cloneNode.html
+++ b/testing/web-platform/tests/dom/nodes/Node-cloneNode.html
@@ -115,7 +115,6 @@ test(function() {
create_element_and_check("main", HTMLElement);
create_element_and_check("map", HTMLMapElement);
create_element_and_check("mark", HTMLElement);
- create_element_and_check("marquee", HTMLElement);
create_element_and_check("meta", HTMLMetaElement);
create_element_and_check("meter", HTMLMeterElement);
create_element_and_check("nav", HTMLElement);
diff --git a/testing/web-platform/tests/tools/html5lib/html5lib/constants.py b/testing/web-platform/tests/tools/html5lib/html5lib/constants.py
index e7089846d..a1f601b40 100644
--- a/testing/web-platform/tests/tools/html5lib/html5lib/constants.py
+++ b/testing/web-platform/tests/tools/html5lib/html5lib/constants.py
@@ -302,7 +302,6 @@ scopingElements = frozenset((
(namespaces["html"], "applet"),
(namespaces["html"], "caption"),
(namespaces["html"], "html"),
- (namespaces["html"], "marquee"),
(namespaces["html"], "object"),
(namespaces["html"], "table"),
(namespaces["html"], "td"),
@@ -386,7 +385,6 @@ specialElements = frozenset((
(namespaces["html"], "li"),
(namespaces["html"], "link"),
(namespaces["html"], "listing"),
- (namespaces["html"], "marquee"),
(namespaces["html"], "menu"),
(namespaces["html"], "meta"),
(namespaces["html"], "nav"),
diff --git a/testing/web-platform/tests/tools/html5lib/html5lib/html5parser.py b/testing/web-platform/tests/tools/html5lib/html5lib/html5parser.py
index 5b9ce7d72..048905ec3 100644
--- a/testing/web-platform/tests/tools/html5lib/html5lib/html5parser.py
+++ b/testing/web-platform/tests/tools/html5lib/html5lib/html5parser.py
@@ -898,7 +898,6 @@ def getPhases(debug):
"strong", "tt", "u"), self.startTagFormatting),
("nobr", self.startTagNobr),
("button", self.startTagButton),
- (("applet", "marquee", "object"), self.startTagAppletMarqueeObject),
("xmp", self.startTagXmp),
("table", self.startTagTable),
(("area", "br", "embed", "img", "keygen", "wbr"),
@@ -935,7 +934,6 @@ def getPhases(debug):
(headingElements, self.endTagHeading),
(("a", "b", "big", "code", "em", "font", "i", "nobr", "s", "small",
"strike", "strong", "tt", "u"), self.endTagFormatting),
- (("applet", "marquee", "object"), self.endTagAppletMarqueeObject),
("br", self.endTagBr),
])
self.endTagHandler.default = self.endTagOther
@@ -1133,12 +1131,6 @@ def getPhases(debug):
self.tree.insertElement(token)
self.parser.framesetOK = False
- def startTagAppletMarqueeObject(self, token):
- self.tree.reconstructActiveFormattingElements()
- self.tree.insertElement(token)
- self.tree.activeFormattingElements.append(Marker)
- self.parser.framesetOK = False
-
def startTagXmp(self, token):
if self.tree.elementInScope("p", variant="button"):
self.endTagP(impliedTagToken("p"))
@@ -1558,17 +1550,6 @@ def getPhases(debug):
self.tree.openElements.insert(
self.tree.openElements.index(furthestBlock) + 1, clone)
- def endTagAppletMarqueeObject(self, token):
- if self.tree.elementInScope(token["name"]):
- self.tree.generateImpliedEndTags()
- if self.tree.openElements[-1].name != token["name"]:
- self.parser.parseError("end-tag-too-early", {"name": token["name"]})
-
- if self.tree.elementInScope(token["name"]):
- element = self.tree.openElements.pop()
- while element.name != token["name"]:
- element = self.tree.openElements.pop()
- self.tree.clearActiveFormattingElements()
def endTagBr(self, token):
self.parser.parseError("unexpected-end-tag-treated-as",
diff --git a/testing/web-platform/tests/tools/html5lib/html5lib/tests/testdata/tree-construction/tests1.dat b/testing/web-platform/tests/tools/html5lib/html5lib/tests/testdata/tree-construction/tests1.dat
index d6726e305..cc65fd2fa 100644
--- a/testing/web-platform/tests/tools/html5lib/html5lib/tests/testdata/tree-construction/tests1.dat
+++ b/testing/web-platform/tests/tools/html5lib/html5lib/tests/testdata/tree-construction/tests1.dat
@@ -284,27 +284,6 @@ Line1<br>Line2<br>Line3<br>Line4
| "foobar"
#data
-<p><b><div><marquee></p></b></div>X
-#errors
-(1,3): expected-doctype-but-got-start-tag
-(1,11): unexpected-end-tag
-(1,24): unexpected-end-tag
-(1,28): unexpected-end-tag
-(1,34): end-tag-too-early
-(1,35): expected-closing-tag-but-got-eof
-#document
-| <html>
-| <head>
-| <body>
-| <p>
-| <b>
-| <div>
-| <b>
-| <marquee>
-| <p>
-| "X"
-
-#data
<script><div></script></div><title><p></title><p><p>
#errors
(1,8): expected-doctype-but-got-start-tag
@@ -1205,26 +1184,6 @@ Line1<br>Line2<br>Line3<br>Line4
| "aoe"
#data
-<a href=a>aa<marquee>aa<a href=b>bb</marquee>aa
-#errors
-(1,10): expected-doctype-but-got-start-tag
-(1,45): end-tag-too-early
-(1,47): expected-closing-tag-but-got-eof
-#document
-| <html>
-| <head>
-| <body>
-| <a>
-| href="a"
-| "aa"
-| <marquee>
-| "aa"
-| <a>
-| href="b"
-| "bb"
-| "aa"
-
-#data
<wbr><strike><code></strike><code><strike></code>
#errors
(1,5): expected-doctype-but-got-start-tag
@@ -1485,26 +1444,6 @@ Line1<br>Line2<br>Line3<br>Line4
| <b>
#data
-<p><b><div><marquee></p></b></div>
-#errors
-(1,3): expected-doctype-but-got-start-tag
-(1,11): unexpected-end-tag
-(1,24): unexpected-end-tag
-(1,28): unexpected-end-tag
-(1,34): end-tag-too-early
-(1,34): expected-closing-tag-but-got-eof
-#document
-| <html>
-| <head>
-| <body>
-| <p>
-| <b>
-| <div>
-| <b>
-| <marquee>
-| <p>
-
-#data
<script></script></div><title></title><p><p>
#errors
(1,8): expected-doctype-but-got-start-tag
@@ -1730,225 +1669,6 @@ Line1<br>Line2<br>Line3<br>Line4
| <colgroup>
#data
-</strong></b></em></i></u></strike></s></blink></tt></pre></big></small></font></select></h1></h2></h3></h4></h5></h6></body></br></a></img></title></span></style></script></table></th></td></tr></frame></area></link></param></hr></input></col></base></meta></basefont></bgsound></embed></spacer></p></dd></dt></caption></colgroup></tbody></tfoot></thead></address></blockquote></center></dir></div></dl></fieldset></listing></menu></ol></ul></li></nobr></wbr></form></button></marquee></object></html></frameset></head></iframe></image></isindex></noembed></noframes></noscript></optgroup></option></plaintext></textarea>
-#errors
-(1,9): expected-doctype-but-got-end-tag
-(1,9): unexpected-end-tag-before-html
-(1,13): unexpected-end-tag-before-html
-(1,18): unexpected-end-tag-before-html
-(1,22): unexpected-end-tag-before-html
-(1,26): unexpected-end-tag-before-html
-(1,35): unexpected-end-tag-before-html
-(1,39): unexpected-end-tag-before-html
-(1,47): unexpected-end-tag-before-html
-(1,52): unexpected-end-tag-before-html
-(1,58): unexpected-end-tag-before-html
-(1,64): unexpected-end-tag-before-html
-(1,72): unexpected-end-tag-before-html
-(1,79): unexpected-end-tag-before-html
-(1,88): unexpected-end-tag-before-html
-(1,93): unexpected-end-tag-before-html
-(1,98): unexpected-end-tag-before-html
-(1,103): unexpected-end-tag-before-html
-(1,108): unexpected-end-tag-before-html
-(1,113): unexpected-end-tag-before-html
-(1,118): unexpected-end-tag-before-html
-(1,130): unexpected-end-tag-after-body
-(1,130): unexpected-end-tag-treated-as
-(1,134): unexpected-end-tag
-(1,140): unexpected-end-tag
-(1,148): unexpected-end-tag
-(1,155): unexpected-end-tag
-(1,163): unexpected-end-tag
-(1,172): unexpected-end-tag
-(1,180): unexpected-end-tag
-(1,185): unexpected-end-tag
-(1,190): unexpected-end-tag
-(1,195): unexpected-end-tag
-(1,203): unexpected-end-tag
-(1,210): unexpected-end-tag
-(1,217): unexpected-end-tag
-(1,225): unexpected-end-tag
-(1,230): unexpected-end-tag
-(1,238): unexpected-end-tag
-(1,244): unexpected-end-tag
-(1,251): unexpected-end-tag
-(1,258): unexpected-end-tag
-(1,269): unexpected-end-tag
-(1,279): unexpected-end-tag
-(1,287): unexpected-end-tag
-(1,296): unexpected-end-tag
-(1,300): unexpected-end-tag
-(1,305): unexpected-end-tag
-(1,310): unexpected-end-tag
-(1,320): unexpected-end-tag
-(1,331): unexpected-end-tag
-(1,339): unexpected-end-tag
-(1,347): unexpected-end-tag
-(1,355): unexpected-end-tag
-(1,365): end-tag-too-early
-(1,378): end-tag-too-early
-(1,387): end-tag-too-early
-(1,393): end-tag-too-early
-(1,399): end-tag-too-early
-(1,404): end-tag-too-early
-(1,415): end-tag-too-early
-(1,425): end-tag-too-early
-(1,432): end-tag-too-early
-(1,437): end-tag-too-early
-(1,442): end-tag-too-early
-(1,447): unexpected-end-tag
-(1,454): unexpected-end-tag
-(1,460): unexpected-end-tag
-(1,467): unexpected-end-tag
-(1,476): end-tag-too-early
-(1,486): end-tag-too-early
-(1,495): end-tag-too-early
-(1,513): expected-eof-but-got-end-tag
-(1,513): unexpected-end-tag
-(1,520): unexpected-end-tag
-(1,529): unexpected-end-tag
-(1,537): unexpected-end-tag
-(1,547): unexpected-end-tag
-(1,557): unexpected-end-tag
-(1,568): unexpected-end-tag
-(1,579): unexpected-end-tag
-(1,590): unexpected-end-tag
-(1,599): unexpected-end-tag
-(1,611): unexpected-end-tag
-(1,622): unexpected-end-tag
-#document
-| <html>
-| <head>
-| <body>
-| <br>
-| <p>
-
-#data
-<table><tr></strong></b></em></i></u></strike></s></blink></tt></pre></big></small></font></select></h1></h2></h3></h4></h5></h6></body></br></a></img></title></span></style></script></table></th></td></tr></frame></area></link></param></hr></input></col></base></meta></basefont></bgsound></embed></spacer></p></dd></dt></caption></colgroup></tbody></tfoot></thead></address></blockquote></center></dir></div></dl></fieldset></listing></menu></ol></ul></li></nobr></wbr></form></button></marquee></object></html></frameset></head></iframe></image></isindex></noembed></noframes></noscript></optgroup></option></plaintext></textarea>
-#errors
-(1,7): expected-doctype-but-got-start-tag
-(1,20): unexpected-end-tag-implies-table-voodoo
-(1,20): unexpected-end-tag
-(1,24): unexpected-end-tag-implies-table-voodoo
-(1,24): unexpected-end-tag
-(1,29): unexpected-end-tag-implies-table-voodoo
-(1,29): unexpected-end-tag
-(1,33): unexpected-end-tag-implies-table-voodoo
-(1,33): unexpected-end-tag
-(1,37): unexpected-end-tag-implies-table-voodoo
-(1,37): unexpected-end-tag
-(1,46): unexpected-end-tag-implies-table-voodoo
-(1,46): unexpected-end-tag
-(1,50): unexpected-end-tag-implies-table-voodoo
-(1,50): unexpected-end-tag
-(1,58): unexpected-end-tag-implies-table-voodoo
-(1,58): unexpected-end-tag
-(1,63): unexpected-end-tag-implies-table-voodoo
-(1,63): unexpected-end-tag
-(1,69): unexpected-end-tag-implies-table-voodoo
-(1,69): end-tag-too-early
-(1,75): unexpected-end-tag-implies-table-voodoo
-(1,75): unexpected-end-tag
-(1,83): unexpected-end-tag-implies-table-voodoo
-(1,83): unexpected-end-tag
-(1,90): unexpected-end-tag-implies-table-voodoo
-(1,90): unexpected-end-tag
-(1,99): unexpected-end-tag-implies-table-voodoo
-(1,99): unexpected-end-tag
-(1,104): unexpected-end-tag-implies-table-voodoo
-(1,104): end-tag-too-early
-(1,109): unexpected-end-tag-implies-table-voodoo
-(1,109): end-tag-too-early
-(1,114): unexpected-end-tag-implies-table-voodoo
-(1,114): end-tag-too-early
-(1,119): unexpected-end-tag-implies-table-voodoo
-(1,119): end-tag-too-early
-(1,124): unexpected-end-tag-implies-table-voodoo
-(1,124): end-tag-too-early
-(1,129): unexpected-end-tag-implies-table-voodoo
-(1,129): end-tag-too-early
-(1,136): unexpected-end-tag-in-table-row
-(1,141): unexpected-end-tag-implies-table-voodoo
-(1,141): unexpected-end-tag-treated-as
-(1,145): unexpected-end-tag-implies-table-voodoo
-(1,145): unexpected-end-tag
-(1,151): unexpected-end-tag-implies-table-voodoo
-(1,151): unexpected-end-tag
-(1,159): unexpected-end-tag-implies-table-voodoo
-(1,159): unexpected-end-tag
-(1,166): unexpected-end-tag-implies-table-voodoo
-(1,166): unexpected-end-tag
-(1,174): unexpected-end-tag-implies-table-voodoo
-(1,174): unexpected-end-tag
-(1,183): unexpected-end-tag-implies-table-voodoo
-(1,183): unexpected-end-tag
-(1,196): unexpected-end-tag
-(1,201): unexpected-end-tag
-(1,206): unexpected-end-tag
-(1,214): unexpected-end-tag
-(1,221): unexpected-end-tag
-(1,228): unexpected-end-tag
-(1,236): unexpected-end-tag
-(1,241): unexpected-end-tag
-(1,249): unexpected-end-tag
-(1,255): unexpected-end-tag
-(1,262): unexpected-end-tag
-(1,269): unexpected-end-tag
-(1,280): unexpected-end-tag
-(1,290): unexpected-end-tag
-(1,298): unexpected-end-tag
-(1,307): unexpected-end-tag
-(1,311): unexpected-end-tag
-(1,316): unexpected-end-tag
-(1,321): unexpected-end-tag
-(1,331): unexpected-end-tag
-(1,342): unexpected-end-tag
-(1,350): unexpected-end-tag
-(1,358): unexpected-end-tag
-(1,366): unexpected-end-tag
-(1,376): end-tag-too-early
-(1,389): end-tag-too-early
-(1,398): end-tag-too-early
-(1,404): end-tag-too-early
-(1,410): end-tag-too-early
-(1,415): end-tag-too-early
-(1,426): end-tag-too-early
-(1,436): end-tag-too-early
-(1,443): end-tag-too-early
-(1,448): end-tag-too-early
-(1,453): end-tag-too-early
-(1,458): unexpected-end-tag
-(1,465): unexpected-end-tag
-(1,471): unexpected-end-tag
-(1,478): unexpected-end-tag
-(1,487): end-tag-too-early
-(1,497): end-tag-too-early
-(1,506): end-tag-too-early
-(1,524): expected-eof-but-got-end-tag
-(1,524): unexpected-end-tag
-(1,531): unexpected-end-tag
-(1,540): unexpected-end-tag
-(1,548): unexpected-end-tag
-(1,558): unexpected-end-tag
-(1,568): unexpected-end-tag
-(1,579): unexpected-end-tag
-(1,590): unexpected-end-tag
-(1,601): unexpected-end-tag
-(1,610): unexpected-end-tag
-(1,622): unexpected-end-tag
-(1,633): unexpected-end-tag
-#document
-| <html>
-| <head>
-| <body>
-| <br>
-| <table>
-| <tbody>
-| <tr>
-| <p>
-
-#data
<frameset>
#errors
(1,10): expected-doctype-but-got-start-tag
diff --git a/testing/web-platform/tests/tools/html5lib/html5lib/tests/testdata/tree-construction/tests19.dat b/testing/web-platform/tests/tools/html5lib/html5lib/tests/testdata/tree-construction/tests19.dat
index 02158c8bb..00cc79243 100644
--- a/testing/web-platform/tests/tools/html5lib/html5lib/tests/testdata/tree-construction/tests19.dat
+++ b/testing/web-platform/tests/tools/html5lib/html5lib/tests/testdata/tree-construction/tests19.dat
@@ -782,18 +782,6 @@
| <applet>
#data
-<!doctype html><marquee><frameset>
-#errors
-(1,34): unexpected-start-tag
-(1,34): expected-closing-tag-but-got-eof
-#document
-| <!DOCTYPE html>
-| <html>
-| <head>
-| <body>
-| <marquee>
-
-#data
<!doctype html><object><frameset>
#errors
(1,33): unexpected-start-tag
diff --git a/testing/web-platform/tests/tools/html5lib/html5lib/treebuilders/_base.py b/testing/web-platform/tests/tools/html5lib/html5lib/treebuilders/_base.py
index 8b97cc11a..13c73bf22 100644
--- a/testing/web-platform/tests/tools/html5lib/html5lib/treebuilders/_base.py
+++ b/testing/web-platform/tests/tools/html5lib/html5lib/treebuilders/_base.py
@@ -4,8 +4,8 @@ from six import text_type
from ..constants import scopingElements, tableInsertModeElements, namespaces
# The scope markers are inserted when entering object elements,
-# marquees, table cells, and table captions, and are used to prevent formatting
-# from "leaking" into tables, object elements, and marquees.
+# table cells, and table captions, and are used to prevent formatting
+# from "leaking" into tables, and object elements.
Marker = None
listElementsMap = {
diff --git a/testing/web-platform/tests/tools/py/py/_xmlgen.py b/testing/web-platform/tests/tools/py/py/_xmlgen.py
index 2ffcaa14b..741e2029e 100644
--- a/testing/web-platform/tests/tools/py/py/_xmlgen.py
+++ b/testing/web-platform/tests/tools/py/py/_xmlgen.py
@@ -79,7 +79,7 @@ class html(Namespace):
'colgroup,comment,dd,del,dfn,dir,div,dl,dt,em,embed,'
'fieldset,font,form,frameset,h1,h2,h3,h4,h5,h6,head,html,'
'i,iframe,img,input,ins,kbd,label,legend,li,link,listing,'
- 'map,marquee,menu,meta,multicol,nobr,noembed,noframes,'
+ 'map,menu,meta,multicol,nobr,noembed,noframes,'
'noscript,object,ol,optgroup,option,p,pre,q,s,script,'
'select,small,span,strike,strong,style,sub,sup,table,'
'tbody,td,textarea,tfoot,th,thead,title,tr,tt,u,ul,xmp,'
diff --git a/toolkit/library/moz.build b/toolkit/library/moz.build
index d9b167547..9daef44a4 100644
--- a/toolkit/library/moz.build
+++ b/toolkit/library/moz.build
@@ -277,6 +277,7 @@ if CONFIG['OS_ARCH'] == 'WINNT':
'psapi',
'ws2_32',
'dbghelp',
+ 'dwmapi',
'rasapi32',
'rasdlg',
'iphlpapi',
diff --git a/toolkit/locales/en-US/chrome/mozapps/extensions/extensions.dtd b/toolkit/locales/en-US/chrome/mozapps/extensions/extensions.dtd
index a99c825f1..098896d99 100644
--- a/toolkit/locales/en-US/chrome/mozapps/extensions/extensions.dtd
+++ b/toolkit/locales/en-US/chrome/mozapps/extensions/extensions.dtd
@@ -33,10 +33,6 @@
<!ENTITY warning.updatesecurity.enable.label "Enable">
<!ENTITY warning.updatesecurity.enable.tooltip "Enable add-on update security checking">
-<!-- global informations -->
-<!ENTITY info.plugincheck.label "Check to see if your plugins are up to date">
-<!ENTITY info.plugincheck.tooltip "Check to see if your plugins are up to date">
-
<!-- categories / views -->
<!ENTITY view.search.label "Search">
<!ENTITY view.discover.label "Get Add-ons">
diff --git a/toolkit/mozapps/extensions/content/extensions.js b/toolkit/mozapps/extensions/content/extensions.js
index 3c3b5894b..99b71562f 100644
--- a/toolkit/mozapps/extensions/content/extensions.js
+++ b/toolkit/mozapps/extensions/content/extensions.js
@@ -809,15 +809,6 @@ var gViewController = {
}
},
-/* Plugincheck service is currently N/A for Pale Moon
- cmd_pluginCheck: {
- isEnabled: function cmd_pluginCheck_isEnabled() true,
- doCommand: function cmd_pluginCheck_doCommand() {
- openURL(Services.urlFormatter.formatURLPref("plugins.update.url"));
- }
- },
-*/
-
cmd_toggleAutoUpdateDefault: {
isEnabled: function cmd_toggleAutoUpdateDefault_isEnabled() true,
doCommand: function cmd_toggleAutoUpdateDefault_doCommand() {
@@ -3028,10 +3019,7 @@ var gDetailView = {
"details.notification.outdated",
[this._addon.name], 1
);
- var warningLink = document.getElementById("detail-warning-link");
- warningLink.value = gStrings.ext.GetStringFromName("details.notification.outdated.link");
- warningLink.href = Services.urlFormatter.formatURLPref("plugins.update.url");
- warningLink.hidden = false;
+ document.getElementById("detail-warning-link").hidden = true;
} else if (this._addon.blocklistState == Ci.nsIBlocklistService.STATE_VULNERABLE_UPDATE_AVAILABLE) {
this.node.setAttribute("notification", "error");
document.getElementById("detail-error").textContent = gStrings.ext.formatStringFromName(
diff --git a/toolkit/mozapps/extensions/content/extensions.xml b/toolkit/mozapps/extensions/content/extensions.xml
index e2eef852a..fc19be4b3 100644
--- a/toolkit/mozapps/extensions/content/extensions.xml
+++ b/toolkit/mozapps/extensions/content/extensions.xml
@@ -1324,9 +1324,7 @@
"notification.outdated",
[this.mAddon.name], 1
);
- this._warningLink.value = gStrings.ext.GetStringFromName("notification.outdated.link");
- this._warningLink.href = Services.urlFormatter.formatURLPref("plugins.update.url");
- this._warningLink.hidden = false;
+ this._warningLink.hidden = true;
this._warningBtn.hidden = true;
} else if (!isUpgrade && this.mAddon.blocklistState == Ci.nsIBlocklistService.STATE_VULNERABLE_UPDATE_AVAILABLE) {
this.setAttribute("notification", "error");
diff --git a/toolkit/mozapps/extensions/content/extensions.xul b/toolkit/mozapps/extensions/content/extensions.xul
index 292ecf8d3..70ce55fa2 100644
--- a/toolkit/mozapps/extensions/content/extensions.xul
+++ b/toolkit/mozapps/extensions/content/extensions.xul
@@ -88,7 +88,6 @@
<command id="cmd_back"/>
<command id="cmd_forward"/>
<command id="cmd_enableCheckCompatibility"/>
-<!-- <command id="cmd_pluginCheck"/> -->
<command id="cmd_enableUpdateSecurity"/>
<command id="cmd_toggleAutoUpdateDefault"/>
<command id="cmd_resetAddonAutoUpdate"/>
@@ -355,15 +354,6 @@
<spacer flex="5000"/> <!-- Necessary to allow the message to wrap -->
</hbox>
</hbox>
-<!-- <hbox class="view-header global-info-container plugin-info-container">
- <hbox class="global-info" flex="1" align="center">
- <button class="button-link global-info-plugincheck"
- label="&info.plugincheck.label;"
- tooltiptext="&info.plugincheck.tooltip;"
- command="cmd_pluginCheck"/>
- <spacer flex="5000"/>
- </hbox>
- </hbox> -->
<hbox class="view-header global-info-container experiment-info-container">
<hbox class="global-info" flex="1" align="center">
<label value="&experiment.info.label;"/>
diff --git a/widget/cocoa/nsDragService.mm b/widget/cocoa/nsDragService.mm
index b92db1b2a..c4d8e6ff0 100644
--- a/widget/cocoa/nsDragService.mm
+++ b/widget/cocoa/nsDragService.mm
@@ -222,7 +222,7 @@ nsDragService::ConstructDragImage(nsIDOMNode* aDOMNode,
bool
nsDragService::IsValidType(NSString* availableType, bool allowFileURL)
{
- NS_OBJC_BEGIN_TRY_ABORT_BLOCK;
+ NS_OBJC_BEGIN_TRY_ABORT_BLOCK_RETURN;
// Prevent exposing fileURL for non-fileURL type.
// We need URL provided by dropped webloc file, but don't need file's URL.
@@ -234,7 +234,7 @@ nsDragService::IsValidType(NSString* availableType, bool allowFileURL)
return true;
- NS_OBJC_END_TRY_ABORT_BLOCK(false);
+ NS_OBJC_END_TRY_ABORT_BLOCK_RETURN(false);
}
NSString*
diff --git a/widget/windows/AudioSession.cpp b/widget/windows/AudioSession.cpp
index 11e5ba50c..1a83e2964 100644
--- a/widget/windows/AudioSession.cpp
+++ b/widget/windows/AudioSession.cpp
@@ -13,7 +13,7 @@
#include "nsIUUIDGenerator.h"
#include "nsIXULAppInfo.h"
-//#include "AudioSession.h"
+#include "AudioSession.h"
#include "nsCOMPtr.h"
#include "nsServiceManagerUtils.h"
#include "nsString.h"
@@ -27,7 +27,7 @@ namespace mozilla {
namespace widget {
/*
- * To take advantage of what Vista+ have to offer with respect to audio,
+ * To take advantage of what Windows has to offer with respect to audio,
* we need to maintain an audio session. This class wraps IAudioSessionControl
* and implements IAudioSessionEvents (for callbacks from Windows)
*/
diff --git a/widget/windows/CompositorWidgetParent.cpp b/widget/windows/CompositorWidgetParent.cpp
index c784ff72e..238141f56 100644
--- a/widget/windows/CompositorWidgetParent.cpp
+++ b/widget/windows/CompositorWidgetParent.cpp
@@ -4,6 +4,7 @@
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#include "CompositorWidgetParent.h"
+#include "VsyncDispatcher.h"
#include "mozilla/Unused.h"
diff --git a/widget/windows/IMMHandler.cpp b/widget/windows/IMMHandler.cpp
index 9bd7d2e7a..e16517a38 100644
--- a/widget/windows/IMMHandler.cpp
+++ b/widget/windows/IMMHandler.cpp
@@ -17,6 +17,8 @@
#include "mozilla/MiscEvents.h"
#include "mozilla/TextEvents.h"
+using namespace mozilla;
+
#ifndef IME_PROP_ACCEPT_WIDE_VKEY
#define IME_PROP_ACCEPT_WIDE_VKEY 0x20
#endif
diff --git a/widget/windows/InkCollector.cpp b/widget/windows/InkCollector.cpp
index 5383dda7c..3268fe95b 100644
--- a/widget/windows/InkCollector.cpp
+++ b/widget/windows/InkCollector.cpp
@@ -7,6 +7,8 @@
#include "InkCollector.h"
+using namespace mozilla;
+
// Msinkaut_i.c and Msinkaut.h should both be included
// https://msdn.microsoft.com/en-us/library/windows/desktop/ms695519.aspx
#include <msinkaut_i.c>
diff --git a/widget/windows/KeyboardLayout.cpp b/widget/windows/KeyboardLayout.cpp
index 9166d97d7..b4801fa19 100644
--- a/widget/windows/KeyboardLayout.cpp
+++ b/widget/windows/KeyboardLayout.cpp
@@ -39,11 +39,6 @@
#include <winable.h>
#endif
-// In WinUser.h, MAPVK_VK_TO_VSC_EX is defined only when WINVER >= 0x0600
-#ifndef MAPVK_VK_TO_VSC_EX
-#define MAPVK_VK_TO_VSC_EX (4)
-#endif
-
namespace mozilla {
namespace widget {
diff --git a/widget/windows/TaskbarPreview.cpp b/widget/windows/TaskbarPreview.cpp
index 6c15df2e0..b07b8039f 100644
--- a/widget/windows/TaskbarPreview.cpp
+++ b/widget/windows/TaskbarPreview.cpp
@@ -139,7 +139,7 @@ TaskbarPreview::Invalidate() {
return NS_OK;
HWND previewWindow = PreviewWindow();
- return FAILED(WinUtils::dwmInvalidateIconicBitmapsPtr(previewWindow))
+ return FAILED(DwmInvalidateIconicBitmaps(previewWindow))
? NS_ERROR_FAILURE
: NS_OK;
}
@@ -284,13 +284,13 @@ TaskbarPreview::GetWindowHook() {
void
TaskbarPreview::EnableCustomDrawing(HWND aHWND, bool aEnable) {
BOOL enabled = aEnable;
- WinUtils::dwmSetWindowAttributePtr(
+ DwmSetWindowAttribute(
aHWND,
DWMWA_FORCE_ICONIC_REPRESENTATION,
&enabled,
sizeof(enabled));
- WinUtils::dwmSetWindowAttributePtr(
+ DwmSetWindowAttribute(
aHWND,
DWMWA_HAS_ICONIC_BITMAP,
&enabled,
@@ -385,11 +385,11 @@ TaskbarPreviewCallback::Done(nsISupports *aCanvas, bool aDrawBorder) {
POINT pptClient = { 0, 0 };
HRESULT hr;
if (!mIsThumbnail) {
- hr = WinUtils::dwmSetIconicLivePreviewBitmapPtr(mPreview->PreviewWindow(),
- hBitmap, &pptClient, flags);
+ hr = DwmSetIconicLivePreviewBitmap(mPreview->PreviewWindow(),
+ hBitmap, &pptClient, flags);
} else {
- hr = WinUtils::dwmSetIconicThumbnailPtr(mPreview->PreviewWindow(),
- hBitmap, flags);
+ hr = DwmSetIconicThumbnail(mPreview->PreviewWindow(),
+ hBitmap, flags);
}
MOZ_ASSERT(SUCCEEDED(hr));
return NS_OK;
diff --git a/widget/windows/WinIMEHandler.cpp b/widget/windows/WinIMEHandler.cpp
index 9debaa2dd..f411cdd50 100644
--- a/widget/windows/WinIMEHandler.cpp
+++ b/widget/windows/WinIMEHandler.cpp
@@ -961,8 +961,8 @@ IMEHandler::ShowOnScreenKeyboard()
} else {
PWSTR path = nullptr;
HRESULT hres =
- WinUtils::SHGetKnownFolderPath(FOLDERID_ProgramFilesCommon, 0,
- nullptr, &path);
+ SHGetKnownFolderPath(FOLDERID_ProgramFilesCommon, 0,
+ nullptr, &path);
if (FAILED(hres) || !path) {
return;
}
diff --git a/widget/windows/WinUtils.cpp b/widget/windows/WinUtils.cpp
index bd42e78f6..28033193f 100644
--- a/widget/windows/WinUtils.cpp
+++ b/widget/windows/WinUtils.cpp
@@ -419,26 +419,10 @@ const char FaviconHelper::kShortcutCacheDir[] = "shortcutCache";
// apis available on vista and up.
WinUtils::SHCreateItemFromParsingNamePtr WinUtils::sCreateItemFromParsingName = nullptr;
-WinUtils::SHGetKnownFolderPathPtr WinUtils::sGetKnownFolderPath = nullptr;
-
// We just leak these DLL HMODULEs. There's no point in calling FreeLibrary
// on them during shutdown anyway.
static const wchar_t kShellLibraryName[] = L"shell32.dll";
static HMODULE sShellDll = nullptr;
-static const wchar_t kDwmLibraryName[] = L"dwmapi.dll";
-static HMODULE sDwmDll = nullptr;
-
-WinUtils::DwmExtendFrameIntoClientAreaProc WinUtils::dwmExtendFrameIntoClientAreaPtr = nullptr;
-WinUtils::DwmIsCompositionEnabledProc WinUtils::dwmIsCompositionEnabledPtr = nullptr;
-WinUtils::DwmSetIconicThumbnailProc WinUtils::dwmSetIconicThumbnailPtr = nullptr;
-WinUtils::DwmSetIconicLivePreviewBitmapProc WinUtils::dwmSetIconicLivePreviewBitmapPtr = nullptr;
-WinUtils::DwmGetWindowAttributeProc WinUtils::dwmGetWindowAttributePtr = nullptr;
-WinUtils::DwmSetWindowAttributeProc WinUtils::dwmSetWindowAttributePtr = nullptr;
-WinUtils::DwmInvalidateIconicBitmapsProc WinUtils::dwmInvalidateIconicBitmapsPtr = nullptr;
-WinUtils::DwmDefWindowProcProc WinUtils::dwmDwmDefWindowProcPtr = nullptr;
-WinUtils::DwmGetCompositionTimingInfoProc WinUtils::dwmGetCompositionTimingInfoPtr = nullptr;
-WinUtils::DwmFlushProc WinUtils::dwmFlushProcPtr = nullptr;
-
// Prefix for path used by NT calls.
const wchar_t kNTPrefix[] = L"\\??\\";
const size_t kNTPrefixLen = ArrayLength(kNTPrefix) - 1;
@@ -462,23 +446,6 @@ static NtTestAlertPtr sNtTestAlert = nullptr;
void
WinUtils::Initialize()
{
- if (!sDwmDll) {
- sDwmDll = ::LoadLibraryW(kDwmLibraryName);
-
- if (sDwmDll) {
- dwmExtendFrameIntoClientAreaPtr = (DwmExtendFrameIntoClientAreaProc)::GetProcAddress(sDwmDll, "DwmExtendFrameIntoClientArea");
- dwmIsCompositionEnabledPtr = (DwmIsCompositionEnabledProc)::GetProcAddress(sDwmDll, "DwmIsCompositionEnabled");
- dwmSetIconicThumbnailPtr = (DwmSetIconicThumbnailProc)::GetProcAddress(sDwmDll, "DwmSetIconicThumbnail");
- dwmSetIconicLivePreviewBitmapPtr = (DwmSetIconicLivePreviewBitmapProc)::GetProcAddress(sDwmDll, "DwmSetIconicLivePreviewBitmap");
- dwmGetWindowAttributePtr = (DwmGetWindowAttributeProc)::GetProcAddress(sDwmDll, "DwmGetWindowAttribute");
- dwmSetWindowAttributePtr = (DwmSetWindowAttributeProc)::GetProcAddress(sDwmDll, "DwmSetWindowAttribute");
- dwmInvalidateIconicBitmapsPtr = (DwmInvalidateIconicBitmapsProc)::GetProcAddress(sDwmDll, "DwmInvalidateIconicBitmaps");
- dwmDwmDefWindowProcPtr = (DwmDefWindowProcProc)::GetProcAddress(sDwmDll, "DwmDefWindowProc");
- dwmGetCompositionTimingInfoPtr = (DwmGetCompositionTimingInfoProc)::GetProcAddress(sDwmDll, "DwmGetCompositionTimingInfo");
- dwmFlushProcPtr = (DwmFlushProc)::GetProcAddress(sDwmDll, "DwmFlush");
- }
- }
-
if (IsWin10OrLater()) {
HMODULE user32Dll = ::GetModuleHandleW(L"user32");
if (user32Dll) {
@@ -1179,32 +1146,6 @@ WinUtils::SHCreateItemFromParsingName(PCWSTR pszPath, IBindCtx *pbc,
return sCreateItemFromParsingName(pszPath, pbc, riid, ppv);
}
-/* static */
-HRESULT
-WinUtils::SHGetKnownFolderPath(REFKNOWNFOLDERID rfid,
- DWORD dwFlags,
- HANDLE hToken,
- PWSTR *ppszPath)
-{
- if (sGetKnownFolderPath) {
- return sGetKnownFolderPath(rfid, dwFlags, hToken, ppszPath);
- }
-
- if (!sShellDll) {
- sShellDll = ::LoadLibraryW(kShellLibraryName);
- if (!sShellDll) {
- return false;
- }
- }
-
- sGetKnownFolderPath = (SHGetKnownFolderPathPtr)
- GetProcAddress(sShellDll, "SHGetKnownFolderPath");
- if (!sGetKnownFolderPath)
- return E_FAIL;
-
- return sGetKnownFolderPath(rfid, dwFlags, hToken, ppszPath);
-}
-
static BOOL
WINAPI EnumFirstChild(HWND hwnd, LPARAM lParam)
{
diff --git a/widget/windows/WinUtils.h b/widget/windows/WinUtils.h
index 37469ce07..1281171be 100644
--- a/widget/windows/WinUtils.h
+++ b/widget/windows/WinUtils.h
@@ -399,14 +399,6 @@ public:
REFIID riid, void **ppv);
/**
- * SHGetKnownFolderPath() calls native SHGetKnownFolderPath()
- * API which is available on Vista and up.
- */
- static HRESULT SHGetKnownFolderPath(REFKNOWNFOLDERID rfid,
- DWORD dwFlags,
- HANDLE hToken,
- PWSTR *ppszPath);
- /**
* GetShellItemPath return the file or directory path of a shell item.
* Internally calls IShellItem's GetDisplayName.
*
@@ -478,31 +470,6 @@ public:
*/
static bool ResolveJunctionPointsAndSymLinks(std::wstring& aPath);
- /**
- * dwmapi.dll function typedefs and declarations
- */
- typedef HRESULT (WINAPI*DwmExtendFrameIntoClientAreaProc)(HWND hWnd, const MARGINS *pMarInset);
- typedef HRESULT (WINAPI*DwmIsCompositionEnabledProc)(BOOL *pfEnabled);
- typedef HRESULT (WINAPI*DwmSetIconicThumbnailProc)(HWND hWnd, HBITMAP hBitmap, DWORD dwSITFlags);
- typedef HRESULT (WINAPI*DwmSetIconicLivePreviewBitmapProc)(HWND hWnd, HBITMAP hBitmap, POINT *pptClient, DWORD dwSITFlags);
- typedef HRESULT (WINAPI*DwmGetWindowAttributeProc)(HWND hWnd, DWORD dwAttribute, LPCVOID pvAttribute, DWORD cbAttribute);
- typedef HRESULT (WINAPI*DwmSetWindowAttributeProc)(HWND hWnd, DWORD dwAttribute, LPCVOID pvAttribute, DWORD cbAttribute);
- typedef HRESULT (WINAPI*DwmInvalidateIconicBitmapsProc)(HWND hWnd);
- typedef HRESULT (WINAPI*DwmDefWindowProcProc)(HWND hWnd, UINT msg, LPARAM lParam, WPARAM wParam, LRESULT *aRetValue);
- typedef HRESULT (WINAPI*DwmGetCompositionTimingInfoProc)(HWND hWnd, DWM_TIMING_INFO *info);
- typedef HRESULT (WINAPI*DwmFlushProc)(void);
-
- static DwmExtendFrameIntoClientAreaProc dwmExtendFrameIntoClientAreaPtr;
- static DwmIsCompositionEnabledProc dwmIsCompositionEnabledPtr;
- static DwmSetIconicThumbnailProc dwmSetIconicThumbnailPtr;
- static DwmSetIconicLivePreviewBitmapProc dwmSetIconicLivePreviewBitmapPtr;
- static DwmGetWindowAttributeProc dwmGetWindowAttributePtr;
- static DwmSetWindowAttributeProc dwmSetWindowAttributePtr;
- static DwmInvalidateIconicBitmapsProc dwmInvalidateIconicBitmapsPtr;
- static DwmDefWindowProcProc dwmDwmDefWindowProcPtr;
- static DwmGetCompositionTimingInfoProc dwmGetCompositionTimingInfoPtr;
- static DwmFlushProc dwmFlushProcPtr;
-
static void Initialize();
static bool ShouldHideScrollbars();
@@ -529,12 +496,6 @@ private:
REFIID riid,
void **ppv);
static SHCreateItemFromParsingNamePtr sCreateItemFromParsingName;
- typedef HRESULT (WINAPI * SHGetKnownFolderPathPtr)(REFKNOWNFOLDERID rfid,
- DWORD dwFlags,
- HANDLE hToken,
- PWSTR *ppszPath);
- static SHGetKnownFolderPathPtr sGetKnownFolderPath;
-
static void GetWhitelistedPaths(
nsTArray<mozilla::Pair<nsString,nsDependentString>>& aOutput);
};
diff --git a/widget/windows/nsAppShell.cpp b/widget/windows/nsAppShell.cpp
index c3e99b2d3..e63d57d89 100644
--- a/widget/windows/nsAppShell.cpp
+++ b/widget/windows/nsAppShell.cpp
@@ -53,9 +53,9 @@ public:
NS_IMETHOD Notify(nsITimer *timer) override {
WAKE_LOCK_LOG("WinWakeLock: periodic timer fired");
- ResetScreenSaverTimeout();
return NS_OK;
}
+
private:
~WinWakeLockListener() {}
@@ -67,75 +67,15 @@ private:
// "locked-foreground" notifications when multipe wake locks are held.
if (aState.EqualsASCII("locked-foreground")) {
WAKE_LOCK_LOG("WinWakeLock: Blocking screen saver");
- // We block the screen saver by periodically resetting the screen
- // saver timeout.
- StartTimer();
- // Prevent the display turning off. On Win7 and later this also
- // blocks the screen saver, but we need the timer started above
- // to block on Win XP and Vista.
+ // Prevent the display turning off.
SetThreadExecutionState(ES_DISPLAY_REQUIRED|ES_CONTINUOUS);
} else {
WAKE_LOCK_LOG("WinWakeLock: Unblocking screen saver");
- // Re-enable screen saver.
- StopTimer();
// Unblock display turning off.
SetThreadExecutionState(ES_CONTINUOUS);
}
return NS_OK;
}
-
- void StartTimer() {
- ResetScreenSaverTimeout();
- MOZ_ASSERT(!mTimer);
- if (mTimer) {
- return;
- }
-
- nsresult rv;
- nsCOMPtr<nsITimer> timer = do_CreateInstance(NS_TIMER_CONTRACTID, &rv);
- if (NS_FAILED(rv)) {
- NS_WARNING("Failed to create screen saver timeout reset timer");
- return;
- }
- // The minimum screensaver timeout that can be specified with Windows' UI
- // is 60 seconds. We set a timer to re-jig the screen saver 10 seconds
- // before we expect the timer to run out, but always at least in 1 second
- // intervals. We reset the timer at a max of 50 seconds, so that if the
- // user changes the timeout using the UI, we won't be caught out.
- int32_t timeout = std::max(std::min(50, (int32_t)mScreenSaverTimeout - 10), 1);
- uint32_t timeoutMs = (uint32_t)timeout * 1000;
- WAKE_LOCK_LOG("WinWakeLock: Setting periodic timer for %d ms", timeoutMs);
- rv = timer->InitWithCallback(this,
- timeoutMs,
- nsITimer::TYPE_REPEATING_SLACK);
- if (NS_FAILED(rv)) {
- NS_WARNING("Failed to initialize screen saver timeout reset timer");
- return;
- }
-
- mTimer = timer.forget();
- }
-
- void StopTimer() {
- WAKE_LOCK_LOG("WinWakeLock: StopTimer()");
- if (!mTimer) {
- return;
- }
- mTimer->Cancel();
- mTimer = nullptr;
- }
-
- // Resets the operating system's timeout for when to disable the screen.
- // Called periodically to keep the screensaver off.
- void ResetScreenSaverTimeout() {
- if (SystemParametersInfo(SPI_GETSCREENSAVETIMEOUT, 0, &mScreenSaverTimeout, 0)) {
- SystemParametersInfo(SPI_SETSCREENSAVETIMEOUT, mScreenSaverTimeout, NULL, 0);
- }
- WAKE_LOCK_LOG("WinWakeLock: ResetScreenSaverTimeout() mScreenSaverTimeout=%d", mScreenSaverTimeout);
- }
-
- UINT mScreenSaverTimeout = 60;
- nsCOMPtr<nsITimer> mTimer;
};
NS_IMPL_ISUPPORTS(WinWakeLockListener, nsIDOMMozWakeLockListener, nsITimerCallback)
diff --git a/widget/windows/nsFilePicker.cpp b/widget/windows/nsFilePicker.cpp
index 4e942968a..53824b93f 100644
--- a/widget/windows/nsFilePicker.cpp
+++ b/widget/windows/nsFilePicker.cpp
@@ -220,7 +220,7 @@ STDMETHODIMP nsFilePicker::QueryInterface(REFIID refiid, void** ppvResult)
/*
- * Vista+ callbacks
+ * Callbacks
*/
HRESULT
diff --git a/widget/windows/nsUXThemeData.cpp b/widget/windows/nsUXThemeData.cpp
index 4d9ac9570..ce2777585 100644
--- a/widget/windows/nsUXThemeData.cpp
+++ b/widget/windows/nsUXThemeData.cpp
@@ -156,10 +156,10 @@ nsUXThemeData::UpdateTitlebarInfo(HWND aWnd)
if (!sTitlebarInfoPopulatedAero && nsUXThemeData::CheckForCompositor()) {
RECT captionButtons;
- if (SUCCEEDED(WinUtils::dwmGetWindowAttributePtr(aWnd,
- DWMWA_CAPTION_BUTTON_BOUNDS,
- &captionButtons,
- sizeof(captionButtons)))) {
+ if (SUCCEEDED(DwmGetWindowAttribute(aWnd,
+ DWMWA_CAPTION_BUTTON_BOUNDS,
+ &captionButtons,
+ sizeof(captionButtons)))) {
sCommandButtons[CMDBUTTONIDX_BUTTONBOX].cx = captionButtons.right - captionButtons.left - 3;
sCommandButtons[CMDBUTTONIDX_BUTTONBOX].cy = (captionButtons.bottom - captionButtons.top) - 1;
sTitlebarInfoPopulatedAero = true;
@@ -293,8 +293,8 @@ bool nsUXThemeData::IsHighContrastOn()
bool nsUXThemeData::CheckForCompositor(bool aUpdateCache)
{
static BOOL sCachedValue = FALSE;
- if (aUpdateCache && WinUtils::dwmIsCompositionEnabledPtr) {
- WinUtils::dwmIsCompositionEnabledPtr(&sCachedValue);
+ if (aUpdateCache) {
+ DwmIsCompositionEnabled(&sCachedValue);
}
return sCachedValue;
}
diff --git a/widget/windows/nsWindow.cpp b/widget/windows/nsWindow.cpp
index 122d18686..907d8b9a5 100644
--- a/widget/windows/nsWindow.cpp
+++ b/widget/windows/nsWindow.cpp
@@ -846,9 +846,9 @@ nsWindow::Create(nsIWidget* aParent,
return NS_ERROR_FAILURE;
}
- if (mIsRTL && WinUtils::dwmSetWindowAttributePtr) {
+ if (mIsRTL) {
DWORD dwAttribute = TRUE;
- WinUtils::dwmSetWindowAttributePtr(mWnd, DWMWA_NONCLIENT_RTL_LAYOUT, &dwAttribute, sizeof dwAttribute);
+ DwmSetWindowAttribute(mWnd, DWMWA_NONCLIENT_RTL_LAYOUT, &dwAttribute, sizeof dwAttribute);
}
if (!IsPlugin() &&
@@ -3113,8 +3113,8 @@ void nsWindow::UpdateGlass()
// Extends the window frame behind the client area
if (nsUXThemeData::CheckForCompositor()) {
- WinUtils::dwmExtendFrameIntoClientAreaPtr(mWnd, &margins);
- WinUtils::dwmSetWindowAttributePtr(mWnd, DWMWA_NCRENDERING_POLICY, &policy, sizeof policy);
+ DwmExtendFrameIntoClientArea(mWnd, &margins);
+ DwmSetWindowAttribute(mWnd, DWMWA_NCRENDERING_POLICY, &policy, sizeof policy);
}
}
#endif
@@ -4961,7 +4961,7 @@ nsWindow::ProcessMessage(UINT msg, WPARAM& wParam, LPARAM& lParam,
/* We don't do this for win10 glass with a custom titlebar,
* in order to avoid the caption buttons breaking. */
!(IsWin10OrLater() && HasGlass()) &&
- WinUtils::dwmDwmDefWindowProcPtr(mWnd, msg, wParam, lParam, &dwmHitResult)) {
+ DwmDefWindowProc(mWnd, msg, wParam, lParam, &dwmHitResult)) {
*aRetValue = dwmHitResult;
return true;
}
diff --git a/xpcom/glue/nsBaseHashtable.h b/xpcom/glue/nsBaseHashtable.h
index f52df3dd1..f074037f3 100644
--- a/xpcom/glue/nsBaseHashtable.h
+++ b/xpcom/glue/nsBaseHashtable.h
@@ -59,6 +59,7 @@ public:
typedef nsBaseHashtableET<KeyClass, DataType> EntryType;
using nsTHashtable<EntryType>::Contains;
+ using nsTHashtable<EntryType>::IsEmpty;
nsBaseHashtable() {}
explicit nsBaseHashtable(uint32_t aInitLength)