From 610fd5a7c3f2e60b7766d2d867712f70bfce9f52 Mon Sep 17 00:00:00 2001 From: calzoneman Date: Sun, 16 Nov 2014 11:19:14 -0600 Subject: [PATCH] Handle #412 --- www/js/util.js | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/www/js/util.js b/www/js/util.js index a3a32f34..d205cc6f 100644 --- a/www/js/util.js +++ b/www/js/util.js @@ -1657,15 +1657,16 @@ function handleVideoResize() { var intv, ticks = 0; var resize = function () { if (++ticks > 10) clearInterval(intv); - if ($("#ytapiplayer").height() === 0) return; + if ($("#ytapiplayer").parent().height() === 0) return; clearInterval(intv); - var height = $("#ytapiplayer").height() - $("#chatline").outerHeight() - 2; + var responsiveFrame = $("#ytapiplayer").parent(); + var height = responsiveFrame.outerHeight() - $("#chatline").outerHeight() - 2; $("#messagebuffer").height(height); $("#userlist").height(height); - $("#ytapiplayer").attr("height", VHEIGHT = $("#ytapiplayer").height()); - $("#ytapiplayer").attr("width", VWIDTH = $("#ytapiplayer").width()); + $("#ytapiplayer").attr("height", VHEIGHT = responsiveFrame.outerHeight()); + $("#ytapiplayer").attr("width", VWIDTH = responsiveFrame.outerWidth()); }; if ($("#ytapiplayer").height() > 0) resize();