From 02d358542536d806fb10bd73359ebbc5f1bb2502 Mon Sep 17 00:00:00 2001 From: Thomas Marstrander Date: Wed, 8 Jul 2015 11:01:20 +0200 Subject: [PATCH] Resize on video loaded and when results are already rendered. (cherry picked from commit b02fe7c) --- js/questionset.js | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/js/questionset.js b/js/questionset.js index c784991..6554bdf 100644 --- a/js/questionset.js +++ b/js/questionset.js @@ -235,6 +235,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. @@ -306,6 +307,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) {