Resize on video loaded and when results are already rendered.

pull/1/head
Thomas Marstrander 2015-07-08 11:01:20 +02:00
parent c282dbf72f
commit b02fe7c668
1 changed files with 7 additions and 2 deletions

View File

@ -234,6 +234,7 @@ H5P.QuestionSet = function (options, contentId) {
var _displayEndGame = function () {
if (rendered) {
$myDom.children().hide().filter('.questionset-results').show();
self.trigger('resize');
return;
}
//Remove old score screen.
@ -305,6 +306,10 @@ H5P.QuestionSet = function (options, contentId) {
}
});
video.attach($videoContainer);
// Resize on video loaded
video.on('loaded', function () {
self.trigger('resize');
});
video.play();
if (params.endGame.skipButtonText) {