Merge pull request #118 from anthonylavado/fix-safari-pip
Enable and fix PiP for Safari
This commit is contained in:
@@ -1443,10 +1443,7 @@ define(['browser', 'require', 'events', 'apphost', 'loading', 'dom', 'playbackMa
|
||||
var list = [];
|
||||
|
||||
var video = document.createElement('video');
|
||||
//if (video.webkitSupportsPresentationMode && video.webkitSupportsPresentationMode('picture-in-picture') && typeof video.webkitSetPresentationMode === "function") {
|
||||
// list.push('PictureInPicture');
|
||||
//}
|
||||
if (document.pictureInPictureEnabled) {
|
||||
if (video.webkitSupportsPresentationMode && typeof video.webkitSetPresentationMode === "function" || document.pictureInPictureEnabled) {
|
||||
list.push('PictureInPicture');
|
||||
}
|
||||
else if (browser.ipad) {
|
||||
@@ -1849,4 +1846,4 @@ define(['browser', 'require', 'events', 'apphost', 'loading', 'dom', 'playbackMa
|
||||
}
|
||||
|
||||
return HtmlVideoPlayer;
|
||||
});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user