From 0c5aacfa241acd02e15145cbe8434a22110e66b8 Mon Sep 17 00:00:00 2001 From: Frode Petterson Date: Tue, 24 Feb 2015 16:02:14 +0100 Subject: [PATCH] Fixed old fullscreen exit in iframe. --- js/h5p.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/js/h5p.js b/js/h5p.js index 9d40789..3042977 100644 --- a/js/h5p.js +++ b/js/h5p.js @@ -290,9 +290,11 @@ H5P.fullScreen = function ($element, instance, exitCallback, body) { H5P.isFullscreen = true; H5P.exitFullScreen = function () { window.top.H5P.exitFullScreen(); + }; + H5P.on(instance, 'exitFullScreen', function () { H5P.isFullscreen = false; H5P.exitFullScreen = undefined; - }; + }); return; }