forked from mirrors/gecko-dev
- Create a local page we will access via an about: URL - In that page, demonstrate how to do some stuff, then fire a custom event indicating its stuff is done _and_ return complex data in that event. console.log() didn't seem to be visible in the HiddenWindow, so I also piped out debug strings for development purposes, so they can be console.logged in the Service, where we can see them. - Instead of listening for DOMContentLoaded/pageshow, instead listen for the new CustomEvent. - In UserCharacteristicsPageService, receive the data from the page and populate the appropriate Glean metrics - Refactor the calling of nsUserCharacteristics::PopulateData() and SubmitPing(). Now we call PopulateDataAndEventuallySubmit() which will eventually call SubmitPing after our promise is resolved. - To make it a little cleaner (so ContentPageStuff() isn't calling SubmitPing()) we return the promise out of ContentPageStuff() that PopulateDataAndEventuallySubmit() will await and then call SubmitPing() when that promise resolves Differential Revision: https://phabricator.services.mozilla.com/D203055 |
||
|---|---|---|
| .. | ||
| crashtests | ||
| BaseHistory.cpp | ||
| BaseHistory.h | ||
| BrowsingContext.cpp | ||
| BrowsingContext.h | ||
| BrowsingContextGroup.cpp | ||
| BrowsingContextGroup.h | ||
| BrowsingContextWebProgress.cpp | ||
| BrowsingContextWebProgress.h | ||
| CanonicalBrowsingContext.cpp | ||
| CanonicalBrowsingContext.h | ||
| ChildProcessChannelListener.cpp | ||
| ChildProcessChannelListener.h | ||
| IHistory.h | ||
| LoadContext.cpp | ||
| LoadContext.h | ||
| metrics.yaml | ||
| moz.build | ||
| nsAboutRedirector.cpp | ||
| nsAboutRedirector.h | ||
| nsCTooltipTextProvider.h | ||
| nsDocShell.cpp | ||
| nsDocShell.h | ||
| nsDocShellEditorData.cpp | ||
| nsDocShellEditorData.h | ||
| nsDocShellEnumerator.cpp | ||
| nsDocShellEnumerator.h | ||
| nsDocShellLoadState.cpp | ||
| nsDocShellLoadState.h | ||
| nsDocShellLoadTypes.h | ||
| nsDocShellTelemetryUtils.cpp | ||
| nsDocShellTelemetryUtils.h | ||
| nsDocShellTreeOwner.cpp | ||
| nsDocShellTreeOwner.h | ||
| nsDSURIContentListener.cpp | ||
| nsDSURIContentListener.h | ||
| nsIDocShell.idl | ||
| nsIDocShellTreeItem.idl | ||
| nsIDocShellTreeOwner.idl | ||
| nsIDocumentLoaderFactory.idl | ||
| nsIDocumentViewer.idl | ||
| nsIDocumentViewerEdit.idl | ||
| nsILoadContext.idl | ||
| nsILoadURIDelegate.idl | ||
| nsIPrivacyTransitionObserver.idl | ||
| nsIReflowObserver.idl | ||
| nsIRefreshURI.idl | ||
| nsIScrollObserver.h | ||
| nsITooltipListener.idl | ||
| nsITooltipTextProvider.idl | ||
| nsIURIFixup.idl | ||
| nsIWebNavigation.idl | ||
| nsIWebNavigationInfo.idl | ||
| nsIWebPageDescriptor.idl | ||
| nsPingListener.cpp | ||
| nsPingListener.h | ||
| nsRefreshTimer.cpp | ||
| nsRefreshTimer.h | ||
| nsWebNavigationInfo.cpp | ||
| nsWebNavigationInfo.h | ||
| SerializedLoadContext.cpp | ||
| SerializedLoadContext.h | ||
| SyncedContext.h | ||
| SyncedContextInlines.h | ||
| URIFixup.sys.mjs | ||
| WindowContext.cpp | ||
| WindowContext.h | ||