bigscreen-player
Advanced tools
Comparing version 4.1.1 to 4.2.0
{ | ||
"name": "bigscreen-player", | ||
"version": "4.1.1", | ||
"version": "4.2.0", | ||
"description": "Simplified media playback for bigscreen devices.", | ||
@@ -5,0 +5,0 @@ "main": "script/bigscreenplayer.js", |
@@ -15,5 +15,6 @@ define('bigscreenplayer/bigscreenplayer', | ||
'bigscreenplayer/version', | ||
'bigscreenplayer/resizer' | ||
'bigscreenplayer/resizer', | ||
'bigscreenplayer/readyhelper' | ||
], | ||
function (MediaState, PlayerComponent, PauseTriggers, DynamicWindowUtils, WindowTypes, MockBigscreenPlayer, Plugins, Chronicle, DebugTool, SlidingWindowUtils, MediaSources, Version, Resizer) { | ||
function (MediaState, PlayerComponent, PauseTriggers, DynamicWindowUtils, WindowTypes, MockBigscreenPlayer, Plugins, Chronicle, DebugTool, SlidingWindowUtils, MediaSources, Version, Resizer, ReadyHelper) { | ||
'use strict'; | ||
@@ -24,2 +25,3 @@ function BigscreenPlayer () { | ||
var subtitleCallbacks = []; | ||
var playerReadyCallback; | ||
var mediaKind; | ||
@@ -37,2 +39,3 @@ var initialPlaybackTimeEpoch; | ||
var subtitlesHidden; | ||
var readyHelper; | ||
@@ -86,2 +89,6 @@ var END_OF_STREAM_TOLERANCE = 10; | ||
} | ||
if (playerComponent && readyHelper) { | ||
readyHelper.callbackWhenReady(evt); | ||
} | ||
} | ||
@@ -101,3 +108,3 @@ | ||
function bigscreenPlayerDataLoaded (bigscreenPlayerData, enableSubtitles, successCallback) { | ||
function bigscreenPlayerDataLoaded (bigscreenPlayerData, enableSubtitles) { | ||
if (windowType !== WindowTypes.STATIC) { | ||
@@ -115,2 +122,9 @@ bigscreenPlayerData.time = mediaSources.time(); | ||
readyHelper = new ReadyHelper( | ||
bigscreenPlayerData.initialPlaybackTime, | ||
windowType, | ||
PlayerComponent.getLiveSupport(), | ||
playerReadyCallback | ||
); | ||
playerComponent = new PlayerComponent( | ||
@@ -128,6 +142,2 @@ playbackElement, | ||
} | ||
if (successCallback) { | ||
successCallback(); | ||
} | ||
} | ||
@@ -176,6 +186,7 @@ | ||
} | ||
playerReadyCallback = callbacks.onSuccess; | ||
var mediaSourceCallbacks = { | ||
onSuccess: function () { | ||
bigscreenPlayerDataLoaded(bigscreenPlayerData, enableSubtitles, callbacks.onSuccess); | ||
bigscreenPlayerDataLoaded(bigscreenPlayerData, enableSubtitles); | ||
}, | ||
@@ -182,0 +193,0 @@ onError: function (error) { |
define('bigscreenplayer/version', | ||
function () { | ||
return '4.1.1'; | ||
return '4.2.0'; | ||
} | ||
); |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
292324
57
7579