Bug 1924803 - Remove warning when CSS zoom is used r=emilio

The CSS warning for the zoom property is no longer necessary now that zoom is supported.

Differential Revision: https://phabricator.services.mozilla.com/D225693
This commit is contained in:
Julian Descottes 2024-10-16 18:01:21 +00:00
parent f8bc57bbb1
commit 005e261054
4 changed files with 0 additions and 29 deletions

View File

@ -1402,7 +1402,6 @@ Document::Document(const char* aContentType)
mTooDeepWriteRecursion(false),
mPendingMaybeEditingStateChanged(false),
mHasBeenEditable(false),
mHasWarnedAboutZoom(false),
mIsRunningExecCommandByContent(false),
mIsRunningExecCommandByChromeOrAddon(false),
mSetCompleteAfterDOMContentLoaded(false),
@ -14560,22 +14559,6 @@ void Document::EvaluateMediaQueriesAndReportChanges(bool aRecurse) {
}
}
void Document::MaybeWarnAboutZoom() {
if (mHasWarnedAboutZoom) {
return;
}
const bool usedZoom = Servo_IsPropertyIdRecordedInUseCounter(
mStyleUseCounters.get(), eCSSProperty_zoom);
if (!usedZoom) {
return;
}
mHasWarnedAboutZoom = true;
nsContentUtils::ReportToConsole(nsIScriptError::warningFlag, "Layout"_ns,
this, nsContentUtils::eLAYOUT_PROPERTIES,
"ZoomPropertyWarning");
}
nsIHTMLCollection* Document::Children() {
if (!mChildrenCollection) {
mChildrenCollection =

View File

@ -3567,8 +3567,6 @@ class Document : public nsINode,
}
void SetDevToolsWatchingDOMMutations(bool aValue);
void MaybeWarnAboutZoom();
// https://drafts.csswg.org/cssom-view/#evaluate-media-queries-and-report-changes
void EvaluateMediaQueriesAndReportChanges(bool aRecurse);
@ -4889,12 +4887,6 @@ class Document : public nsINode,
// eDesignMode or eContentEditable.
bool mHasBeenEditable : 1;
// Whether we've warned about the CSS zoom property.
//
// We don't use the general deprecated operation mechanism for this because we
// also record this as a `CountedUnknownProperty`.
bool mHasWarnedAboutZoom : 1;
// While we're handling an execCommand call by web app, set
// to true.
bool mIsRunningExecCommandByContent : 1;

View File

@ -30,9 +30,6 @@ CompositorAnimationWarningOpacityFrameInactive=Animation cannot be run on the co
CompositorAnimationWarningHasRenderingObserver=Animation cannot be run on the compositor because the element has rendering observers (-moz-element or SVG clipping/masking)
CompositorAnimationWarningHasCurrentColor=Animations of background-color cannot be run on the compositor with current-color keyframe.
## LOCALIZATION NOTE: Do not translate zoom, calc(), "transform", "transform-origin: 0 0"
ZoomPropertyWarning=This page uses the non standard property “zoom”. Consider using calc() in the relevant property values, or using “transform” along with “transform-origin: 0 0”.
## LOCALIZATION NOTE(PrincipalWritingModePropagationWarning):
## Do not translate <html>, <body>, CSS, "writing-mode", "direction", "text-orientation", :root, and "The Principal Writing Mode" because they are technical terms.
PrincipalWritingModePropagationWarning=When rendering the <html> element, the used values of CSS properties “writing-mode”, “direction”, and “text-orientation” on the <html> element are taken from the computed values of the <body> element, not from the <html> elements own values. Consider setting these properties on the :root CSS pseudo-class. For more information see “The Principal Writing Mode” in https://www.w3.org/TR/css-writing-modes-3/#principal-flow

View File

@ -991,7 +991,6 @@ static void RecordUseCountersIfNeeded(Document* aDoc,
return;
}
Servo_UseCounters_Merge(docCounters, sheetCounters);
aDoc->MaybeWarnAboutZoom();
}
bool Loader::MaybePutIntoLoadsPerformed(SheetLoadData& aLoadData) {