diff --git a/dom/base/nsDocument.cpp b/dom/base/nsDocument.cpp index 450e78912408..b59060e25386 100644 --- a/dom/base/nsDocument.cpp +++ b/dom/base/nsDocument.cpp @@ -2687,7 +2687,7 @@ WarnIfSandboxIneffective(nsIDocShell* aDocShell, } bool -nsDocument::IsSynthesized() { +nsIDocument::IsSynthesized() { nsCOMPtr internalChan = do_QueryInterface(mChannel); bool synthesized = false; if (internalChan) { @@ -12250,7 +12250,7 @@ ReportExternalResourceUseCounters(nsIDocument* aDocument, void* aData) } void -nsDocument::ReportUseCounters(UseCounterReportKind aKind) +nsIDocument::ReportUseCounters(UseCounterReportKind aKind) { static const bool sDebugUseCounters = false; if (mReportedUseCounters) { diff --git a/dom/base/nsDocument.h b/dom/base/nsDocument.h index 17986633f57f..e3a6ea2a1770 100644 --- a/dom/base/nsDocument.h +++ b/dom/base/nsDocument.h @@ -206,22 +206,6 @@ public: nsRadioGroupStruct* GetRadioGroup(const nsAString& aName) const; nsRadioGroupStruct* GetOrCreateRadioGroup(const nsAString& aName); - enum class UseCounterReportKind { - // Flush the document's use counters only; the use counters for any - // external resource documents will be flushed when the external - // resource documents themselves are destroyed. - eDefault, - - // Flush use counters for the document and for its external resource - // documents. (Should only be necessary for tests, where we need - // flushing to happen synchronously and deterministically.) - eIncludeExternalResources, - }; - - void ReportUseCounters(UseCounterReportKind aKind = UseCounterReportKind::eDefault); - - bool IsSynthesized(); - // Check whether shadow DOM is enabled for the global of aObject. static bool IsShadowDOMEnabled(JSContext* aCx, JSObject* aObject); // Check whether shadow DOM is enabled for the document this node belongs to. diff --git a/dom/base/nsIDocument.h b/dom/base/nsIDocument.h index 8eb049fdfc02..c07399b2d7a9 100644 --- a/dom/base/nsIDocument.h +++ b/dom/base/nsIDocument.h @@ -3488,6 +3488,22 @@ public: bool DidFireDOMContentLoaded() const { return mDidFireDOMContentLoaded; } + bool IsSynthesized(); + + enum class UseCounterReportKind { + // Flush the document's use counters only; the use counters for any + // external resource documents will be flushed when the external + // resource documents themselves are destroyed. + eDefault, + + // Flush use counters for the document and for its external resource + // documents. (Should only be necessary for tests, where we need + // flushing to happen synchronously and deterministically.) + eIncludeExternalResources, + }; + + void ReportUseCounters(UseCounterReportKind aKind = UseCounterReportKind::eDefault); + void SetDocumentUseCounter(mozilla::UseCounter aUseCounter) { if (!mUseCounters[aUseCounter]) {