Bug 1362212 - Add chromeonly HTMLMediaElement.reportCanPlayTelemetry. r=bz
This enables the Firefox front end code to call into Gecko to direct it to report
telemetry as to whether we have available platform decoders at an opportune moment
where doing so is unlikely to cause jank.
Gecko can then dispatch a task to collect this information on a non-main thread
as in order to determine whether we have platform decoders requires us to load
shared libraries from disk, which can cause jank.
MozReview-Commit-ID: GkQEAqWc1aQ
--- a/dom/webidl/HTMLMediaElement.webidl
+++ b/dom/webidl/HTMLMediaElement.webidl
@@ -133,16 +133,19 @@ partial interface HTMLMediaElement {
// player interfaces to display the song title, artist, etc.
[Throws]
object? mozGetMetadata();
// Mozilla extension: provides access to the fragment end time if
// the media element has a fragment URI for the currentSrc, otherwise
// it is equal to the media duration.
readonly attribute double mozFragmentEnd;
+
+ [ChromeOnly]
+ void reportCanPlayTelemetry();
};
// Encrypted Media Extensions
partial interface HTMLMediaElement {
readonly attribute MediaKeys? mediaKeys;
// void, not any: https://www.w3.org/Bugs/Public/show_bug.cgi?id=26457
[NewObject]