diff --git a/content/base/public/nsDeprecatedOperationList.h b/content/base/public/nsDeprecatedOperationList.h index af6a98d59844..e31a2448a00e 100644 --- a/content/base/public/nsDeprecatedOperationList.h +++ b/content/base/public/nsDeprecatedOperationList.h @@ -28,3 +28,4 @@ DEPRECATED_OPERATION(NoExposedProps) DEPRECATED_OPERATION(MutationEvent) DEPRECATED_OPERATION(MozSlice) DEPRECATED_OPERATION(Components) +DEPRECATED_OPERATION(PrefixedVisibilityAPI) diff --git a/content/base/src/nsDocument.cpp b/content/base/src/nsDocument.cpp index 842f5b0a6b46..e2bc9b7e32c0 100644 --- a/content/base/src/nsDocument.cpp +++ b/content/base/src/nsDocument.cpp @@ -9527,6 +9527,7 @@ nsDocument::PostVisibilityUpdateEvent() NS_IMETHODIMP nsDocument::GetMozHidden(bool* aHidden) { + WarnOnceAbout(ePrefixedVisibilityAPI); return GetHidden(aHidden); } @@ -9540,6 +9541,7 @@ nsDocument::GetHidden(bool* aHidden) NS_IMETHODIMP nsDocument::GetMozVisibilityState(nsAString& aState) { + WarnOnceAbout(ePrefixedVisibilityAPI); return GetVisibilityState(aState); } diff --git a/dom/locales/en-US/chrome/dom/dom.properties b/dom/locales/en-US/chrome/dom/dom.properties index ca38638a3718..cad8698cfbe1 100644 --- a/dom/locales/en-US/chrome/dom/dom.properties +++ b/dom/locales/en-US/chrome/dom/dom.properties @@ -114,3 +114,5 @@ MutationEventWarning=Use of Mutation Events is deprecated. Use MutationObserver MozSliceWarning=Use of mozSlice on the Blob object is deprecated. Use slice instead. # LOCALIZATION NOTE: Do not translate "Components" ComponentsWarning=The Components object is deprecated. It will soon be removed. +# LOCALIZATION NOTE: Do not translate "mozHidden", "mozVisibilityState", "hidden", or "visibilityState" +PrefixedVisibilityApiWarning='mozHidden' and 'mozVisibilityState' are deprecated. Please use the unprefixed 'hidden' and 'visibilityState' instead.