Bug 1851959 - Remove dom.picture_source_dimension_attributes.enabled pref r=emilio

Differential Revision: https://phabricator.services.mozilla.com/D188317
This commit is contained in:
Gregory Pappas 2023-09-15 15:58:17 +00:00
Родитель e5c7fdab51
Коммит 7885cb3891
6 изменённых файлов: 5 добавлений и 22 удалений

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

@ -74,8 +74,7 @@ bool HTMLSourceElement::ParseAttribute(int32_t aNamespaceID, nsAtom* aAttribute,
const nsAString& aValue,
nsIPrincipal* aMaybeScriptedPrincipal,
nsAttrValue& aResult) {
if (StaticPrefs::dom_picture_source_dimension_attributes_enabled() &&
aNamespaceID == kNameSpaceID_None &&
if (aNamespaceID == kNameSpaceID_None &&
(aAttribute == nsGkAtoms::width || aAttribute == nsGkAtoms::height)) {
return aResult.ParseHTMLDimension(aValue);
}
@ -133,8 +132,7 @@ void HTMLSourceElement::AfterSetAttr(int32_t aNameSpaceID, nsAtom* aName,
NS_GetSourceForMediaSourceURI(uri, getter_AddRefs(mSrcMediaSource));
}
}
} else if (StaticPrefs::dom_picture_source_dimension_attributes_enabled() &&
aNameSpaceID == kNameSpaceID_None &&
} else if (aNameSpaceID == kNameSpaceID_None &&
IsAttributeMappedToImages(aName) && IsInPicture()) {
BuildMappedAttributesForImage();
@ -187,10 +185,6 @@ JSObject* HTMLSourceElement::WrapNode(JSContext* aCx,
void HTMLSourceElement::BuildMappedAttributesForImage() {
MOZ_ASSERT(NS_IsMainThread());
if (!StaticPrefs::dom_picture_source_dimension_attributes_enabled()) {
return;
}
mMappedAttributesForImage = nullptr;
Document* document = GetComposedDoc();

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

@ -28,10 +28,8 @@ partial interface HTMLSourceElement {
attribute DOMString sizes;
[CEReactions, SetterThrows]
attribute DOMString media;
[CEReactions, SetterThrows,
Pref="dom.picture_source_dimension_attributes.enabled"]
[CEReactions, SetterThrows]
attribute unsigned long width;
[CEReactions, SetterThrows,
Pref="dom.picture_source_dimension_attributes.enabled"]
[CEReactions, SetterThrows]
attribute unsigned long height;
};

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

@ -3285,13 +3285,6 @@
value: false
mirror: always
# This enables width and height attributes and map these attributes to img
# element's style.
- name: dom.picture_source_dimension_attributes.enabled
type: bool
value: true
mirror: always
# Is support for Element.requestPointerLock enabled?
# This is added for accessibility purpose. When user has no way to exit
# pointer lock (e.g. no keyboard available), they can use this pref to

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

@ -1,4 +1,4 @@
prefs: [dom.security.featurePolicy.experimental.enabled:true, dom.security.featurePolicy.header.enabled:true, dom.security.featurePolicy.webidl.enabled:true, dom.forms.inputmode:true, dom.forms.autocapitalize:true, dom.picture_source_dimension_attributes.enabled:true]
prefs: [dom.security.featurePolicy.experimental.enabled:true, dom.security.featurePolicy.header.enabled:true, dom.security.featurePolicy.webidl.enabled:true, dom.forms.inputmode:true, dom.forms.autocapitalize:true]
[idlharness.https.html?exclude=(Document|Window|HTML.*)]
[AudioTrack interface: existence and properties of interface prototype object]
expected: FAIL

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

@ -1,5 +1,4 @@
[dimension-attributes.html]
prefs: [dom.picture_source_dimension_attributes.enabled:true]
[<col width="0"> mapping to <col> width property]
bug: https://github.com/whatwg/html/issues/4717

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

@ -1,4 +1,3 @@
[picture-aspect-ratio.html]
prefs: [dom.picture_source_dimension_attributes.enabled:true]
expected:
if (os == "android") and fission: [OK, TIMEOUT]