Revision 7dbb4b66740563687a254b8e4cd8f36ac836d48f authored by Mike West on 16 August 2018, 13:13:12 UTC, committed by Blink WPT Bot on 16 August 2018, 13:40:45 UTC
This patch removes the 'target' attribute by replacing it with a new 'destination' value that distinguishes between top-level and nested navigations. Spec: https://github.com/mikewest/sec-metadata/commit/de7530709176c56956a5f696b52244f25f86e4fd Bug: 861678, 843478 Change-Id: I2bf5df1b93fb2c7c341cbe6da30d99bb19d40626 Reviewed-on: https://chromium-review.googlesource.com/1172137 Reviewed-by: Kinuko Yasuda <kinuko@chromium.org> Reviewed-by: Philip Jägenstedt <foolip@chromium.org> Commit-Queue: Mike West <mkwst@chromium.org> Cr-Commit-Position: refs/heads/master@{#583605}
1 parent 9762614
media.js
//
// Returns the URI of a supported video source based on the user agent
//
function getVideoURI(base)
{
var extension = '.mp4';
var videotag = document.createElement("video");
if ( videotag.canPlayType &&
videotag.canPlayType('video/ogg; codecs="theora, vorbis"') )
{
extension = '.ogv';
}
return base + extension;
}
//
// Returns the URI of a supported audio source based on the user agent
//
function getAudioURI(base)
{
var extension = '.mp3';
var audiotag = document.createElement("audio");
if ( audiotag.canPlayType &&
audiotag.canPlayType('audio/ogg') )
{
extension = '.oga';
}
return base + extension;
}
function getMediaContentType(url) {
var extension = new URL(url, location).pathname.split(".").pop();
var map = {
"mp4": "video/mp4",
"ogv": "video/ogg",
"mp3": "audio/mp3",
"oga": "audio/ogg",
};
return map[extension];
}
![swh spinner](/static/img/swh-spinner.gif)
Computing file changes ...